0% found this document useful (0 votes)
51 views15 pages

Ilovepdf Merged

Hi am study diploma in Computer engineering and technology

Uploaded by

sayedshaad02
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
51 views15 pages

Ilovepdf Merged

Hi am study diploma in Computer engineering and technology

Uploaded by

sayedshaad02
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 15

PART A – Micro-Project Proposal

Music Player using Java

1.0 Brief Introduction


a. Java is a class-based, object-oriented programming language that is
designed to have as few implementation dependencies as possible. It is a
general-purpose programming language intended to let application
developers write once, run anywhere (WORA), meaning that compiled
Java code can run on all platforms that support Java without the need for
recompilation. Java applications are typically compiled to bytecode that
can run on any Java virtual machine (JVM) regardless of the underlying
computer architecture. The syntax of Java is similar to C and C++, but
has fewer low-level facilities than either of them. The Java runtime
provides dynamic capabilities (such as reflection and runtime code
modification) that are typically not available in traditional compiled
languages.

i. Java was originally developed by James Gosling at Sun


Microsystems (which has since been acquired by Oracle) and
released in 1995 as a core component of Sun Microsystems' Java
platform. The original and reference implementation Java
compilers, virtual machines, and class libraries were originally
released by Sun under proprietary licenses. As of May 2007, in
compliance with the specifications of the Java Community Process,
Sun had relicensed most of its Java technologies under the GNU
General Public License. Oracle offers its own HotSpot Java Virtual
Machine, however the official reference implementation reference
implementation is the OpenJDK JVM which is free open source
software and used by most developers and is the default JVM for
almost all Linux distributions.

Music Player lets you manage all your music files quickly and easily . This audio
player supports almost all types of mp3 , midi ,wav , flac raw aac files and other
audio formats .

Easily browse and play music songs by genres , albums , artists , songs and folder.
Media is integral parts of our lives. We are creating media player using java to
handle all the music requirements of user.

2.0 Aim of the Micro-Project


To Design a java program play music stored on machine and control it using
various java components.

3.0 Intended Course Outcomes


Java Basics: Understand syntax and OOP principles.
File Handling: Manage and read audio files.
GUI Design: Create user-friendly interfaces.
Audio Playback: Integrate playback using Java Sound API.
Event Handling: Implement user interaction responses.
Testing: Develop debugging and testing skills.
Project Management: Organize with version control and documentation.
Enhancements: Add features like playlists and volume control.
Deployment: Package and distribute the application.

4.0 Literature Review

1. Java Sound API: Tools for audio playback and manipulation (Oracle).
2. JavaFX and Swing: Frameworks for creating user interfaces (J.F. DiMarzio).
3. Audio File Formats: Understanding MP3, WAV encoding/decoding (Bruce B.
R. B.).
4. Event-Driven Programming: Essential for user interaction in GUIs (Cay S.
Horstmann).
5. Multimedia Frameworks: Libraries like JLayer and JavaFX Media for audio
support (John F. Meyer).
6. User Experience Design: Focus on intuitive interfaces and user-centered
design (Steve Krug).

5.0 Proposed Methodology

1. Requirements Analysis: Gather user needs for features.


2. System Design: Plan architecture and UI layout.
3. Technology Selection: Choose libraries (Java Sound API, JLayer)
and frameworks (JavaFX, Swing).
4. Implementation:
o Develop UI.
o Implement audio management (playback controls).
o Program event handling.
5. Testing: Perform unit and integration testing.
6. User Feedback: Collect and incorporate user feedback.
7. Deployment: Package as executable JAR or installer.

This structured approach ensures a comprehensive development process for


the music player.

5.0 Resources Required (major resources like raw material, tools, software etc.)
S. No. Name of Specifications Qty Remarks
Resource/material
1 PC Core i3, RAM 4GB 1
2 Operating System Windows 10/11 1
3 Software JDK 20, VS Code/Eclipse 1

6.0 Action Plan (Sequence and time required for major activities for 8-10 Weeks)

S. No. Details of activity Planned Planned Name of


