Question: QUESTION 1 In the following code example, the underlined portion of the statement is what: currentStudent = directory.getStudent ( targetID ) ; An argument A

QUESTION 1
In the following code example, the underlined portion of the statement is what:
currentStudent = directory.getStudent(targetID);
An argument
A return type
An object reference
A method
12 points
QUESTION 2
In the following code example, the underlined portion of the statement is what:
bannerDisplay = session.getUserByID(IDnum).getFirstName()+"\'s recent activity:";
A return type
A method call
String concatenation
An argument
12 points
QUESTION 3
In the following code example, the underlined portion of the statement is what:
currentStudent = directory.getStudent(targetID);
An object reference
A return type
An argument
A method
12 points
QUESTION 4
In the following code example, the underlined portion of the statement is what:
currentStudent = directory.getStudent(targetID);
A method
An object reference
An argument
A return type
12 points
QUESTION 5
What can be said about the following Java statement:
test = new SimpleDate();
A method with no return value is being called.
An object is being flagged for garbage collection.
The default constructor method is being called.
Arguments are being passed to a method.
12 points
QUESTION 6
The arguments (data provided to a method that is called) are enclosed in parenthesis that follow the method name.
True
False
4 points
QUESTION 7
Objects which do not have at least one object reference pointing to them are marked for garbage collection.
True
False
4 points
QUESTION 8
Methods which change the value of an object's instance variables are called accessor methods.
True
False
4 points
QUESTION 9
The return value of a method is indicated by either a data type or class type.
True
False
4 points
QUESTION 10
Methods that change or modify the instance variables of a class are called mutator methods.
True
False
4 points
QUESTION 11
An object reference which has been declared but not yet assigned to an object has the literal value null.
True
False
4 points
QUESTION 12
A constructor method is used to assign initial values to the instance variables of a class.
True
False
4 points
QUESTION 13
To call the default constructor method for a class, it is necessary to pass a comma-separated list of initial data values (called an argument list) to assign to the object.
True
False
4 points
QUESTION 14
Which of the following (select all correct answers) show examples of a method call involving an accessor method:
appointment.setTime(1500);
target = directory.findStudent(ID);
newStudent.changeName("Paul Simon");
String temp = currentStudent.getName();
14 points
QUESTION 15
Which of the following are likely examples of mutator methods? Select all correct answers.
String name = currentUser.getFirstName();
target = database.lookup(userID);
currentUser.changePassword(oldPassword, newPassword, retypedNewPassword);
session.resetSession();

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!