Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func PathForKey ¶
func PathForKey(raw string) paths.Unencrypted
PathForKey removes the trailing `/` from the raw path, which is required so the derived key matches the final list path (which also has the trailing encrypted `/` part of the path removed).
func TypedDecryptStreamInfo ¶
func TypedDecryptStreamInfo(ctx context.Context, streamMetaBytes []byte, path Path, encStore *encryption.Store) ( _ *pb.StreamInfo, streamMeta pb.StreamMeta, err error)
TypedDecryptStreamInfo decrypts stream info.
Types ¶
type EOFReader ¶
type EOFReader struct {
// contains filtered or unexported fields
}
EOFReader holds reader and status of EOF.
func NewEOFReader ¶
NewEOFReader keeps track of the state, has the internal reader reached EOF.
type Path ¶
type Path struct {
// contains filtered or unexported fields
}
Path is a representation of an object path within a bucket.
func CreatePath ¶
func CreatePath(bucket string, unencPath paths.Unencrypted) (path Path)
CreatePath will create a Path for the provided information.
func (Path) UnencryptedPath ¶
func (p Path) UnencryptedPath() paths.Unencrypted
UnencryptedPath returns the unencrypted path part of the path.
type PeekThresholdReader ¶ added in v1.0.6
type PeekThresholdReader struct {
// contains filtered or unexported fields
}
PeekThresholdReader allows a check to see if the size of a given reader exceeds the maximum inline segment size or not.
func NewPeekThresholdReader ¶ added in v1.0.6
func NewPeekThresholdReader(r io.Reader) (pt *PeekThresholdReader)
NewPeekThresholdReader creates a new instance of PeekThresholdReader.
func (*PeekThresholdReader) IsLargerThan ¶ added in v1.0.6
func (pt *PeekThresholdReader) IsLargerThan(thresholdSize int) (bool, error)
IsLargerThan returns a bool to determine whether a reader's size is larger than the given threshold or not.
type Store ¶
type Store interface { Get(ctx context.Context, path storj.Path, object storj.Object) (ranger.Ranger, error) Put(ctx context.Context, path storj.Path, data io.Reader, metadata Metadata, expiration time.Time) (Meta, error) Delete(ctx context.Context, path storj.Path) (storj.ObjectInfo, error) }
Store interface methods for streams to satisfy to be a store.