Home | History | Annotate | Download | only in base64

Lines Matching refs:Encoder

40 func NewEncoding(encoder string) *Encoding {
41 if len(encoder) != 64 {
47 copy(e.encode[:], encoder)
52 for i := 0; i < len(encoder); i++ {
53 e.decodeMap[encoder[i]] = byte(i)
84 * Encoder
147 type encoder struct {
156 func (e *encoder) Write(p []byte) (n int, err error) {
204 // Close flushes any pending output from the encoder.
206 func (e *encoder) Close() error {
216 // NewEncoder returns a new base64 stream encoder. Data written to
219 // writing, the caller must Close the returned encoder to flush any
222 return &encoder{enc: enc, w: w}