COMP 1451 Flashcards

1
Q

What are libraries?

A

Set of dynamically loadable libraries that java can call at runtime - provide set of known facilities, abstract interface to tasks that such as network access that are typically resource heavy on operating system

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

What do you need to know when looking up new classes in Java libraries?

A

You need to know the interface not the implemetnation

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

What are Maps?

A

collections that contain pairs of values of which one is a key and one is value

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

Should fields be private?

A

Heck yes, they should never be public pretty much

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

What is encapsualtion?

A

encapsulation is wrapping code and data together in a single unit. Fully encapsulated objects will have all data members set to private

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

What is Coupling?

A

The degree of direct knowledge that one element has of another or how much a change in A forces change in B

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

Cohesion - what it is?

A

The degree to which a Class has a single purpose. The more cohesive a Class is the easier to it is to maintain and re-use

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

What is refactoring?

A

Making a bucnh of small changes to code without changing what it does

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

What is regression testing?

A

egression testing involves re-running test, Use of a test rig or test harness can relieve some of the burden.

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

What is a test harness?

A

A test class designed to replaces human activity

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

What is method polymorphism?

A

Overloading a constructor

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

What is Dynamic method lookup?

A

The process of determining which method signature is denoted at runtime

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

What is a static reference

A

A declared type of reference

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

What a dynamic reference is?

A

The type of the object a reference points to

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

What does a compiler do?

A

check for static type violations

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

What are the namespaces?

A

Used to organize code into logical groups

17
Q

Why must the package statement be the first statement in the source file?

A

Because the compiler needs to know what the file heirarchy is

18
Q

Are HashMaps a collection?

A

No.

19
Q

What is subtyping?

A

Objects of a subtyype can be used where objects of a supertype are expected

20
Q

What is Casting?

A

When we assign a subtype object address to a supertype reference

21
Q

What is inherited form a super or parent class?

A

all non-private fields methods and constructors

22
Q

What is a concrete class?

A

Has no abstract methods defined

23
Q

What is an interface?

A

Completely abstract class

24
Q

Can a class have multiple parent classes?

A

Oh sure there bud but it must be inherited from interfaces because because that way there is no competing implementation