Versions in this module Expand all Collapse all v1 v1.0.3 Nov 18, 2023 v1.0.2 Nov 18, 2023 Changes in this version + const MinSDK + const NoEntry + const SortedFlag + const UTF8Flag + func PackResources() ([]byte, error) + type Attribute struct + NS PoolRef + Name PoolRef + RawValue PoolRef + TypedValue Data + func (attr *Attribute) MarshalBinary() ([]byte, error) + func (attr *Attribute) UnmarshalBinary(bin []byte) error + type CharData struct + RawData PoolRef + TypedData Data + func (cdt *CharData) MarshalBinary() ([]byte, error) + func (cdt *CharData) UnmarshalBinary(bin []byte) error + type Data struct + ByteSize uint16 + Res0 uint8 + Type DataType + Value uint32 + func (d *Data) MarshalBinary() ([]byte, error) + func (d *Data) UnmarshalBinary(bin []byte) error + type DataType uint8 + const DataAttribute + const DataDimension + const DataDynamicReference + const DataFloat + const DataFraction + const DataIntBool + const DataIntColorARGB4 + const DataIntColorARGB8 + const DataIntColorRGB4 + const DataIntColorRGB8 + const DataIntDec + const DataIntHex + const DataNull + const DataReference + const DataString + func (i DataType) String() string + type Element struct + AttributeCount uint16 + AttributeSize uint16 + AttributeStart uint16 + Children []*Element + ClassIndex uint16 + IDIndex uint16 + NS PoolRef + Name PoolRef + StyleIndex uint16 + func (el *Element) MarshalBinary() ([]byte, error) + func (el *Element) UnmarshalBinary(buf []byte) error + type ElementEnd struct + NS PoolRef + Name PoolRef + func (el *ElementEnd) MarshalBinary() ([]byte, error) + func (el *ElementEnd) UnmarshalBinary(bin []byte) error + type Entry struct + func (nt *Entry) MarshalBinary() ([]byte, error) + func (nt *Entry) UnmarshalBinary(bin []byte) error + type Map struct + func (m *Map) MarshalBinary() ([]byte, error) + func (m *Map) UnmarshalBinary(bin []byte) error + type Namespace struct + func (ns *Namespace) MarshalBinary() ([]byte, error) + func (ns *Namespace) UnmarshalBinary(bin []byte) error + type NodeHeader struct + Comment PoolRef + LineNumber uint32 + func (hdr *NodeHeader) MarshalBinary() ([]byte, error) + func (hdr *NodeHeader) UnmarshalBinary(bin []byte) error + type Package struct + func (pkg *Package) MarshalBinary() ([]byte, error) + func (pkg *Package) UnmarshalBinary(bin []byte) error + type Pool struct + func (pl *Pool) IsSorted() bool + func (pl *Pool) IsUTF8() bool + func (pl *Pool) MarshalBinary() ([]byte, error) + func (pl *Pool) RefByName(s string) (PoolRef, error) + func (pl *Pool) UnmarshalBinary(bin []byte) error + type PoolRef uint32 + func (ref PoolRef) Resolve(pl *Pool) string + type ResType uint16 + const ResNull + const ResStringPool + const ResTable + const ResTableLibrary + const ResTablePackage + const ResTableType + const ResTableTypeSpec + const ResXML + const ResXMLCharData + const ResXMLEndElement + const ResXMLEndNamespace + const ResXMLResourceMap + const ResXMLStartElement + const ResXMLStartNamespace + func (i ResType) String() string + func (t ResType) IsSupported() bool + type Span struct + func (spn *Span) UnmarshalBinary(bin []byte) error + type Table struct + func NewMipmapTable(pkgname string) (*Table, string) + func OpenSDKTable() (*Table, error) + func OpenTable() (*Table, error) + func (tbl *Table) MarshalBinary() ([]byte, error) + func (tbl *Table) RefByName(name string) (TableRef, error) + func (tbl *Table) SpecByName(name string) (int, *Package, int, *TypeSpec, error) + func (tbl *Table) UnmarshalBinary(bin []byte) error + type TableRef uint32 + func (ref TableRef) Resolve(tbl *Table) (*Entry, error) + type Type struct + func (typ *Type) MarshalBinary() ([]byte, error) + func (typ *Type) UnmarshalBinary(bin []byte) error + type TypeSpec struct + func (spec *TypeSpec) MarshalBinary() ([]byte, error) + func (spec *TypeSpec) UnmarshalBinary(bin []byte) error + type Value struct + func (val *Value) MarshalBinary() ([]byte, error) + func (val *Value) UnmarshalBinary(bin []byte) error + type XML struct + Children []*Element + Map *Map + Namespace *Namespace + Pool *Pool + func UnmarshalXML(r io.Reader, withIcon bool, targetSDK int) (*XML, error) + func (bx *XML) MarshalBinary() ([]byte, error) + func (bx *XML) RawValueByName(elname string, attrname xml.Name) (string, error) + func (bx *XML) UnmarshalBinary(buf []byte) error