Start date Finish date Responsible Team
Members
1 Analysis 29/07/2024 03/08/2024
Develop programs to handle events in Java
2 05/08/2024 10/08/2024
Programming
Develop programs using GUI Framework
3 12/08/2024 17/08/2024
(AWT and Swing)
Write algorithm and draw program
4 19/08/2024 24/08/2024
flowchart
5 Coding and testing 02/09/2024 07/09/2024
6 Coding and testing 09/09/2024 14/09/2024
7 Coding and testing 16/09/2024 21/09/2024
8 Coding and testing 23/09/2024 28/09/2024
9 Report writing 30/10/2024 05/10/2024
10 Demo and Submission 07/10/2024 12/10/2024
Submitted by:
1) 1 UZEEFA KHAN
2) SAYED FAIZAN
3) SAYYED HAMMAD
4) MEHRAAN SHAIKH
A Micro-project Report on “Calculator using Swing”

PART B – Micro-Project Report

Acknowledgement

It is not until you undertake the project like this one that you realize how massive the effort it really
is, or how much you must rely upon the Selfless efforts and goodwill of others. There are many who
helped us with this project, and we want to thank them all from the core of our Hearts.
We owe special words of thanks to our Teacher Afzal Ahmad Sir for their vision, thoughtful counseling
and encouragement at every step of the project. We are also thankful to the teachers of the Department
for giving us the best of knowledge and guidance throughout the project.
And last but not the least, we find no words to acknowledge the financial assistance & moral support
rendered by our parents in making the effort a success. All this has become reality because of their
blessings and above all by the grace of God.

1|Page
A Micro-project Report on “Calculator using Swing”

CONTENTS

1 Rationale ……………….…………………………………………………..…….. 3

2 Course Outcomes Addressed .………………………………………….…..……. 3

3 Literature Review ………………………………………………………..………. 3

4 Actual Methodology followed …………………………………………..………. 7

5 Actual Resources Required …………………………………..…………..…….. 8

6 Output of Miro-Project …………………………………………..………..……. 8

7 Skills Developed/Learning out of this Micro-Project ………………..……….. 8

8 Applications of this Microproject ..……………………………….…..…………. 8

9 Area of Future Improvement ………………………………………………….. 8

2|Page
A Micro-project Report on “Calculator using Swing”

Calculator using Swing

1.0 Rationale
Project work is the activity that is intended to integrate all the domains of learning i.e. cognitive,
psychomotor and affective domains wherever applicable, the hence it is very important from the
teacher and student point of view. Any project work is not research, but an experience of doing some
complex work by students on their own, or ‘work-based learning’. Project can be of micro, mini, minor
and major levels depending on at what stage of learning (from first semester to the last semester) it is
incorporated; but all these categories will have the same characteristics. Only the amount of effort put
in and time required will be changing. Therefore, the project work is defined as ‘A purposeful student
activity planned, designed and performed by a student or group of students to solve the identified
problems (or complete a relatively complex task) which requires them to integrate the various
types of skills acquired over a period to help them to accomplish higher level of cognitive and
affective domain outcomes and sometimes the psychomotor domain outcomes as well'. (Earnest,
Joshua and S. K. Gupta). This definition means that the project work leads to the integration of
knowledge, skills and attitudes of the three domains of learning acquired over a period of time.

2.0 Course Outcomes Addressed


1.Develop programs to handle events in Java Programming.

2.Develop programs using GUI Framework (AWT and Swing).

3.0 Literature Review

1. Java Sound API: Tools for audio playback and manipulation (Oracle).
2. JavaFX and Swing: Frameworks for creating user interfaces (J.F. DiMarzio).
3. Audio File Formats: Understanding MP3, WAV encoding/decoding (Bruce B. R.
B.).
4. Event-Driven Programming: Essential for user interaction in GUIs (Cay S.
Horstmann).
5. Multimedia Frameworks: Libraries like JLayer and JavaFX Media for audio
support (John F. Meyer).
6. User Experience Design: Focus on intuitive interfaces and user-centered design
(Steve Krug).
3|Page
A Micro-project Report on “Calculator using Swing”

Websites:
https://www.tutorialspoint.com/java/
http://nptel.ac.in/courses/106105084/30
https://www.javatpoint.com/java-tutorial
https://docs.oracle.com/

4.0 Actual Methodology Followed


In order to create any application/program following steps are followed.
• Defining and Analyzing the Problem. In this step, a programmer studies the problem
• Designing the Algorithm and drawing flowcharts
• Coding or Writing the Program
• Test Execution
• Debugging
• Final Documentation.
As each member wanted to learn all the steps, we have done all the activities as a team. Each member
was involved in every step.
 Calculator front end was designed on paper.
 Accordingly, GUI of calculator using Swing was developed.
 Event handling mechanism was implemented.

