Nov
13
2008
0

Java Programming with Passion: Day 2

The link to the online training

2. Learning the basics of Java language

Getting input from keyboard

The finished project mygetinputfromkeyboardjoptionpaneproject2

Control Structure

The finished project myownwhileproject

Written by hkai in: Java, Learning Track | Tags:
Nov
13
2008
0

Java Programming with Passion: Day 1

The link to the online training.
I know I’m lazy, it’s nearly 3 months ago I decided to take this online training course, but it’s just today I started seriously. So I’m challenging myself to finish the 13 weeks online training within 2 weeks to cache up with others if any. To prove it, I’ll post the progress and my homework.

1. Getting started

Getting to know your Java programming environment

myhelloproject2.zip is the finished project.

Java programming basics

Difference about && and & is: & will evaluate the expression whether the 1st is true or false, so does | and ||.

int i=0; boolean result= (i>0) && (++i>0); //here the result=false and i=0 since ++i was not evaluted
result= (i>0) & (++i>0); //here result still false but i=1

The finished project mygreatestvalueproject2

Written by hkai in: Java, Learning Track | Tags:
Aug
06
2008
1

Java Programming with Passion: Week1

It’s been 2 years since my last Java project. I decided to spend sometime to renew my Java knowledge by taking Sang Shin’s course.
I’ll report my progress and upload my finished homework here.

You can find the tutorial hereĀ 

Written by hkai in: Java, Learning Track |
Nov
20
2007
0

Using android.widget.ArrayAdapter

I’m developing the universal converter on a new platform: Android
The 1st screen will be a ListActivity, if it’s an array of object, android.widget.ArrayAdapter would be very helpful.
Here’s a sample:

 private Vector<Type> types;
 public void onCreate(Bundle icicle) {
        super.onCreate(icicle);
        init();
        setListAdapter(new ArrayAdapter<Type>(this,
                android.R.layout.simple_list_item_1_small, types));
    }

android.R.layout.simple_list_item_1 and simple_list_item_1_small works fine with ArrayAdapter.

Written by hkai in: Android, Java, Mobile, Universal Converter |
Jul
18
2007
0

ATUC Part 3: J2ME Edition with NetBeans Mobility 5.5

Play it on your phone!

Download the JAD/JAR file: atuc_nbjme.zip

The development notes: nbjme_development_notes.pdf

nbjme_01.jpg

Written by hkai in: Java, Universal Converter |
Jul
18
2007
1

ATUC Part 2: Java Edition with NetBeans 5.5

Java is my favorite programming language since 1996, and NetBeans is my favorite Java IDE since 1998.

It tooks me 2-3 hours to develop the Java Edition, download the Jar file here

Execute this way: java -jar atuc_nbjse.jar

The development notes: nbjse_development_notes.pdf

nbjse_01.jpg

Written by hkai in: Java, My Software, Universal Converter |
Apr
29
2007
0

Migration from Windows to Linux Part6: Java development environment

Since 1996, I begin to use Java 1.0 to develop programs, on Windows and then Linux.
Now I’m using Java 1.5 and IDEA 5.0 for most of my Java development.
I also use Netbeans5.5, as I use Forte 1.0 since 1997, and Netbeans is still my favorite IDE for Java.

Install Sun JDK 1.6 through Automagix2, and then you can install Sun JDK 1.5 with this command:

aptitude install sun-java5-jdk

IDEA 5.0 need JDK 1.5 to run, it’s not supporting JDK 1.6.

After installed JDK1.5 and JDK1.6, it’s time to install some Java tools and IDE

  1. Squirrel SQL client:
    • install: java -jar squirrel-sql-2.5-install.jar
    • configure the JDBC drivers for MSSQL, add jtds-1.2.jar
    • for MySQL, add mysql-connector-java.jar
  2. NetBeans 5.5
    • just download and install
    • copy C:\Documents and Settings\username\.netbeans\5.5 to /home/username/.netbeans/5.5
    • Start netbeans
  3. IDEA
    • unzip to a dir, like /opt/idea
    • change the file /opt/idea/bin/idea.sh
      IDEA_JDK=/usr/lib/jvm/java-1.5.0-sun
    • then run ./idea.sh
  4. I also installed the following software for my Java development works
    • iReport: design report from sql commands
    • Kettle: ETL works
  5. finally, I also installed eclipse, which is becoming popular recently, but I seldom use it. I heard about it’s very good on Java development, but I still like Netbeans and IDEA.
Written by hkai in: Java, Linux Ubuntu |
Apr
20
2007
0

Install SUN JDK

  1. apt-get install java-package
  2. download jdk-1_5_0_11-linux-i586.bin from http://java.sun.com
  3. login as a normal user, fakeroot make-jpkg jdk-1_5_0_11-linux-i586.bin
  4. dpkg -i sun-j2sdk1.5_1.5.0+update11_i386.deb

Didn’t test with JDK6 yet, but JDK5 should be enough till end of this year, as most software package works fine with JDK5.

Written by hkai in: Java, Linux Debian |
Dec
13
2006
0

upgrade SQuirreL SQL Client

Today I’m upgrading SQuirreL SQL Client to latest version 2.3.2.

Before I run the jar file, I execute the uninstaller of the old version. it locate at c:\program files\squirrel sql client\uninstaller

just run: java -jar uninstaller.jar

will uninstall the old version. The database session will be kept somewhere safe. When the new version installed, the session was there untouched.

Happy upgrading.

Written by hkai in: Java |
Nov
11
2006
0

NetBeans IDE 5.5

Just installed NetBeans 5.5 with Mobility, EE and Virtual Web pack. I think Sun are going to drop Java Studio Creator and even the Enterprise Edition. The Virtual Web is copied from Studio Creator and all components are there also.

In one word, if you are still using Eclipse, it’s time to switch to NetBeans in this release. It just has everything you need and it’s mature.

Written by hkai in: Java |

Powered by WordPress | Aeros Theme | TheBuckmaker.com WordPress Themes