What is this course about?
Understand Java OOP one small idea at a time. Start with a class, one object and one method, then practise controlled state, inheritance, interfaces and composition. Finish with collections and class-based file CRUD.
Learn one OOP idea at a time: 7 guided topics, 350 small Java programs, 70 quiz questions and 3 class-based file CRUD projects. Multiline source, tested reference output and VS Code setup.
Where you can use the skills
- A class-based student registry.
- A persistent library catalogue.
- A help-desk ticket store with an open-ticket queue.
These are application ideas for your learning and portfolio. The published curriculum below shows the actual lessons and projects.
What you will work towards
Explain classes and objects using small everyday examples.
Protect valid state and compare inheritance with composition.
Use interfaces, object collections, stacks and queues.
Build three persistent projects with separate domain, repository and menu classes.
Who is this course for?
- Java Level 1 learners ready for OOP.
- College students who want clear step-by-step class examples.
- Learners preparing for further Java application development.
Before you start
Java variables, conditions, loops, methods and basic files, or the Java Level 1 course. Use a compatible local JDK and the included VS Code guide.
Your course curriculum.
7 topics × 50 programs = 350 programs · 70 quiz questions · 3 file-based CRUD projects.
01Classes, Objects & Constructors
- Meet an empty class
- One object remembers a name
- Two objects keep different names
- Read default field values
- A field initializer gives a starting value
- Call one object method
- Read state inside a method
- Return a calculated value
- Give a method an argument
- Change an object with a method
- Start with a no-argument constructor
- Pass a name to a constructor
- Use this to name the current object
- Initialize two fields together
- Overload a constructor
- Chain constructors with this
- Observe constructor order
- Count created objects with static
- Separate static and instance values
- Call a static factory method
- Two reference names, one object
- Reassign a reference separately
- Compare reference identity
- Check a missing object
- Pass an object to a method
- Reassigning a parameter leaves the caller
- Return a new object
- Return the current object
- Make an explicit value copy
- Print a useful object description
- Store objects in an array
- Visit every object in an array
- Fill an initially empty object array
- Total values from several objects
- Find an object by its ID
- Read keyboard data into an object
- A boolean-returning object method
- An object method with a local variable
- Call one instance method from another
- Reuse an object between calls
- Create a fresh object in each loop
- Use a named class constant
- Overload an instance method
- Read a final instance field
- Swap references, not objects
- Return an object selected by a rule
- Keep a simple object snapshot
- Reset an object deliberately
- Create an array with a factory loop
- Explain a tiny object model
02Encapsulation & Validation
- A private name · first step
- A private name · build a read-only label
- Rename through an operation · first step
- Rename through an operation · trace two renames
- Reject a blank name · first step
- Reject a blank name · reject blank input
- Keep marks in range · first step
- Keep marks in range · protect the previous mark
- Validate during construction · first step
- Validate during construction · reject an invalid object
- Deposit with a rule · first step
- Deposit with a rule · reject a negative deposit
- Withdraw without overdrawing · first step
- Withdraw without overdrawing · leave funds unchanged
- Reserve the last seat · first step
- Reserve the last seat · reject a second reservation
- Increase stock through restock · first step
- Increase stock through restock · reject empty restock
- Sell only available stock · first step
- Sell only available stock · reject overselling
- Expose a calculated total · first step
- Expose a calculated total · recalculate after a change
- Read-only identity · first step
- Read-only identity · list stable identities
- Immutable coordinates · first step
- Immutable coordinates · keep the original coordinate
- Copy an incoming array · first step
- Copy an incoming array · change the caller array
- Copy an outgoing array · first step
- Copy an outgoing array · change the returned array
- Return an immutable list snapshot · first step
- Return an immutable list snapshot · reject snapshot modification
- Reject duplicate names · first step
- Reject duplicate names · handle a duplicate join
- Control a state transition · first step
- Control a state transition · reject repeated completion
- Set a date pair atomically · first step
- Set a date pair atomically · preserve both old values
- Use a private helper · first step
- Use a private helper · reject a null argument
- Bound a counter · first step
- Bound a counter · stop at the maximum
- Normalize before storing · first step
- Normalize before storing · compare normalized values
- Final reference with mutable state · first step
- Final reference with mutable state · trace allowed mutation
- Return a domain result · first step
- Return a domain result · read a rejected result
- Separate objects preserve separate rules · first step
- Separate objects preserve separate rules · reject an overfill
03Inheritance & Reuse
- A child inherits a method · first step
- A child inherits a method · compare parent and child calls
- Add a child-only method · first step
- Add a child-only method · combine inherited and added behaviour
- Construct the parent with super · first step
- Construct the parent with super · construct two children
- Parent runs before child · first step
- Parent runs before child · trace separate constructions
- Pass shared and special values · first step
- Pass shared and special values · read the child detail
- Override one instance method · first step
- Override one instance method · compare implementations
- Extend parent work with super · first step
- Extend parent work with super · keep the base message separate
- Keep parent fields private · first step
- Keep parent fields private · preserve another child state
- Use a protected helper · first step
- Use a protected helper · reuse the protected calculation
- Inherit from one direct parent · first step
- Inherit from one direct parent · read shared and specific behaviour
- Follow a three-level chain · first step
- Follow a three-level chain · trace all three levels
- Create sibling subclasses · first step
- Create sibling subclasses · compare sibling reuse
- A child is assignable to its parent · first step
- A child is assignable to its parent · check the shared identity
- A parent reference exposes parent members · first step
- A parent reference exposes parent members · keep the child reference for its extra method
- Check a subtype with instanceof · first step
- Check a subtype with instanceof · handle a plain parent
- Overload does not override · first step
- Overload does not override · call both signatures
- A final method remains inherited · first step
- A final method remains inherited · use the fixed inherited method
- A final class ends a branch · first step
- A final class ends a branch · use a final child through its parent
- Static methods are hidden · first step
- Static methods are hidden · compare the two class methods
- Fields are not overridden methods · first step
- Fields are not overridden methods · compare field selection
- Call an inherited method from a child · first step
- Call an inherited method from a child · mix base and child operations
- Validate in the parent constructor · first step
- Validate in the parent constructor · reject invalid shared data
- Delegate between child constructors · first step
- Delegate between child constructors · choose the named constructor
- Override toString from Object · first step
- Override toString from Object · use the Object reference
- Choose is-a carefully · first step
- Choose is-a carefully · total related objects
04Polymorphism, Abstract Classes & Interfaces
- Dispatch through a parent reference · first step
- Dispatch through a parent reference · dispatch inside a loop
- Two shapes answer the same request · first step
- Two shapes answer the same request · total different shapes
- A polymorphic parameter · first step
- A polymorphic parameter · reuse one caller
- Return an abstraction · first step
- Return an abstraction · choose another implementation
- Shared code in an abstract class · first step
- Shared code in an abstract class · compare raw and wrapped content
- Construct an abstract base through a child · first step
- Construct an abstract base through a child · combine base state and child behaviour
- Meet one small interface · first step
- Meet one small interface · call the ability on several objects
- Implement two interfaces · first step
- Implement two interfaces · view the second ability
- An interface can extend another · first step
- An interface can extend another · use the smaller contract
- A default interface method · first step
- A default interface method · compare required and default methods
- Override a default method · first step
- Override a default method · compare default and replacement
- Resolve two default methods explicitly · first step
- Resolve two default methods explicitly · use the resolved method through an interface
- Call a static interface utility · first step
- Call a static interface utility · check an empty cleaned label
- Replace a strategy object · first step
- Replace a strategy object · compare strategies on one input
- Inject a notifier contract · first step
- Inject a notifier contract · reuse the same notifier
- Use a test implementation · first step
- Use a test implementation · check the recorded call
- Anonymous implementation of a contract · first step
- Anonymous implementation of a contract · trace the boundary
- A lambda for one abstract method · first step
- A lambda for one abstract method · filter with the same rule
- Use a method reference · first step
- Use a method reference · reject the nonpositive cases
- Overload selection uses declared types · first step
- Overload selection uses declared types · compare a parent-typed argument
- Runtime dispatch inside an inherited method · first step
- Runtime dispatch inside an inherited method · verify the inherited caller
- A covariant return type · first step
- A covariant return type · use the parent declaration
- Provide an equality contract · first step
- Provide an equality contract · use equality in a set
- Keep a consistent contract · first step
- Keep a consistent contract · test the contract on invalid input
- Add an implementation without changing the loop · first step
- Add an implementation without changing the loop · extend the plan
05Composition & Object Relationships
- A car has an engine · first step
- A car has an engine · construct two owners
- Pass a collaborator to a constructor · first step
- Pass a collaborator to a constructor · share one collaborator
- Delegate a small job · first step
- Delegate a small job · check delegated behaviour
- Compose a student address · first step
- Compose a student address · reuse an immutable value
- One invoice contains several lines · first step
- One invoice contains several lines · total two owned parts
- Reject a missing required collaborator · first step
- Reject a missing required collaborator · reject a missing engine
- An optional collaborator · first step
- An optional collaborator · choose self-study
- Sharing a mutable helper shares changes · first step
- Sharing a mutable helper shares changes · observe a shared update
- Copy a mutable helper for ownership · first step
- Copy a mutable helper for ownership · isolate an outside change
- A shallow copy still shares elements · first step
- A shallow copy still shares elements · observe an element change
- A deep-enough copy duplicates mutable parts · first step
- A deep-enough copy duplicates mutable parts · protect the copied element
- Build a report from data and formatting · first step
- Build a report from data and formatting · check the composed output
- Replace one implementation of a helper · first step
- Replace one implementation of a helper · replace only the formatter
- Compose instead of inheriting from a list · first step
- Compose instead of inheriting from a list · use the narrow register API
- Keep coordination in one service · first step
- Keep coordination in one service · verify the coordination
- Contain a stack for undo · first step
- Contain a stack for undo · undo the most recent edit
- Contain a queue for service · first step
- Contain a queue for service · handle an empty desk
- Define equality for a contained value · first step
- Define equality for a contained value · compare identity separately
- Connect objects with IDs · first step
- Connect objects with IDs · resolve the ID relation
- A composed object can calculate a derived value · first step
- A composed object can calculate a derived value · isolate the delivery component
- Own a simple state machine · first step
- Own a simple state machine · finish the class
- Use a clock collaborator in a test · first step
- Use a clock collaborator in a test · advance a controlled clock
- Decorate a collaborator · first step
- Decorate a collaborator · trace nested wrappers
- Compose a validation rule · first step
- Compose a validation rule · exercise the rejected branch
- Keep a course and its lessons separate · first step
- Keep a course and its lessons separate · update only one owned lesson
06Object Collections, Stacks & Queues
- A typed list of students · first step
- A typed list of students · iterate over objects
- Insert at a chosen list position · first step
- Insert at a chosen list position · replace an existing position
- Find a student by ID · first step
- Find a student by ID · report a missing ID
- Remove matching objects safely · first step
- Remove matching objects safely · leave nonmatching items intact
- Remove through an iterator · first step
- Remove through an iterator · empty the list through traversal
- Sort objects by one property · first step
- Sort objects by one property · sort marks descending
- Break a sorting tie · first step
- Break a sorting tie · keep the primary order
- Value equality controls list membership · first step
- Value equality controls list membership · check a different value
- Use a set for unique values · first step
- Use a set for unique values · preserve first insertion order
- Keep sorted unique codes · first step
- Keep sorted unique codes · read the sorted extremes
- Look up objects in a map · first step
- Look up objects in a map · handle a missing key
- Create without overwriting a map value · first step
- Create without overwriting a map value · reject an existing key
- Update and delete map entries · first step
- Update and delete map entries · delete a keyed record
- Iterate map entries · first step
- Iterate map entries · list only the keys
- Group an object list · first step
- Group an object list · separate two groups
- Push and pop a stack · first step
- Push and pop a stack · drain the stack in order
- Peek without changing a stack · first step
- Peek without changing a stack · inspect an empty stack safely
- Implement one-level undo · first step
- Implement one-level undo · leave state when history is empty
- Queue tickets in arrival order · first step
- Queue tickets in arrival order · serve every ticket
- Inspect a queue safely · first step
- Inspect a queue safely · handle an empty poll
- Use both ends of a deque · first step
- Use both ends of a deque · remove from the other end
- Choose priority instead of arrival order · first step
- Choose priority instead of arrival order · define a priority tie-breaker
- Write a generic box · first step
- Write a generic box · use a different type safely
- Write a bounded generic helper · first step
- Write a bounded generic helper · accept a decimal number
- Protect a returned object collection · first step
- Protect a returned object collection · compare snapshot and later state
07Classes, Files & Repository CRUD
- Write one object field · first step
- Write one object field · save inside a data folder
- Load text into a new object · first step
- Load text into a new object · normalize loaded text
- Handle a first run without a file · first step
- Handle a first run without a file · read an existing store
- Store one record as a delimited line · first step
- Store one record as a delimited line · inspect the two stored fields
- Parse a stored integer field · first step
- Parse a stored integer field · reject a nonnumeric ID
- Validate field count · first step
- Validate field count · reject a missing field
- Reject blank loaded values · first step
- Reject blank loaded values · reject an invalid loaded object
- Frame arbitrary text with Base64 · first step
- Frame arbitrary text with Base64 · round-trip the encoded value
- Store multiple record lines · first step
- Store multiple record lines · persist an empty collection
- Add a format header · first step
- Add a format header · reject an unknown header
- Reject duplicate stored IDs · first step
- Reject duplicate stored IDs · reject a duplicate fixture
- Load into temporary state · first step
- Load into temporary state · preserve live state on a corrupt row
- Put file access in a repository · first step
- Put file access in a repository · reopen through a new repository
- Create only if the record is absent · first step
- Create only if the record is absent · protect an existing record
- Read a record without changing the store · first step
- Read a record without changing the store · search a missing record without mutation
- Update a matching record · first step
- Update a matching record · reject update of a missing ID
- Delete a matching record · first step
- Delete a matching record · keep records when ID is absent
- Write a replacement through a temporary file · first step
- Write a replacement through a temporary file · leave the target before committing
- Request an atomic replacement when supported · first step
- Request an atomic replacement when supported · trace the non-atomic fallback operation
- Back up before a deliberate change · first step
- Back up before a deliberate change · restore a backup fixture
- Close a reader with try-with-resources · first step
- Close a reader with try-with-resources · read until end of file
- Do not hide a load error · first step
- Do not hide a load error · follow the successful load branch
- Inject a repository path · first step
- Inject a repository path · isolate two repositories
- Use an in-memory repository contract · first step
- Use an in-memory repository contract · test replacement without file I/O
- Verify a complete CRUD cycle · first step
- Verify a complete CRUD cycle · persist the CRUD cycle
Scope in Pakistan, the Gulf and abroad
Use these directions to plan your next steps. They are learning and portfolio suggestions, not a list of current vacancies or a guarantee of employment.
Pakistan
Use clear class-based projects to strengthen programming studies and portfolio discussions with local teams. Add databases, testing and framework experience for professional application roles.
Gulf countries
Build towards enterprise or backend application work through further Java projects and framework study. Review the actual role requirements, portfolio expectations and experience requested by employers.
Other countries & remote work
OOP, interfaces and collections are foundations for broader Java application work. The occupation wage context is a longer-term comparison, not promised earnings after this course.
Software Developers — United States
A broader occupation to research as you build experience. These figures describe U.S. employees across experience levels, not earnings after this course.
| 10th percentile | Median | 90th percentile |
|---|---|---|
| $39.64/hr | $65.38/hr | $103.21/hr |
Percentiles show points in a wage distribution; they are not minimum or maximum offers. This is not beginner pay or a freelance quote. Pakistan and Gulf offers depend on the actual role, experience and package; no universal local USD/hour rate is claimed.
View the original occupation wage table ↗Source checked 2 November 2026.For current Gulf-market research, see the Hays GCC Salary Guide 2026. Confirm the specific employer’s duties, required experience and entry conditions before relying on an offer.
Frequently asked questions
How much practice is included?
Seven topics with 50 small programs each: 350 programs, seven opening lectures, 70 quiz questions and three class-based file CRUD projects.
Will Java edits run live in the browser?
The website does not host a JVM. Study and edit online, view tested reference output, and compile your changes locally using the VS Code guide.
Should I finish Java Level 1 first?
Yes, or already understand Java variables, conditions, loops, methods and basic file handling. Each OOP topic then starts with a simple everyday example.
Which learning modes can I request?
Self-study, tutor support, onsite classes near GPO in Sadar, Rawalpindi Cantt, and online classes via Google Meet. Admin confirms available guided class slots before payment.
What is the course fee?
PKR 20,000 is the listed total course fee. Confirm the agreed fee, duration, learning mode and schedule with Cody.pk before paying.
What can I see before enrolling?
The course description, curriculum outline, fees and public guides are available to browse. The editor, exercises and study materials require the relevant active enrollment, including any free place assigned by admin.
How do I apply and get access?
Apply with this course selected, your name, email and WhatsApp number. Choose your mode and, where required, an available class slot. Submit payment details through checkout. Access opens after admin verifies the payment and activates the enrollment.
Can I download study materials?
The student workspace shows materials for your enrolled course. Course-bundle downloads are available when admin enables download permission for your enrollment.
Are the international hourly figures a job or income promise?
No. They are 2025 U.S. employee occupation statistics, covering different experience levels. They are not beginner pay, freelance billing rates, Pakistan or Gulf offers, or a prediction of income after this course.
Course conversation
Questions and learning experiences about Java Level 2 · OOP.
Join the conversation
Keep it helpful and relevant. Comments appear after admin review. Your public name and comment may be displayed; your account email is visible only to admin. Please leave out phone numbers and private details.
Choose your pace. Make a start.
Request self-study, tutor support, onsite classes or online Google Meet classes. Guided modes use admin-managed class slots. Confirm your agreed fee and schedule before payment.
- ApplySend your name, email, WhatsApp and learning goals.
- Confirm the planAgree your mode, available slot and fee with Cody.pk.
- Pay & startPayment verification and activation open the enrolled course.
Manual Easypaisa: Rashid Irshad · 03145366708. Raast ID: 03145366708. Use the course checkout to confirm the amount and submit your payment reference for verification.


Start a useful conversation.
No published comments yet. Ask about the course or share your learning experience.