Algorithm:

 Import Required Libraries:

 Java Swing (GUI components)


 AWT (for layout and events)
 JavaZoom (for audio playback)

 Class Declaration:

 layer class banaiye jo audio player functionalities ko contain kare.

 Initialize Variables:

 Player, BufferedInputStream, FileInputStream, aur File objects declare karein.

 Constructor (layer):

4|Page
A Micro-project Report on “Calculator using Swing”
 JFrame create karein aur iski properties set karein (size, layout, background color).
 Choose Your Song button create karein:
o ActionListener add karein jo open_dialog() method call kare.
 Play button create karein:
o ActionListener add karein jo audio file ko play kare.
 Pause button create karein:
o ActionListener add karein jo audio ko pause kare.

 Open Dialog Method (open_dialog):

 JFileChooser use karein user ko file select karne ke liye.


 Agar user file select kare:
o File ka path lein aur FileInputStream aur BufferedInputStream initialize karein.
o Player object create karein audio playback ke liye.

 Main Method:

 layer class ka instance create karein aur application ko run karein.

5.0 Actual Resources Used


S. No. Name of Specifications Qty Remarks
Resource/material
1 PC Core i3, RAM 4GB 1
2 Operating System Windows 10 1
3 Software Turbo C 1

6.0 Outputs of the Micro-Project


Coding:
package jlay;

import javax.swing.*; import java.awt.*;


import java.awt.event.ActionEvent; import
java.awt.event.ActionListener; import
java.io.BufferedInputStream;

import java.io.File;

5|Page
A Micro-project Report on “Calculator using Swing”

import javazoom.jl.decoder.JavaLayerException;
import javazoom.jl.player.Player; import
java.io.FileInputStream; import java.io.IOException;

import java.util.function.Function;

public class layer {

Player ;

BufferedInputStream bis;

FileInputStream fis;

File file;

layer(){

JFrame main = new JFrame();


main.setVisible(true); main.setVisible(400,440);
main.setLayout(new FlowLayout());

main.setBackground(Color.MAGENTA);

JButton choose = new JButton("Choose Your Song");

choose.addActionListener

new ActionListener()

@Override

public void action Performed(ActionEvent actionEvent)

open_dialog();

);

main.add(choose);

6|Page
A Micro-project Report on “Calculator using Swing”
JButton play = new JButton("Play"); play.addActionListener(new
ActionListener() {

@Override

public void actionPerformed(ActionEvent actionEvent) {


try {

player.play(100);

catch (Exception x){}

});

main.add(play);

JButton pause = new JButton("Pause"); pause.addActionListener(new


ActionListener() {

@Override

public void actionPerformed(ActionEvent actionEvent) {


try {

player.wait();

catch (Exception x){}

});

main.add(pause);

main.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);

void open_dialog()

JFileChooser fc = new JFileChooser();

7|Page
A Micro-project Report on “Calculator using Swing”
int result = fc.showOpenDialog(null);

if (result == JFileChooser.APPROVE_OPTION)

{ try
{

file = new File(fc.getSelectedFile().getAbsolutePath()); fis


= new FileInputStream(file);

bis = new BufferedInputStream(fis);

try {

player = new javazoom.jl.player.Player(bis);

catch (Exception ec){}

catch(IOException e)

e.printStackTrace();

public static void main(String[] args)

layer l = new layer();

Output screen snapshot:

8|Page
A Micro-project Report on “Calculator using Swing”

9|Page
A Micro-project Report on “Calculator using Swing”

7.0 Skill Developed / learning out of this Micro-Project


Thus we have build music player using Java and various GUI components.

8.0 Applications of this Micro-Project


This calculator can be used to perform basic mathematical operations on two numbers.

9.0 Area of Future Improvement


 Floating point numbers operations.
 Scientific operations.
 Unit converters can be added.

**************

10 | P a g e
A Micro-project Report on “Calculator using Swing”
Total
Process Assessment Product Assessment
Marks
Project
Roll
Name Project Project Report/ Individual
No.
Proposal (2 Methodology Working Presentation 10
marks) (2 marks) model (2 (4 Marks)
marks)

11 | P a g e

You might also like