Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewDesiredSubImageLargerThanMasterErr ¶
func NewDesiredSubImageLargerThanMasterErr() error
Types ¶
type Collection ¶
type CollectionName ¶
type CollectionName string
type Image ¶
type Image interface { GetFormat() imageformat.Format GetSize() uint64 GetResolution() resolution.Resolution GetPhoto() Photo GetData() (io.ReadCloser, error) SetData(io.Reader) error }
type Photo ¶
type Photo interface { GetHash() PhotoHash GetDescription() (string, error) SetDescription(string) error GetTimeTaken() (time.Time, error) SetTimeTaken(time.Time) error GetImages() ([]Image, error) GetImageByResolutionID(resolution.ResolutionID) (Image, error) //****** I am not sure I like this. Would rather have a "NewPhoto func that generated internally *********" //Can only be set once if trying to overwrite should fail SetOriginalImage(fmt imageformat.Format, size uint64, height, width uint64, data io.Reader) (Image, error) //Can only be set once if trying to overwrite should fail SetMasterImage(fmt imageformat.Format, size uint64, height, width uint64, data io.Reader) (Image, error) //Should check to see if we have an image of that resolution first //Commenting out as I think that we shouldn't have so setable fields // NewImage(fmt imageformat.Format, size uint64, height, width uint64, data io.Reader) (Image, error) CreateSubImage(resolution.Resolution) error RemoveImage(resolution.ResolutionID) error }
Click to show internal directories.
Click to hide internal directories.