UML Use Case Diagram for GPS Application

UML Use Case Diagram is :
The use case model captures the requirements of a system.
Use cases are services or functions provided by the system to its users.
A use case is a set of scenarios that describing an interaction between a user and a system.
Use case diagrams model the functionality of a system using actors and use cases.


The two main components of a use case diagram are use cases and actors.


An actor is represents a user or another system that will interact with the system you are modeling.
A use case is an external view of the system that represents some action the user might perform in order to complete a task.


Below is my sample use case for GPS system :
use case for admin side;

use case for client side;

Balinese Art Shop Online


One tourist destination in the world's most famous is the Bali island (Island of the Gods) besides having an amazing culture and an amazing tourist area. Bali community is also a good craftsmen. if you want to buy art bali products, you can visit the site Balineseartshop.

There you can see the results of the public arts of Bali and can be bought without having to come to Bali.

In this blog I included some photos of the products sold on the website Balineseartshop.













From Balineseartshop


BY ART FROM MY SITE - We are an online art shop that provides various traditional arts of Bali. we are here to offer low prices and excellent customer service. if you want to get the latest information about our products you can log in and become a member of our online art shop. if you become a member you will also get a variety of convenience shipping or discounts from us.

Create J2ME MidLet with Command, List and Alert

The following is a simple example of creating a Command, List and the Alert in J2ME Midlet. The first thing you should do is install the JDK on the C system, then install the Java ™ Platform Micro Edition Software Development Kit or Netbean built J2ME.

This program that we will create:

list menu :


select one list :


result alert :





The following step program creation :


Step #1 : create all object needed and declare it


