[erlang-questions] custom type specifier

Costin-Tiberiu RADU costin.tiberiu.radu@REDACTED
Mon May 11 15:54:58 CEST 2009


Good afternoon everybody,

I have the following question that bugs me. 
AS of R13 we have unicode as a type specifier so we can have in a binary
something like :
<<Value:Size/TypeSpecifierList ,...,ValueN:SizeN/TypeSpecifierList>>
Where 
Type= integer | float | binary | bytes | bitstring | bits | utf8 | utf16
| utf32

Where can I find some indications on how to define a type specifier so
in my module I can have some new types like:

<<Value:Size/huffman,..>>
or
<<Value:Size/fibonacci,..>>
or
<<Value:Size/base64,...>>
or any custom encoding method for that matter.

My question may seem (and probably is) pretty trivial, but I am new in
writting code with erlang and some things are not pretty easy to find if
you do not know where to look.
I have looked into unicode.erl (in R13B source code) but haven't seen
anything relevant to answer my question.

Best regards and many thanks

-- 
Costin-Tiberiu RADU <costin.tiberiu.radu@REDACTED>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20090511/74942d8f/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 197 bytes
Desc: Aceast fragment din mesaj este semnat digital
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20090511/74942d8f/attachment.bin>


More information about the erlang-questions mailing list