public class IOManagerImpl extends Object implements IOManager
| Modifier and Type | Field and Description |
|---|---|
protected static org.slf4j.Logger |
LOG |
| Constructor and Description |
|---|
IOManagerImpl(String... tempDirs)
Constructs a new IOManager.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Removes all temporary files.
|
BufferFileReader |
createBufferFileReader(FileIOChannel.ID channelID) |
BufferFileWriter |
createBufferFileWriter(FileIOChannel.ID channelID) |
FileIOChannel.ID |
createChannel() |
FileIOChannel.ID |
createChannel(String prefix) |
FileIOChannel.Enumerator |
createChannelEnumerator() |
static void |
deleteChannel(FileIOChannel.ID channel)
Deletes the file underlying the given channel.
|
File[] |
getSpillingDirectories()
Gets the directories that the I/O manager spills to.
|
String[] |
getSpillingDirectoriesPaths()
Gets the directories that the I/O manager spills to, as path strings.
|
static String[] |
splitPaths(String separatedPaths) |
String[] |
tempDirs() |
public IOManagerImpl(String... tempDirs)
tempDirs - The basic directories for files underlying anonymous channels.public void close()
throws Exception
close in interface AutoCloseableExceptionpublic FileIOChannel.ID createChannel()
createChannel in interface IOManagerpublic FileIOChannel.ID createChannel(String prefix)
createChannel in interface IOManagerpublic FileIOChannel.Enumerator createChannelEnumerator()
createChannelEnumerator in interface IOManagerpublic static void deleteChannel(FileIOChannel.ID channel)
channel - The channel to be deleted.public File[] getSpillingDirectories()
public String[] getSpillingDirectoriesPaths()
public BufferFileWriter createBufferFileWriter(FileIOChannel.ID channelID) throws IOException
createBufferFileWriter in interface IOManagerIOExceptionpublic BufferFileReader createBufferFileReader(FileIOChannel.ID channelID) throws IOException
createBufferFileReader in interface IOManagerIOExceptionCopyright © 2023–2024 The Apache Software Foundation. All rights reserved.