OCJP(310-065)

多选题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 Bookclass?()AThe JAR fi

题目
多选题
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 Bookclass?()
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

参考答案和解析
正确答案: A,D
解析: 暂无解析
如果没有搜索结果,请直接 联系老师 获取答案。
相似问题和答案

第1题:

Click the Exhibit button. Given the fully-qualified class names: com.foo.bar.Dog com.foo.bar.blatz.Book com.bar.Car com.bar.blatz.Sun Which graph represents the correct directory structure for a JAR file from which those classes can be used by the compiler and JVM? ()

A.Jar A

B.Jar B

C.Jar C

D.Jar D

E.Jar E


参考答案:A

第2题:

You work as an application developer at Certkiller .com. Certkiller .com has asked you to develop an application that monitors and controls the activities of a Windows service.You need to use the appropriate class to meet Certkiller .com’s requirements. What should you do?()

  • A、 Use the ServiceBase class.
  • B、 Use the ServiceInstaller class.
  • C、 Use the ServiceManager class.
  • D、 Use the ServiceController class.

正确答案:D

第3题:

You are creating a class that performs complex financial calculations.The class contains a method named GetCurrentRate that retrieves the current interest rate and a variable named currRate that stores the current interest rate.You write serialized representations of the class.You need to write a code segment that updates the currRate variable with the current interest ratewhen an instance of the class is deserialized.Which code segment should you use?()

A.

B.

C.

D.


参考答案:D

第4题:

Given the fully-qualified class names:  com.foo.bar.Dog  com.foo.bar.blatz.Book  com.bar.Car  com.bar.blatz.Sun  Which graph represents the correct directory structure for a JAR file from which those classes can be used by the compiler and JYM?() 

  • A、 Jar A
  • B、 Jar B
  • C、 Jar C
  • D、 Jar D
  • E、 Jar E

正确答案:A

第5题:

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

第6题:

A fire involving trash and paper waste would be classified as a ______.

A.class A

B.class B

C.class C

D.class D


正确答案:A

第7题:

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

正确答案:B,D,F

第8题:

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

第9题:

In which two web application directories can dependent classes and libraries be located? ()

  • A、 /WEB-INF/lib as a JAR file
  • B、 /META-INF/lib as a JAR file
  • C、 /classes as compiled class files
  • D、 /WEB-INF/lib as compiled class files
  • E、 /WEB-INF/classes as compiled class files
  • F、 /META-INF/classes as compiled class files

正确答案:A,E

第10题:

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 -d /foo/myLib.jar Book.java
  • G、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,G

更多相关问题