SUBJECTS
|
BROWSE
|
CAREER CENTER
|
POPULAR
|
JOIN
|
LOGIN
Business Skills
|
Soft Skills
|
Basic Literacy
|
Certifications
About
|
Help
|
Privacy
|
Terms
|
Email
Search
Test your basic knowledge |
iOS 5 App Development Objective C
Start Test
Study First
Subjects
:
it-skills
,
apple
Instructions:
Answer 50 questions in 15 minutes.
If you are not ready to take this test, you can
study here
.
Match each statement with the correct term.
Don't refresh. All questions and answers are randomly picked and ordered every time you load a test.
This is a study tool. The 3 wrong answers for each question are randomly chosen from answers to other questions. So, you might find at times the answers obvious, but you will see it re-enforces your understanding as you take the test each time.
1. A block of statements identified by a name that can accept one or more arguments passed to it by value and can optionally return a value
CGFloat
Functions
class
Anytime you call a method with new - alloc or copy. You own and must release that object.
2. if you implemented both the setter and getter - the @synthesize method...
subview(s)
will be ignored
copy - retain
selector[message]
3. The only reason to temporarily own an object - is...
methods
to give it someone else - or another object
ready-made instances - instantiation from scratch - and nib based instantiation
Core Graphics Framework
4. Values to be supplied as the parameters to the method
methods for generating an instance
arguments[message]
creating an initializer
cannot be added to an array
5. Core foundation classes are prefixed with _ and suffixed with _
view controller
alloc - singleton - informational utility method?
parentViewController
CF - Ref
6. UIView - designated initializer...
subview(s)
(id)initWithFrame:(CGRect)aRect;
Core Graphics Framework
you always return the newly initialized object(return self)
7. A function in the objective c library that simply displays or logs it's argument
alloc - singleton - informational utility method?
receiver - selector - arguments
an object's property
NSLog routine
8. When do you take ownership?...
they need to be defined in the implementation file
Anytime you call a method with new - alloc or copy. You own and must release that object.
instance variables
object
9. In Objective C - the name of a setter method is set plus the name of the instance variable it is changing - for example PossessionName would be...
group of global functions already assigned to this class
receiver[message]
%d
setPossessionName
10. NSArray - important methods...
designated initializer
count - objectAtIndex - makeObjectsPerformSelector - sortedArrayUsingSelector - lastObject
%d
receiver - selector - arguments
11. A method in a _ is required unless its preceded by an @optional.
Functions
Continue
only the innermost loop in which the break is executed is terminated
protocol
12. In Objective C arrays can hold only...
references to objects
viewWillDissapear: and viewWillAppear:
NSBundle
data source - delegate and view controller
13. Why properties?
methods for generating an instance
safety - subclassability and makes code look more consistent with C structs
initializer
Object wrapper around primitive types like int - float - double - BOOl
14. SomeClass* aVariable = [[SomeClass alloc] init]; is an example of what kind of instance?
Instantiation from scratch
variable scope - if defined within a block
object
CF - Ref
15. All objects are accessed using...
class methods - initializers
cannot be added to an array
for inheritance - adopting the superclasses implementation
pointers
16. A UITableView usually needs three different pieces...
UIViewController
Ready-Made Instance
data source - delegate and view controller
object
17. Defining variables - three parts...
type - name and value
unordered collection of objects - objects must be unique
data source - delegate and view controller
ready-made instances - instantiation from scratch - and nib based instantiation
18. At the top of any implementation file...
CGRect bounds - GCPoint center - CGRect frame
instance
instance variable of an object is valid
you must import the header file of that class
19. A command directed to an object is called an...
selector[message]
view controller's initialization method
header files declare
message
20. Dynamic binding means that when we call a certain object's method - and there are several _ of that method - the right one is figured out at runtime.
wait until the loop finishes processing the event - at the end release it
selector[message]
implementation
receiving and handling events that are associated with it
21. If a class declares a _ that is different from its superclass - you must override the superclass' _ to call the new _...
NSBundle
designated initializer
its dataSource
array[class - NSMutableArray]
22. Three ways instances are created...
Is a placeholder object
ready-made instances - instantiation from scratch - and nib based instantiation
superclass's
instance of UIView or one of its subclasses
23. Ready-made instances...
accessors - individually we call them 'getters' and 'setters'
class methods - initializers
NSBundle
calling code that does the instantiation for you
24. Origin of a view's coordinate system is _ left
object
an object's property
upper
initializer
25. initWithFrame: the designated initializer for UIView gives the view
size and position
has one root view controller
define it in the implemenation file
position
26. Name of the method to be executed
selector[message]
values
collection of collections - NSArray of an NSArray
an object's property
27. NSDictionary...
only the innermost loop in which the break is executed is terminated
Hash table - Look up objects using a key to get a value.
@synthesize
will be ignored
28. In general - class methods tend to be factory methods - that is...
methods for generating an instance
in the dealloc - or when a Controller's view is 'unloaded'
you always return the newly initialized object(return self)
nil
29. Class methods do not operate on an _ or have any access to _ variables....
only the class and subclasses can access
CGFloat
is called every time the event occurs
instance
30. When the message endEditing: is sent to a view - if it or any of its subviews or currently the _ - it will resign its first responder statues - and the keyboard will be dismissed.
first responder
is called every time the event occurs
the array becomes an owner of that object and has a pointer to it.
safety - subclassability and makes code look more consistent with C structs
31. Inside a method - _ is an implicit local variable. Typically - _ is used so that an object can send a message to itself....
'getters' and 'setters'
subview(s)
self
receiver
32. When an NSMutableArray is deallocated - it sends...
array[class - NSMutableArray]
data
position
the message release to all its entries
33. NSNumber - class...
instance of UIView or one of its subclasses
UIViewController
only the innermost loop in which the break is executed is terminated
Object wrapper around primitive types like int - float - double - BOOl
34. In Cocoa Touch - the table view asks another object _ what it should display...
view controller
its dataSource
UIView
view
35. It's class is sent the message alloc - which creates an instance of that class and returns a pointer to it - and then that instance is sent the message init - which gives its instance variables initial values.
to give it someone else - or another object
creating an initializer
CGFloat
'getters' and 'setters'
36. A view is a subclass of _
callbacks
UIView
draw images
selector[message]
37. If you aren't going to initialize an instance reference pointer at the moment you declare it by assigning a real value - it's a good idea to assign it _.
CGRect bounds - GCPoint center - CGRect frame
nil
references to objects
Object wrapper around primitive types like int - float - double - BOOl
38. Property List...
Data Encapsulation
collection of collections - NSArray of an NSArray
Object wrapper around primitive types like int - float - double - BOOl
new instances of the class or retrieve some global property of the class.
39. NSString* s2 = [s uppercase String]; Is an example of what kind of instance?
data
pointer - class
Ready-Made Instance
class
40. Each class picks one _ as it's designated initializer....
you must import the header file of that class
a mechanism to enable specific callbacks
initializer
Core Graphics Framework
41. Name of the new class - it's superclass - the instance variables that each instance of this class has - and any methods this class implements
setPossessionName
header files declare
object
class
42. Categories are an Objective C way to add _ to an existing class without subclassing
instance variable of an object is valid
viewWillAppear - viewDidAppear - viewWillDisappear & viewDidDisappear
methods
header files declare
43. Object Oriented based analogue to a function is called a...
method
is an instance of that class
callbacks
NSCoder
44. UIImageView is used to...
retain
draw images
Object wrapper around primitive types like int - float - double - BOOl
declaration and initialization of a variable
45. class methods...
group of global functions already assigned to this class
CGRect
instance variables
pointer - class
46. When you send a message to _ - you are sending a message to _ - but demanding that the search for the method begin at the superclass....
causes the program to immediately exit from the loop it is executing - whether its for - while or do
super - self
header files declare
CF - Ref
47. Execution of the break statement...
retain
causes the program to immediately exit from the loop it is executing - whether its for - while or do
parentViewController
instance of UIView or one of its subclasses
48. Primitives and C Structures...
cannot be added to an array
receiving and handling events that are associated with it
NSLog routine
creates an instance of NSString that holds the character string
49. Asking a class or object to execute a method
in the dealloc - or when a Controller's view is 'unloaded'
message
instance variables
Ready-Made Instance
50. Reducing details to focus on the core concepts
@synthesize
Core Graphics Framework
'getters' and 'setters'
Abstraction