public class Menu21 extends MIDlet implements CommandListener{
//create object needed
private List mainMenu;
private List titleFilm;
private List contactkAdm;
private List scheduleFilm;
private Command cmdExit;
private Command cmdBack;
private Command cmdSelect;
private Display display;
private Alert alert1;
private Image img = null;

public Menu21(){
//declare object
display = Display.getDisplay(this);
mainMenu = new List("Theatre21", Choice.IMPLICIT);
titleFilm = new List("Title", Choice.IMPLICIT);
contactkAdm = new List("Contact", Choice.EXCLUSIVE);
scheduleFilm = new List("Schedule", Choice.MULTIPLE);
cmdBack = new Command("Back", Command.BACK, 1);
cmdExit = new Command("Exit", Command.EXIT, 2);
cmdSelect = new Command("Select", Command.SCREEN, 2);
alert1 = new Alert(null);
alert1.setTimeout(10000);

}



Step #2: makes all the objects and fill in the required content in objects startApp ()


public void startApp() {
//create object icon
try {
img = Image.createImage("/small.png");
}catch(Exception e){
System.out.println("image null " +e.getMessage());
img=null;
}

//add command to main menu
mainMenu.addCommand(cmdExit);
mainMenu.addCommand(cmdPilihl);

//add list to main menu
mainMenu.append("Title", img);
mainMenu.append("contact", img);
mainMenu.append("Schedule", img);
mainMenu.append("Info", img);

//set command main menu
mainMenu.setCommandListener(this);
//set main menu as displayable
display.setCurrent(mainMenu);

}


Step #3 : Create Command listener


public void commandAction(Command c, Displayable d) {
if (c==cmdExit){
destroyApp(false);
notifyDestroyed();
}else if(c==cmdPilihl){
if(display.getCurrent()==mainMenu){
evenMainMenu();
}else if(display.getCurrent()==titleFilm){
evenTitle();
}else if(display.getCurrent()==contactkAdm){
evenContact();
}else if(display.getCurrent()==scheduleFilm){
evenSchedule();
}
}else if(c==cmdBack){
display.setCurrent(mainMenu);
}
}




Step #4 : Create all Object needed in action listener

private void evenJudul() {
int i = titleFilm.getSelectedIndex();
alert1.setTitle("Title " + titleFilm.getString(i));
if(titleFilm.getString(i).equals("Avatar")){
alert1.setString("i think you know about this film...");
}else if(titleFilm.getSelectedIndex()==1){
alert1.setString("menceritakan tentang bumi th 2012");
}else if(titleFilm.getSelectedIndex()==2){
alert1.setString("i don't know about this film..");
}else if(titleFilm.getSelectedIndex()==3){
alert1.setString("story about Gi Joe the 'Bolang'");
}
display.setCurrent(alert1);
}


private void evenContact() {
int i = contactkAdm.getSelectedIndex();
alert1.setTitle(contactkAdm.getString(i)+" kami :\n");
if(i==0){
alert1.setString("cieforblack@gmail.com");
}else if(i==1){
alert1.setString("cie_78@yahoo.com");
}else if(i==2){
alert1.setString("ciefor78@gmail.com");
}
display.setCurrent(alert1);
}

private void evenSchedule() {
boolean[] selctSchedule = new boolean[scheduleFilm.size()];
int jumpil = scheduleFilm.getSelectedFlags(selectSchedule);
alert1.setTitle("Schedule 21");

StringBuffer isi = new StringBuffer("You select "+jumpil+" hari\n");
for(int i=0;i if(selectSchedule[i])
isi.append((i+1)+". hari "+scheduleFilm.getString(i)+"\n");
}

alert1.setString(isi.toString());
display.setCurrent(alert1);
}

private void evenMainMenu() {
if(mainMenu.getSelectedIndex()==0){
listtitle();
}else if(mainMenu.getSelectedIndex()==1){
listContact();
}else if(mainMenu.getSelectedIndex()==2){
listSchedule();
}else if(mainMenu.getSelectedIndex()==3){
info21();
}
}


private void info21() {
alert1.setTitle("INFORMATION");
alert1.setString("Bioskop21 Information\n"
+"Name : Widya\n"
+"Nim : 07.11.1634");

display.setCurrent(alert1);
}

private void listSchedule() {
jadwalFilm.deleteAll();

scheduleFilm.addCommand(cmdExit);
scheduleFilm.addCommand(cmdBack);
scheduleFilm.addCommand(cmdPilihl);

scheduleFilm.append("Monday", null);
scheduleFilm.append("Tuesday", null);
scheduleFilm.append("Wednesday", null);
scheduleFilm.append("Thursday", null);
scheduleFilm.append("Friday", null);
scheduleFilm.append("Saturday", null);
scheduleFilm.append("Sunday", null);

scheduleFilm.setCommandListener(this);
display.setCurrent(scheduleFilm);
}

private void listTitle() {
try {
img = Image.createImage("/small.png");
}catch(Exception e){
System.out.println("image null " +e.getMessage());
img=null;
}

titleFilm.deleteAll();

titleFilm.addCommand(cmdExit);
titleFilm.addCommand(cmdPilihl);
titleFilm.addCommand(cmdBack);

titleFilm.append("Avatar", img);
titleFilm.append("2012", null);
titleFilm.append("UP IN THE AIR", null);
titleFilm.append("GI JOE", null);

titleFilm.setCommandListener(this);
display.setCurrent(judulFilm);
}

private void listContact() {

contactAdm.deleteAll();
contactAdm.addCommand(cmdExit);
contactAdm.addCommand(cmdBack);
contactAdm.addCommand(cmdSelect);

contactAdm.append("E-Mail", null);
contactAdm.append("Facebook", null);
contactAdm.append("Yahoo", null);

contactAdm.setCommandListener(this);
display.setCurrent(contactAdm);
}

Apple iPad still has some weaknesses





New tablet computer from Apple, iPad, is a revolutionary device. Steve Jobs, CEO of Apple, even commenting on this device as 'the most important thing' is announced.

content and features that are owned, Apple iPad is quite promising. The device mentioned can have many functions for its users, ranging from e-book reader, video player and even to handheld game consoles.

However, Apple iPad still considered to have some shortcomings. These deficiencies could be a reason for consumers to not rush to adopt Apple's gadget is cool.

What are the drawbacks? according to InformationWeek, following a number of weaknesses in Apple iPad:

