> My question is regarding PER encoding of PrintableString .
> In case of PrintableString whether we have to encode the ASCII value of
> the PrintableString itself OR we have to store the PrintableString in a
> table( which is canonically ordered) and then we have encode the index
> of that character?
Is the PrintableString contained by permitted alphabet, for instance,
PrintableString (FROM ("AB")) ?
If it is not so constrained, you would simply use 7 bits per character;
if it is so constrained, and the constraint allows for a tighter encoding,
you would encode the index.
By way of example, the string "ABABAA" would encode as
06830A0C283040 (last 6 are padding bits) if not constrained, but as
0650 (last 2 are padding bits) if constrained FROM ("AB").
That is,
in the first case, the binary encoding for A is 1000001 while B is 1000010;
in the 2nd case, the binary encoding for A is 0 while B is 1.
=====================================================================
Conrad Sigona Toll Free : 1-888-OSS-ASN1
OSS Nokalva Voice Mail : 1-732-302-9669 x400
[EMAIL PROTECTED] Fax : 1-419-831-5035
http://www.oss.com My direct line : 1-315-845-1773