public class CSDKFile
extends java.lang.Object
implements csdk.v1_0.api.filesystem.IFile
| Constructor and Description |
|---|
CSDKFile(csbase.logic.ClientFile file)
Construtor
|
| Modifier and Type | Method and Description |
|---|---|
csdk.v1_0.api.filesystem.IFileLock |
acquireExclusiveLock(java.awt.Window window) |
csdk.v1_0.api.filesystem.IFileLock |
acquireSharedLock(java.awt.Window window) |
boolean |
canExecute() |
boolean |
canRead() |
boolean |
canWrite() |
void |
close()
Fecha o arquivo.
|
void |
close(boolean force) |
boolean |
exists() |
csdk.v1_0.api.filesystem.IFile[] |
getChildren() |
csbase.logic.ClientFile |
getFile()
Obtém o arquivo encapsulado.
|
csdk.v1_0.api.filesystem.FileLocationType |
getFileLocationType() |
java.io.InputStream |
getInputStream() |
long |
getModificationDate() |
java.lang.String |
getName() |
java.io.OutputStream |
getOutputStream() |
csdk.v1_0.api.filesystem.IFile |
getParent() |
java.lang.String[] |
getPath() |
java.lang.String |
getStringPath() |
java.lang.String |
getType() |
boolean |
isDirectory() |
void |
open(boolean readOnly) |
long |
position() |
void |
position(long newPosition) |
int |
read(byte[] dst,
int off,
int len,
long position) |
int |
read(byte[] dst,
long position) |
long |
size() |
void |
write(byte[] src,
int off,
int len,
long position) |
void |
write(byte[] src,
long position) |
public CSDKFile(csbase.logic.ClientFile file)
file - arquivo encapsulado.public void close(boolean force)
throws java.io.IOException
close in interface csdk.v1_0.api.filesystem.IFilejava.io.IOExceptionpublic void close()
throws java.io.IOException
java.io.IOException - em caso de erro de I/O.public csdk.v1_0.api.filesystem.IFile[] getChildren()
throws java.lang.Exception
getChildren in interface csdk.v1_0.api.filesystem.IFilejava.lang.Exceptionpublic java.io.InputStream getInputStream()
throws java.io.IOException
getInputStream in interface csdk.v1_0.api.filesystem.IFilejava.io.IOExceptionpublic long getModificationDate()
getModificationDate in interface csdk.v1_0.api.filesystem.IFilepublic java.lang.String getName()
getName in interface csdk.v1_0.api.filesystem.IFilepublic java.io.OutputStream getOutputStream()
throws java.io.IOException
getOutputStream in interface csdk.v1_0.api.filesystem.IFilejava.io.IOExceptionpublic java.lang.String[] getPath()
getPath in interface csdk.v1_0.api.filesystem.IFilepublic java.lang.String getStringPath()
getStringPath in interface csdk.v1_0.api.filesystem.IFilepublic java.lang.String getType()
getType in interface csdk.v1_0.api.filesystem.IFilepublic boolean isDirectory()
isDirectory in interface csdk.v1_0.api.filesystem.IFilepublic void open(boolean readOnly)
throws java.lang.Exception
open in interface csdk.v1_0.api.filesystem.IFilejava.lang.Exceptionpublic long position()
throws java.io.IOException
position in interface csdk.v1_0.api.filesystem.IFilejava.io.IOExceptionpublic void position(long newPosition)
throws java.io.IOException
position in interface csdk.v1_0.api.filesystem.IFilejava.io.IOExceptionpublic int read(byte[] dst,
int off,
int len,
long position)
throws java.lang.Exception
read in interface csdk.v1_0.api.filesystem.IFilejava.lang.Exceptionpublic int read(byte[] dst,
long position)
throws java.lang.Exception
read in interface csdk.v1_0.api.filesystem.IFilejava.lang.Exceptionpublic long size()
size in interface csdk.v1_0.api.filesystem.IFilepublic void write(byte[] src,
int off,
int len,
long position)
throws java.io.IOException,
csdk.v1_0.api.filesystem.FileLockedException
write in interface csdk.v1_0.api.filesystem.IFilejava.io.IOExceptioncsdk.v1_0.api.filesystem.FileLockedExceptionpublic void write(byte[] src,
long position)
throws java.io.IOException,
csdk.v1_0.api.filesystem.FileLockedException
write in interface csdk.v1_0.api.filesystem.IFilejava.io.IOExceptioncsdk.v1_0.api.filesystem.FileLockedExceptionpublic csdk.v1_0.api.filesystem.FileLocationType getFileLocationType()
getFileLocationType in interface csdk.v1_0.api.filesystem.IFilepublic csbase.logic.ClientFile getFile()
public csdk.v1_0.api.filesystem.IFile getParent()
getParent in interface csdk.v1_0.api.filesystem.IFilepublic boolean exists()
throws java.io.IOException
exists in interface csdk.v1_0.api.filesystem.IFilejava.io.IOExceptionpublic boolean canExecute()
canExecute in interface csdk.v1_0.api.filesystem.IFilepublic boolean canRead()
canRead in interface csdk.v1_0.api.filesystem.IFilepublic boolean canWrite()
canWrite in interface csdk.v1_0.api.filesystem.IFilepublic csdk.v1_0.api.filesystem.IFileLock acquireExclusiveLock(java.awt.Window window)
throws java.lang.Exception
acquireExclusiveLock in interface csdk.v1_0.api.filesystem.IFilejava.lang.Exceptionpublic csdk.v1_0.api.filesystem.IFileLock acquireSharedLock(java.awt.Window window)
throws java.lang.Exception
acquireSharedLock in interface csdk.v1_0.api.filesystem.IFilejava.lang.ExceptionCopyright © 2018. All Rights Reserved.