Eiffel Media API
Overview Cluster Class Classes Index      Previous Next      Top Features

kernel.unicode

Class UC_UNICODE_ROUTINES


Direct ancestors

UC_CTYPE, KL_IMPORTED_INTEGER_ROUTINES, KL_SHARED_PLATFORM

Known direct descendants

XM_XSLT_EMITTER

Features

Invariants

indexing

description

Unicode routines

library

Gobo Eiffel Kernel Library

copyright

Copyright (c) 2001-2002, Eric Bezault and others

license

Eiffel Forum License v2 (see forum.txt)

date

$Date: 2005/10/25 04:52:53 $

revision

$Revision: 1.9 $

class

UC_UNICODE_ROUTINES

inherit

UC_CTYPE

feature -- Access

close_punctuation_category: INTEGER

-- Close punctuation

-- (From UC_UNICODE_CONSTANTS)

connector_punctuation_category: INTEGER

-- Connector punctuation

-- (From UC_UNICODE_CONSTANTS)

control_other_category: INTEGER

-- Control character

-- (From UC_UNICODE_CONSTANTS)

currency_symbol_category: INTEGER

-- Currency symbol

-- (From UC_UNICODE_CONSTANTS)

dash_punctuation_category: INTEGER

-- Dash punctuation

-- (From UC_UNICODE_CONSTANTS)

decimal_digit_number_category: INTEGER

-- Decimal digit number

-- (From UC_UNICODE_CONSTANTS)

enclosing_mark_category: INTEGER

-- Enclosing mark

-- (From UC_UNICODE_CONSTANTS)

final_quote_punctuation_category: INTEGER

-- Final_quote punctuation

-- (From UC_UNICODE_CONSTANTS)

format_other_category: INTEGER

-- Format character

-- (From UC_UNICODE_CONSTANTS)

initial_quote_punctuation_category: INTEGER

-- Initial punctuation

-- (From UC_UNICODE_CONSTANTS)

letter_number_category: INTEGER

-- Letter number

-- (From UC_UNICODE_CONSTANTS)

line_separator_category: INTEGER

-- Line separator

-- (From UC_UNICODE_CONSTANTS)

lowercase_letter_category: INTEGER

-- Lower case letter

-- (From UC_UNICODE_CONSTANTS)

math_symbol_category: INTEGER

-- Mathematics symbol

-- (From UC_UNICODE_CONSTANTS)

modifier_letter_category: INTEGER

-- Modifier letter

-- (From UC_UNICODE_CONSTANTS)

modifier_symbol_category: INTEGER

-- Modifier symbol

-- (From UC_UNICODE_CONSTANTS)

non_spacing_mark_category: INTEGER

-- Non-spacing mark

-- (From UC_UNICODE_CONSTANTS)

open_punctuation_category: INTEGER

-- Open punctuation

-- (From UC_UNICODE_CONSTANTS)

other_letter_category: INTEGER

-- Other letter

-- (From UC_UNICODE_CONSTANTS)

other_number_category: INTEGER

-- Other number

-- (From UC_UNICODE_CONSTANTS)

other_punctuation_category: INTEGER

-- Other punctuation

-- (From UC_UNICODE_CONSTANTS)

other_symbol_category: INTEGER

-- Other symbol

-- (From UC_UNICODE_CONSTANTS)

paragraph_separator_category: INTEGER

-- Paragraph separator

-- (From UC_UNICODE_CONSTANTS)

platform: KL_PLATFORM

-- Platform-dependent properties

-- (From KL_SHARED_PLATFORM)

ensure
platform_not_void: Result /= Void
private_other_category: INTEGER

-- Private-use character

-- (From UC_UNICODE_CONSTANTS)

space_separator_category: INTEGER

-- Space separator

-- (From UC_UNICODE_CONSTANTS)

spacing_combining_mark_category: INTEGER

-- Spacing combining mark

