Documentation ¶
Index ¶
- Constants
- func AttributesToGRPC(xs []Attribute) (res []container.Container_Attribute)
- func GlobalizeFail(c *status.Code)
- func LocalizeFailStatus(c *status.Code) bool
- type Attribute
- func (a *Attribute) FromGRPCMessage(m grpc.Message) error
- func (a *Attribute) GetKey() string
- func (a *Attribute) GetValue() string
- func (a *Attribute) MarshalJSON() ([]byte, error)
- func (a *Attribute) SetKey(v string)
- func (a *Attribute) SetValue(v string)
- func (a *Attribute) StableMarshal(buf []byte) []byte
- func (a *Attribute) StableSize() (size int)
- func (a *Attribute) ToGRPCMessage() grpc.Message
- func (a *Attribute) Unmarshal(data []byte) error
- func (a *Attribute) UnmarshalJSON(data []byte) error
- type Container
- func (c *Container) FromGRPCMessage(m grpc.Message) error
- func (c *Container) GetAttributes() []Attribute
- func (c *Container) GetBasicACL() uint32
- func (c *Container) GetNonce() []byte
- func (c *Container) GetOwnerID() *refs.OwnerID
- func (c *Container) GetPlacementPolicy() *netmap.PlacementPolicy
- func (c *Container) GetVersion() *refs.Version
- func (c Container) HomomorphicHashingState() bool
- func (c *Container) MarshalJSON() ([]byte, error)
- func (c *Container) SetAttributes(v []Attribute)
- func (c *Container) SetBasicACL(v uint32)
- func (c *Container) SetHomomorphicHashingState(enable bool)
- func (c *Container) SetNonce(v []byte)
- func (c *Container) SetOwnerID(v *refs.OwnerID)
- func (c *Container) SetPlacementPolicy(v *netmap.PlacementPolicy)
- func (c *Container) SetVersion(v *refs.Version)
- func (c *Container) StableMarshal(buf []byte) []byte
- func (c *Container) StableSize() (size int)
- func (c *Container) ToGRPCMessage() grpc.Message
- func (c *Container) Unmarshal(data []byte) error
- func (c *Container) UnmarshalJSON(data []byte) error
- type DeleteRequest
- type DeleteRequestBody
- func (r *DeleteRequestBody) FromGRPCMessage(m grpc.Message) error
- func (r *DeleteRequestBody) GetContainerID() *refs.ContainerID
- func (r *DeleteRequestBody) GetSignature() *refs.Signature
- func (r *DeleteRequestBody) SetContainerID(v *refs.ContainerID)
- func (r *DeleteRequestBody) SetSignature(v *refs.Signature)
- func (r *DeleteRequestBody) StableMarshal(buf []byte) []byte
- func (r *DeleteRequestBody) StableSize() (size int)
- func (r *DeleteRequestBody) ToGRPCMessage() grpc.Message
- func (r *DeleteRequestBody) Unmarshal(data []byte) error
- type DeleteResponse
- type DeleteResponseBody
- type GetRequest
- type GetRequestBody
- func (r *GetRequestBody) FromGRPCMessage(m grpc.Message) error
- func (r *GetRequestBody) GetContainerID() *refs.ContainerID
- func (r *GetRequestBody) SetContainerID(v *refs.ContainerID)
- func (r *GetRequestBody) StableMarshal(buf []byte) []byte
- func (r *GetRequestBody) StableSize() (size int)
- func (r *GetRequestBody) ToGRPCMessage() grpc.Message
- func (r *GetRequestBody) Unmarshal(data []byte) error
- type GetResponse
- type GetResponseBody
- func (r *GetResponseBody) FromGRPCMessage(m grpc.Message) error
- func (r *GetResponseBody) GetContainer() *Container
- func (r *GetResponseBody) GetSessionToken() *session.Token
- func (r *GetResponseBody) GetSignature() *refs.Signature
- func (r *GetResponseBody) SetContainer(v *Container)
- func (r *GetResponseBody) SetSessionToken(v *session.Token)
- func (r *GetResponseBody) SetSignature(v *refs.Signature)
- func (r *GetResponseBody) StableMarshal(buf []byte) []byte
- func (r *GetResponseBody) StableSize() (size int)
- func (r *GetResponseBody) ToGRPCMessage() grpc.Message
- func (r *GetResponseBody) Unmarshal(data []byte) error
- type ListRequest
- type ListRequestBody
- func (r *ListRequestBody) FromGRPCMessage(m grpc.Message) error
- func (r *ListRequestBody) GetOwnerID() *refs.OwnerID
- func (r *ListRequestBody) SetOwnerID(v *refs.OwnerID)
- func (r *ListRequestBody) StableMarshal(buf []byte) []byte
- func (r *ListRequestBody) StableSize() (size int)
- func (r *ListRequestBody) ToGRPCMessage() grpc.Message
- func (r *ListRequestBody) Unmarshal(data []byte) error
- type ListResponse
- type ListResponseBody
- func (r *ListResponseBody) FromGRPCMessage(m grpc.Message) error
- func (r *ListResponseBody) GetContainerIDs() []refs.ContainerID
- func (r *ListResponseBody) SetContainerIDs(v []refs.ContainerID)
- func (r *ListResponseBody) StableMarshal(buf []byte) []byte
- func (r *ListResponseBody) StableSize() (size int)
- func (r *ListResponseBody) ToGRPCMessage() grpc.Message
- func (r *ListResponseBody) Unmarshal(data []byte) error
- type PutRequest
- type PutRequestBody
- func (r *PutRequestBody) FromGRPCMessage(m grpc.Message) error
- func (r *PutRequestBody) GetContainer() *Container
- func (r *PutRequestBody) GetSignature() *refs.Signature
- func (r *PutRequestBody) SetContainer(v *Container)
- func (r *PutRequestBody) SetSignature(v *refs.Signature)
- func (r *PutRequestBody) StableMarshal(buf []byte) []byte
- func (r *PutRequestBody) StableSize() (size int)
- func (r *PutRequestBody) ToGRPCMessage() grpc.Message
- func (r *PutRequestBody) Unmarshal(data []byte) error
- type PutResponse
- type PutResponseBody
- func (r *PutResponseBody) FromGRPCMessage(m grpc.Message) error
- func (r *PutResponseBody) GetContainerID() *refs.ContainerID
- func (r *PutResponseBody) SetContainerID(v *refs.ContainerID)
- func (r *PutResponseBody) StableMarshal(buf []byte) []byte
- func (r *PutResponseBody) StableSize() (size int)
- func (r *PutResponseBody) ToGRPCMessage() grpc.Message
- func (r *PutResponseBody) Unmarshal(data []byte) error
Constants ¶
const ( // SysAttributeName is a string of human-friendly container name registered as the domain in NNS contract. SysAttributeName = SysAttributePrefix + "NAME" // SysAttributeZone is a string of zone for container name. SysAttributeZone = SysAttributePrefix + "ZONE" // SysAttributeHomomorphicHashing is a container's homomorphic hashing state. SysAttributeHomomorphicHashing = SysAttributePrefix + "DISABLE_HOMOMORPHIC_HASHING" )
const ( // SysAttributeNameNeoFS is a string of human-friendly container name registered as the domain in NNS contract. // Deprecated: use SysAttributeName. SysAttributeNameNeoFS = SysAttributePrefixNeoFS + "NAME" // SysAttributeZoneNeoFS is a string of zone for container name. // Deprecated: use SysAttributeZone. SysAttributeZoneNeoFS = SysAttributePrefixNeoFS + "ZONE" // SysAttributeHomomorphicHashingNeoFS is a container's homomorphic hashing state. // Deprecated: use SysAttributeHomomorphicHashing. SysAttributeHomomorphicHashingNeoFS = SysAttributePrefixNeoFS + "DISABLE_HOMOMORPHIC_HASHING" )
const ( // StatusNotFound is a local status.Code value for // CONTAINER_NOT_FOUND container failure. StatusNotFound status.Code = iota // StatusEACLNotFound is a local status.Code value for // EACL_NOT_FOUND failure. StatusEACLNotFound )
const SysAttributePrefix = "__SYSTEM__"
SysAttributePrefix is a prefix of key to system attribute.
const SysAttributePrefixNeoFS = "__NEOFS__"
SysAttributePrefixNeoFS is a prefix of key to system attribute. Deprecated: use SysAttributePrefix.
const SysAttributeZoneDefault = "container"
SysAttributeZoneDefault is a default value for SysAttributeZone attribute.
Variables ¶
This section is empty.
Functions ¶
func AttributesToGRPC ¶
func AttributesToGRPC(xs []Attribute) (res []container.Container_Attribute)
func LocalizeFailStatus ¶
LocalizeFailStatus checks if passed global status.Code is related to container failure and:
then localizes the code and returns true, else leaves the code unchanged and returns false.
Arg must not be nil.
Types ¶
type Attribute ¶
type Attribute struct {
// contains filtered or unexported fields
}
func AttributesFromGRPC ¶
func AttributesFromGRPC(xs []container.Container_Attribute) (res []Attribute, err error)
func (*Attribute) MarshalJSON ¶
func (*Attribute) StableMarshal ¶
func (*Attribute) StableSize ¶
func (*Attribute) ToGRPCMessage ¶
func (*Attribute) UnmarshalJSON ¶
type Container ¶
type Container struct {
// contains filtered or unexported fields
}
func (*Container) GetAttributes ¶
func (*Container) GetBasicACL ¶
func (*Container) GetOwnerID ¶
func (*Container) GetPlacementPolicy ¶
func (c *Container) GetPlacementPolicy() *netmap.PlacementPolicy
func (*Container) GetVersion ¶
func (Container) HomomorphicHashingState ¶
HomomorphicHashingState returns container's homomorphic hashing state:
- true if hashing is enabled;
- false if hashing is disabled.
All container's attributes must be unique, otherwise behavior is undefined.
See also SetHomomorphicHashingState.
func (*Container) MarshalJSON ¶
func (*Container) SetAttributes ¶
func (*Container) SetBasicACL ¶
func (*Container) SetHomomorphicHashingState ¶
SetHomomorphicHashingState sets homomorphic hashing state for container.
All container's attributes must be unique, otherwise behavior is undefined.
See also HomomorphicHashingState.
func (*Container) SetOwnerID ¶
func (*Container) SetPlacementPolicy ¶
func (c *Container) SetPlacementPolicy(v *netmap.PlacementPolicy)
func (*Container) SetVersion ¶
func (*Container) StableMarshal ¶
func (*Container) StableSize ¶
func (*Container) ToGRPCMessage ¶
func (*Container) UnmarshalJSON ¶
type DeleteRequest ¶
type DeleteRequest struct { session.RequestHeaders // contains filtered or unexported fields }
func (*DeleteRequest) FromGRPCMessage ¶
func (r *DeleteRequest) FromGRPCMessage(m grpc.Message) error
func (*DeleteRequest) GetBody ¶
func (r *DeleteRequest) GetBody() *DeleteRequestBody
func (*DeleteRequest) SetBody ¶
func (r *DeleteRequest) SetBody(v *DeleteRequestBody)
func (*DeleteRequest) ToGRPCMessage ¶
func (r *DeleteRequest) ToGRPCMessage() grpc.Message
type DeleteRequestBody ¶
type DeleteRequestBody struct {
// contains filtered or unexported fields
}
func (*DeleteRequestBody) FromGRPCMessage ¶
func (r *DeleteRequestBody) FromGRPCMessage(m grpc.Message) error
func (*DeleteRequestBody) GetContainerID ¶
func (r *DeleteRequestBody) GetContainerID() *refs.ContainerID
func (*DeleteRequestBody) GetSignature ¶
func (r *DeleteRequestBody) GetSignature() *refs.Signature
func (*DeleteRequestBody) SetContainerID ¶
func (r *DeleteRequestBody) SetContainerID(v *refs.ContainerID)
func (*DeleteRequestBody) SetSignature ¶
func (r *DeleteRequestBody) SetSignature(v *refs.Signature)
func (*DeleteRequestBody) StableMarshal ¶
func (r *DeleteRequestBody) StableMarshal(buf []byte) []byte
func (*DeleteRequestBody) StableSize ¶
func (r *DeleteRequestBody) StableSize() (size int)
func (*DeleteRequestBody) ToGRPCMessage ¶
func (r *DeleteRequestBody) ToGRPCMessage() grpc.Message
func (*DeleteRequestBody) Unmarshal ¶
func (r *DeleteRequestBody) Unmarshal(data []byte) error
type DeleteResponse ¶
type DeleteResponse struct { session.ResponseHeaders // contains filtered or unexported fields }
func (*DeleteResponse) FromGRPCMessage ¶
func (r *DeleteResponse) FromGRPCMessage(m grpc.Message) error
func (*DeleteResponse) GetBody ¶
func (r *DeleteResponse) GetBody() *DeleteResponseBody
func (*DeleteResponse) SetBody ¶
func (r *DeleteResponse) SetBody(v *DeleteResponseBody)
func (*DeleteResponse) ToGRPCMessage ¶
func (r *DeleteResponse) ToGRPCMessage() grpc.Message
type DeleteResponseBody ¶
type DeleteResponseBody struct{}
func (*DeleteResponseBody) FromGRPCMessage ¶
func (r *DeleteResponseBody) FromGRPCMessage(m grpc.Message) error
func (*DeleteResponseBody) StableMarshal ¶
func (r *DeleteResponseBody) StableMarshal(_ []byte) []byte
func (*DeleteResponseBody) StableSize ¶
func (r *DeleteResponseBody) StableSize() (size int)
func (*DeleteResponseBody) ToGRPCMessage ¶
func (r *DeleteResponseBody) ToGRPCMessage() grpc.Message
func (*DeleteResponseBody) Unmarshal ¶
func (r *DeleteResponseBody) Unmarshal([]byte) error
type GetRequest ¶
type GetRequest struct { session.RequestHeaders // contains filtered or unexported fields }
func (*GetRequest) FromGRPCMessage ¶
func (r *GetRequest) FromGRPCMessage(m grpc.Message) error
func (*GetRequest) GetBody ¶
func (r *GetRequest) GetBody() *GetRequestBody
func (*GetRequest) SetBody ¶
func (r *GetRequest) SetBody(v *GetRequestBody)
func (*GetRequest) ToGRPCMessage ¶
func (r *GetRequest) ToGRPCMessage() grpc.Message
type GetRequestBody ¶
type GetRequestBody struct {
// contains filtered or unexported fields
}
func (*GetRequestBody) FromGRPCMessage ¶
func (r *GetRequestBody) FromGRPCMessage(m grpc.Message) error
func (*GetRequestBody) GetContainerID ¶
func (r *GetRequestBody) GetContainerID() *refs.ContainerID
func (*GetRequestBody) SetContainerID ¶
func (r *GetRequestBody) SetContainerID(v *refs.ContainerID)
func (*GetRequestBody) StableMarshal ¶
func (r *GetRequestBody) StableMarshal(buf []byte) []byte
func (*GetRequestBody) StableSize ¶
func (r *GetRequestBody) StableSize() (size int)
func (*GetRequestBody) ToGRPCMessage ¶
func (r *GetRequestBody) ToGRPCMessage() grpc.Message
func (*GetRequestBody) Unmarshal ¶
func (r *GetRequestBody) Unmarshal(data []byte) error
type GetResponse ¶
type GetResponse struct { session.ResponseHeaders // contains filtered or unexported fields }
func (*GetResponse) FromGRPCMessage ¶
func (r *GetResponse) FromGRPCMessage(m grpc.Message) error
func (*GetResponse) GetBody ¶
func (r *GetResponse) GetBody() *GetResponseBody
func (*GetResponse) SetBody ¶
func (r *GetResponse) SetBody(v *GetResponseBody)
func (*GetResponse) ToGRPCMessage ¶
func (r *GetResponse) ToGRPCMessage() grpc.Message
type GetResponseBody ¶
type GetResponseBody struct {
// contains filtered or unexported fields
}
func (*GetResponseBody) FromGRPCMessage ¶
func (r *GetResponseBody) FromGRPCMessage(m grpc.Message) error
func (*GetResponseBody) GetContainer ¶
func (r *GetResponseBody) GetContainer() *Container
func (*GetResponseBody) GetSessionToken ¶
func (r *GetResponseBody) GetSessionToken() *session.Token
GetSessionToken returns token of the session within which requested container was created.
func (*GetResponseBody) GetSignature ¶
func (r *GetResponseBody) GetSignature() *refs.Signature
GetSignature returns signature of the requested container.
func (*GetResponseBody) SetContainer ¶
func (r *GetResponseBody) SetContainer(v *Container)
func (*GetResponseBody) SetSessionToken ¶
func (r *GetResponseBody) SetSessionToken(v *session.Token)
SetSessionToken sets token of the session within which requested container was created.
func (*GetResponseBody) SetSignature ¶
func (r *GetResponseBody) SetSignature(v *refs.Signature)
SetSignature sets signature of the requested container.
func (*GetResponseBody) StableMarshal ¶
func (r *GetResponseBody) StableMarshal(buf []byte) []byte
func (*GetResponseBody) StableSize ¶
func (r *GetResponseBody) StableSize() (size int)
func (*GetResponseBody) ToGRPCMessage ¶
func (r *GetResponseBody) ToGRPCMessage() grpc.Message
func (*GetResponseBody) Unmarshal ¶
func (r *GetResponseBody) Unmarshal(data []byte) error
type ListRequest ¶
type ListRequest struct { session.RequestHeaders // contains filtered or unexported fields }
func (*ListRequest) FromGRPCMessage ¶
func (r *ListRequest) FromGRPCMessage(m grpc.Message) error
func (*ListRequest) GetBody ¶
func (r *ListRequest) GetBody() *ListRequestBody
func (*ListRequest) SetBody ¶
func (r *ListRequest) SetBody(v *ListRequestBody)
func (*ListRequest) ToGRPCMessage ¶
func (r *ListRequest) ToGRPCMessage() grpc.Message
type ListRequestBody ¶
type ListRequestBody struct {
// contains filtered or unexported fields
}
func (*ListRequestBody) FromGRPCMessage ¶
func (r *ListRequestBody) FromGRPCMessage(m grpc.Message) error
func (*ListRequestBody) GetOwnerID ¶
func (r *ListRequestBody) GetOwnerID() *refs.OwnerID
func (*ListRequestBody) SetOwnerID ¶
func (r *ListRequestBody) SetOwnerID(v *refs.OwnerID)
func (*ListRequestBody) StableMarshal ¶
func (r *ListRequestBody) StableMarshal(buf []byte) []byte
func (*ListRequestBody) StableSize ¶
func (r *ListRequestBody) StableSize() (size int)
func (*ListRequestBody) ToGRPCMessage ¶
func (r *ListRequestBody) ToGRPCMessage() grpc.Message
func (*ListRequestBody) Unmarshal ¶
func (r *ListRequestBody) Unmarshal(data []byte) error
type ListResponse ¶
type ListResponse struct { session.ResponseHeaders // contains filtered or unexported fields }
func (*ListResponse) FromGRPCMessage ¶
func (r *ListResponse) FromGRPCMessage(m grpc.Message) error
func (*ListResponse) GetBody ¶
func (r *ListResponse) GetBody() *ListResponseBody
func (*ListResponse) SetBody ¶
func (r *ListResponse) SetBody(v *ListResponseBody)
func (*ListResponse) ToGRPCMessage ¶
func (r *ListResponse) ToGRPCMessage() grpc.Message
type ListResponseBody ¶
type ListResponseBody struct {
// contains filtered or unexported fields
}
func (*ListResponseBody) FromGRPCMessage ¶
func (r *ListResponseBody) FromGRPCMessage(m grpc.Message) error
func (*ListResponseBody) GetContainerIDs ¶
func (r *ListResponseBody) GetContainerIDs() []refs.ContainerID
func (*ListResponseBody) SetContainerIDs ¶
func (r *ListResponseBody) SetContainerIDs(v []refs.ContainerID)
func (*ListResponseBody) StableMarshal ¶
func (r *ListResponseBody) StableMarshal(buf []byte) []byte
func (*ListResponseBody) StableSize ¶
func (r *ListResponseBody) StableSize() (size int)
func (*ListResponseBody) ToGRPCMessage ¶
func (r *ListResponseBody) ToGRPCMessage() grpc.Message
func (*ListResponseBody) Unmarshal ¶
func (r *ListResponseBody) Unmarshal(data []byte) error
type PutRequest ¶
type PutRequest struct { session.RequestHeaders // contains filtered or unexported fields }
func (*PutRequest) FromGRPCMessage ¶
func (r *PutRequest) FromGRPCMessage(m grpc.Message) error
func (*PutRequest) GetBody ¶
func (r *PutRequest) GetBody() *PutRequestBody
func (*PutRequest) SetBody ¶
func (r *PutRequest) SetBody(v *PutRequestBody)
func (*PutRequest) ToGRPCMessage ¶
func (r *PutRequest) ToGRPCMessage() grpc.Message
type PutRequestBody ¶
type PutRequestBody struct {
// contains filtered or unexported fields
}
func (*PutRequestBody) FromGRPCMessage ¶
func (r *PutRequestBody) FromGRPCMessage(m grpc.Message) error
func (*PutRequestBody) GetContainer ¶
func (r *PutRequestBody) GetContainer() *Container
func (*PutRequestBody) GetSignature ¶
func (r *PutRequestBody) GetSignature() *refs.Signature
func (*PutRequestBody) SetContainer ¶
func (r *PutRequestBody) SetContainer(v *Container)
func (*PutRequestBody) SetSignature ¶
func (r *PutRequestBody) SetSignature(v *refs.Signature)
func (*PutRequestBody) StableMarshal ¶
func (r *PutRequestBody) StableMarshal(buf []byte) []byte
func (*PutRequestBody) StableSize ¶
func (r *PutRequestBody) StableSize() (size int)
func (*PutRequestBody) ToGRPCMessage ¶
func (r *PutRequestBody) ToGRPCMessage() grpc.Message
func (*PutRequestBody) Unmarshal ¶
func (r *PutRequestBody) Unmarshal(data []byte) error
type PutResponse ¶
type PutResponse struct { session.ResponseHeaders // contains filtered or unexported fields }
func (*PutResponse) FromGRPCMessage ¶
func (r *PutResponse) FromGRPCMessage(m grpc.Message) error
func (*PutResponse) GetBody ¶
func (r *PutResponse) GetBody() *PutResponseBody
func (*PutResponse) SetBody ¶
func (r *PutResponse) SetBody(v *PutResponseBody)
func (*PutResponse) ToGRPCMessage ¶
func (r *PutResponse) ToGRPCMessage() grpc.Message
type PutResponseBody ¶
type PutResponseBody struct {
// contains filtered or unexported fields
}
func (*PutResponseBody) FromGRPCMessage ¶
func (r *PutResponseBody) FromGRPCMessage(m grpc.Message) error
func (*PutResponseBody) GetContainerID ¶
func (r *PutResponseBody) GetContainerID() *refs.ContainerID
func (*PutResponseBody) SetContainerID ¶
func (r *PutResponseBody) SetContainerID(v *refs.ContainerID)
func (*PutResponseBody) StableMarshal ¶
func (r *PutResponseBody) StableMarshal(buf []byte) []byte
func (*PutResponseBody) StableSize ¶
func (r *PutResponseBody) StableSize() (size int)
func (*PutResponseBody) ToGRPCMessage ¶
func (r *PutResponseBody) ToGRPCMessage() grpc.Message
func (*PutResponseBody) Unmarshal ¶
func (r *PutResponseBody) Unmarshal(data []byte) error