Java Forums

Main Menu
Home
Today's Posts
FAQ
Search
Contact Us

Java Network
Linux Archive
Java Tips
Java Tips Blog

Sponsored Links





Welcome to the Java Forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community, you will:

  • have access to post topics
  • communicate privately with other members (PM)
  • not see advertisements between posts
  • have the possibility to earn one of our surprises if you are an active member
  • access many other special features that will be introduced later.

Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 04-17-2008, 10:45 AM
Member
 
Join Date: Apr 2008
Posts: 3
rajeshgubba is on a distinguished road
How can i copy a folder from one place to another..
Hi,

How can i copy the folder from one place to another place..

Including its subfolders and files....

Using java code...

please help me...
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 04-17-2008, 04:02 PM
sukatoa's Avatar
Senior Member
 
Join Date: Jan 2008
Location: Cebu City, Philippines
Posts: 527
sukatoa is on a distinguished road
Send a message via Yahoo to sukatoa
Take a look at File Class... there is a mkdir() method there... have some experiments on it....

About copying files, also have a look at FileChannel Class.... it is more safer to implement....

regards,
sukatoa
Bookmark Post in Technorati
Reply With Quote
  #3 (permalink)  
Old 06-03-2008, 01:36 AM
jad jad is offline
Member
 
Join Date: Jun 2008
Posts: 2
jad is on a distinguished road
folder backup in java
how do i make folder backup in jave by copying each hour only the changes occured on the folder or subfolder(s),and by folder cloning
Bookmark Post in Technorati
Reply With Quote
  #4 (permalink)  
Old 06-03-2008, 05:04 AM
sukatoa's Avatar
Senior Member
 
Join Date: Jan 2008
Location: Cebu City, Philippines
Posts: 527
sukatoa is on a distinguished road
Send a message via Yahoo to sukatoa
You may persist/save a log file with a data that represents the exact length/size of those files inside the folders/subfolders.

Implementing it with thread is safe. you may use sleep(long hour) method to make the thread fall a sleep every hour. After every interval, check the files inside those folders if their size have been changed by comparing them with the data inside that log file.

If yes, then do the copy....
__________________
A specific, detailed, simple, well elaborated, and "tested before asking" question may gather more quick replies. hopefully
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
Bookmark Post in Technorati
Reply With Quote
  #5 (permalink)  
Old 06-14-2008, 04:21 AM
Member
 
Join Date: Jun 2008
Posts: 22
ferranb is on a distinguished road
Another dirt way is executing an operating system command. Of course, it means you have to consider all your target operating systems.

Ferran
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Want Some Expert Advice? JAX India 2008 Might Be the Right Place james Java Announcements 2 03-03-2008 10:05 PM
add password to folder ismailsaleh AWT / Swing 1 01-08-2008 07:46 AM
How to place panel into frame vivek_9912 AWT / Swing 2 11-20-2007 01:21 AM
how to place a divider of the splitpane? christina New To Java 1 08-06-2007 09:41 PM
how to place an image in an applet paty Java Applets 2 08-04-2007 07:15 PM


All times are GMT +3. The time now is 07:05 PM.


VBulletin, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2006 - 2007, www.java-forums.org