🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.language
Article #17161

Re: System commands

#17161
From: William Yu
Date: Tue, 08 Dec 1998 00:00
14 lines
1114 bytes
Vasudevan Srinivasan wrote:

> How do I run system commands like renaming/copying/deleting a file or

java.io.File has most of what you need.  There isn't a copy method but
you can implement it by using InputStream to read from a file and
OutputStream to write to a new file.

> spawn a process from inside a java application ?

Threads will do what you want.  Except you can't think of them in the
same way as fork.  I would suggest reading up on this subject very
carefully as my experience says Threads are needed in any non-trivial
Java application.
Technical Details
Message-ID: <366CDEC4.F10E39E3@Bigfoot.com>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <366C299A.D3B214C@netrisk.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f74b3,7082a9d3587f7529
X-Google-Attributes: gidf74b3,public
From: William Yu <William_Yu@Bigfoot.com>
Subject: Re: System commands
Date: 1998/12/08
Message-ID: <366CDEC4.F10E39E3@Bigfoot.com>
X-Deja-AN: 419976422
Content-Transfer-Encoding: 7bit
References: <366C299A.D3B214C@netrisk.com>
X-Accept-Language: en
Content-Type: text/plain; charset=us-ascii
Organization: Another Netscape Collabra Server User
Mime-Version: 1.0
Newsgroups: borland.public.jbuilder.java.language