public interface BatchRepositoryService
The methods in this service are a best effort, which means that if an error occurs with one resource, the error continues on to the next resource.
Each method returns an ActionStatus
with a
ActionStatus.CompletionStatus
and message that indicates the overall completion
status. The ActionStatus also contains a list of ActionStatusDetail
s, which
indicates the status of each file.
Modifier and Type | Method and Description |
---|---|
ActionStatus |
checkin(List<String> paths,
RepositoryCheckinSpecification checkinSpecification)
Checks in all of the files that are specified in the list of paths (which can contain container paths and file
paths) that are ready for check in.
|
ActionStatus |
checkout(List<String> paths)
Checks out all of the files that are specified in the list of paths (which can contain container paths and file
paths).
|
void |
downloadAsZip(Set<String> paths,
String localFilePath,
boolean overwrite)
Downloads the files from a specified set of paths to a the zip file.
|
ActionStatus |
uploadAndExpand(String parentPath,
String localZipFilePath,
boolean enableVersioningOnAllNewFiles,
RepositoryCheckinSpecification checkinSpecification,
boolean createParentFolders)
Unzips the zip file that is specified in localZipFilePath and saves the contents to the repository location that
is specified in parentPath.
|
ActionStatus checkout(List<String> paths)
paths
- The list of paths.ActionStatus checkin(List<String> paths, RepositoryCheckinSpecification checkinSpecification)
If null
is specified for checkin, it is interpreted as a blank comment and the MINOR
version update value, if the file is versioned.
paths
- The list of paths.checkinSpecification
- The method to check in files. If null is specified and the files are versioned, the
version defaults to a MAJOR version.ActionStatus uploadAndExpand(String parentPath, String localZipFilePath, boolean enableVersioningOnAllNewFiles, RepositoryCheckinSpecification checkinSpecification, boolean createParentFolders) throws IOException
If null
is specified for checkin, it is interpreted as a blank comment and the MAJOR
version update value, if the file is versioned.
parentPath
- The parent path to the container in which to create and expand the contents of the specified
zip file.localZipFilePath
- The local file path to the zip file to upload and expand.enableVersioningOnAllNewFiles
- Indicates whether to enable versioning for new files.checkinSpecification
- The method to check in files. Applies to existing versioned files and new files, if
enableVersioningOnAllNewFiles is true.createParentFolders
- Indicates whether to create parent containers, if they do not exist.IOException
void downloadAsZip(Set<String> paths, String localFilePath, boolean overwrite) throws RepositoryItemNotFoundException, IOException
paths
- The list of paths to download.localFilePath
- The local file path in which to save the zip file.overwrite
- Indicates whether to overwrite the local zip file, if it exists.RepositoryItemNotFoundException
IOException
<i>Copyright (c) 2020, SAS Institute Inc., Cary, NC, USA</i>