Senin, 18 Juli 2011

Web Service

Pengenalan terhadap XML :

Terdiri dari elemen dan dan atribut
Tag
dapat memiliki attributes. Dalam contoh dibawah ini, “task” pertama memiliki “id”
dengan attribut “1”, sedangkan “task” yang kedua memiliki “id” dengan attribute “2”.


connect to database
2
alex
50


list table rows
4
alex
100



Attributes
Tag dapat juga terdiri dari attribute-attribute. Didalam contoh, tag “task” memiliki
attribute dengan nama “id”. Sebuah attribut diikuti dengan tanda sama dengan (=) dan
diikuti dengan value atau nilainya.

XML Schema

Tag didefinisikan menggunakan XML schema language. Sebuah schema mendefinisikan
struktur dari dokumen XML. Sebuah skema juga digunakan membatasi content dari
sebuah dokumen XML kedalam sebuah element, attributes, dan values tertentu.

Namespace
Ada beberapa kasus dimana tag atau element Anda memiliki nama yang sama. Misalnya, ada
beberapa element yang mempunya nama yang sama yaitu “name”. Untuk mengatasi hal tersebut,
sebuah namespace digunakan.


Java APIs bagi XML

- JAXP

JAXP atau Java API for XML Processing (JAXP) adalah sebuah fleksible API yang
mendukung Anda untuk mendukung sembarang XML-complient parser didalam aplikasi
Java Anda. Ia memiliki sebuah layer plugability, dimana Anda dapat menambahkan
sembarang implementasi dari SAX atau DOM APIs.

- DOM API
Document Object Model (DOM) adalah sebuah struktur tree, dimana tiap node akan
terdiri dari sebuah komponen dari struktur XML.

- SAX API
Simple API for XML (SAX) adalah sebuah event-based XML parser API. Ia akan membaca
XML dokumen dari awal hingga akhir.

- XLST API

Extensible Stylesheet Language (XSL) memiliki tiga sub-komponen:
XSL-FO
– Formatting Objects standard. XSL-FO adalah sebuah standard yang
menyediakan mekanisme untuk mendeskripsikan aspek-aspek dari sebuah object
misalnya ukuran huruf dan layout halaman. Sub komponen ini tidak tercover didalam
JAXP.
XSLT
– adalah sebuah transformation language dimana Anda diharapkan dapat
mendefisinikan sendiri transformasi dari sebuah XML ke format yang lain seperti HTML.
Xpath
– adalah sebuah language spesification, dimana Anda diharapkan dapat
menspesifikasikan sendiri bagian-bagian dari struktur XML yang direference setiap saat.
Xpath adalah sebuah mekanisme pengalamatan yang mendukung Anda untuk
mendefinisikan sebuah path kepada element.

Web Services
>> Web Services Messaging
Beberapa karakteristik dari web service adalah:
- Message-based
- Standards-based
- Programming language independent
- Platform-neutral
>> SOAP (Simple Object Access Protocol)
adalah sebuah XML-based mark-up language untuk pergantian pesan diantara aplikasi-aplikasi. SOAP berguna seperti sebuah amplop yang digunakan untuk pertukaran data object didalam network.

Web Services Description
Spesifikasi WSDL mendefinisikan tujuh tipe element:
Types – element untuk mendefinisikan tipe data. Mereka akan mendefinisikan tipe data (seperti string atau integer) dari element didalam sebuah message.
- Message - abstract, pendefinisian tipe data yang akan dikomunikasikan.
- Operation – sebuah deskripsi abstract dari sebuah action yang didukung oleh service.
lebih dari satu endpoints.
- Port Type – sebuah koleksi abstract dari operations yang didukung oleh
menjadi sebuah protokol transport dan data format (ex. SOAP
- Binding – mendefinisikan penyatuan dari tipe port (koleksi dari operasioperasi)
1.1 pada HTTP). Ini adalah sebuah protokol konkret dan sebuah
spesifikasi data format didalam tipe port tertentu.
- Port – mendefinisikan sebuah komunikasi endpoint sebagai kombinasi dari
binding dan alamat network. Bagi protokol HTTP, ini adalah sebuah bentuk
dari URL sedangkan bagi protokol SMTP, ini adalah sebuah form dari email
address.
- Service – satu set port yang terkorelasi atau suatu endpoints.
»»  Baca Selengkapnya...

Aplikasi Midlet

Buatlah sebuah project dengan nama HelloWorld. Kemudian buatlah sebuah file Java
bernama HelloWorld.java yang berisi listing program sebagai berikut:

import javax.microedition.midlet.*;
import javax.microedition.lcdui.*;
public class HelloWorld extends MIDlet {
private Display display ;
private TextBox t ;
public HelloWorld(){
display = Display.getDisplay(this) ;
t = new TextBox("My First MIDlet","HelloWorld",256,0);
display.setCurrent(t);
}
public void startApp() {
}
public void pauseApp() {
}
public void destroyApp(boolean unconditional) {
}
}

