Documentation ¶
Overview ¶
Package baseEmoji implements baseEmoji encoding as specified by absolutely nobody.
baseEmoji is similar to base64 only it uses emoji to encode a given set of data instead of the more common a-zA-Z0-9+/= character set.
You probably shouldn't use this in any kind of serious production environment.
Index ¶
Constants ¶
This section is empty.
Variables ¶
var Utf8Header []byte = []byte{0xEF, 0xBB, 0xBF}
UTF8Header is the UTF-8 byte order mark. This needs to be prepended to text files in order for viewers (browsers, text editors, etc) to display the UTF-8 encoded characters correctly.
Functions ¶
This section is empty.
Types ¶
type EmojiString ¶
type EmojiString []Emoji
func (EmojiString) String ¶
func (es EmojiString) String() string
func (*EmojiString) ToBytes ¶
func (es *EmojiString) ToBytes() []byte
ToByte returns the EmojiString as a byte slice. This does not prepend the UTF-8 BOM.
func (*EmojiString) WriteFile ¶
func (es *EmojiString) WriteFile(filename string) error
WriteFile writes the emoji string to the given filename. This prepends the UTF-8 BOM automatically.
type Encoding ¶
type Encoding struct {
// contains filtered or unexported fields
}
var DefaultEncoding *Encoding
func NewEncode ¶
func NewEncode(emString EmojiString) (*Encoding, error)
NewEncode returns a new Encoding given the EmojiString provided. An error is returned if there are not 65 characters in the EmojiString. The last character is the padding character.