Documentation ¶
Index ¶
- type Address
- func (a *Address) ContainerID() *cid.ID
- func (a *Address) Marshal() ([]byte, error)
- func (a *Address) MarshalJSON() ([]byte, error)
- func (a *Address) ObjectID() *oid.ID
- func (a *Address) Parse(s string) error
- func (a *Address) SetContainerID(id *cid.ID)
- func (a *Address) SetObjectID(id *oid.ID)
- func (a *Address) String() string
- func (a *Address) ToV2() *refs.Address
- func (a *Address) Unmarshal(data []byte) error
- func (a *Address) UnmarshalJSON(data []byte) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Address ¶
Address represents v2-compatible object address.
func NewAddress ¶
func NewAddress() *Address
NewAddress creates and initializes blank Address.
Works similar as NewAddressFromV2(new(Address)).
Defaults:
- cid: nil;
- oid: nil.
func NewAddressFromV2 ¶
NewAddressFromV2 converts v2 Address message to Address.
Nil refs.Address converts to nil.
func (*Address) ContainerID ¶
ContainerID returns container identifier.
func (*Address) MarshalJSON ¶
MarshalJSON encodes Address to protobuf JSON format.
func (*Address) SetContainerID ¶
SetContainerID sets container identifier.
func (*Address) SetObjectID ¶
SetObjectID sets object identifier.
func (*Address) UnmarshalJSON ¶
UnmarshalJSON decodes Address from protobuf JSON format.
Click to show internal directories.
Click to hide internal directories.