Documentation
¶
Index ¶
- Constants
- func AddMediaFileSpecConfig(opts flagsets.ConfigOptions, config flagsets.Config) error
- func AddPathSpecConfig(opts flagsets.ConfigOptions, config flagsets.Config) error
- func AddProcessSpecConfig(opts flagsets.ConfigOptions, config flagsets.Config) error
- func AddProcessSpecOptionTypes(set flagsets.ConfigOptionTypeSetHandler)
- func NewMediaFileSpecOptionType(name string, adder flagsets.ConfigAdder, types ...flagsets.ConfigOptionType) flagsets.ConfigOptionTypeSetHandler
- type MediaFileSpec
- type PathSpec
- type ProcessSpec
Constants ¶
View Source
const ProcessSpecUsage = ` - **<code>mediaType</code>** *string* This OPTIONAL property describes the media type to store with the local blob. The default media type is ` + mime.MIME_OCTET + ` and ` + mime.MIME_GZIP + ` if compression is enabled. - **<code>compress</code>** *bool* This OPTIONAL property describes whether the content should be stored compressed or not. `
Variables ¶
This section is empty.
Functions ¶
func AddMediaFileSpecConfig ¶
func AddMediaFileSpecConfig(opts flagsets.ConfigOptions, config flagsets.Config) error
func AddPathSpecConfig ¶
func AddPathSpecConfig(opts flagsets.ConfigOptions, config flagsets.Config) error
func AddProcessSpecConfig ¶
func AddProcessSpecConfig(opts flagsets.ConfigOptions, config flagsets.Config) error
func AddProcessSpecOptionTypes ¶
func AddProcessSpecOptionTypes(set flagsets.ConfigOptionTypeSetHandler)
func NewMediaFileSpecOptionType ¶
func NewMediaFileSpecOptionType(name string, adder flagsets.ConfigAdder, types ...flagsets.ConfigOptionType) flagsets.ConfigOptionTypeSetHandler
Types ¶
type MediaFileSpec ¶
type MediaFileSpec struct { // PathSpec holds the path that points to a file to be the base for the imput PathSpec `json:",inline"` ProcessSpec `json:",inline"` }
func NewMediaFileSpec ¶
func NewMediaFileSpec(typ, path, mediatype string, compress bool) MediaFileSpec
type PathSpec ¶
type PathSpec struct { inputs.InputSpecBase `json:",inline"` // Path is a file or repository path Path string `json:"path"` }
func NewPathSpec ¶
type ProcessSpec ¶
type ProcessSpec struct { MediaType string `json:"mediaType,omitempty"` CompressWithGzip *bool `json:"compress,omitempty"` }
func NewProcessSpec ¶
func NewProcessSpec(mediatype string, compress bool) ProcessSpec
func (*ProcessSpec) Compress ¶
func (s *ProcessSpec) Compress() bool
Compress returns if the blob should be compressed using gzip.
func (*ProcessSpec) ProcessBlob ¶
func (s *ProcessSpec) ProcessBlob(ctx inputs.Context, acc accessio.DataAccess, fs vfs.FileSystem) (accessio.TemporaryBlobAccess, string, error)
func (*ProcessSpec) SetMediaTypeIfNotDefined ¶
func (s *ProcessSpec) SetMediaTypeIfNotDefined(mediaType string)
SetMediaTypeIfNotDefined sets the media type of the input blob if its not defined.
Click to show internal directories.
Click to hide internal directories.