Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type UploadApplication ¶
type UploadApplication struct {
application.Application
}
UploadApplication implements the application.Application interface as a commandline application for uploading photos using the Flickr API
func (*UploadApplication) DefaultFlagSet ¶
func (app *UploadApplication) DefaultFlagSet() *flag.FlagSet
Return the default FlagSet necessary for the UploadApplication to run.
func (*UploadApplication) Run ¶
func (app *UploadApplication) Run(ctx context.Context) (interface{}, error)
Invoke the UploadApplication with its default FlagSet.
func (*UploadApplication) RunWithFlagSet ¶
func (app *UploadApplication) RunWithFlagSet(ctx context.Context, fs *flag.FlagSet) (interface{}, error)
Invoke the UploadApplication with a custom FlagSet.
type UploadError ¶
type UploadError struct {
// contains filtered or unexported fields
}
UploadError is a custom error type that can be JSON-serialized.
func (*UploadError) Error ¶
func (e *UploadError) Error() string
The error message associated with this instance.
func (*UploadError) MarshalJSON ¶
func (e *UploadError) MarshalJSON() ([]byte, error)
This error instance serialized as a string for JSON-marshaling.
func (*UploadError) String ¶
func (e *UploadError) String() string
The error message associated with this instance.
type UploadResult ¶
type UploadResult struct { // The URI of file that was uploaded. Path string `json:"path,omitempty"` // The Photo ID of a successfully uploaded file. PhotoId int64 `json:"photoid,omitempty"` // An UploadError instance if the file was not able to be uploaded. Error *UploadError `json:"error,omitempty"` }
UploadResult is struct containing information about an atomic upload.
Click to show internal directories.
Click to hide internal directories.