Friday, July 9, 2010

Java 3

Java-OOP-object oriented programming-modular/reusable

reusable modules = classes
modules: small part of the entire program
the name of the library.package.name of class
write text - java.lang.System
formatted text - java.awt.Font
shapes - java.awt.Graphics
See Java API(Application programming Interface) document for all the reusable classes
Class
-reusable modules, create instances, filled with methods, provide you applet with methods
- serve as a blueprints for the objects that programmers need to create
Instances = Objects
-each object you create is referred to as an instance of the class
Class Attributes (Noun)
-deta elements defined in a class
-data items that describe things a class represent
Method (Action)
-make the instances do something
1. Set data values
2. Protect data elements from errors
SDK(Software Development Kit)
JRE (java Runtime Engine)
JDK (Java Development Kit)
-collection of reusable modules/classes
1. complies
2. runs the java program
BlueJ program - a GUI(Graphic User Interface)
1. edit
2. compile
3. test out/ run programs
UML (Unified Modeling Language)
example - explanation

Student - name of class/ title
Name
Address - list of data attributes/ the message to display
Phone
Set Personal Info - methods it needs to do its job/ what botton the user clicks
Enroll

No comments:

Post a Comment