#ff0000 30  - #000655 NetBeans 4.1 -  IDE   J2ME 
#000655  
#def    Java      IDE. ,    ,        .      NetBeans IDE 4.1 (www.netBeans.org). 

  ,   NetBeans IDE 4.1   Java 2 Platform, Micro Edition MIDP .           .    "MyHello",     "Hello World"   . 


 ,   NetBeans IDE 4.1  NetBeans Mobility Pack 4.1.    . 
  

  NetBeans IDE  ,    MIDP .    :    (MIDP Visual Designer)     (Source Code Editor). 

            ,     .     .     :       Source Editor,         Visual Designer.  ,      ,        . 

 Source Editor,      . Source Code Editor             .
 MIDP    Visual Designer-.
  J2ME MIDP 
 File > New Project (Ctrl-Shift-N).   Categories  Mobile;  Projects - Mobile Application    Next. 
 MyHello     (Project Name).   Project Location  .            $PROJECTHOME. 
  Set as Main Project  Create Hello MIDlet (     ).  Next. 
   Target Platform  J2ME Wireless Toolkit. 
  Finish.    $PROJECTHOME./MyHello.         .        Flow Design  Visual Designer. 
 Java 

    Midlet-. 
  Screen Design.      Screen Designer    helloTextBox[Textbox] ,    ,   . 
   helloTextBox   - .     "Hello, World!". 
   
 Run > Run Main Project (F6)   Run.     Output,      .       . ,  HelloMIDlet.java    .        .     DefaultColorPhone. 
        Launch.             . 
        Exit.    . 
 MIDP    Source Editor
  J2ME MIDP 
 File > New Project (Ctrl-Shift-N).   Categories  Mobile;  Projects - Mobile Application    Next. 
 MyHelloMIDlet     (Project Name).   Project Location  .            $PROJECTHOME. 
  Set as Main Project    Create Hello MIDlet.  Next. 
   Target Platform  J2ME Wireless Toolkit. 
  Finish.    $PROJECTHOME./MyHello.         . 
    MyHelloMIDlet   Explorer   New > File/Folder. 
 Categories  MIDP,  File Types  MIDlet   Next. 
     HelloMIDlet.  Finish.   HelloMIDlet.java. 
   HelloMIDlet.java  ,     . 
   Source Editor   

   public class HelloMidlet extends MIDlet
 

   public class HelloMIDlet
      extends MIDlet implements javax.microedition.lcdui.CommandListener
   {
     startApp(): 

public HelloMIDlet() { }
private void initialize() {
javax.microedition.lcdui.Display.getDisplay(this).setCurrent(get_helloTextBox());
}
public void commandAction(javax.microedition.lcdui.Command command, javax.microedition.lcdui.Displayable displayable) {
if (displayable == helloTextBox) {
if (command == exitCommand) {
javax.microedition.lcdui.Display.getDisplay(this).setCurrent(null);
destroyApp(true);
notifyDestroyed();
}
}
}
private javax.microedition.lcdui.TextBox get_helloTextBox() {
if (helloTextBox == null) {
helloTextBox = new javax.microedition.lcdui.TextBox(null, "Test String",120, 0x0);
helloTextBox.addCommand(get_exitCommand());
helloTextBox.setCommandListener(this);
}
return helloTextBox;
}
private javax.microedition.lcdui.Command get_exitCommand() {
if (exitCommand == null) {
exitCommand = new javax.microedition.lcdui.Command("Exit", javax.microedition.lcdui.Command.EXIT, 1);
}
return exitCommand;
}
javax.microedition.lcdui.TextBox helloTextBox;
javax.microedition.lcdui.Command exitCommand; 
  startApp()   

public void startApp() {
 initialize();
  }
 Java 

  ,    .      get_helloTextBox()  "Test String"   ,   "Hello World." 
   
 Run > Run Main Project (F6)   Run.     Output,      .       . ,  HelloMIDlet.java    .        .     DefaultColorPhone. 
        Launch.             . 
        Exit.    . 
  

       ,    MIDlet    .
  
     MyHello Project   Properties.   Properties  Platform.         . 
    Device   QwertyDevice.  OK. 
  .       QwertyDevice . 
   
  Tools > Java Platform Manager. 
  Java Platform Editor    Add Platform. 
  Choose Platform Folder  Add Platform   Browse.    ,    . , c:\WTK22.  Next. 
 Configure the Platform Page IDE    .        .  Finish. 
 File > "MyHello" Properties. 
  Platform ,      (, J2ME Wireless Toolkit 2.2)    Emulator Platform.  OK. 
 

       jar  jad   .             .
 
   MyHello Project   Properties.   Properties  Add Configuration    Project Configuration.      Add Configuration. 
      Configuration Name.           jar/jad . ,  BlackWhiteDisplay   OK.      . 
        Manage Configurations   Properties.     Project Configuration Manager,         . 
 

 ,      ,  .        Project Properties.
     MyHello Project   Properties.   Properties  Platform.     J2ME MIDP Configuration. 
       BlackWhiteDisplay. 
   Platform .         Default.     Use Default Project Configuration Values  .     . 
  Device  DefaultGrayPhone. 
 Project Configuration    Properties.  ,  Device      .         .  OK,       Properties. 
 ability

   ability,        ,    .      ability      ,  .        ,             .  ,      ability.         ,   ability.
     MyHello    Properties. 
 Abilities    Category. 
    Project Configuration.      ability. 
     Use Values  "DefaultConfiguration". 
  Add Ability.      Add Ability. 
  New Ability. 
  New Ability    ability.  OK.  ability     . 

   ability   .         Project Configuration    Add Ability.
    ( ).

    ,    ,        abilities.         ability.
        .     "Default Configuration".     BlackWhiteDisplay. 
         TextBox   Preprocessor Blocks > Create If/Else Block.       "Gray"   "Hello World".       "Color". 
       .  ,        . 
 

       .
     MyHello Project   Run. 
        MyHello Project -> Set Active Project Configuration,     .            .  . 
      -.    -     "Hello World Gray",     - "Hello World Color". 
 Client-Server 
  Wireless Connection

  J2ME Wireless Connection Wizard      client/server      . 

  J2ME Wireless Connection Wizard      ,   MIDP    web  ,    , J2SE service   . 

  client/server  : 
 Wireless Connection Wizard.    Mobile Project   ,   File > New File,  MIDP > Wireless Connection Wizard. 
 , web       . 
 ,        . 
       . 
   : 
-    .
,     . 
 . 
 MIDlet,   . 

 :
J2ME   
    
    xml 
    ,    MIDlet. 

J2ME ,    MIDlet    J2ME .       web .     web  (web.xml).
 
  
     MyHello Project   New > File/Folder. 
  MIDP,   Localization Support Class.  Next. 
   ,  Finish.      LocalizationSupport.java  messages.properties. 
 Tools > Internationalization > Internationalization Wizard.    . 
 HelloMIDlet MIDlet     .  Next. 
   HelloMIDlet Messages   ,       .  Next. 
  Value   ,   HelloMIDlet MIDlet. 
 ,       messages.properties,         . 
     Projects   Add Locale. 
  Predefined Locales  .        . 
  message.properties  Projects      newly-added locale. 
     . 

     microedition.locale      messages.properties.