Documentation ¶
Index ¶
- type Client
- func (c Client) Create(ctx context.Context, shareName, path string, input CreateDirectoryInput) (resp CreateDirectoryResponse, err error)
- func (c Client) Delete(ctx context.Context, shareName, path string) (resp DeleteResponse, err error)
- func (c Client) Get(ctx context.Context, shareName, path string) (resp GetResponse, err error)
- func (c Client) GetMetaData(ctx context.Context, shareName, path string) (resp GetMetaDataResponse, err error)
- func (c Client) SetMetaData(ctx context.Context, shareName, path string, input SetMetaDataInput) (resp SetMetaDataResponse, err error)
- type CreateDirectoryInput
- type CreateDirectoryResponse
- type CreateOptions
- type DeleteResponse
- type DirectoryId
- type GetMetaDataOptions
- type GetMetaDataResponse
- type GetResponse
- type SetMetaDataInput
- type SetMetaDataOptions
- type SetMetaDataResponse
- type StorageDirectory
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
Client is the base client for File Storage Shares.
func NewWithBaseUri ¶ added in v0.21.0
func (Client) Create ¶
func (c Client) Create(ctx context.Context, shareName, path string, input CreateDirectoryInput) (resp CreateDirectoryResponse, err error)
Create creates a new directory under the specified share or parent directory.
func (Client) Delete ¶
func (c Client) Delete(ctx context.Context, shareName, path string) (resp DeleteResponse, err error)
Delete removes the specified empty directory Note that the directory must be empty before it can be deleted.
func (Client) Get ¶
Get returns all system properties for the specified directory, and can also be used to check the existence of a directory.
func (Client) GetMetaData ¶
func (c Client) GetMetaData(ctx context.Context, shareName, path string) (resp GetMetaDataResponse, err error)
GetMetaData returns all user-defined metadata for the specified directory
func (Client) SetMetaData ¶
func (c Client) SetMetaData(ctx context.Context, shareName, path string, input SetMetaDataInput) (resp SetMetaDataResponse, err error)
SetMetaData updates user defined metadata for the specified directory
type CreateDirectoryInput ¶
type CreateDirectoryInput struct { // The time at which this file was created at - if omitted, this'll be set to "now" // This maps to the `x-ms-file-creation-time` field. // ... Yes I know it says File not Directory, I didn't design the API. CreatedAt *time.Time // The time at which this file was last modified - if omitted, this'll be set to "now" // This maps to the `x-ms-file-last-write-time` field. // ... Yes I know it says File not Directory, I didn't design the API. LastModified *time.Time // MetaData is a mapping of key value pairs which should be assigned to this directory MetaData map[string]string }
type CreateDirectoryResponse ¶ added in v0.21.0
type CreateOptions ¶ added in v0.21.0
type CreateOptions struct {
// contains filtered or unexported fields
}
func (CreateOptions) ToHeaders ¶ added in v0.21.0
func (c CreateOptions) ToHeaders() *client.Headers
func (CreateOptions) ToOData ¶ added in v0.21.0
func (c CreateOptions) ToOData() *odata.Query
func (CreateOptions) ToQuery ¶ added in v0.21.0
func (c CreateOptions) ToQuery() *client.QueryParams
type DeleteResponse ¶ added in v0.21.0
type DirectoryId ¶ added in v0.22.0
type DirectoryId struct { // AccountId specifies the ID of the Storage Account where this Directory exists. AccountId accounts.AccountId ShareName string // DirectoryPath specifies the path representing this Directory. DirectoryPath string }
func NewDirectoryID ¶ added in v0.22.0
func NewDirectoryID(accountId accounts.AccountId, shareName, directoryPath string) DirectoryId
func ParseDirectoryID ¶ added in v0.22.0
func ParseDirectoryID(input, domainSuffix string) (*DirectoryId, error)
ParseDirectoryID parses `input` into a Directory ID using a known `domainSuffix`
func (DirectoryId) ID ¶ added in v0.22.0
func (b DirectoryId) ID() string
func (DirectoryId) String ¶ added in v0.22.0
func (b DirectoryId) String() string
type GetMetaDataOptions ¶ added in v0.21.0
type GetMetaDataOptions struct{}
func (GetMetaDataOptions) ToHeaders ¶ added in v0.21.0
func (g GetMetaDataOptions) ToHeaders() *client.Headers
func (GetMetaDataOptions) ToOData ¶ added in v0.21.0
func (g GetMetaDataOptions) ToOData() *odata.Query
func (GetMetaDataOptions) ToQuery ¶ added in v0.21.0
func (g GetMetaDataOptions) ToQuery() *client.QueryParams
type GetMetaDataResponse ¶ added in v0.21.0
type GetResponse ¶ added in v0.21.0
type GetResponse struct { HttpResponse *client.Response // A set of name-value pairs that contain metadata for the directory. MetaData map[string]string // The value of this header is set to true if the directory metadata is completely // encrypted using the specified algorithm. Otherwise, the value is set to false. DirectoryMetaDataEncrypted bool }
type SetMetaDataInput ¶ added in v0.21.0
type SetMetaDataOptions ¶ added in v0.21.0
type SetMetaDataOptions struct {
// contains filtered or unexported fields
}
func (SetMetaDataOptions) ToHeaders ¶ added in v0.21.0
func (s SetMetaDataOptions) ToHeaders() *client.Headers
func (SetMetaDataOptions) ToOData ¶ added in v0.21.0
func (s SetMetaDataOptions) ToOData() *odata.Query
func (SetMetaDataOptions) ToQuery ¶ added in v0.21.0
func (s SetMetaDataOptions) ToQuery() *client.QueryParams
type SetMetaDataResponse ¶ added in v0.21.0
type StorageDirectory ¶
type StorageDirectory interface { Delete(ctx context.Context, shareName, path string) (resp DeleteResponse, err error) GetMetaData(ctx context.Context, shareName, path string) (resp GetMetaDataResponse, err error) SetMetaData(ctx context.Context, shareName, path string, input SetMetaDataInput) (resp SetMetaDataResponse, err error) Create(ctx context.Context, shareName, path string, input CreateDirectoryInput) (resp CreateDirectoryResponse, err error) Get(ctx context.Context, shareName, path string) (resp GetResponse, err error) }
Click to show internal directories.
Click to hide internal directories.