immutable class TOKEN < $IS_EQ, $STR, $BINARY, $HASH, $NIL
****

________This_class_provides_tokens_for_use_in_determining_collating_order
___of_strings.___It_provides_a_numeric_identifier_for_all_of_the_names_which
___appear_in_the_source_form_of_repertoire_maps_and_locale_files.__It_is
___congruent_to_the_CARD_class_-_but_with_only_equality_testing,_creation
___and_string_representation_actions_available!.
___NOTE_A_token_must_have_an_encoding_with_one_or_more_bits_set.__Void_is
________NOT_a_valid_token.


Ancestors
$NIL $IS_NIL $HASH $IS_EQ
$BINARY $STR



Public


Constants
const Num_Bits : CARD := asize ; .. Included as Num_Bits

Features
aget( .. Included as aget
aset( .. Included as aset
binstr(octet_cnt : CARD) : BINSTR .. Included as binstr
binstr : BINSTR .. Included as binstr
build(str_cursor : BIN_CURSOR) : SAME .. Included as build
build(str_cursor : BIN_CURSOR,octet_cnt : CARD) : SAME .. Included as build
card : CARD .. Included as card
create(str : BINSTR) : SAME .. Included as create
create( .. Included as create
create( .. Included as create
create(str : STR) : SAME .. Included as create
hash : CARD .. Included as hash
****
________This_routine_returns_a_hash_value_computed_from_self_by_successive
___shifts_and_xors_of_the_bit-pattern_forming_the_numeric_value.
hex_str(lib : LIBCHARS) : STR .. Included as hex_str
hex_str : STR .. Included as hex_str
is_eq(other : SAME) : BOOL .. Included as is_eq
****
________This_predicate_returns_true_if_and_only_if_self_and_other_are
___the_same_valid_token_values,_otherwise_false.
is_eq(other : $OB) : BOOL .. Included as is_eq
**** This is the generic equality predicate. c.f. the class $IS_EQ
is_nil : BOOL .. Included as is_nil
****
________This_predicate_returns_true_if_and_only_if_self_is_nil_-_for_this
___class_void_is_the_same_as_nil.
nil : SAME
****
________This_routine_returns_the_value_of_the_nil_token,_in_this_class_that
___is_the_void_value.
read(index : BIN_CURSOR) : SAME .. Included as read
str(lib : LIBCHARS) : STR .. Included as str
str : STR .. Included as str
write(fyle : BIN_FILE) .. Included as write

Iters
aelt!( .. Included as aelt!
aelt!( .. Included as aelt!
aelt!( .. Included as aelt!
aelt! : T .. Included as aelt!
aind! : CARD .. Included as aind!
octet! : OCTET .. Included as octet!
****
________This_iter_yields_successive_octets_of_self_INCLUDING_a_preceding
___octet_giving_the_count_of_following_octets_in_MS_first_order!


Private

const Max_24 : CARD := 16777215 ; .. Included as Max_24
**** Max value in 24 bits!
const asize : CARD := NUM_BITS::Num_Bits ; .. Included as asize
do_build( .. Included as do_build
is_legal_aelts_arg( .. Included as is_legal_aelts_arg

The Sather Home Page