Object Oriented Programming

studied byStudied by 6 people
0.0(0)
Get a hint
Hint

Class

1 / 21

encourage image

There's no tags or description

Looks like no one added any tags here yet for you.

22 Terms

1

Class

the description/template of what the data looks like (the state) and what the data can do (the behaviour)

New cards
2

Objects

data items, an object is an instance of a class

New cards
3

attributes

gives and object’s properties

New cards
4

methods

describes the actions that the object can perform

New cards
5

instantiation

creating objects within a class

New cards
6

setter

sets the value of a particular attribute

New cards
7

getter

retrieves the value of a particular attribute

New cards
8

encapsulation

attributes cannot be directly accessed/edited by the user by making them private

New cards
9

constructor

allows a new object to be created

New cards
10

super class

parent class

New cards
11

subclass

class within a parent class

New cards
12

inheritance

  • where the subclass possess all of the methods/attributes of the superclass

  • each subclass can have its own attributes along with those in the superclass

New cards
13

overriding

classing a method from an object that shares the same name as a method further up

  • can be ignored is using superclass each super.______

    • the method from the original subclass is used instead

New cards
14

Declarative programming

statements are written that describe the problem to be solved and the language implementation decides the best way of solving it

New cards
15

Functional programming

statements are written as a series of functions which accept input data as arguments and return an output

New cards
16

procedural programming

has a series of instructions that tell the computer what to do with the input in order to solve the problem

New cards
17

structured programming

type of procedural programming which uses modular programming techniques to split large programs into manageable chunks

New cards
18

object oriented programming

abstracts details of implementations away from the programmers to make code reusable and programs easy to maintain

New cards
19

example of object oriented programming

class ToyTank

private colour

private name

public procedure new(givenColour, givenName)

colour = givenColour

name = givenName

end procedure

public procedure getColour()

print(“My colour is”, colour)

end procedure

public procedure setColour(newColour)

colour = newColour

end procedure

end class

New cards
20

Polymorphism

Reusing the same code in another area/object to obtain different results

New cards
21

Parameters

A variables used in a subroutine to refer to data provided within the input of the subroutine

New cards
22

method examples

update [attribute]

change [attribute]

set [attribute]

New cards

Explore top notes

note Note
studied byStudied by 10 people
... ago
5.0(1)
note Note
studied byStudied by 5 people
... ago
5.0(1)
note Note
studied byStudied by 11 people
... ago
5.0(1)
note Note
studied byStudied by 4 people
... ago
5.0(1)
note Note
studied byStudied by 98 people
... ago
5.0(2)
note Note
studied byStudied by 56 people
... ago
5.0(4)
note Note
studied byStudied by 8 people
... ago
5.0(1)
note Note
studied byStudied by 15 people
... ago
5.0(1)

Explore top flashcards

flashcards Flashcard (29)
studied byStudied by 13 people
... ago
5.0(1)
flashcards Flashcard (167)
studied byStudied by 14 people
... ago
5.0(1)
flashcards Flashcard (147)
studied byStudied by 7 people
... ago
5.0(1)
flashcards Flashcard (41)
studied byStudied by 28 people
... ago
5.0(1)
flashcards Flashcard (95)
studied byStudied by 8 people
... ago
5.0(1)
flashcards Flashcard (90)
studied byStudied by 3 people
... ago
5.0(2)
flashcards Flashcard (42)
studied byStudied by 2 people
... ago
5.0(1)
flashcards Flashcard (24)
studied byStudied by 71 people
... ago
5.0(1)
robot