← ACARA Digital Technologies Years 9–10

Class, object, property and method

A blueprint for dogs. An object like Rex is made from it. Properties are its data (nouns like name) and methods are its actions (verbs like bark).

Understanding Class, object, property and method in ACARA Digital Technologies Years 9–10

What it does: rex.name reads the name property, which stores data about Rex. Properties are the nouns of an object. The brackets call the bark method, so Rex performs an action. Methods are the verbs of an object. A class is the blueprint. An object like Rex is one real thing made from that blueprint. Rex is one specific dog, so he is an object. Dog describes all dogs, so it is the class. The class keyword creates a blueprint. It is not a dog itself, only the plan for making dogs.

Common mistakes: A property belongs to the object, so it must be set with this. The line should be this.name = name; otherwise the dog never gets a name property. The closing bracket of console.log is missing. The method body should say console.log('Woof!');.

Class: _____________________  ·  Name: _____________________  ·  Date: _________

Free printable worksheet with full answer key — or add this module to a class and your students practise it interactively.

This module's key terms are also in a printable crossword (Modules 728–742) and word search (Modules 710–742).

Take this worksheet further — free with Cloodit

Each concept is reinforced from every angle — learned, then applied, then tested.

Learning
Duo
In class Dog, which statement is correct?
Dog is the blueprint and Rex is one object made from itRex is the blueprint and Dog is one object made from it
Matches
Dog.bark();
↓
bark is a method of a dog object, not of the class blueprint. Make an object like rex first, then call rex.bark().
Applying
Meanings
Term
class Dog
Meaning
A blueprint for dogs. An object like Rex is made from it. Properties are its data (nouns like name) and methods are its actions (verbs like bark).
Practice
class Dog {
Testing
Gaps
Dog {
Check Answer
Spots
2 constructor(name) {
3 name = name;

Cloodit turns curriculum-aligned coding content into journeys students work through one biome at a time.

The 'Peregrine Falcon' badge — Operator Ace, one of Cloodit's 106 collectible badges
Students earn collectable badges

Over 100 of them, across seven natural biomes.

Study Buddy
Students build a real study resource

Turns their work into revision material ready for Flash Cards and Exam study.

Diamond Dash — one of Cloodit's live, competitive Sprint games
Students lock in with Sprints

Live, competitive practice for the start of the lesson or a teacher-led lesson finisher.

A Cloodit certificate of achievement, ready to personalise and print
Custom printable certificates

Honour your top performers, or encourage a student who's trying hard — ready to print in seconds.

Quick Questions

1. In class Dog, which statement is correct?
A. Rex is the blueprint and Dog is one object made from it
B. Dog is the blueprint and Rex is one object made from it ✓
A class is the blueprint. An object like Rex is one real thing made from that blueprint.
2. Which one is a property of a Dog object?
A. name ✓
B. bark()
Properties hold data and are like nouns, such as name or age. bark() is an action, so it is a method.
3. Which one is a method of a Dog object?
A. bark() ✓
B. age
Methods are actions and are like verbs. Brackets show that bark() is called to do something. age just stores data.
4. How many Dog objects can you make from one Dog class?
A. Only one, because a class makes a single object
B. As many as you need, such as Rex and Bella ✓
One blueprint can make many objects. Each object keeps its own data, like its own name.
5. Which sentence matches the idea of properties and methods?
A. Properties are nouns that hold data and methods are verbs that act ✓
B. Properties are verbs that act and methods are nouns that hold data
Properties describe what an object has, like a name. Methods describe what an object can do, like bark.

Match the Pairs

class Dog { } → A blueprint that describes what every dog will have and do
let rex = new Dog("Rex"); → Makes one object, the dog Rex, from the Dog blueprint
A property holds data about an object, like a noun (the dog's name) → console.log(rex.name);
A method is an action an object can do, like a verb (bark) → rex.bark();
Dog.bark(); → bark is a method of a dog object, not of the class blueprint. Make an object like rex first, then call rex.bark().
let rex = Dog("Rex"); → The new keyword is missing, so no object is made from the class. It should be new Dog("Rex").

Key Term

class Dog
A blueprint for dogs. An object like Rex is made from it. Properties are its data (nouns like name) and methods are its actions (verbs like bark).

Fill in the Blanks

1. class Dog { bark() { console.log("Woof!"); } }
Hint: Type the keyword that declares a blueprint for making objects.
2. const rex = new Dog("Rex");
Hint: Type the name of the class (blueprint) that Rex is made from.
3. const rex = new Dog("Rex"); console.log(rex.name);
Hint: Type the property, a noun holding data, that stores what the dog is called.
4. const rex = new Dog("Rex"); rex.bark();
Hint: Type the method, a verb or action, that makes Rex make a noise.
5. constructor(name) { this.name = name; }
Hint: Type the keyword that refers to the object currently being built.

Spot the Error

Question 1
A class Dog {
B constructor(name) {
C name = name;
D }
E }
Line C — A property belongs to the object, so it must be set with this. The line should be this.name = name; otherwise the dog never gets a name property.
Question 2
A class Dog {
B bark() {
C console.log('Woof!';
D }
E }
Line C — The closing bracket of console.log is missing. The method body should say console.log('Woof!');
Question 3
A class Dog {
B constructor(name, age) {
C this.name = name;
D this.age = name;
E }
F }
Line D — The age property is being given the name value. It should be this.age = age; so each property stores its own data.
Question 4
A class Dog {
B function bark() {
C return 'Woof!';
D }
E }
Line B — Methods inside a class are written without the function keyword. The line should be bark() {
Question 5
A class Dog {
B construct(name) {
C this.name = name;
D }
E }
Line B — The special method that builds each object must be called constructor, not construct. It should be constructor(name) {

Student with a class code? Join your class →