Namespace: go.std.encoding.ascii85
v1.0Contents
Summary
Provides a low-level interface to the encoding/ascii85 package.
Package ascii85 implements the ascii85 data encoding
as used in the btoa tool and Adobe's PostScript and PDF document formats.
Index
- *CorruptInputError
- CorruptInputError
- Decode
- Encode
- MaxEncodedLen
- NewDecoder
- NewEncoder
- arrayOfCorruptInputError
Legend
-
Constant
Variable
Function
Macro
Special form
Type
GoVar
Receiver/Method
Constants
Constants are variables with :const true in their metadata. Joker currently does not recognize them as special; as such, it allows redefining them or their values.-
(None.)
Variables
-
(None.)
Functions, Macros, and Special Forms
-
Decode
Function v1.0(Decode dst src flush)
Decode decodes src into dst, returning both the number
of bytes written to dst and the number consumed from src.
If src contains invalid ascii85 data, Decode will return the
number of bytes successfully written and a CorruptInputError.
Decode ignores space and control characters in src.
Often, ascii85-encoded data is wrapped in <~ and ~> symbols.
Decode expects these to have been stripped by the caller.
If flush is true, Decode assumes that src represents the
end of the input stream and processes it completely rather
than wait for the completion of another 32-bit block.
NewDecoder wraps an io.Reader interface around Decode.
Go input arguments: (dst []byte, src []byte, flush bool)
Go returns: (ndst int, nsrc int, err error)
Joker input arguments: [^arrayOfByte dst, ^arrayOfByte src, ^Boolean flush]
Joker returns: [^Int ndst, ^Int nsrc, ^Error err] -
Encode
Function v1.0(Encode dst src)
Encode encodes src into at most MaxEncodedLen(len(src))
bytes of dst, returning the actual number of bytes written.
The encoding handles 4-byte chunks, using a special encoding
for the last fragment, so Encode is not appropriate for use on
individual blocks of a large data stream. Use NewEncoder() instead.
Often, ascii85-encoded data is wrapped in <~ and ~> symbols.
Encode does not add these.
Go input arguments: (dst []byte, src []byte)
Go returns: int
Joker input arguments: [^arrayOfByte dst, ^arrayOfByte src]
Joker returns: ^Int -
MaxEncodedLen
Function v1.0(MaxEncodedLen n)
MaxEncodedLen returns the maximum length of an encoding of n source bytes.
Go input arguments: (n int)
Go returns: int
Joker input arguments: [^Int n]
Joker returns: ^Int -
NewDecoder
Function v1.0(NewDecoder r)
NewDecoder constructs a new ascii85 stream decoder.
Go input arguments: (r io.Reader)
Go returns: io.Reader
Joker input arguments: [^go.std.io/Reader r]
Joker returns: ^go.std.io/Reader -
NewEncoder
Function v1.0(NewEncoder w)
NewEncoder returns a new ascii85 stream encoder. Data written to
the returned writer will be encoded and then written to w.
Ascii85 encodings operate in 32-bit blocks; when finished
writing, the caller must Close the returned encoder to flush any
trailing partial block.
Go input arguments: (w io.Writer)
Go returns: io.WriteCloser
Joker input arguments: [^go.std.io/Writer w]
Joker returns: ^go.std.io/WriteCloser
Types
-
*CorruptInputError
Concrete Type v1.0 -
CorruptInputError
Concrete Type v1.0 -
Error
Receiver for CorruptInputError v1.0([])
-
arrayOfCorruptInputError
Concrete Type v1.0