Using RMI and the FileSystemView class

Discussion in 'Java' started by Helen, Apr 5, 2004.

  1. Helen

    Helen Guest

    Hi

    I have two Java applications that communicate via RMI. In the client
    application I want to allow the user to specify a file on a server and
    then send a job to the server application. The server application
    requires the correct path of the file chosen by the user and the
    client application requires the IP address of the machine the file
    resides on.

    In Swing for Java 1.4 it seems the JFileChooser is clever enough to
    browse the LAN. However, it is not possible to obtain the IP address
    of the machine the file resides on or the correct path due to mounted
    file systems etc from the JFileChooser.

    To overcome this problem I am going to ask the user to specify in the
    preferences for the client application the IP address for all the
    servers the may wish to use. Then create a customised JFileChooser
    that has a drop down list of the specified server IP addresses. When a
    new IP address is selected the event handler will create a stub to a
    remote FileSystemView object initiated by the server application. This
    new remote FileSystemView object will replace the one currently used
    by the JFileChooser.

    I don't know if this solution is a bit heavy handed. I also think that
    my problem isn't that obscure and someone else must have encountered
    it before. If anyone else has an alternate solution that is a lot more
    elegant that would be great. Also if you think the above idea is just
    not feasible to implement please let me know as I am just about to
    start the prototyping phase.

    If you haven't guessed already, network programming is something I am
    relatively new to so any help would be greatly appreciated.

    Thanks

    Helen
     
    Helen, Apr 5, 2004
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Christian Bongiorno

    JFileChooser and FileSystemView

    Christian Bongiorno, Jul 21, 2004, in forum: Java
    Replies:
    0
    Views:
    954
    Christian Bongiorno
    Jul 21, 2004
  2. joe
    Replies:
    0
    Views:
    572
  3. Buu Nguyen

    RMI, JINI or RMI/IIOP

    Buu Nguyen, Aug 25, 2004, in forum: Java
    Replies:
    1
    Views:
    595
    Sudsy
    Aug 25, 2004
  4. JScoobyCed

    RMI Vs RMI over IIOP

    JScoobyCed, Jan 28, 2005, in forum: Java
    Replies:
    1
    Views:
    768
    Dag Sunde
    Jan 28, 2005
  5. Replies:
    1
    Views:
    663
Loading...

Share This Page