Simpan file diatas pada direktori /src. Selanjutnya lakukan Build. Dari MIDlet
HelloWorld :
• Program Midlet mengimport paket javax.microedition.midlet dan
javax.microedition.lcdui. Paket javax.microedition.midlet
mendefinisikan MIDP dan paket javax.microedition.lcdui menyediakan
fungsi-fungsi untuk memanipulasi antarmuka GUI pada handled.
• Setiap program Midlet harus merupakan turunan dari class Midlet yang
didefinisikan pada paket javax.microedition.midlet. Hal ini mirip dengan
Applet yaitu setiap applet Java haruslah turunan dari class Applet atau JApplet.
MIDlet haruslah mengimplementasikan fungsi-fungsi abstract pada class MIDlet,
minimal 3 fungsi berikut :
o public void startApp()
o public void pauseApp()
o public void destroyApp(boolean unconditional)
• Setiap program MIDlet tidak boleh memiliki fungsi public static void
main(String args[]) selayaknya aplikasi Java non-Applet.
»»  Baca Selengkapnya...

Sabtu, 14 Mei 2011

Kuliah Mobile Game


hari ini baru pertama kali aku mendapatkan mata kuliah mobile programming dimana disini menggunakan bahasa pemrograman JENI yang diajar dosen dari seamolec yaitu bu cahya tapi bu cahya tidak masuk digantikan oleh pak prayitno. langkah pertama kita diminta untuk menginstal java yang urutannya adalah :
1. Instal jdk (java development kit)
2. Netbeans
latihan awal kita membuat hello world langkahnya :
1. file new project
2. Pilih JavaME
3. Mobile Aplication
4. Disitu ada beberapa pilihan tampilan resolusi dan layoutnya
Emulator Platform, Device, Device Configuration, Device Profile ( kalau tidak ingin banyak fitur biasanya di Device Configuration : CLDC.1.0 dan Device Profile : MIDP-2.0 )
5. Finish (Maka secara otomatis tampil emulator hello world)

»»  Baca Selengkapnya...

Sabtu, 31 Juli 2010

apt proxy configuration

when beginning to use a proxy I'm very glad, how glad not everyone who can I restrict internet access and blocked when coming to the sites that smelled of pornography. but this made me upset when I want to update linux can not because of the proxy server after several hours I tried to try, eh was just added this script only.
step 1
* you type this command
# Nano / etc / apt / apt.conf (usually this file does not exist)

step 2
* you enter this script
Acquire:: http::Proxy "http://192.168.0.1:8080";

* you save
* type a command to test
# apt-get update

if no error appears means that successful
good luck
»»  Baca Selengkapnya...

Minggu, 25 Juli 2010

Create Book Pages in Microsoft Word 2007

when we make a book like this form will be pages, page 1 then page 2 and so forth behind him like that. There are steps that must be done:

step 1
you click the page layout ---> margin ---> custom margins
for multipage menu that normally you'd change it to mirror page
display will appear like this:






























step 2
klik home --> Print
check setting on manual duplex
klik OK

after that the printer will automatically print your pages, wait until a command to reverse the paper. when there are orders behind the paper and submit it to the printer. do not let the wrong turn it over. ok. good luck

»»  Baca Selengkapnya...

Rabu, 30 Juni 2010

Changing the Mysql Password

Mysql is a powerful database software, reliable security and convenience in use and can integrate with other databases.
steps to change the mysql password is as follows:
1. You run the mysql with the following command:
/etc/init.d/mysql start || service mysql start

2.Sign in to mysql by typing the following command:
mysql -u root -p

when prompted enter the password in it because by default the password blank.
3.Select the mysql database by typing the following command:
use mysql;

4.To find a list of existing users enter the following command :
select user,password from user;

5.If there's just delete the blank user because if not delete all the one entered into the database just by typing the command mysql only.
delete user from user where user='';

6.Well now we only replace his root password
update user set password=password(‘password baru’) where user=’root’;

7.Then write flush privileges;
8.Replacement of the password has been finished, now exit from mysql by typing quit;
9.Restart mysql with command /etc/init.d/mysql restrart certainly by the root user.
Well now we've got a new mysql password. So when we go in as root user will be asked for his password.
»»  Baca Selengkapnya...

Rabu, 18 Februari 2009

Eliminate Virus Recycler

Recently I was made dizzy by a virus on this one, why not confused harm can not be scanned by any anti-virus can not lose, really crazy???. this way the virus can be lost. alhamdullillah.
easy to remove viruses Recycler, Recycler folder instead you click on the recycle bin you press shift and hold press del. but the records should be scanned first with antivirus is uptodate.
good luck! Bablas Angine ...
»»  Baca Selengkapnya...