Documentation ¶
Index ¶
- func DefaultImage() string
- func FromBuffer(buf bytes.Buffer) string
- func FromLocal(fname string) (string, error)
- func FromRemote(url string) string
- func New(ctx activity.InitContext) (activity.Activity, error)
- func NewImage(url string) string
- func SetDefaultImage(img string)
- func ToBuffer(buf bytes.Buffer) []byte
- func ToLocal(buf bytes.Buffer, fname string) error
- type Activity
- type Input
- type Output
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FromBuffer ¶
FromBuffer accepts a buffer and returns a base64 encoded string.
func FromLocal ¶
FromLocal reads a local file and returns the base64 encoded version.
func FromRemote ¶
FromRemote is a better named function that presently calls NewImage which will be deprecated. Function accepts an RFC compliant URL and returns a base64 encoded result.
func New ¶
func New(ctx activity.InitContext) (activity.Activity, error)
New optional factory method, should be used if one activity instance per configuration is desired
func NewImage ¶
DEPRECATED Begin a NewImage to fetch TODO: Deprecate NewImage
func ToBuffer ¶
ToBuffer accepts a base64 encoded string
and returns a file buffer can save to image file.
Types ¶
type Activity ¶
type Activity struct { }
Activity is an sample Activity that can be used as a base to create a custom activity
func (*Activity) Eval ¶
Eval implements api.Activity.Eval - Logs the Message
Click to show internal directories.
Click to hide internal directories.