  • No Adobe flash
  • Not equipped with a camera
  • Not to multitasking
  • The screen has a small size, which is 9.7 inches
  • Not using Mac OS
  • Storage capacity is not big enough
  • The battery is not easily replaced
  • Does not have HDMI port

what with all these shortcomings iPad, this product will still be interested?? we will wait seoak exploits of this great product.

see also :
Apple iPad new technology from Apple

Apple iPad new technology from Apple

Apple CEO, Steve Jobs announced the latest product named Apple iPad. iPad is probably the latest version of the iPhone, because it has the exact same form with the iPhone.

This technologically advanced device touch screen with dimensions of 9.7 inches and weighs 1.5 pounds. Processors using Apple processor A4 1 GHz. Battery endurance is almost the same as the iPod resistance in general, ie for 10 hours for the use of active and nearly a month when in standby.

iPad is launched in two versions, first version with dibandrol As the price of 499 dollars with 16 GB of memory and one worth 829 U.S. dollars with 65 GB of memory and is equipped with 3G connectivity. but for the both version has been equipped iPad WiFi devices.

For the name, Apple even had to buy the copyright of Fujitsu iPad've used first names for one product.

The function of the iPad was almost the same as the iPhone, ranging from check emails, browsing, streaming from YouTube, see photos and video, iWorks etc. But that became the hallmarks of this iPad is a application to read and direct mendonload aka e-books electronic books from the Internet. To support that, at the same time Apple also opened a new online store, iBook Store.

but these new products sold in the U.S. market. New iPad next 2-3 months will touch another country markets.

see also :
Apple iPad still has some weaknesses

Vespa and sexy girl

Piaggio aircraft factory during which produces many types of aircraft during World War 2 was destroyed by allied bombers. This company became bankrupt, so that after the world war over this company was taken over by enrico piagio. Because he saw the roads in Italy were destroyed and the economy is bad then he led the company to focus on designing an inexpensive
means of transportation.


Corradino d'Ascanio was an aeronautical engineer who used to designed, built, and flew the first modern helicopter in the world, eventually was asked to reply to design a simple reply of transportation, economical, but also comfortable and elegant D'Ascanio was an engineer who really hate the bike why he designed a revolutionary new product that yg inspired to apply aircraft and aircraft technology (monocoque construction, front-wheel design is also derived from the design of aircraft wheels, for easy replacement tires) even the initial products, is using an aircraft wheel

vespa, the name given enrico himself when he first saw the design the vespa = a kind of Italian bees (Wasp in english)
until now, the design remains the Vespa motorcycle design most sensual truly revolutionary machine simpe step 2

Most structures using aluminum design also considered a completely different motorcycle was considered noisy and uncomfortable

This antique motorcycle enthusiasts are not only men but also women. vespa always look beautiful when integrated with a woman.

vesva antique galery :









a simple client/server source in java

in building the client / server application we will make two initial source, the server source and the client source for connections to the server.
The following is a simple example of the connection client / server using TCP.





code for the server :



/**
* Tserver.java
* Example server program using TCP.
*/
import javax.swing.*;
public class Tserver {

final static int serverPort = 3456; // port server location

public static void main(String args[]) {
java.net.ServerSocket sock = null; // server socket location
java.net.Socket clientSocket = null; // creating socket
java.io.PrintWriter pw = null; // output soket
java.io.BufferedReader br = null; // input soket

try {
sock = new java.net.ServerSocket(serverPort); // create socket and bind to port
System.out.println("waiting connection from client..");
clientSocket = sock.accept(); // waiting connection from client
System.out.println("connection successfull");
pw = new java.io.PrintWriter
(clientSocket.getOutputStream(),true);
br = new java.io.BufferedReader(
new java.io.InputStreamReader(clientSocket.getInputStream()));

Integer r = Integer.parseInt(br.readLine()); // read message from client
Double hsl = 3.14 * r * r ;
//System.out.println("pesan dari client.. >" + hsl);
JOptionPane.showMessageDialog(null,answer "+hsl); // send response to client

pw.close(); // closing
br.close();
clientSocket.close();
sock.close();
} catch (Throwable e) {
System.out.println("Error " + e.getMessage());
e.printStackTrace();
}
}
}




code for the client :
Java Programming for a Beginner, 5-disk DVD Complete Training Suite. Edition 2009




SOURCE CODE


/**
* Tclient.java
* Example Client program using TCP.
*/
import javax.swing.*;
public class Tclient {

final static String serverIPname = "localhost"; // server IP name
final static int serverPort = 3456; // port server

public static void main(String args[]) {
java.net.Socket sock = null; // Socket object for connection
java.io.PrintWriter pw = null; // socket output to server
java.io.BufferedReader br = null; // socket input from server

try {
sock = new java.net.Socket(serverIPname,serverPort); // create socket and connection
pw = new java.io.PrintWriter(sock.getOutputStream(), true); // create reader and writer
br = new java.io.BufferedReader(new java.io.InputStreamReader(sock.getInputStream()));
System.out.println("Koneksi ke server");
pw.println(JOptionPane.showInputDialog(null,"masukkan nilai r ")); //send message to server
System.out.println("sending message to server");
String answer = br.readLine(); // get data server
System.out.println("message from server"+ answer);
JOptionPane.showMessageDialog(null,"server answer " + answer);
pw.close(); // closing
br.close();
sock.close();
} catch (Throwable e) {
System.out.println("Error " + e.getMessage());
e.printStackTrace();
}
}
}