23CS21T2 - OBJECT-ORIENTED PROGRAMMING THROUGH JAVA
(Common to CSE, CSE (DS), CSE (AI&ML), AI&DS, and IT)
Course
Professional Core Credits: 3
Category:
Course
Theory Lecture-Tutorial-Practical: 3-0-0
Type:
Sessional Evaluation: 30
Basic Programming Skills and Problem
Prerequisite: Univ. Exam Evaluation: 70
Solving Skills
Total Marks: 100
To identify Java language components and how they work together in
applications
To learn the fundamentals of object-oriented programming in Java, including
defining classes, invoking methods, and using class libraries.
Objectives:
Learning to extend Java classes with inheritance and dynamic binding and how
to use exception handling in Java applications
Understanding to design applications with threads in Java
To understand how to use Java APIs for program development.
Upon successful completion of the course, the students will be able to:
Analyze problems, design solutions using OOP principles, and implement
CO1
them efficiently in Java. (L4)
Design and implement classes to model real-world entities, with a focus on
CO2
attributes, behaviors, and relationships between objects (L4)
Course
Outcomes Demonstrate an understanding of inheritance hierarchies and polymorphic
CO3
behavior, including method overriding and dynamic method dispatch. (L3)
Apply Competence in handling exceptions and errors to write robust and
CO4
fault-tolerant code. (L3)
Perform string operations in Java, implement multithreaded programming,
CO5
and manage event handling.(L3)
UNIT-I
Object Oriented Programming: Basic concepts, Principles, Program Structure in
Java: Introduction, Writing Simple Java Programs, Elements or Tokens in Java
Programs, Java Statements, Command Line Arguments, User Input to Programs, Escape
Sequences Comments, Programming Style.
Data Types, Variables, and Operators: Introduction, Data Types in Java, Declaration
of Variables, Data Types, Type Casting, Scope of Variable Identifier, Literal Constants,
Symbolic Constants, Formatted Output with printf() Method, Static Variables and
Course Methods, Attribute Final.
Content Introduction to Operators: Precedence and Associativity of Operators, Assignment
Operator ( = ), Basic Arithmetic Operators, Increment (++) and Decrement (--)
Operators, Ternary Operator, Relational Operators, Boolean Logical Operators, Bitwise
Logical Operators.
Control Statements: Introduction, if Expression, Nested if Expressions, if–else
Expressions, Ternary Operator?:, Switch Statement, Iteration Statements, while
Expression, do–while Loop, for Loop, Nested for Loop, For–Each for Loop, Break
Statement, Continue Statement.
UNIT-II
Classes and Objects: Introduction, Class Declaration and Modifiers, Class Members,
Declaration of Class Objects, Assigning One Object to Another, Access Control for
Class Members, Accessing Private Members of Class, Constructor Methods for Class,
Overloaded Constructor Methods, Nested Classes, Final Class and Methods, Passing
Arguments by Value and by Reference, Keyword this.
Methods: Introduction, Defining Methods, Overloaded Methods, Overloaded
Constructor Methods, Class Objects as Parameters in Methods, Access Control,
Recursive Methods, Nesting of Methods, Overriding Methods, Attributes Final and
Static.
UNIT-III
Arrays: Introduction, Declaration and Initialization of Arrays, Storage of Array in
Computer Memory, Accessing Elements of Arrays, Operations on Array Elements,
Assigning Array to Another Array, Dynamic Change of Array Size, Sorting of Arrays,
Search for Values in Arrays, Class Arrays, Two-dimensional Arrays, Arrays of Varying
Lengths, Three-dimensional Arrays, Arrays as Vectors.
Inheritance: Introduction, Process of Inheritance, Types of Inheritances, Universal
Super Class-Object Class, Inhibiting Inheritance of Class Using Final, Access Control
and Inheritance, Multilevel Inheritance, Application of Keyword Super, Constructor
Method and Inheritance, Method Overriding, Dynamic Method Dispatch, Abstract
Classes, Interfaces and Inheritance.
Interfaces: Introduction, Declaration of Interface, Implementation of Interface,
Multiple Interfaces, Nested Interfaces, Inheritance of Interfaces, Default Methods in
Interfaces, Static Methods in Interface, Functional Interfaces, Annotations.
UNIT-IV
Packages and Java Library: Introduction, Defining Package, Importing Packages and
Classes into Programs, Path and Class Path, Access Control, Packages in Java SE,
Java.lang Package and its Classes, Class Object, Enumeration, class Math, Wrapper
Classes, Auto-boxing and Auto-unboxing, Java util Classes and Interfaces, Formatter
Class, Random Class, Time Package, Class Instant (java.time.Instant), Formatting for
Date/Time in Java, Temporal Adjusters Class, Temporal Adjusters Class.
Exception Handling: Introduction, Hierarchy of Standard Exception Classes,
Keywords throws and throw, try, catch, and finally Blocks, Multiple Catch Clauses,
Class Throwable, Unchecked Exceptions, Checked Exceptions.
Java I/O and File: Java I/O API, standard I/O streams, types, Byte streams, Character
streams, Scanner class, Files in Java(Text Book 2)
UNIT-V
String Handling in Java: Introduction, Interface Char Sequence, Class String,
Methods for Extracting Characters from Strings, Comparison, Modifying, Searching;
Class String Buffer.
Multithreaded Programming: Introduction, Need for Multiple Threads Multithreaded
Programming for Multi-core Processor, Thread Class, Main Thread-Creation of New
Threads, Thread States, Thread Priority-Synchronization, Deadlock and Race
Situations, Inter-thread Communication-Suspending, Resuming, and Stopping of
Threads.
Event Handling: Keyboard Events, Mouse Events.
TEXT BOOKS:
1. JAVA one step ahead, Anitha Seth, B.L.Juneja, Oxford.
2. Joy with JAVA, Fundamentals of Object Oriented Programming, Debasis
Samanta, Monalisa Sarma, Cambridge, 2023.
Text Books 3. JAVA 9 for Programmers, Paul Deitel, Harvey Deitel, 4thEdition, Pearson.
&
References
Books
REFERENCE BOOKS:
1. The complete Reference Java, 11thedition, Herbert Schildt,TMH
2. Introduction to Javaprogramming, 7thEdition, Y Daniel Liang, Pearson
1. https://nptel.ac.in/courses/106/105/106105191/
E-Resources 2. https://infyspringboard.onwingspan.com/web/en/app/toc/lex_auth_01288046454
7618816347 shared/overview