Class ShareFileCopyOptions

java.lang.Object
com.azure.storage.file.share.options.ShareFileCopyOptions

public final class ShareFileCopyOptions extends Object
Extended options that may be passed when copying a share.
  • Constructor Details

    • ShareFileCopyOptions

      public ShareFileCopyOptions()
      Creates a new instance of ShareFileCopyOptions.
  • Method Details

    • getFilePermission

      public String getFilePermission()
      Gets the file permission key.
      Returns:
      The file's permission key.
    • setFilePermission

      public ShareFileCopyOptions setFilePermission(String filePermissionKey)
      Sets the file permission key.
      Parameters:
      filePermissionKey - The file permission key.
      Returns:
      the updated options.
    • getSmbProperties

      public FileSmbProperties getSmbProperties()
      Gets the SMB properties to set on the destination file.
      Returns:
      Optional SMB properties to set on the destination file or directory. The only properties that are considered are file attributes, file creation time, file last write time, and file permission key. The rest are ignored.
    • setSmbProperties

      public ShareFileCopyOptions setSmbProperties(FileSmbProperties smbProperties)
      Sets the SMB properties to set on the destination file.
      Parameters:
      smbProperties - Optional SMB properties to set on the destination file or directory. The only properties that are considered are file attributes, file creation time, file last write time, and file permission key. The rest are ignored.
      Returns:
      The updated options.
    • getPermissionCopyModeType

      public PermissionCopyModeType getPermissionCopyModeType()
      Gets the option to copy file security descriptor from source file or to set it using the value which is defined by the header value of FilePermission or FilePermissionKey.
      Returns:
      the option to copy file security descriptor from source file or to set it using the value which is defined by the header value of FilePermission or FilePermissionKey.
    • setPermissionCopyModeType

      public ShareFileCopyOptions setPermissionCopyModeType(PermissionCopyModeType copyModeType)
      Sets the option to copy file security descriptor from source file or to set it using the value which is defined by the header value of FilePermission or FilePermissionKey.
      Parameters:
      copyModeType - specified option to copy file security descriptor from source file or to set it using the value which is defined by the header value of FilePermission or FilePermissionKey.
      Returns:
      The updated options.
    • isIgnoreReadOnly

      public Boolean isIgnoreReadOnly()
      Gets the optional boolean specifying to overwrite the target file if it already exists and has read-only attribute set.
      Returns:
      Optional boolean specifying to overwrite the target file if it already exists and has read-only attribute set.
    • setIgnoreReadOnly

      public ShareFileCopyOptions setIgnoreReadOnly(Boolean ignoreReadOnly)
      Sets the optional boolean specifying to overwrite the target file if it already exists and has read-only attribute set.
      Parameters:
      ignoreReadOnly - Optional boolean specifying to overwrite the target file if it already exists and has read-only attribute set.
      Returns:
      The updated options.
    • isArchiveAttributeSet

      public Boolean isArchiveAttributeSet()
      Gets the optional boolean specifying to set archive attribute on a target file. True means archive attribute will be set on a target file despite attribute overrides or a source file state.
      Returns:
      Optional boolean specifying to set archive attribute on a target file. True means archive attribute will be set on a target file despite attribute overrides or a source file state.
    • setArchiveAttribute

      public ShareFileCopyOptions setArchiveAttribute(Boolean archiveAttribute)
      Sets the optional boolean specifying to set archive attribute on a target file. True means archive attribute will be set on a target file despite attribute overrides or a source file state.
      Parameters:
      archiveAttribute - Optional boolean Specifying to set archive attribute on a target file. True means archive attribute will be set on a target file despite attribute overrides or a source file state.
      Returns:
      The updated options.
    • getMetadata

      public Map<String,String> getMetadata()
      Gets the metadata to associate with the file.
      Returns:
      Metadata to associate with the file.
    • setMetadata

      public ShareFileCopyOptions setMetadata(Map<String,String> metadata)
      Sets the metadata to associate with the file.
      Parameters:
      metadata - Metadata to associate with the file. If there is leading or trailing whitespace in any metadata key or value, it must be removed or encoded.
      Returns:
      The updated options.
    • getDestinationRequestConditions

      public ShareRequestConditions getDestinationRequestConditions()
      Returns:
      ShareRequestConditions
    • setDestinationRequestConditions

      public ShareFileCopyOptions setDestinationRequestConditions(ShareRequestConditions requestConditions)
      Sets the ShareRequestConditions to add conditions on copying the file.
      Parameters:
      requestConditions - ShareRequestConditions
      Returns:
      The updated options.
    • getSmbPropertiesToCopy

      public CopyableFileSmbPropertiesList getSmbPropertiesToCopy()
      Gets the SMB properties to copy from the source file.
      Returns:
      SMB properties to copy from the source file.
    • setSmbPropertiesToCopy

      public ShareFileCopyOptions setSmbPropertiesToCopy(CopyableFileSmbPropertiesList smbProperties)
      Sets the SMB properties to copy from the source file.
      Parameters:
      smbProperties - list of SMB properties to copy from the source file.
      Returns:
      The updated options.
    • getFilePermissionFormat

      public FilePermissionFormat getFilePermissionFormat()
      Gets the file permission format.
      Returns:
      file permission format.
    • setFilePermissionFormat

      public ShareFileCopyOptions setFilePermissionFormat(FilePermissionFormat filePermissionFormat)
      Sets the file permission format.
      Parameters:
      filePermissionFormat - the file permission format.
      Returns:
      The updated options.
    • getPosixProperties

      public FilePosixProperties getPosixProperties()
      Optional properties to set on NFS files. Note that this property is only applicable to files created in NFS shares.
      Returns:
      FilePosixProperties
    • setPosixProperties

      public ShareFileCopyOptions setPosixProperties(FilePosixProperties posixProperties)
      Optional properties to set on NFS files. Note that this property is only applicable to files created in NFS shares.
      Parameters:
      posixProperties - FilePosixProperties
      Returns:
      The updated options.
    • getModeCopyMode

      public ModeCopyMode getModeCopyMode()
      Optional properties to set on NFS files. Note that this property is only applicable to files created in NFS shares. If not populated, the destination file will have the default File Mode.
      Returns:
      The destination file's FileMode.
    • setModeCopyMode

      public ShareFileCopyOptions setModeCopyMode(ModeCopyMode modeCopyMode)
      Optional properties to set on NFS files. Note that this property is only applicable to files created in NFS shares. If not populated, the destination file will have the default File Mode.
      Parameters:
      modeCopyMode - The destination file's FileMode.
      Returns:
      The updated options.
    • getOwnerCopyMode

      public OwnerCopyMode getOwnerCopyMode()
      Optional properties to set on NFS files. Note that this property is only applicable to files created in NFS shares. If not populated,the destination file will have the default Owner and Group.
      Returns:
      The destination file's Owner and Group.
    • setOwnerCopyMode

      public ShareFileCopyOptions setOwnerCopyMode(OwnerCopyMode ownerCopyMode)
      Optional properties to set on NFS files. Note that this property is only applicable to files created in NFS shares. If not populated,the destination file will have the default Owner and Group.
      Parameters:
      ownerCopyMode - The destination file's Owner and Group.
      Returns:
      The updated options.