immutable class CASE_MAPLET < $IS_EQ, $IMMUTABLE
****
This class provides a maplet for one or more mappings between upper
___and_lower_cases_of_alphabetic_scripts_(Latin,_Greek,_Cyrillic,_Armenian_and_Georgian).
________Its_three_components_are_used_to_denote/describe_a_single_one-to-one
___mapping_for_one_character_encoding_to_another_coding_which_is_identical
___except_for_its_case.


Ancestors
$IMMUTABLE $STR $BINARY $IS_EQ



Public


Readable Attributes
attr base : CHAR_CODE ;
**** This attribute gives the code value of the first 'from' case code in the maplet.
attr count : CARD ;
**** This final attribute indicates the number of upper/lower pairs
___denoted_by_this_maplet.___
attr offset : INT ;
**** This second attribute gives the offset to be used in calculating
___the_conversion_from_range_to_domain_and_vv.___There_is_a_special
___case_when_the_offset_is_one_as_the_count_then_refers_to_pairs_of_adjacent
___numeric_values.___This_maplet_kind_is_quite_common_in_the_various_script
___extensions_in_the_code_standard._

Features
binstr : BINSTR
build(index : BIN_CURSOR) : SAME
create(str : BINSTR) : SAME .. Included as create
create(code_base : CHAR_CODE,off : INT,cnt : CARD) : SAME
in_domain(code : CHAR_CODE) : BOOL
**** This predicate returns true if and only if the given code number
___is_in_the_domain_of_this_maplet.
in_range(code : CHAR_CODE) : BOOL
****
________This_predicate_returns_true_if_and_only_if_the_given_code_number
___is_in_the_range_of_this_maplet.
is_disjoint(other : SAME) : BOOL
**** This routine returns true if and only if self and other have
___NO_elements_in_common!!
is_eq(other : SAME) : BOOL
**** This routine returns true if and only if self and other have
___identical_component_values.
is_eq(other : $OB) : BOOL .. Included as is_eq
**** This is the generic equality predicate. c.f. the class $IS_EQ
map(lowcode : CHAR_CODE) : CHAR_CODE .. Included as map
read(index : BIN_CURSOR) : SAME .. Included as read
reverse_map(upcode : CHAR_CODE) : CHAR_CODE .. Included as reverse_map
str(lib : LIBCHARS) : STR .. Included as str
**** This routine returns a textual representation of the maplet in
___the_given_repertoire_and_encoding.
str : STR .. Included as str
**** This routine returns a textual representation of the maplet in
___the_default_repertoire_and_encoding.
write(fyle : BIN_FILE) .. Included as write


Private

const Min_Code_Size : CARD := 2 ;
**** must have at least code kind plus 1 octet
attr base : CHAR_CODE ;
**** This attribute gives the code value of the first 'from' case code in the maplet.
attr count : CARD ;
**** This final attribute indicates the number of upper/lower pairs
___denoted_by_this_maplet.___
is_valid(val : CHAR_CODE,off : INT,cnt : CARD) : BOOL
**** This private predicate determines whether the creation of a maplet
___will_result_in_mappings_always_being_valid_provided_that_the_appropriate
___range/domain_check_is_part_of_the_mapping_routine_definitions.
attr offset : INT ;
**** This second attribute gives the offset to be used in calculating
___the_conversion_from_range_to_domain_and_vv.___There_is_a_special
___case_when_the_offset_is_one_as_the_count_then_refers_to_pairs_of_adjacent
___numeric_values.___This_maplet_kind_is_quite_common_in_the_various_script
___extensions_in_the_code_standard._

The Sather Home Page