aspose file tools
The moose likes Beginning Java and the fly likes passing and getting parameters Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Elasticsearch in Action this week in the Big Data forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "passing and getting parameters " Watch "passing and getting parameters " New topic

passing and getting parameters

preethi Ayyappan
Ranch Hand

Joined: Oct 04, 2007
Posts: 518
I am calling one java standalone application from another standalone application like the following

I want to pass and get parameters in both the application.Is it possible in standalone application?

Campbell Ritchie

Joined: Oct 13, 2005
Posts: 41079
Are you running two JVMs?

Do a search on JavaRanch; that sort of question comes up about every two weeks. Lots of possibilities:
  • You could connect the two together with Sockets.
  • You could create a class to embody data and serialise its instances from one application and deserialise them into the other application.
  • You could have a text file with data in, writing and rewriting it from the different applications.
  • Rob Spoor

    Joined: Oct 27, 2005
    Posts: 19908

    I have a question for you.

    Your code obviously recognizes class Ivr. Yet you still use reflection to create an instance. Why?

    First of all, why use Class.forName if Ivr is available; therefore Ivr.class is also available. That will return the same as Class.forName("Ivr").

    Second of all, why not say
    That's a) a lot better to read, and b) faster.

    SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
    How To Ask Questions How To Answer Questions
    It is sorta covered in the JavaRanch Style Guide.
    subject: passing and getting parameters