|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
NutchFileSystem is an interface for a fairly simple distributed file system. A Nutch installation might consist of multiple machines, which should swap files transparently. This interface allows other Nutch systems to find and place files into the distributed Nutch-controlled file world. The standard job of NutchFileSystem is to take the location- independent NutchFile objects, and resolve them using local knowledge and local instances of ShareGroup.
Method Summary | |
void |
close()
Close down the fs. |
void |
completeDir(NutchFile nutchFile)
Sometimes the NutchFileSystem user constructs a directory of many subparts, often built slowly over time. |
void |
delete(NutchFile nutchFile)
Delete the given NutchFile and everything below it. |
File |
get(NutchFile nutchFile)
Obtains the indicated NutchFile, whether remote or local. |
File |
get(NutchFile nutchFile,
long timeout)
Same as above, but expires after the given number of ms, returning null. |
File |
getWorkingFile()
Get a real File for a name that's not yet under NutchFS control. |
void |
lock(NutchFile lockFile,
boolean exclusive)
Obtain a lock with the given NutchFile as the lock object |
void |
put(NutchFile nutchFile,
File workingFile,
boolean overwrite)
Associates a NutchFile with a given real-fs File. |
void |
release(NutchFile lockFile)
Release the lock. |
void |
renameTo(NutchFile src,
NutchFile dst)
Rename the given NutchFile to something new. |
Method Detail |
public File getWorkingFile() throws IOException
IOException
public void put(NutchFile nutchFile, File workingFile, boolean overwrite) throws IOException
IOException
public void completeDir(NutchFile nutchFile) throws IOException
IOException
public File get(NutchFile nutchFile) throws IOException
IOException
public File get(NutchFile nutchFile, long timeout) throws IOException
IOException
public void lock(NutchFile lockFile, boolean exclusive) throws IOException
IOException
public void release(NutchFile lockFile) throws IOException
IOException
public void delete(NutchFile nutchFile) throws IOException
IOException
public void renameTo(NutchFile src, NutchFile dst) throws IOException
IOException
public void close() throws IOException
IOException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |