public class FileOperations extends Object implements IInheritedBehaviors
Modifier and Type | Method and Description |
---|---|
Collection<BatchClientBehavior> |
customBehaviors()
Gets a collection of behaviors that modify or customize requests to the Batch service.
|
void |
deleteFileFromComputeNode(String poolId,
String nodeId,
String fileName)
Deletes the specified file from the specified compute node.
|
void |
deleteFileFromComputeNode(String poolId,
String nodeId,
String fileName,
Boolean recursive)
Deletes the specified file from the specified compute node.
|
void |
deleteFileFromComputeNode(String poolId,
String nodeId,
String fileName,
Boolean recursive,
Iterable<BatchClientBehavior> additionalBehaviors)
Deletes the specified file from the specified compute node.
|
void |
deleteFileFromTask(String jobId,
String taskId,
String fileName)
Deletes the specified file from the specified task's directory on its compute node.
|
void |
deleteFileFromTask(String jobId,
String taskId,
String fileName,
Boolean recursive)
Deletes the specified file from the specified task's directory on its compute node.
|
void |
deleteFileFromTask(String jobId,
String taskId,
String fileName,
Boolean recursive,
Iterable<BatchClientBehavior> additionalBehaviors)
Deletes the specified file from the specified task's directory on its compute node.
|
void |
getFileFromComputeNode(String poolId,
String nodeId,
String fileName,
Iterable<BatchClientBehavior> additionalBehaviors,
OutputStream outputStream)
Downloads the specified file from the specified compute node.
|
void |
getFileFromComputeNode(String poolId,
String nodeId,
String fileName,
OutputStream outputStream)
Downloads the specified file from the specified compute node.
|
void |
getFileFromTask(String jobId,
String taskId,
String fileName,
Iterable<BatchClientBehavior> additionalBehaviors,
OutputStream outputStream)
Downloads the specified file from the specified task's directory on its compute node.
|
void |
getFileFromTask(String jobId,
String taskId,
String fileName,
OutputStream outputStream)
Downloads the specified file from the specified task's directory on its compute node.
|
FileProperties |
getFilePropertiesFromComputeNode(String poolId,
String nodeId,
String fileName)
Gets information about a file on a compute node.
|
FileProperties |
getFilePropertiesFromComputeNode(String poolId,
String nodeId,
String fileName,
Iterable<BatchClientBehavior> additionalBehaviors)
Gets information about a file on a compute node.
|
FileProperties |
getFilePropertiesFromTask(String jobId,
String taskId,
String fileName)
Gets information about a file from the specified task's directory on its compute node.
|
FileProperties |
getFilePropertiesFromTask(String jobId,
String taskId,
String fileName,
Iterable<BatchClientBehavior> additionalBehaviors)
Gets information about a file from the specified task's directory on its compute node.
|
List<NodeFile> |
listFilesFromComputeNode(String poolId,
String nodeId)
Lists files on the specified compute node.
|
List<NodeFile> |
listFilesFromComputeNode(String poolId,
String nodeId,
Boolean recursive,
DetailLevel detailLevel)
Lists files on the specified compute node.
|
List<NodeFile> |
listFilesFromComputeNode(String poolId,
String nodeId,
Boolean recursive,
DetailLevel detailLevel,
Iterable<BatchClientBehavior> additionalBehaviors)
Lists files on the specified compute node.
|
List<NodeFile> |
listFilesFromTask(String jobId,
String taskId)
Lists the files in the specified task's directory on its compute node.
|
List<NodeFile> |
listFilesFromTask(String jobId,
String taskId,
Boolean recursive,
DetailLevel detailLevel)
Lists the files in the specified task's directory on its compute node.
|
List<NodeFile> |
listFilesFromTask(String jobId,
String taskId,
Boolean recursive,
DetailLevel detailLevel,
Iterable<BatchClientBehavior> additionalBehaviors)
Lists the files in the specified task's directory on its compute node.
|
IInheritedBehaviors |
withCustomBehaviors(Collection<BatchClientBehavior> behaviors)
Sets a collection of behaviors that modify or customize requests to the Batch service.
|
public Collection<BatchClientBehavior> customBehaviors()
customBehaviors
in interface IInheritedBehaviors
BatchClientBehavior
instances.public IInheritedBehaviors withCustomBehaviors(Collection<BatchClientBehavior> behaviors)
withCustomBehaviors
in interface IInheritedBehaviors
behaviors
- The collection of BatchClientBehavior
instances.public List<NodeFile> listFilesFromTask(String jobId, String taskId) throws BatchErrorException, IOException
jobId
- The ID of the job.taskId
- The ID of the task.NodeFile
objects.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public List<NodeFile> listFilesFromTask(String jobId, String taskId, Boolean recursive, DetailLevel detailLevel) throws BatchErrorException, IOException
jobId
- The ID of the job.taskId
- The ID of the task.recursive
- If true, performs a recursive list of all files of the task. If false or null, returns only the files in the root task directory.detailLevel
- A DetailLevel
used for filtering the list and for controlling which properties are retrieved from the service.NodeFile
objects.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public List<NodeFile> listFilesFromTask(String jobId, String taskId, Boolean recursive, DetailLevel detailLevel, Iterable<BatchClientBehavior> additionalBehaviors) throws BatchErrorException, IOException
jobId
- The ID of the job.taskId
- The ID of the task.recursive
- If true, performs a recursive list of all files of the task. If false or null, returns only the files in the root task directory.detailLevel
- A DetailLevel
used for filtering the list and for controlling which properties are retrieved from the service.additionalBehaviors
- A collection of BatchClientBehavior
instances that are applied to the Batch service request.NodeFile
objects.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public List<NodeFile> listFilesFromComputeNode(String poolId, String nodeId) throws BatchErrorException, IOException
poolId
- The ID of the pool that contains the compute node.nodeId
- The ID of the compute node.NodeFile
objects.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public List<NodeFile> listFilesFromComputeNode(String poolId, String nodeId, Boolean recursive, DetailLevel detailLevel) throws BatchErrorException, IOException
poolId
- The ID of the pool that contains the compute node.nodeId
- The ID of the compute node.recursive
- If true, recursively lists all files on the compute node. If false or null, lists only the files in the compute node root directory.detailLevel
- A DetailLevel
used for filtering the list and for controlling which properties are retrieved from the service.NodeFile
objects.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public List<NodeFile> listFilesFromComputeNode(String poolId, String nodeId, Boolean recursive, DetailLevel detailLevel, Iterable<BatchClientBehavior> additionalBehaviors) throws BatchErrorException, IOException
poolId
- The ID of the pool that contains the compute node.nodeId
- The ID of the compute node.recursive
- If true, recursively lists all files on the compute node. If false or null, lists only the files in the compute node root directory.detailLevel
- A DetailLevel
used for filtering the list and for controlling which properties are retrieved from the service.additionalBehaviors
- A collection of BatchClientBehavior
instances that are applied to the Batch service request.NodeFile
objects.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public void deleteFileFromTask(String jobId, String taskId, String fileName) throws BatchErrorException, IOException
jobId
- The ID of the job containing the task.taskId
- The ID of the task.fileName
- The name of the file to delete.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public void deleteFileFromTask(String jobId, String taskId, String fileName, Boolean recursive) throws BatchErrorException, IOException
jobId
- The ID of the job containing the task.taskId
- The ID of the task.fileName
- The name of the file to delete.recursive
- If the file-path parameter represents a directory instead of a file, you can set the recursive parameter to true to delete the directory and all of the files and subdirectories in it. If recursive is false or null, then the directory must be empty or deletion will fail.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public void deleteFileFromTask(String jobId, String taskId, String fileName, Boolean recursive, Iterable<BatchClientBehavior> additionalBehaviors) throws BatchErrorException, IOException
jobId
- The ID of the job containing the task.taskId
- The ID of the task.fileName
- The name of the file to delete.recursive
- If the file-path parameter represents a directory instead of a file, you can set the recursive parameter to true to delete the directory and all of the files and subdirectories in it. If recursive is false or null, then the directory must be empty or deletion will fail.additionalBehaviors
- A collection of BatchClientBehavior
instances that are applied to the Batch service request.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public void deleteFileFromComputeNode(String poolId, String nodeId, String fileName) throws BatchErrorException, IOException
poolId
- The ID of the pool that contains the compute node.nodeId
- The ID of the compute node.fileName
- The name of the file to delete.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public void deleteFileFromComputeNode(String poolId, String nodeId, String fileName, Boolean recursive) throws BatchErrorException, IOException
poolId
- The ID of the pool that contains the compute node.nodeId
- The ID of the compute node.fileName
- The name of the file to delete.recursive
- If the file-path parameter represents a directory instead of a file, you can set the recursive parameter to true to delete the directory and all of the files and subdirectories in it. If recursive is false or null, then the directory must be empty or deletion will fail.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public void deleteFileFromComputeNode(String poolId, String nodeId, String fileName, Boolean recursive, Iterable<BatchClientBehavior> additionalBehaviors) throws BatchErrorException, IOException
poolId
- The ID of the pool that contains the compute node.nodeId
- The ID of the compute node.fileName
- The name of the file to delete.recursive
- If the file-path parameter represents a directory instead of a file, you can set the recursive parameter to true to delete the directory and all of the files and subdirectories in it. If recursive is false or null, then the directory must be empty or deletion will fail.additionalBehaviors
- A collection of BatchClientBehavior
instances that are applied to the Batch service request.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public void getFileFromTask(String jobId, String taskId, String fileName, OutputStream outputStream) throws BatchErrorException, IOException
jobId
- The ID of the job containing the task.taskId
- The ID of the task.fileName
- The name of the file to download.outputStream
- A stream into which the file contents will be written.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public void getFileFromTask(String jobId, String taskId, String fileName, Iterable<BatchClientBehavior> additionalBehaviors, OutputStream outputStream) throws BatchErrorException, IOException
jobId
- The ID of the job containing the task.taskId
- The ID of the task.fileName
- The name of the file to download.additionalBehaviors
- A collection of BatchClientBehavior
instances that are applied to the Batch service request.outputStream
- A stream into which the file contents will be written.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public void getFileFromComputeNode(String poolId, String nodeId, String fileName, OutputStream outputStream) throws BatchErrorException, IOException
poolId
- The ID of the pool that contains the compute node.nodeId
- The ID of the compute node.fileName
- The name of the file to download.outputStream
- A stream into which the file contents will be written.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public void getFileFromComputeNode(String poolId, String nodeId, String fileName, Iterable<BatchClientBehavior> additionalBehaviors, OutputStream outputStream) throws BatchErrorException, IOException
poolId
- The ID of the pool that contains the compute node.nodeId
- The ID of the compute node.fileName
- The name of the file to download.additionalBehaviors
- A collection of BatchClientBehavior
instances that are applied to the Batch service request.outputStream
- A stream into which the file contents will be written.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public FileProperties getFilePropertiesFromTask(String jobId, String taskId, String fileName) throws BatchErrorException, IOException
jobId
- The ID of the job containing the task.taskId
- The ID of the task.fileName
- The name of the file to retrieve.FileProperties
instance containing information about the file.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public FileProperties getFilePropertiesFromTask(String jobId, String taskId, String fileName, Iterable<BatchClientBehavior> additionalBehaviors) throws BatchErrorException, IOException
jobId
- The ID of the job containing the task.taskId
- The ID of the task.fileName
- The name of the file to retrieve.additionalBehaviors
- A collection of BatchClientBehavior
instances that are applied to the Batch service request.FileProperties
instance containing information about the file.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public FileProperties getFilePropertiesFromComputeNode(String poolId, String nodeId, String fileName) throws BatchErrorException, IOException
poolId
- The ID of the pool that contains the compute node.nodeId
- the ID of the compute node.fileName
- The name of the file to retrieve.FileProperties
instance containing information about the file.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.public FileProperties getFilePropertiesFromComputeNode(String poolId, String nodeId, String fileName, Iterable<BatchClientBehavior> additionalBehaviors) throws BatchErrorException, IOException
poolId
- The ID of the pool that contains the compute node.nodeId
- the ID of the compute node.fileName
- The name of the file to retrieve.additionalBehaviors
- A collection of BatchClientBehavior
instances that are applied to the Batch service request.FileProperties
instance containing information about the file.BatchErrorException
- Exception thrown when an error response is received from the Batch service.IOException
- Exception thrown when there is an error in serialization/deserialization of data sent to/received from the Batch service.Copyright © 2019. All rights reserved.