Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

java file transfer from hfs to non-hfs filesystem and back



From: email@hidden
Subject: Cross filesystem resource forks
Date: April 22, 2004 2:05:28 PM PDT
To: email@hidden

Hi,

My apologies if i am posting to the wrong list, if there is a more
appropriate one please let me know.


Problem:
i need to transfer files using a java client from a os x machine, to
a linux server, and download via web browser back to the mac, retaining
the mac specific file information.

Conditions:
- java transfer from mac os x to linux
- i cannot use the MacBinary format because there are file operations
that need to be performed on the server
- web browser download from linux to mac os x OR os 9
- i can not do anything to the files once the browser download is
started - the file(s) are tar.gz'ed before download
- after the download is finished, and the tar.gz is unpacked, the mac
user must be able to double click the file and have it open with the
appropriate app without any other operation having to be performed.

My understanding of the situation:
- the mac specific information is held in the resource fork of the file
- the resource fork information can only be handled by the HFS/HFS+
file system
- when osx transfers a file between hfs and non hfs systems it creates
a file
called ._myfile which represents the resource fork info.
- you need to keep this ._myfile together with the data fork myfile
- when you transfer this pair of files back to an hfs file system, the
mac os should use the ._myfile for the resource information.

My current implementation:
- i have the SplitForks utility from the /Developer/Tools package
- the java app uses the SplitForks tool (SplitForks myfile) before the
transfer
- both files are transferred to the linux server
- files are tarred and gzipped before download
- files can be downloaded and unpacked
- md5 on the downloaded ._myfile and myfile show that they are
identical
- mac os does not find any creator/type information

thanks for your help

larry
_______________________________________________
java-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/java-dev
Do not post admin requests to the list. They will be ignored.




Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.