public class GKFileActions
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
static class |
GKFileActions.FileResult
FileResult encapsulates the result of basic file actions.
|
static class |
GKFileActions.GetFileResult
GetFileResult encapsulates the result of the "Get File" action.
|
static class |
GKFileActions.ListFilesResult
ListFilesResult encapsulates the result of the "List Files" action.
|
static class |
GKFileActions.PutFileResult
PutFileResult encapsulates the result of the "Put File" action.
|
static class |
GKFileActions.Status
Status is the named result of an action.
|
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
TAG |
| Constructor and Description |
|---|
GKFileActions(GKCard card)
Create a
GKFileActions that communicates with card. |
| Modifier and Type | Method and Description |
|---|---|
GKFileActions.FileResult |
deleteFile(GKFile file)
Delete the given file on the GateKeeper Card.
|
GKFileActions.GetFileResult |
getFile(GKFile file,
java.io.File localFile)
Retrieve the given file from the GateKeeper Card.
|
GKFileActions.ListFilesResult |
listFiles(java.lang.String cardPath)
Retrieve a list of files stored at the given path on the GateKeeper Card.
|
GKFileActions.FileResult |
makeDirectory(java.lang.String cardPath)
Create a directory at the given path on the GateKeeper Card.
|
GKFileActions.PutFileResult |
putFile(java.io.InputStream localFile,
java.lang.String cardPath)
Store the given data to the given path on the GateKeeper Card.
|
GKFileActions.FileResult |
renameFile(GKFile file,
java.lang.String name)
Rename the file located at fromCardPath to the name specified by toCardPath
|
public GKFileActions(GKCard card)
GKFileActions that communicates with card.card - the GKCard to be used with file actionspublic GKFileActions.ListFilesResult listFiles(java.lang.String cardPath) throws java.io.IOException
cardPath - the path at which to retrieve the list of filesListFilesResult of the actionjava.io.IOException - when communication with the GateKeeper Card has been disrupted.public GKFileActions.GetFileResult getFile(GKFile file, java.io.File localFile) throws java.io.IOException
file - a GKFile referencing the file to retrievelocalFile - a File to store retrieved file dataGetFileResult of the actionjava.io.IOException - when communication with the GateKeeper Card has been disrupted.public GKFileActions.PutFileResult putFile(java.io.InputStream localFile, java.lang.String cardPath) throws java.io.IOException
localFile - a stream with file datacardPath - the path at which to store the file dataFileResult of the actionjava.io.IOException - when communication with the GateKeeper Card has been disrupted.public GKFileActions.FileResult renameFile(GKFile file, java.lang.String name) throws java.io.IOException
file - the GKFile to be renamedname - the new name of the file, relative to the file's current card pathFileResult of the actionjava.io.IOException - when communication with the GateKeeper Card has been disrupted.public GKFileActions.FileResult deleteFile(GKFile file) throws java.io.IOException
file - a GKFile referencing the file to deleteFileResult of the actionjava.io.IOException - when communication with the GateKeeper Card has been disrupted.public GKFileActions.FileResult makeDirectory(java.lang.String cardPath) throws java.io.IOException
cardPath - the path at which to create the directoryFileResult of the actionjava.io.IOException - when communication with the GateKeeper Card has been disrupted.