A developer is creating a class Book, that needs to access c

题目
多选题
A developer is creating a class Book, that needs to access class Paper. The Paper class is deployed in a JAR named myLib.jar. Which three, taken independently, will allow the developer to use the Paper class while compiling the Book class?()
A

The JAR file is located at $JAVA_HOME/jre/classes/myLib.jar

B

The JAR file is located at $JAVA_HOME/jre/lib/ext/myLib.jar

C

The JAR file is located at /foo/myLib.jar and a classpath environment variable is set that includes /foo/myLib.jar/Paper.class

D

The JAR file is located at /foo/myLib.jar and a classpath environment variable is set that includes /foo/myLib.jar

E

The JAR file is located at /foo/myLib.jar and the Book class is compiled using javac –cp /foo/myLib.jar/Paper Book.java

F

The JAR file is located at foo/myLib.jar and the Book class is compiled using javac –classpath /foo/myLib.jar Book.java

如果没有搜索结果或未解决您的问题,请直接 联系老师 获取答案。
相似问题和答案

第1题:

Which class of Cisco access points operate under IEEE 802.3af power?()

  • A、Class A
  • B、Class 1
  • C、Class 2
  • D、Class 3
  • E、Class 4

正确答案:D

第2题:

Which declaration prevents creating a subclass of an outer class?()

  • A、 Static class FooBar{}
  • B、 Private class FooBar{}
  • C、 Abstract public class FooBar{}
  • D、 Final public class FooBar{}
  • E、 Final abstract class FooBar{}

正确答案:D

第3题:

如果当前目录是“C:Xaccess\book”,在此目录下还有一个名为“access2000”的文件夹,其中有一个名为“01.htm”的文件,那么这个文件对于当前目录的相对路径是( )。

A.C:\aecess2000\01.htm

B.access\book\access2000\01.htm.

C.CAaecess\book\access2000\01.htm

D.access2000\01.htm


正确答案:D
解析:本题考查绝对路径和相对路径。相对路径和绝对路径的最大区别就是绝对路径是包含盘符的,所以在这4个选项中,选项A和选项C属于绝对路径,选项B和选项D属于相对路径。选项A这个路径访问的是在C盘下 access2000文件夹中的01.btm文件,而不是题目要求的文件;选项B,这个路径是题目要求的文件相对于C盘的相对路径:选项C,这个路径是题目要求的文件的绝对路径;选项D,这个路径是题目要求的文件相对于当前目录的相对路径。答案为D。

第4题:

You want to limit access to a method of a public class to members of the same class. Which access accomplishes this objective?()  

  • A、 public
  • B、 private
  • C、 protected
  • D、 transient
  • E、 default access

正确答案:B

第5题:

An administrator replaced a router with a switch. End users are able to access network shares butare not able to access the Internet. Which of the following is the BEST explanation why the usersare unable to access the Internet?()

  • A、Router routes traffic between different networks and a switch does not
  • B、The new switch is faulty and needs to be replaced and configured correctly
  • C、The firewall needs to be setup to allow traffic to reach the Internet
  • D、The switch needs to be setup to forward data traffic to the Internet

正确答案:A

第6题:

A developer is creating a class Book that needs to access class Paper.The Paper class is deployed in a JARnamedmyLib.jar.Whichthree,taken independently,will allow the developer to use the Paper class while compiling the Book class?()

  • A、The JAR fileis located at$JAVA_HOME/jre/classes/myLib.jar.
  • B、The JAR fileis located at$JAVA_HOME/jre/lib/ext/myLib.jar.
  • C、TheJ AR fileis located at/foo/myLib.jar and aclasspath environment variable is set that includes /foo/myLib.jar/Paper.class.
  • D、The JAR fileis located at/foo/myLib.jar and a classpath environment variable is set that includes/foo/myLib.jar.
  • E、The JAR file is located at/foo/myLib.jar and the Book class is compiled using javac-cp/foo/myLib.jar/Paper Book.java.
  • F、The JAR file is located at/foo/myLib.jar and the Book class is compiled using javac-classpath/foo/myLib.jar Book.java.

正确答案:B,D,F

第7题:

You work as an application developer at Certkiller .com. You are in the process of creating an application for Certkiller .com’s Human Resources department that tracks employee benefits. You have to store current employee data without recompiling the application. You elect to store this employee data as a custom section in the application configuration file. The relevant portion of the application configuration file is shown in the following exhibit: <?xml version="1.0" encoding="utf-8" ?>   You want to use the .NET 2.0 Configuration API to access the custom section. You need to ensure that programmatic access of the EmployeeSection element is enabled. What should you do?()

  • A、 Create a custom section handler class that inherits the ConfigurationSection interface.
  • B、 Add a section element to the EmployeeSection element of the application configuration file.
  • C、 Create a custom section handler class that implements the IConfigurationSectionHandler interface.
  • D、 Add an EmployeeSection element to the configSections element of the application configuration file.
  • E、 Create a custom section handler class that implements the IApplicatioSettingsProvider interface.
  • F、 Add a section element to the configSections element of the application configuration file.

正确答案:A,F

第8题:

如果当前目录是"C:\access\book",在此目录下还有一个名为"access2003"的文件夹,其中有一个名为"01.htm"的文件,那么这个文件对于当前目录的相对路径是( )。

A.C:\access2003\01.htm

B.access\book\access2003\01.htm

C.C:\access\book\access2003\01.htm

D.access2003\01.htm


正确答案:D
解析:在这四个选项中,选项A和选项C属于绝对路径,选项B和选项D属于相对路径。选项A这个路径访问的是在C盘下access2003文件夹中的01.htrn文件,而不是题目要求的文件;选项B,这个路径是题目要求的文件相对于C盘的相对路径;选项C,这个路径是题目要求的文件的绝对路径;选项D,这个路径是题目要求的文件相对于当前目录的相对路径。答案为D。

第9题:

Which two are benefits of fully encapsulating a class?()  

  • A、 Performance of class methods is improved.
  • B、 Implementation details of the class are hidden.
  • C、 Access modifiers can be omitted on class data members.
  • D、 Code that uses the encapsulation class can access data members directly.
  • E、 Internal operation of the class can be modified without impacting clients of that class.

正确答案:B,E

第10题:

You want to limit access to a method of a public class to members of the same class. Which access modifier accomplishes this objective?()  

  • A、 Public
  • B、 Private
  • C、 Protected
  • D、 Transient
  • E、 No access modifier is required

正确答案:B

更多相关问题