OOP1

¡Supera tus tareas y exámenes ahora con Quizwiz!

Sub Class

*Sub-class When a class is extended from a another class. The sub-class will use the functionality and properties of the class it extends from and then build more specific properties and methods it can do from there. A sub-class inherits all the abilities and properties or attributes from the class it inherits from. A FighterPlane is a sub-class of a Plane object. Rectangle is a sub-class of a Shape class. This is also called a derived class or a child class.

Argument

Information that's passed into a method/function. In Java, C#, JavaScript, and similar languages, arguments are placed inside the parentheses when calling the function. Arguments are also sometimes called parameters.

Primitive Data Type

Basic data types. In java these include things such as integers, decimals, booleans, text or alpha-numeric characters. These are simple forms of data that can be used in variables. In fact, all of every kind of data object used in Java is really made up many combinations of primitive data types.

Object State

The values of all an instance of an object's properties at any given time. If you have an instance of a Tank object and display all the property values of it to the screen at a given time you are outputting that instance of the Tank object's state to the screen.

Properties ("has a" items)

These are the things an object has or can be described by. This can be thought of in the form of nouns. They can sometimes be referred to as variables, attributes, data, characteristics, or traits.

Processes ("can do" items)

Things an object can do. They can be thought of in the form of verbs. These are also called "behaviors", in fact, Dreamweaver calls Javascript functions "behaviors". Sometimes they are called "operations".

Base Class

This is the object type or blueprint that can be used as a starting point for objects that will include the base class properties and processes but that will add more to a new object. For example, a Plane object could be used as a base for a flghterPlane object. FighterPlane is a more advanced, more detailed version of Plane. The base class is the class that is used as a foundation for a more extensive, specialized type. A general WaterBot is a base class for a specialized SquidBot. The WaterBot is the base class (also called a superclass) and the SquidBot is the sub-class (also called derived class).

Cast

This is when an extended object is treated as a copy of the basic object type that was extended to create the more advanced object type. It can be done implicitly or explicitly.

Object

A big variable that contains multiple variables. The variables it contains can be primitive data types like integers, text, booleans, decimals or even other objects. They can also include actions that the object can take. The blueprint for defining an object is called a constructor in Javascript. In the Java programming language the blueprint for an object is called a "class". The object concept is fundamental to the notion of an object-oriented programming language.

Instance

A copy of an object when the constructor creates one. It's not the blueprint of how to create the object. It's a COPY of the object. It's the virtual object created when memory space is devoted on a disk to hold the properties and methods contained in its blueprint/class.

Method

A function that is inside of a class. It is part of the blueprint for what an instance of the class will be able to do. It is said to "belong" to the object type. These are things it can "do". Also called "processes".

New

A keyword in multiple languages that indicates a new copy of an object should be constructed. It's usage goes like this: Plane plane1=new Plane();

Accessor

A method inside of a constructor function that will allow an instance of that type of object to get the value of one of its private properties the method needs to be public to be accessed by other classes.

Constructor

A method that is the only kind of method used to create new objects of the class it is declared in. It is the function that contains the necessary information and that is used to create an object of the type of class it is included in.

API

A pre-written library or set of objects and their properties and processes that you can make use of in writing programs. It is provided in most programming languages so you can build more complex applications without having to create everything from scratch.

Modular

A section of a program is sectioned off to itself and other sections that need to use it can do so without needing access to all the details of the internal code to the module. It keeps all the code for particular features together as much as possible without being dispersed all throughout a program. Example: the capability to allow a photon shooter to fire can be contained into a few functions and accessed through a single button or keystroke; the section doing the actual firing is contained in one section or area.

Class

The blueprint for creating instances of an object. It contains all the methods and properties that an object will be able to work with when it is constructed. It is invoked using the "new" keyword.

Encapsulation

The idea of keeping a section of a program sectioned off to itself so all the other sections of the program don't intermix with it. It can be used to refer to modularity. This is done when you have different modules of code like a type of bot that can be used by the rest of the program but that only when one has been created and only by making used of the methods it has in it to do anything. The term encapsulation is often used interchangeably with information hiding. You might consider information hiding as being the principle and encapsulation being the technique.

Instantiation

The process of creating an instance of some class object using the "new" keyword and the class constructor method. It creates a new copy of an object and gives a value or values to all the needed properties Within the class for that copy.

Members

The properties and methods that belong to a class.

Extend

When a base class or object constructor is used as a starting point for creating a new, more advanced, version of an object. A plane class can be extended to create a FighterPlane class.

Inheritance

When an object gets some of its properties and processes from a more basic Object constructor. A FighterPlane object inherits the properties and processes of a Plane object.

Composition

When an object is made up of a group of other objects. For example, an astronaut Suit object could include a Helmet, Glove, Boot and other objects to make a full Suit object. This gives additional properties and functionality to the Suit object than it would have by itself. This is different than getting additional properties and functionality from inheritance.

Polymorphism

When an object that has been extended from another base object is both an instance of the base object AND the newly defined, more advanced Object. Example: an object could be a FighterPlane AND a Plane at the same time because the FighterPlane Object extends the Plane object. It has everything the Plane class has and more. A CorvetteCar is also a BasicCar. A SkyscraperBuilding is also a BasicBuilding.

Abstraction

When complex processes are hidden from the user who gets a simple interface to use to make something work. This is done in code when a program user can click buttons to make a game work but they have no idea what is going on behind those buttons in the class files of code. It's like a car that a user just needs a key for to turn the engine over and run it. The hood hides all the complex machinery. The key ignition is the abstraction to allow a person to use the car.

Over-riding

When the exact same variable name or method name is used and given a new value or different instructions in a sub-classed method.


Conjuntos de estudio relacionados

Chap 3 Theories of Delinquency and intervention programs

View Set

Microeconomics Chapter 12 SmartBook

View Set

Ch. 3 environmental risk comprehensive science

View Set

Chapter 4: Groups, Teams, and Diversity

View Set

chapter 2 Jam and Nuts is evaluating their resources so that they can compete with other companies. They have evaluated their plant, equipment, and geographic location. What other physical resource do they need to evaluate to complete this scan? A) Contro

View Set