Chapter 3 Flashcards

1
Q

method

A

a program module that contains a series of statements that carry out a task

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Invoke/call a method

A

execute it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

client method

A

a method that calls another

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Abstraction

A

The programming feature that allows you to use a method name to encapsulate a series of statements

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Method header

A

The first line of the method and contains information about how other methods can interact with it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Declaration

A

Another name for a method header

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

method body

A

Set of statements between curly braces that follow the header and that carry out the method’s actions

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Implementation

A

describes the actions that execute within a method, method body

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Stub

A

A method that contains no statements, programmers create stubs as temporary placeholders during the program development process

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Access modifier (another term)

A

Access spesifier

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

return type

A

Indicates the type of data that is send back to its calling method ofter completion of the method

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

To return a call

A

is to send a call from a called method back to the calling method

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

A fully qualified identifier

A

Includes a class name and a dot before the identifier

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Arguments

A

Are data items sent to methods in a method call

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Parameters

A

Data items received by a method

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Implementation hiding

A

Is a principle of object-oriented programming that describes the encapsulation of method details within a class

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

Interface to a method

A

includes the methods return type, name, arguments. Is the part that the client sees and uses

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

A black box

A

Device that you can use without understanding how it works

19
Q

Local variable

A

Known only within the boundaries of a method

20
Q

A methods signature

A

The combination of the method name and number, types and order of arguements

21
Q

Actual parameters

A

Arguments in a method call

22
Q

Formal parameters

A

The variables in a method declaration that accept the values from actual parameters

23
Q

Return statement

A

ends a method and frequently sends a value from a called method back to the calling method

24
Q

Method type

A

Its return type

25
Q

Unreachable statements

A

those that cannot be executed because the logical path can never encounter them; an unreachable statement causes a compiler error

26
Q

Dead code

A

Is a set of statements that are logically unreachable

27
Q

is-a-relationship

A

Is the relationship between an object and the class of which it is a member

28
Q

Instantiation of a class

A

Is an object; iow, it is one tangible example of a class

29
Q

A class client /class user

A

Is an application or class that instantiates objects of another prewritten class

30
Q

Data fields

A

Data variables declared in a class outside of any method

31
Q

Instance variables

A

Data components of a class

32
Q

Assigning private access to a field

A

No other classes can access the field’s values, and only methods of the same class are allowed to set, get, or otherwise use private variables

33
Q

Information hiding

A

The object-oriented programming principle used when creating private access for data fields; a class’s private data can be changed or manipulated only by a class’s own methods and not by methods that belong to other classes

34
Q

Mutator methods

A

Set values

35
Q

Accessor methods

A

retrieve values

36
Q

Non-static methods

A

those methods used with object instantiations are called instance methods

37
Q

Primary key

A

is a unique identifier for data within a database

38
Q

New operator

A

Allocates the memory needed to hold an object

39
Q

Reference to an object

A

The name for a memory address where the object is held

40
Q

Constructor

A

is a method that establishes an object

41
Q

Default constructer

A

Is one that requires no parameters; if you do not write one, a default constructor is created for a class automatically by Java compiler

42
Q

Abstract data type(ADT)

A

A type whose implementation is hidden and accessed through its public methods

43
Q

Programmer-defined data type

A

One that is created by a programmer and not built into the language