Java Applications runs on Mobile

Dear Digital Dreamers
I would like to know how to load Simple Java Applciations in Mobile. S0 that it runs in Mobile.

hi!,
First you have to go through these link which is given by sun.
http://developers.sun.com/techtopics/mobility/getstart/
and for this
http://developers.sun.com/techtopics/mobility/midp/articles/wtoolkit/
here you get the code of HelloMIDlet class follow the instruction they said in document.
in j2me wireless toolkit there is option : project -> run via ota .you have click on this after build your app. It makes a html ,jad , jar and manifest file in bin directory of you app package.now you have to change/edit the html file where the full path is written like link
connect your mobile through data cable and copy the bin folder in you mobile and open the html file in browser.it ask to click on link after that it install the application.
bye

Similar Messages

  • Integrating java application running on OC4J server with EP Iview

    Hi,
         I Want to Integrate Java Application running on OC4J server with my Enterprise portal
    Can any one please help me out in this??
    Regards
    Padma N

    Hi Padma
    Its possible to integrate a java application running in the other server with enterprise portal.In portal i think there is a IView template call Java application template.Using this generally we can do this.But in you case what type of a java application is it?Just a class or webapplication or a server side application.This you can also acheive using a webdynpro applications as these are very flexible with integration into EP.In webdynpro you can use suspend and resume plugs to navigate from one application to other application.I have given my ideas how to implement.But integration mainly depends upon your landscape and version compatibilities and type of the application you need to integrate.
    Hope this answer helps you in implementation.
    Regards
    Kalyan

  • How to Run a Hello World Java application on WIndows Mobile

    Hi!
    We have a sample Plug-in environment Java application downloaded from http://www-128.ibm.com/developerworks/library/os-ecl-ercp/index.html - IBM library.
    We have downloaded the source files org.eclipse.testworkbenchapp_1.0.0.jar and tried running the application on desktop PC, this worked fine.
    We are using Eclipse 3.2 to run this Java application on Desktop.
    Now, we are trying to run the same application on Intermec Windows Mobile 5.0 device.
    1. The device has IBM J9 ? WebSphere MicroEnvironment MIDP 2.0 for Windows Mobile2003 installed in it.
    2. On installing this on Windows Mobile, in Start ? Programs ? we find MIDlet HQ - on launching this, opens a window with Install button.
    3. On Click on Install button, another window opens which asks for URL to install.
    4. In the URL Edit box, I give file:////Org.Eclipse.testWorkbenchapp.feature_1.0.0.jar which is present in \MyDocuments\Update site folder copied from desktop workspace via Active sync ? As mentioned in the above IBM library site.
    5. I have also tried file:////MyDocuments\Updatesite\Org.Eclipse.testWorkbenchapp.feature_1.0.0.jar as input to URL.
    6. On click OK, I get an error titled AMS Error with description The application descriptor was missing the required MIDlet Name field.
    I am held up here and not able to move further.
    As mentioned in the above IBM library site I tried downloading the update site folder via Eclipse ? Software Updates ? Find and Install in Help menu.
    I selected Search for new features to install and browsed the Update site folder location present in my Eclipse workspace. This also does not work.
    Any help in this regard in greatly appreciated. Thanks in advance!

    I would ask such questions in the J2ME forums, or even better in a websphere forum, like here:
    http://www-128.ibm.com/developerworks/forums/wsdd_forums.jsp

  • Can Web dynpro Java application run as background application

    Hi Experts,
    Is it possible to execute the Web dynpro java application in background without opening the application in a web browser.
    We just want the WD java application deployed on the SAP Web AS server to be invoked and get executed as a background application by some external web application. It should not get open at any point of time in a web browser.
    Can anyone suggest if it is possible?
    Thanks & Regards,
    Anurag

    Hi Anurag,
    Since Web Dynpro is "SAPu2019s standard UI technology based on MVC for developing user interfaces" (see http://www.sdn.sap.com/irj/sdn/nw-wdjava) it is by design not possible to run 'in the background'.
    There are other possibilities to develop server processes per your requirements, such as developing web services or servlet development.
    Web services are the de facto standard for executing business logic on a remote server. However, as I understand your external web application is not capable of sending web service requests, have you tried the servlet approach?
    See http://help.sap.com/saphelp_nwce711core/helpdata/en/3f/f8bc3d8af79633e10000000a11405a/frameset.htm for more info on how to develop a servlet using NWDS.
    Take particular attention to the sub-topic 'Servicing Client Requests' of the above guide
    Hope this helps!
    Best regards,
    Robin van het Hof

  • Can J2ME or Java application run on Pocket PC?

    Hi everyone,
    I got myself recently an iPAQ, I was wondering whether I can develop Java applications on my PC and run it on my iPAQ for usage?
    What's needed and the procedure to implement this?
    Thanks.
    regards,
    Aldrick

    You can create J2ME applications in some IDE like Websphere Device Developer. Then you need to configure j9 on your PocketPC and build and run the application on the device. All these steps can be done easily in Websphere Device Developer (WSDD)
    atikku

  • Profile native code that JAVA application runs

    our application is suffers from a severe memory leak. the application runs on Weblogic that uses the severe container and access Oracle DB.
    the JAVA heap was monitored for several weeks (using the verbose gc flag) and no leak was discovered. we monitored the native heap (by using the pmap command) and we saw that the heap size increasing. therefor we think the problem is in the native code that runs in this process (the major suspect is the OCI, Oracle client).
    after reading the man page of collect and your Article (Profiling Java Appl with Sun Studio 11) I'm confused. I would like to monitor the native heap (with -H option) but in the man page it's written that "Heap profiling is not supported for java programs" so i wheni set the flag -j off i got a warning that this process is java and i might use the -j on.
    please advice what are the values of the flags -j an -H in case of i need to monitor the native code of java application.
    thanks
    yahav

    thanks again for the additional article about the Weblogic.
    in the startManaged script I added the following prefix:
    collect -H on -j off -d /tmp/ java...
    when i typed leaks on er_print, i got a list of possible leaks and allocs.
    some activities were made on the application so i assume that data should be collected. as the size of the experiment folder slightly increased.
    so far we can assume that the data that is relegated to the non java process was collected.
    when i typed leaks again within the er_print tool i got the same results.
    it means that no native heap activities was made.
    is it correct analysis?
    regards the leak that was discovered above, how one can identify the function that cause this leak. i can see calls like:
    malloc, ReadKnownVMs, CreateExecutionEnvironment. this functions relate to the JVM. i would expect to see some trace (allocs) regards the other native code that runs such as the Oracle OCI client.
    I'm suspecting i'm collecting this info.
    is there any other flags to set for such collection? or any other commands in the analysis command

  • Java application running non-Java programs

    Greetings,
    I'd like to have an application start up another non-Java application. How do I do this? For example, how would I execute the following commands from a java application?
    Unix: "ls > /tmp/ls.dat"
    NT: "dir > c:\temp\dir.dat"
    TIA,
    --Paul Galvin

    You can use Runtime.exec. You'll have to do the redirection manually, by getting the Process from the exec method, opening the output stream, and writing the results to the file you want to redirect the output to. See the many posts on Runtime.exec in this and other forums.

  • How to install a java application onto my mobile phone?

    Hi,
    I'm trying to install a simple hello world application onto my Samsung SGH-X650. I'm using WAP, because I have no other options. But when I try to download the jar file, I get an "unsupported file format" error. When I try the jad file, it displays as a text file. However, downloading from websites (ie. getjar.com) works (usually). Additionally when I put the jad file I downloaded from getjar to my own webpage, I get them as text files too...
    Any ideas?
    Thanks in advance,
    Viktor Erdelyi

    (((My phone doesn't know about Bluetooth, and the data cable is too expensive regarding that I don't use it every day, I just sometimes download a 20 kb file like a java app.)))
    But I managed to set the MIME type, now I get "invalid JAR"... I'm trying to install the JAR generated by NetBeans. In theory, CLDC and MIDP versions are ok.
    From google:
    "Samsung, for some strange reason, does not allow installing .jars over cable or bluetooth or any other way than over Internet connection."

  • My java application runs quite slowly.

    My application is just for creating a data structure(like map<double,link<Object>>) and then search in the it and delete some element or add some,
    the application reads data from a file, and every 5000 lines, it will compute once, and here is the finish time of each roll:(ms)
    94
    187
    234
    297
    344
    11828
    22354
    32761
    obviously, after five rolls, the application becomes slower, and after that keep going in the slow speed.
    in each roll the overhead of computing should be the same
    I just do not get the idea why it becomes slow.

    private BuyBook buyBook = new BuyBook();
         private SellBook sellBook = new SellBook();
         TreeMap<Double,ArrayList<IOrderEntity>>tmpSellBook;
         IOrderEntity tmpSellOE;
         IOrderEntity tmpBuyOE ;
         IOrderEntity tmp;
         Double buyPrice;
         Double sellPrice;
         ReversedTreeMap<Double,ArrayList<IOrderEntity>>tmpBuyBook;
         Iterator it1;
         Iterator it2;
    public /*synchronized*/ void synchronizeBooks(IOrder o){
                   if(o.getType()==1){
                        if(((LimitOrderEntity)o).isBuy()){
                             getBuyBook().sync((LimitOrderEntity)o);
                        }else{
                             getSellBook().sync((LimitOrderEntity)o);
                   }else if(o.getType()==3){
                        getSellBook().update((CancelLimitOrderEntity)o);
                        getBuyBook().update((CancelLimitOrderEntity)o);
                   }else{
                        println("illegal param"+o);
    public void exchange(IOrderEntity order) {
              if(order.getType()==2){
                   while(order!=null){
                        if(order.isBuy()){
                             sellPrice = findProperOrderInSell(order);
                             if(sellPrice.isNaN()||getSellBook().getSellList().get(order.getSymbol()).isEmpty())
                                  return;
                             tmpSellBook = getSellBook().getSellList().get(order.getSymbol());
                             tmpSellOE = (IOrderEntity)tmpSellBook.get(sellPrice).get(0)/*firstEntry().getValue()*/;
                             if(order.getQuantity().intValue()>tmpSellOE.getQuantity().intValue()){
                                  order.setQuantity(order.getQuantity()-tmpSellOE.getQuantity());
                                  println("transaction of "+order.getSymbol()+" :"+order.getOrderId()+" with "+tmpSellOE.getOrderId()+" on "+tmpSellOE.getQuantity()+" shares at price "+tmpSellOE.getPrice());
                                  it1 = tmpSellBook.get(sellPrice).iterator();
                                  if(it1.hasNext()/*&&it1.next()!=null*/){
                                       it1.next();
                                       it1.remove();
                                       if(tmpSellBook.get(sellPrice).isEmpty()){
                                            Iterator it2 = tmpSellBook.entrySet().iterator();
                                            it2.next();
                                            it2.remove();
                             }else if(order.getQuantity().intValue()==tmpSellOE.getQuantity().intValue()){
                                  //order.setQuantity(order.getQuantity()-tmpSellOE.getQuantity());
                                  println("transaction of "+order.getSymbol()+" :"+order.getOrderId()+" with "+tmpSellOE.getOrderId()+" on "+tmpSellOE.getQuantity()+" shares at price "+tmpSellOE.getPrice());
                                  it1 = tmpSellBook.get(sellPrice).iterator();
                                  if(it1.hasNext()/*&&it1.next()!=null*/){
                                       it1.next();
                                       it1.remove();
                                       if(tmpSellBook.get(sellPrice).isEmpty()){
                                            it2 = tmpSellBook.entrySet().iterator();
                                            it2.next();
                                            it2.remove();
                                  return;
                             }else{
                                  println("transaction of "+order.getSymbol()+" :"+order.getOrderId()+" with "+tmpSellOE.getOrderId()+" on "+order.getQuantity()+" shares at price "+tmpSellOE.getPrice());
                                  tmp = tmpSellBook.get(sellPrice).get(0);
                                  tmp.setQuantity(tmpSellBook.get(sellPrice).get(0).getQuantity()-order.getQuantity());
                                  /*tmp.setTime(order.getTime());
                                  Iterator it1 = tmpSellBook.get(sellPrice).iterator();
                                  if(it1.hasNext()&&it1.next()!=null){
                                       it1.next();
                                       it1.remove();
                                       if(tmpSellBook.get(sellPrice).isEmpty()){
                                            Iterator it2 = tmpSellBook.entrySet().iterator();
                                            it2.next();
                                            it2.remove();
                                  synchronizeBooks(tmp);*/
                                  return;
                        }else{
                             buyPrice = findProperOrderInBuy(order);
                             if(buyPrice.isNaN()||getBuyBook().getBuyList().get(order.getSymbol()).isEmpty())
                                  return;
                             tmpBuyBook = getBuyBook().getBuyList().get(order.getSymbol());
                             tmpBuyOE = (IOrderEntity)tmpBuyBook.get(buyPrice).get(0)/*firstEntry().getValue()*/;
                             if(order.getQuantity().intValue()>tmpBuyOE.getQuantity().intValue()){
                                  order.setQuantity(order.getQuantity()-tmpBuyOE.getQuantity());
                                  println("transaction of "+order.getSymbol()+" :"+order.getOrderId()+" with "+tmpBuyOE.getOrderId()+" on "+tmpBuyOE.getQuantity()+" shares at price "+tmpBuyOE.getPrice());
                                  it1 = tmpBuyBook.get(buyPrice).iterator();
                                  if(it1.hasNext()/*&&it1.next()!=null*/){
                                       it1.next();
                                       it1.remove();
                                       if(tmpBuyBook.get(buyPrice).isEmpty()){
                                            it2 = tmpBuyBook.entrySet().iterator();
                                            it2.next();
                                            it2.remove();
                             }else if(order.getQuantity().intValue()==tmpBuyOE.getQuantity().intValue()){
                                  //order.setQuantity(order.getQuantity()-tmpSellOE.getQuantity());
                                  println("transaction of "+order.getSymbol()+" :"+order.getOrderId()+" with "+tmpBuyOE.getOrderId()+" on "+tmpBuyOE.getQuantity()+" shares at price "+tmpBuyOE.getPrice());
                                  it1 = tmpBuyBook.get(buyPrice).iterator();
                                  if(it1.hasNext()/*&&it1.next()!=null*/){
                                       it1.next();
                                       it1.remove();
                                       if(tmpBuyBook.get(buyPrice).isEmpty()){
                                            it2 = tmpBuyBook.entrySet().iterator();
                                            it2.next();
                                            it2.remove();
                                  return;
                             }else{
                                  println("transaction of "+order.getSymbol()+" :"+order.getOrderId()+" with "+tmpBuyOE.getOrderId()+" on "+order.getQuantity()+" shares at price "+tmpBuyOE.getPrice());
                                  tmp = tmpBuyBook.get(buyPrice).get(0);
                                  tmp.setQuantity(tmpBuyBook.get(buyPrice).get(0).getQuantity()-order.getQuantity());
                                  /*tmp.setTime(order.getTime());
                                  Iterator it1 = tmpBuyBook.get(buyPrice).iterator();
                                  if(it1.hasNext()&&it1.next()!=null){
                                       it1.next();
                                       it1.remove();
                                       if(tmpBuyBook.get(buyPrice).isEmpty()){
                                            Iterator it2 = tmpBuyBook.entrySet().iterator();
                                            it2.next();
                                            it2.remove();
                                  synchronizeBooks(tmp);*/
                                  return;
    public Double findProperOrderInBuy(IOrderEntity order){
              if(getBuyBook().getBuyList()!=null&&!getBuyBook().getBuyList().isEmpty()){
                   tmpBuyBook = getBuyBook().getBuyList().get(order.getSymbol());
                   if(tmpBuyBook!=null&&!tmpBuyBook.isEmpty()){
                        return tmpBuyBook.firstKey();
              return Double.NaN;
          * find a proper price for a sell order
          * @param order
          * @return the price, if NaN, means no proper price
         public Double findProperOrderInSell(IOrderEntity order){
              if(getSellBook().getSellList()!=null&&!getSellBook().getSellList().isEmpty()){
                   tmpSellBook = getSellBook().getSellList().get(order.getSymbol());
                   if(tmpSellBook!=null&&!tmpSellBook.isEmpty()){
                        return tmpSellBook.firstKey();
              return Double.NaN;
    .......this is buybook
    private Map<String,ReversedTreeMap<Double,ArrayList<IOrderEntity>>> buyList =
              new HashMap<String,ReversedTreeMap<Double,ArrayList<IOrderEntity>>>();
         Iterator it1;Object test1;Iterator it2;Object test2;Iterator it3;Object test3;IOrderEntity tmp;
          * get the buybook in a map
          * @return the map
         public Map<String,ReversedTreeMap<Double,ArrayList<IOrderEntity>>> getBuyList() {
              return buyList;
          * set the buybook
          * @param buyList
         public void setBuyList(Map<String,ReversedTreeMap<Double,ArrayList<IOrderEntity>>> buyList) {
              this.buyList = buyList;
          * synchronize the list with a list of IOrderEntity
          * @param loe: the list
         public void sync(List<IOrderEntity> loe){
              for(IOrderEntity x:loe){
                   sync(x);
          * synchronize the with an IOrderEntity object
          * @param x the IOrderEntity
         public void sync(IOrderEntity x){
              if(x.getSymbol()!=null&&x.getQuantity()>0&&x.getTime()>=0){
                   //if the entity is well-formated
                   if(getBuyList().containsKey(x.getSymbol())){
                        //if the symbol exist in list already
                        if(getBuyList().get(x.getSymbol()).containsKey(x.getPrice())){
                             //if the price has been there
                             getBuyList().get(x.getSymbol()).get(x.getPrice()).add(/*put(x.getTime(), */x);
                        }else{
                             //else the price is new
                             ArrayList<IOrderEntity> tmpTreeMap1 = new ArrayList<IOrderEntity>();
                             tmpTreeMap1.clear();
                             tmpTreeMap1.add(/*put(x.getTime(), */x);
                             getBuyList().get(x.getSymbol()).put(x.getPrice(), tmpTreeMap1);
                   else{
                        ReversedTreeMap<Double,ArrayList<IOrderEntity>> tmpTreeMap2 = new ReversedTreeMap<Double,ArrayList<IOrderEntity>>();
                        //else the symbol is new
                        ArrayList<IOrderEntity> tmpTreeMap1 = new ArrayList<IOrderEntity>();
                        tmpTreeMap2.clear();
                        tmpTreeMap1.clear();
                        tmpTreeMap1.add(/*put(x.getTime(), */x);
                        tmpTreeMap2.put(x.getPrice(), tmpTreeMap1);
                        getBuyList().put(x.getSymbol(), tmpTreeMap2);
          * update the book with a cancelListmitorderenetity
          * @param cloe:cancellimitorderentity
         public void update(CancelLimitOrderEntity cloe){
              it1 = getBuyList().entrySet().iterator();
              test1 = null;
              while(it1.hasNext()&&(test1 = it1.next())!=null){
                   it2 = ((Map.Entry<String,ReversedTreeMap<Double,ArrayList<IOrderEntity>>>)test1).getValue().entrySet().iterator();
                   test2 = null;
                   while(it2.hasNext()&&(test2 = it2.next())!=null){
                        it3 = ((Map.Entry<Double,ArrayList<IOrderEntity>>)test2).getValue().iterator();
                        test3 = null;
                        while(it3.hasNext()&&(test3 = it3.next())!=null){
                             tmp = ((IOrderEntity)test3);
                             if(cloe.getOrderId().equals(tmp.getOrderId())){
                                  if(cloe.getQuantity().intValue()<tmp.getQuantity().intValue()){
                                       tmp.setQuantity(tmp.getQuantity()-cloe.getQuantity());
                                       tmp.setTime(cloe.getTime());
                                       //delete
                                       it3.remove();
                                       //add
                                       ((Map.Entry<Double,ArrayList<IOrderEntity>>)test2).getValue().add(tmp);
                                       return;
                                  }else if(cloe.getQuantity().intValue() == tmp.getQuantity().intValue()){
                                       it3.remove();
                                       if(((Map.Entry<Double,ArrayList<IOrderEntity>>)test2).getValue().isEmpty()){
                                            it2.remove();
                                            if(((Map.Entry<String,ReversedTreeMap<Double,ArrayList<IOrderEntity>>>)test1).getValue().isEmpty()){
                                                 it1.remove();
                                       return;
                                  }else{
                                       //System.out.println(cloe.getOrderId()+":cancel quantity>current quantity.");
                                       return;
    ....and this is sell book
    private Map<String,TreeMap<Double,ArrayList<IOrderEntity>>> sellList =
              new HashMap<String,TreeMap<Double,ArrayList<IOrderEntity>>>();
         Iterator it1;Object test1;Iterator it2;Object test2;Iterator it3;Object test3;IOrderEntity tmp;
          * get the buybook in a map
          * @return the map
         public Map<String,TreeMap<Double,ArrayList<IOrderEntity>>> getSellList() {
              return sellList;
          * set the buybook
          * @param buyList
         public void setSellList(Map<String,TreeMap<Double,ArrayList<IOrderEntity>>> sellList) {
              this.sellList = sellList;
          * synchronize the list with a list of IOrderEntity
          * @param loe: the list
         public void sync(List<IOrderEntity> loe){
              for(IOrderEntity x:loe){
                   sync(x);
          * synchronize the with an IOrderEntity object
          * @param x the IOrderEntity
         public void sync(IOrderEntity x){
              ArrayList<IOrderEntity> tmpTreeMap1 = new ArrayList<IOrderEntity>();
              TreeMap<Double,ArrayList<IOrderEntity>> tmpTreeMap2 = new TreeMap<Double,ArrayList<IOrderEntity>>();
              if(x.getSymbol()!=null&&x.getQuantity()>0&&x.getTime()>=0){
                   //if the entity is well-formated
                   if(getSellList().containsKey(x.getSymbol())){
                        //if the symbol exist in list already
                        if(getSellList().get(x.getSymbol()).containsKey(x.getPrice())){
                             //if the price has been there
                             getSellList().get(x.getSymbol()).get(x.getPrice()).add(/*put(x.getTime(), */x);
                        }else{
                             //else the price is new
                             tmpTreeMap1.clear();
                             tmpTreeMap1.add(/*put(x.getTime(), */x);
                             getSellList().get(x.getSymbol()).put(x.getPrice(), tmpTreeMap1);
                   else{
                        //else the symbol is new
                        tmpTreeMap2.clear();
                        tmpTreeMap1.clear();
                        tmpTreeMap1.add(/*put(x.getTime(), */x);
                        tmpTreeMap2.put(x.getPrice(), tmpTreeMap1);
                        getSellList().put(x.getSymbol(), tmpTreeMap2);
          * update the book with a cancelListmitorderenetity
          * @param cloe:cancellimitorderentity
         public void update(CancelLimitOrderEntity cloe){
              it1 = getSellList().entrySet().iterator();
              test1 = null;
              while(it1.hasNext()&&(test1 = it1.next())!=null){
                   it2 = ((Map.Entry<String,TreeMap<Double,ArrayList<IOrderEntity>>>)test1).getValue().entrySet().iterator();
                   test2 = null;
                   while(it2.hasNext()&&(test2 = it2.next())!=null){
                        it3 = ((Map.Entry<Double,ArrayList<IOrderEntity>>)test2).getValue()./*entrySet().*/iterator();
                        test3 = null;
                        while(it3.hasNext()&&(test3 = it3.next())!=null){
                             tmp = ((/*Map.Entry<Long, */IOrderEntity/*>*/)test3)/*.getValue()*/;
                             if(cloe.getOrderId().equals(tmp.getOrderId())){
                                  if(cloe.getQuantity().intValue()<tmp.getQuantity().intValue()){
                                       tmp.setQuantity(tmp.getQuantity()-cloe.getQuantity());
                                       tmp.setTime(cloe.getTime());
                                       //delete
                                       it3.remove();
                                       //add
                                       ((Map.Entry<Double,ArrayList<IOrderEntity>>)test2).getValue().add(tmp);
                                       return;
                                  }else if(cloe.getQuantity().intValue() == tmp.getQuantity().intValue()){
                                       it3.remove();
                                       if(((Map.Entry<Double,ArrayList<IOrderEntity>>)test2).getValue().isEmpty()){
                                            it2.remove();
                                            if(((Map.Entry<String,TreeMap<Double,ArrayList<IOrderEntity>>>)test1).getValue().isEmpty()){
                                                 it1.remove();
                                       return;
                                  }else{
                                       //System.out.println(cloe.getOrderId()+": cancel quantity>current quantity.");
                                       return;
         }here is how the application start
    AbstractExchangeDelegate ed3 = new ExchangeDelegate("largetest");
                   input = zipFile.getInputStream(entry);
                   IStockDataSource sdsd1 = new StockDataSourceDelegate(input);
                   if(sdsd1!=null){
                        int counter = 0;
                        //ed.sychronizeBooks(sdsd.getAllOrderEntityAsList(), sdsd.getCancelLimitOrderEntityList());
                        for(IOrder x:sdsd1.getAllOrderEntityAsList()){
                             if(!(x.getType()==2))
                                  ed3.synchronizeBooks(x);
                             else{
                                  ed3.exchange((MarketOrderEntity)x);
                                  counter++;
                        if(counter>5000){
                             System.gc();
                   }

  • Run windows services from java application

    can java application run a windows server
    i have a web server that runing using tomcat and mysql
    can i make a icon in the systray
    that give me the option to (using a menu)
    run the server ,wicth means : tomcat and mysql are runing
    stop the server
    get tomcat stacktrace in a window
    i was thinking about runing tomcat and mysql as services
    and write the systray application using java,
    the systray application should acces window services ,
    and run/stop requierd services.
    what happend on a machine thar runs linux?
    thanks
    shay

    Ok .so it's will be a diffrent way under linux..
    for systray i will use http://systray.sourceforge.net/
    and for services i'll use the
    "net start <Service>" and "net stop service"
    i need to keep track on the service status
    so my Systray status will be updated
    what is the command for getting the status of the proccess
    thanks shay

  • Can j2me applications run on SGMP

    Hi,
    I want to know if SGMP can execute/host J2ME applications. The documentation mentions about enterprise apps like SAP, Siebel, Remedy,etc.
    Please throw some light on it.
    Regards
    Deepak Mawandia

    Hi Deepak,
    Not sure what you are getting at. Are you asking if the SGMP gateway can execute/host J2ME apps? I don't think that applies, since the gateway runs in a Java EE application server that runs on J2SE. The purpose of SGMP is to enable J2ME-based client applications running on mobile devices to synchronize with various backends.

  • Reading a XML file in a standalone java application

    Hi,
    What are my options if I have a standalone java application running outside any app. server and I need to read an XML file, probably read some of the attributes in the file...? Please explain clearly as I'm new to this. Appreciate your help.
    Thanks,
    Mahdad

    nope you don't need a DTD
    you have to write your Java code in a way that doesn't rely too much on the structure:
    - avoid getFirstChild().getFirstChild()... because you know that this element is first grandson of that element)
    - prefer using getElementByTagName() or some XPath() API
    but if the XML completely changes, well, yeah, you have to do some programmation: better think well your document structure in the beginning.

  • WD Java application is displaying ABAP MESSAGE NUMBER, Not the text

    HI
    We have WD Java applications running on Adpeted RFC model, Now the Success/Error Messages coming from backend are not displayed in the text, Message number is shown rather. In ABAP side, the language pool is maintained only for the danish language and the same danish language is set as portal language for the end  user.
    Does the Meta Jco Default language play any role here? I can see it is set as Danish by default but in one of the workign system it is English?
    Can you explain where the problem could be?
    regards
    Pranav

    I completely agree, we checked the message pool and found that the mesasage text is maintained for specific code in specific language, but on portal is not displaying the text, but it is displaying the code. it seems the language information of portal user is not being passed to backend.
    regards
    Pranav

  • How can my java application get its own PID?

    My java application runs under AIX?
    The application needs to get its own PID.
    There is a possibility to get it by
    Runtime.exec("ps -ef | grep <user.name>");
    But is there any other alternate possibility?
    Any idea would be great appreciated
    kind regards

    Hello! I found several ways for this in a blog from someone called Igor Minar on
    http://net3x.blogspot.com/2007/03/how-java-application-can-discover-its.html
    He found several ways:
    * Use Java management and monitoring API
    ManagementFactory.getRuntimeMXBean().getName();returns something like
    1826@localhost
    where 1826 is the PID of the JVM process, i.e. my application's process. But this hack is JVM dependent and may not work on JVM's other than Sun's
    * Use a shell script to put a property in place that is set to the PID:
    exec java -Dpid=$$ -jar myapp.jar* Java Native Interface - cumbersome and platform dependent solution
    * Use procfs (Linux solution: read /proc/self, nifty nifty, posted in the comments of the resp. post!)
    int pid = Integer.parseInt( ( new File("/proc/self")).getCanonicalFile().getName() );* From another comment: Reflection will work (on Unix): The Process class has a field called pid which can be queried:
    static int getPID(Process process) throws IllegalAccessException, IllegalArgumentException,
                                                                      NoSuchFieldException, SecurityException
         Field field = process.getClass().getDeclaredField("pid");
         field.setAccessible(true);
         return field.getInt(process);
    }But this solution looks a bit of a kludge to me. I think the /proc/self solution is best - it definitely rox my sox!
    Hope this helps!

  • Call a Java Application from MicroFocus COBOL (in UNIX environment)

    Hello,
    Could you please let me know, how to call a Java application from a MicroFocus COBOL application. If anyone has any code samples, that would be of great help.
    Thanks in advance,
    Tijo.

    You generally can't cause a program to be executed on a different >server. Basic security, you know. Besides this idea of having the Java >application run on a different server wasn't mentioned in your original >post. That leads me to believe we don't have the whole story.So I think you need to step back and find out what are the requirements. For example: Does your program need to start this Java application running, or is it already running and your program needs to connect to it somehow?
    My program has to start a Java class file, meaning that the Micro Focus COBOL module will call the Java class file. Will it be running on the same machine as your program, or on some other machine?
    For both cases, I would like to know the answer.a) Running on the same machine as my program is running.
    b) Running on the different machine.
    And then there are the questions about whether your program needs to have a conversation with the Java application, or whether it just needs to start it and that's all.
    COBOL program has to call a Java class by passing some parameters and Java class in turn process it and return some value back.. Kind of Request and Response model.Plenty of questions to be asked. Go and find out what they are.
    Sorry ... if I am not clear on my questions. Anyhow, thank you very much for providing the information.

Maybe you are looking for

  • Need help in archiveing and deleting records

    Hi frnds I wrote a procedure to archive the records and delete the archived one but after inserting and deleting the tot counter is not working and its showing 1 record inserted and i didnt tried the deletion part,pls find my code and how to get the

  • NullPointerException at oracle.sql.BLOB.createTemporary(BLOB.java:590)

    Hi, I seldom use the BLOB. Here is the coding that creates a BLOB. private  BLOB getBlob(byte[] str, Connection con) throws SQLException, IOException {   BLOB blob = BLOB.createTemporary(con, true, BLOB.DURATION_SESSION);   blob.open(BLOB.MODE_READWR

  • Macbook Air and Keynote performance

    I'm very happy with my Macbook Air so far (except for the trackpad button that seems to be unresponsive at times). BUT. I chose the Air to use it for Keynote presentations. I'm a little bit upset to see that some Keynote effects that I like such as c

  • Match & iPad Newbie

    Hi I'm a DJ and got an iPad as a backup should either of my laptops go down. I have a 64 gb library and many times the location may have poor to zero wireless signal. So I want to know best way to have my favorite songs on the iPad and have the other

  • Error when i try and download iOS 7

    error when i try and download iOS 7