Documentation ¶
Index ¶
- Constants
- Variables
- func Attach(url string)
- func AttachAdmin(url string)
- func HttpGet(url string) (string, error)
- func HttpGetJson(url string) (map[string]interface{}, error)
- func ParsePicasaTime(timestamp string) int64
- func UrlJoin(strs ...string) string
- type GalleryConfig
- type GalleryPanel
- type Image
- type M
- type PicasaAPI
- type PicasaAlbum
- type PicasaPhoto
- func (p *PicasaPhoto) Collection() string
- func (p *PicasaPhoto) Disable()
- func (p *PicasaPhoto) Enable()
- func (p *PicasaPhoto) FullSize() string
- func (p *PicasaPhoto) Indexes() [][]string
- func (p *PicasaPhoto) MediumThumbnail() Image
- func (p *PicasaPhoto) PreSave()
- func (p *PicasaPhoto) Unique() bson.M
- type WaitGroupErr
Constants ¶
View Source
const (
PicasaAPIBase = "https://picasaweb.google.com/data/feed/api/"
)
Variables ¶
Functions ¶
func AttachAdmin ¶
func AttachAdmin(url string)
func HttpGetJson ¶
Given a URL, fetch it and return a string map of the data
func ParsePicasaTime ¶
Taken a timestamp in the picasa format, which seems like the standard iso format time, return a int64 timestamp, ex:
2009-04-27T07:18:46.000Z ->
Types ¶
type GalleryConfig ¶
type GalleryConfig struct { Id bson.ObjectId `bson:"_id,omitempty"` Type string UserId string LastRun int64 }
func LoadGalleryConfig ¶
func LoadGalleryConfig() *GalleryConfig
func (*GalleryConfig) Check ¶
func (g *GalleryConfig) Check() error
func (*GalleryConfig) Collection ¶
func (g *GalleryConfig) Collection() string
func (*GalleryConfig) Indexes ¶
func (g *GalleryConfig) Indexes() [][]string
func (*GalleryConfig) Save ¶
func (g *GalleryConfig) Save()
func (*GalleryConfig) SourceLink ¶
func (g *GalleryConfig) SourceLink() string
func (*GalleryConfig) String ¶
func (g *GalleryConfig) String() string
type GalleryPanel ¶
type GalleryPanel struct{}
func (*GalleryPanel) Render ¶
func (gp *GalleryPanel) Render() string
type PicasaAPI ¶
type PicasaAPI struct {
UserId string
}
func NewPicasaAPI ¶
func (*PicasaAPI) ListAlbums ¶
func (p *PicasaAPI) ListAlbums() ([]*PicasaAlbum, error)
func (*PicasaAPI) ListPhotos ¶
func (p *PicasaAPI) ListPhotos(album *PicasaAlbum) ([]*PicasaPhoto, error)
func (*PicasaAPI) UpdateAlbums ¶
Update all picasa album info
func (*PicasaAPI) UpdatePhotos ¶
func (p *PicasaAPI) UpdatePhotos(album *PicasaAlbum) error
type PicasaAlbum ¶
type PicasaAlbum struct { Id bson.ObjectId `bson:"_id,omitempty"` ApiUrl string // id AlbumId string //gphoto$id Published string PublishedTimestamp int64 Updated string UpdatedTimestamp int64 Title string Slug string Summary string Rights string //gphoto$access Links []string AlbumType string // gphoto$albumType Thumbnail string // media$thumbnail NumPhotos int Enabled bool `bson:",omitempty"` }
func ByAlbumId ¶
func ByAlbumId(id string) (*PicasaAlbum, error)
func (*PicasaAlbum) AlbumLink ¶
func (a *PicasaAlbum) AlbumLink() string
func (*PicasaAlbum) Collection ¶
func (a *PicasaAlbum) Collection() string
func (*PicasaAlbum) Disable ¶
func (a *PicasaAlbum) Disable()
func (*PicasaAlbum) Enable ¶
func (a *PicasaAlbum) Enable()
func (*PicasaAlbum) Indexes ¶
func (a *PicasaAlbum) Indexes() [][]string
func (*PicasaAlbum) PreSave ¶
func (a *PicasaAlbum) PreSave()
func (*PicasaAlbum) String ¶
func (p *PicasaAlbum) String() string
func (*PicasaAlbum) Unique ¶
func (a *PicasaAlbum) Unique() bson.M
type PicasaPhoto ¶
type PicasaPhoto struct { Id bson.ObjectId `bson:"_id,omitempty"` ApiUrl string // id AlbumId string //gphoto$albumid PhotoId string // gphoto$id Published string PublishedTimestamp int64 Updated string UpdatedTimestamp int64 Title string Slug string Summary string Rights string //gphoto$access Links []string Size int Height int Width int ExifTags map[string]string Position int Large Image Thumbnails []Image Enabled bool `bson:",omitempty"` }
func (*PicasaPhoto) Collection ¶
func (p *PicasaPhoto) Collection() string
func (*PicasaPhoto) Disable ¶
func (p *PicasaPhoto) Disable()
func (*PicasaPhoto) Enable ¶
func (p *PicasaPhoto) Enable()
func (*PicasaPhoto) FullSize ¶
func (p *PicasaPhoto) FullSize() string
func (*PicasaPhoto) Indexes ¶
func (p *PicasaPhoto) Indexes() [][]string
func (*PicasaPhoto) MediumThumbnail ¶
func (p *PicasaPhoto) MediumThumbnail() Image
func (*PicasaPhoto) PreSave ¶
func (p *PicasaPhoto) PreSave()
func (*PicasaPhoto) Unique ¶
func (p *PicasaPhoto) Unique() bson.M
type WaitGroupErr ¶
func (*WaitGroupErr) Error ¶
func (w *WaitGroupErr) Error(err error)
func (*WaitGroupErr) GetError ¶
func (w *WaitGroupErr) GetError() error
Click to show internal directories.
Click to hide internal directories.