- Project Overview & Setup
- Evolution of Java
- Java Platform Editions
- Java Architecture
- Windows & Eclipse Setup
- Project Implementation Map
- Assertions Guide
A comprehensive Java-based application for managing student enrollment, courses, and grades in an educational institution. Built with modern Java features and solid object-oriented design principles.
ccrm-java-project/
├── data/ # CSV data files
├── screenshots/ # Application screenshots
└── src/ # Source code
└── edu/
└── ccrm/ # Main package
├── domain/ # Domain classes
├── service/ # Business logic
├── io/ # File operations
├── cli/ # User interface
├── config/ # Configuration
├── util/ # Utilities
└── exception/ # Custom exceptions
- Student management (add, update, view, delete)
- Course management with capacity control
- Enrollment system with grade tracking
- Semester-based course offerings
- Comprehensive data validation
- CSV-based data persistence
- Automated backup system
- Import/Export functionality
- Data validation and error handling
- Modern Java NIO.2 file operations
- Stream API for data processing
- Date/Time API for temporal operations
- Robust error handling and logging
- Configurable application settings
- Singleton Pattern (AppConfig)
- Builder Pattern (Course creation)
- Service Layer Pattern
- Data Access Object Pattern
- Inheritance (Person → Student/Instructor)
- Interface-based design
- Encapsulation of data and behavior
- Polymorphic service implementations
The Campus Course & Records Manager (CCRM) is a comprehensive Java application designed for educational institutions to manage student enrollment, course offerings, and academic records. It demonstrates modern Java development practices and object-oriented principles.
- Student enrollment management
- Course catalog administration
- Grade tracking and GPA calculation
- Semester-based course scheduling
- Data persistence using CSV files
- Automated backup system
- JDK 17 or higher
- Read/Write permissions for data directory
- Command-line interface access (PowerShell or Command Prompt)
-
Create the bin directory:
mkdir bin
-
Compile the source code (all Java files):
javac -d bin src\edu\ccrm\CCRMApp.java src\edu\ccrm\cli\*.java src\edu\ccrm\config\*.java src\edu\ccrm\domain\*.java src\edu\ccrm\exception\*.java src\edu\ccrm\io\*.java src\edu\ccrm\service\*.java src\edu\ccrm\util\*.java
-
Run the application:
java -cp bin edu.ccrm.CCRMApp
-
To clean the project (remove compiled files):
Remove-Item -Path bin -Recurse -Force
-
To run with assertions enabled:
java -ea -cp bin edu.ccrm.CCRMApp
src/edu/ccrm/
: Core package directorydomain/
: Domain model classes (Student, Course, etc.)service/
: Business logic implementationcli/
: Command-line interface componentsio/
: Data persistence and file operationsutil/
: Utility classes and helpers
-
Ensure data directory exists:
mkdir -p data
-
Default configuration is loaded from:
src/edu/ccrm/config/app.properties
- Application will create necessary directories
- Initial data files will be generated
- Default admin credentials will be displayed
-
1995: Java 1.0
- First release by Sun Microsystems
- "Write Once, Run Anywhere" principle
- Basic OOP features and AWT
-
1998: Java 2 (1.2)
- Introduction of the Java platform editions
- J2SE, J2EE, and J2ME split
- Swing GUI framework
-
2000: Java 1.3
- HotSpot JVM included
- Java Sound framework
- JNDI included in core
-
2002: Java 1.4
- Assert keyword
- Regular expressions
- Exception chaining
- IPv6 support
-
2004: Java 5 (1.5)
- Generics
- Annotations
- Enumerations
- Enhanced for loop
- Autoboxing/unboxing
-
2006: Java 6
- Performance improvements
- Scripting language support
- JDBC 4.0
- JAX-WS 2.0
-
2011: Java 7
- Try-with-resources
- Diamond operator
- Multi-catch blocks
- NIO.2 file API
-
2014: Java 8 (Major Release)
- Lambda expressions
- Stream API
- Optional class
- New Date/Time API
- Default methods
-
2018: Java 11 (LTS)
- Local variable type inference
- HTTP client API
- Single-file source code
- Dynamic class-file constants
-
2021: Java 17 (LTS)
- Sealed classes
- Pattern matching for switch
- Strong encapsulation of JDK internals
- Context-specific deserialization filters
-
2023: Java 21 (LTS)
- Virtual threads
- Pattern matching for switch
- Record patterns
- Sequenced collections
- Purpose: Embedded and mobile devices
- Key Features:
- Minimal memory footprint
- Optimized for limited resources
- Subset of SE APIs
- Use Cases:
- IoT devices
- Mobile phones
- Embedded systems
- Specifications:
- Connected Limited Device Configuration (CLDC)
- Connected Device Configuration (CDC)
- Mobile Information Device Profile (MIDP)
- Purpose: Core platform functionality
- Key Features:
- Complete core Java APIs
- Desktop and command-line capabilities
- Base for other editions
- Use Cases:
- Desktop applications (like this CCRM)
- Command-line tools
- Standard libraries
- Core Components:
- Language fundamentals
- Collections framework
- I/O and NIO
- Concurrency utilities
- Security features
- Purpose: Large-scale enterprise applications
- Key Features:
- Built on top of SE
- Enterprise-scale capabilities
- Distributed computing
- Use Cases:
- Web applications
- Enterprise systems
- Microservices
- Technologies:
- Servlets and JSP
- Enterprise JavaBeans (EJB)
- Java Persistence API (JPA)
- WebSocket and REST support
- Dependency Injection
┌─────────────────────────────────────────────┐
│ JDK │
│ ┌─────────────────────────────────────────┐ │
│ │ Development │ │
│ │ Tools (javac) │ │
│ │ ┌─────────────────────────────────────┐ │ │
│ │ │ JRE │ │ │
│ │ │ ┌─────────────────────────────────┐ │ │ │
│ │ │ │ JVM │ │ │ │
│ │ │ │ - Bytecode Verifier │ │ │ │
│ │ │ │ - Class Loader │ │ │ │
│ │ │ │ - Execution Engine │ │ │ │
│ │ │ └─────────────────────────────────┘ │ │ │
│ │ │ Class Libraries │ │ │
│ │ └─────────────────────────────────────┘ │ │
│ └─────────────────────────────────────────┘ │
└─────────────────────────────────────────────┘
- Purpose: Complete development environment
- Components:
- Development Tools
- javac (compiler)
- jar (archiver)
- javadoc (documentation)
- jdb (debugger)
- JRE (for running applications)
- API Documentation
- Source Code
- Development Tools
- Purpose: Minimum environment to run Java applications
- Components:
- Java Class Libraries
- Core Classes
- Extension Classes
- Standard Libraries
- JVM
- Supporting Files
- Java Class Libraries
- Purpose: Abstract computing machine providing platform independence
- Key Components:
- Class Loader Subsystem
- Loading
- Linking
- Initialization
- Runtime Data Areas
- Method Area
- Heap
- Stack
- PC Registers
- Native Method Stack
- Execution Engine
- Interpreter
- JIT Compiler
- Garbage Collector
- Class Loader Subsystem
- Java source code (.java) is compiled to bytecode (.class)
- Class loader loads, links, and initializes the bytecode
- Bytecode verifier ensures code safety
- JVM executes the bytecode using:
- Interpreter for immediate execution
- JIT compiler for optimized performance
- Garbage collector manages memory automatically
- Java 17 or higher
- CSV file support
- Command-line interface
- Read/Write file system permissions
- Comprehensive Java platform documentation
- Detailed architectural explanations
- Evolution of Java documentation
- Platform comparison details
- Educational content for Java concepts
-
Download JDK 17
- Visit Oracle's JDK download page
- Select Windows x64 Installer
-
Run the Installer
-
Set JAVA_HOME
-
Update PATH
-
Verify Installation
java --version javac --version
-
Download Eclipse
- Visit Eclipse Downloads
- Choose "Eclipse IDE for Java Developers"
-
Install Eclipse
-
Import CCRM Project
Syllabus Topic | Implementation Location | Description |
---|---|---|
Abstract Classes | src/edu/ccrm/domain/Person.java |
Base class demonstrating abstraction |
Inheritance | src/edu/ccrm/domain/Student.java src/edu/ccrm/domain/Instructor.java |
Extends Person class |
Interfaces | src/edu/ccrm/service/Persistable.java src/edu/ccrm/service/Searchable.java |
Generic service contracts |
Collections | src/edu/ccrm/service/StudentServiceImpl.java |
ConcurrentHashMap usage |
Stream API | src/edu/ccrm/service/EnrollmentServiceImpl.java |
Data processing with streams |
File I/O | src/edu/ccrm/io/ImportExportService.java |
NIO.2 file operations |
Exception Handling | src/edu/ccrm/exception/ |
Custom exceptions |
Generics | src/edu/ccrm/service/Persistable.java |
Generic type parameters |
Lambda Expressions | src/edu/ccrm/util/CourseComparator.java |
Functional interfaces |
Date/Time API | src/edu/ccrm/util/DateTimeUtil.java |
Modern date operations |
-
Command-line:
java -ea -cp bin edu.ccrm.CCRMApp
-
Eclipse:
- Right-click project → Run As → Run Configurations
- Arguments tab → VM arguments:
-ea
// Validate student registration
public void enrollStudent(Student student, Course course) {
// Pre-conditions
assert student != null : "Student cannot be null";
assert course != null : "Course cannot be null";
assert student.isActive() : "Student must be active";
// Process enrollment
// ...
// Post-conditions
assert student.getEnrolledCourses().contains(course) : "Enrollment failed";
}
- Domain object validation
- Service layer pre/post conditions
- Data integrity checks
- Business rule enforcement
# Run specific test with assertions
java -ea -cp bin edu.ccrm.test.EnrollmentTest
# Run all tests with assertions
java -ea -cp bin edu.ccrm.test.TestSuite
# Run main application with assertions
java -ea -cp bin edu.ccrm.CCRMApp
- CSV file support
- Command-line interface
- Read/Write file system permissions
- Install JDK 17 or higher
- Open PowerShell in the project directory
- Create bin directory and compile:
mkdir bin javac -d bin src\edu\ccrm\CCRMApp.java src\edu\ccrm\cli\*.java src\edu\ccrm\config\*.java src\edu\ccrm\domain\*.java src\edu\ccrm\exception\*.java src\edu\ccrm\io\*.java src\edu\ccrm\service\*.java src\edu\ccrm\util\*.java
- Run the application:
java -cp bin edu.ccrm.CCRMApp
See USAGE.md for detailed operation instructions.