Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterEmbosser ¶
func RegisterEmbosser(ctx context.Context, scheme string, init_func EmbosserInitializationFunc) error
RegisterEmbosser registers 'scheme' as a key pointing to 'init_func' in an internal lookup table used to create new `Embosser` instances by the `NewEmbosser` method.
Types ¶
type Embosser ¶
type Embosser interface { EmbossImage(context.Context, string, bool) ([]image.Image, error) EmbossImageWithReader(context.Context, io.Reader, string, bool) ([]image.Image, error) Close(context.Context) error }
func NewEmbosser ¶
NewEmbosser returns a new `Embosser` instance configured by 'uri'. The value of 'uri' is parsed as a `url.URL` and its scheme is used as the key for a corresponding `EmbosserInitializationFunc` function used to instantiate the new `Embosser`. It is assumed that the scheme (and initialization function) have been registered by the `RegisterEmbosser` method.
type EmbosserInitializationFunc ¶
EmbosserInitializationFunc is a function defined by individual embosser package and used to create an instance of that embosser
type GrpcEmbosser ¶
type GrpcEmbosser struct {
// contains filtered or unexported fields
}