isobmff-builder-0.11.3.0: A (bytestring-) builder for the ISO-14496-12 base media file format

Safe HaskellNone
LanguageHaskell2010

Data.Type.BitRecords.Sized

Description

Size Fields

Synopsis

Documentation

data Sized sf r :: IsA BitRecord Source #

A record with a size member, and a nested record that can be counted using SizeFieldValue.

Instances

type Eval BitRecord (Sized rt len t1 sf r) Source # 
type Eval BitRecord (Sized rt len t1 sf r) = (.+:) rt * Nat len t1 ((:=) rt len Nat t1 ((@:) rt * Nat len t1 "size" sf) (SizeFieldValue BitRecord r)) r

type Sized8 t = Sized FieldU8 t Source #

A convenient alias for a Sized with an FieldU8 size field.

type Sized16 t = Sized FieldU16 t Source #

A convenient alias for a Sized with an FieldU16 size field.

type Sized32 t = Sized FieldU32 t Source #

A convenient alias for a Sized with an FieldU32 size field.

type Sized64 t = Sized FieldU64 t Source #

A convenient alias for a Sized with an FieldU64 size field.

data SizedField sf r :: IsA BitRecord Source #

A record with a size member, and a nested field that can be counted using SizeFieldValue.

Instances

type Eval BitRecord (SizedField rt k st len t2 rt1 len1 t1 sf r) Source # 
type Eval BitRecord (SizedField rt k st len t2 rt1 len1 t1 sf r) = (.+.) rt k st len t2 rt1 * Nat len1 t1 ((:=) rt1 len1 Nat t1 ((@:) rt1 * Nat len1 t1 "size" sf) (SizeFieldValue (IsA Type (BitRecordField rt k st len t2)) r)) r

type SizedField8 t = SizedField FieldU8 t Source #

A convenient alias for a SizedField with an FieldU8 size field.

type SizedField16 t = SizedField FieldU16 t Source #

A convenient alias for a SizedField with an FieldU16 size field.

type SizedField32 t = SizedField FieldU32 t Source #

A convenient alias for a SizedField with an FieldU32 size field.

type SizedField64 t = SizedField FieldU64 t Source #

A convenient alias for a SizedField with an FieldU64 size field.

type family SizeFieldValue (c :: k) :: Nat Source #

For something to be augmented by a size field there must be an instance of this family to generate the value of the size field, e.g. by counting the elements.

Instances

type SizeFieldValue BitRecord b Source # 
type SizeFieldValue (A Type (BitRecordField rt k st size t) -> Type) (MkField rt k st size t) Source # 
type SizeFieldValue (A Type (BitRecordField rt k st size t) -> Type) (MkField rt k st size t) = size
type SizeFieldValue (A Type (BitRecordField rt * k size t) -> Type) ((:=) rt size k t f v) Source # 
type SizeFieldValue (A Type (BitRecordField rt * k size t) -> Type) ((:=) rt size k t f v) = SizeFieldValue k v
type SizeFieldValue (A Type (BitRecordField rt k st len t) -> Type) (LabelF rt k st len t l f) Source # 
type SizeFieldValue (A Type (BitRecordField rt k st len t) -> Type) (LabelF rt k st len t l f) = SizeFieldValue (IsA Type (BitRecordField rt k st len t)) f