Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

A portablity problem

Posted on 1998-11-14
2
Medium Priority
?
145 Views
Last Modified: 2013-11-22
I have to write a servlet that copies a text file from a remote server to the local server. The remote server can be anything - Unix, NT.
How that can be done without using URLs or NFS? I think my problem is the naming convention.
0
Comment
Question by:Gadi031698
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 

Author Comment

by:Gadi031698
ID: 1227459
Edited text of question
0
 
LVL 16

Accepted Solution

by:
heyhey_ earned 40 total points
ID: 1227460
i don't think your problem is the naming convention, but the protocol for transfer of remote data ...
the remote machine manages its own File System and if you want to get some files from there, you will need some kind of server program (working there) that can handle your file request and return the appropriate file(s)

there are many standard protocols for data exchange (FTP, HTTP, even POP3 ...) and the URL object in Java is just a wrapper of the appropriate protocol so if you create HTTP URL object and call getInputStream, the URL object will send the appropriate HTTP request message and will handle the HTTP response message, giving you the pure data. so does FTP URL object ...
(there is no magic at all)

if you are working on LAN with NFS you can probably use File object with appropriate name ...

hope this helps
  heyhey
(if you really don't want to use URL objects, you have to write your own server app. clients should connect to the server (using Sockets) ask for particular file; the server will send them the file and they can save it ...)
0

Featured Post

[Webinar] Lessons on Recovering from Petya

Skyport is working hard to help customers recover from recent attacks, like the Petya worm. This work has brought to light some important lessons. New malware attacks like this can take down your entire environment. Learn from others mistakes on how to prevent Petya like worms.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction Raise your hands if you were as upset with FireMonkey as I was when I discovered that there was no TListview.  I use TListView in almost all of my applications I've written, and I was not going to compromise by resorting to TStringGrid…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
Viewers learn about the third conditional statement “else if” and use it in an example program. Then additional information about conditional statements is provided, covering the topic thoroughly. Viewers learn about the third conditional statement …
Video by: Michael
Viewers learn about how to reduce the potential repetitiveness of coding in main by developing methods to perform specific tasks for their program. Additionally, objects are introduced for the purpose of learning how to call methods in Java. Define …
Suggested Courses

609 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question