-- (From UC_UNICODE_CONSTANTS)

surrogate_other_category: INTEGER

-- Surrogate character

-- (From UC_UNICODE_CONSTANTS)

titlecase_letter_category: INTEGER

-- Title case letter

-- (From UC_UNICODE_CONSTANTS)

unassigned_other_category: INTEGER

-- Unassigned chacaracter

-- (From UC_UNICODE_CONSTANTS)

uppercase_letter_category: INTEGER

-- Upper case letter

-- (From UC_UNICODE_CONSTANTS)

lower_code (a_code_point: INTEGER): INTEGER

-- Code of lower-case character of character with code a_code_point

-- (From UC_CTYPE)

require
valid_code: valid_code (a_code_point)
ensure
valid_lower_code: valid_code (Result)
maximum_ascii_character: CHARACTER

-- Largest ASCII character
-- ensure
-- definition: Result.code = maximum_ascii_code
-- end

-- (From UC_UNICODE_CONSTANTS)

maximum_ascii_character_code: INTEGER

-- Largest code for ASCII characters
-- (2^7 - 1)
-- ensure
-- definition: Result = 127
-- small_enough: Result <= Platform.Maximum_byte_code
-- end

-- (From UC_UNICODE_CONSTANTS)

maximum_unicode_character_code: INTEGER

-- Largest code for unicode characters
-- ensure
-- definition: Result = 1114109
-- end

-- (From UC_UNICODE_CONSTANTS)

minimum_ascii_character: CHARACTER

-- Smallest ASCII character
-- ensure
-- definition: Result.code = minimum_ascii_code
-- end

-- (From UC_UNICODE_CONSTANTS)

minimum_ascii_character_code: INTEGER

-- Smallest code for ASCII characters
-- ensure
-- definition: Result = 0
-- end

-- (From UC_UNICODE_CONSTANTS)

minimum_unicode_character_code: INTEGER

-- Smallest code for unicode characters
-- ensure
-- definition: Result = 0
-- end

-- (From UC_UNICODE_CONSTANTS)

title_code (a_code_point: INTEGER): INTEGER

-- Code of title-case character of character with code a_code_point

-- (From UC_CTYPE)

require
valid_code: valid_code (a_code_point)
ensure
valid_title_code: valid_code (Result)
upper_code (a_code_point: INTEGER): INTEGER

-- Code of upper-case character of character with code a_code_point

-- (From UC_CTYPE)

require
valid_code: valid_code (a_code_point)
ensure
valid_upper_code: valid_code (Result)

feature -- Status report

code_to_string (a_code: INTEGER): STRING

-- Return a string with a_code as its single character.
-- (If the character code is bigger than the maximum for
-- CHARACTER, the dynamic type of the result will be UC_STRING
-- or a descendant.)

require
a_code_valid: valid_code (a_code)
ensure
string_not_void: Result /= Void
count_set: Result.count = 1
code_set: Result.item_code (1) = a_code
is_ascii_string (a_string: STRING): BOOLEAN

-- Does a_string contain only ASCII characters?

require
a_string_not_void: a_string /= Void
valid_ascii_code (a_code: INTEGER): BOOLEAN

-- Is a_code a valid ASCII code?

ensure
definition: Result = (a_code >= minimum_ascii_character_code anda_code <= maximum_ascii_character_code)
valid_code (a_code: INTEGER): BOOLEAN

-- Is a_code a valid unicode?

-- (From UC_CTYPE)

ensure
definition: Result = (a_code >= minimum_unicode_character_code anda_code <= maximum_unicode_character_code)

feature -- Obsolete

platform_: KL_PLATFORM

-- Platform-dependent properties

-- (From KL_SHARED_PLATFORM)

obsolete

[040101] Use Platform instead.

ensure
platform_not_void: Result /= Void

invariant

-- From ANY
reflexive_equality: standard_is_equal (Current)
reflexive_conformance: conforms_to (Current)

end