C# Класс Pchp.Library.CharMap

Bitmap representig a set of Unicode characters.
Показать файл Открыть проект

Открытые методы

Метод Описание
Add ( char c ) : void

Adds character to the set.

Add ( string str ) : void

Adds all characters contained in a specified string.

AddRange ( char first, char last ) : void

Adds a range of characters to the set.

AddUsingMask ( string mask ) : void

Adds characters matching given mask.

The mask may contain single characters as well as intervals "a..b", where a, b are characters and a is less than or equal to b.

There are no characters delimiting elements of the mask.

If the mask is not valid as a whole its valid parts are processed.

AddUsingMask ( string mask, string separator ) : void

Adds characters using a mask with specified interval bounds separator.

AddUsingRegularMask ( string mask, int start, int end, char separator ) : void

Adds character range given a regular-expression like mask. E.g. [a-zA-Z].

CharMap ( int size ) : System

Creates a new instance of CharMap.

CharMap ( uint map ) : System

Creates a new instance of CharMap based on specified map.

ClearAll ( ) : void

Clears all bits in the map.

Doesn't necessarily lead to clearing the whole map. Clears the map up to the last bit ever set.

Contains ( char c ) : bool

Retrieves whether a character belongs to the set.

Remove ( char c ) : void

Removes character from the set.

RemoveRange ( char first, char last ) : void

Removes a range of characters from the set.

ToString ( char first, char last, bool complement ) : string

Accumulates all characters contained or not contained in the set to the string in ascending order.

Описание методов

Add() публичный Метод

Adds character to the set.
is not mapped by this instance.
public Add ( char c ) : void
c char The character to be added.
Результат void

Add() публичный Метод

Adds all characters contained in a specified string.
Some character within is not mapped by this instance.
public Add ( string str ) : void
str string The string which characters to add. Can be a null reference.
Результат void

AddRange() публичный Метод

Adds a range of characters to the set.
or are not mapped by this instance. The is less than the .
public AddRange ( char first, char last ) : void
first char The lower bound of the range.
last char The upper bound of the range.
Результат void

AddUsingMask() публичный Метод

Adds characters matching given mask.

The mask may contain single characters as well as intervals "a..b", where a, b are characters and a is less than or equal to b.

There are no characters delimiting elements of the mask.

If the mask is not valid as a whole its valid parts are processed.

is not valid mask. An item of is not convertible to character. Any character of is not mapped by this instance.
public AddUsingMask ( string mask ) : void
mask string The mask of characters to be added. Any collection with items convertible to the type.
Результат void

AddUsingMask() публичный Метод

Adds characters using a mask with specified interval bounds separator.
public AddUsingMask ( string mask, string separator ) : void
mask string The mask.
separator string The separator.
Результат void

AddUsingRegularMask() публичный Метод

Adds character range given a regular-expression like mask. E.g. [a-zA-Z].
public AddUsingRegularMask ( string mask, int start, int end, char separator ) : void
mask string The mask.
start int An index of '[' character in the mask where the range starts.
end int An index of the last character of the range. Usually the index of ']' character.
separator char The separator character. Usually '-'.
Результат void

CharMap() публичный Метод

Creates a new instance of CharMap.
public CharMap ( int size ) : System
size int The number of characters to be mapped.
Результат System

CharMap() публичный Метод

Creates a new instance of CharMap based on specified map.
public CharMap ( uint map ) : System
map uint The bits used for character map.
Результат System

ClearAll() публичный Метод

Clears all bits in the map.
Doesn't necessarily lead to clearing the whole map. Clears the map up to the last bit ever set.
public ClearAll ( ) : void
Результат void

Contains() публичный Метод

Retrieves whether a character belongs to the set.
is not mapped by this instance.
public Contains ( char c ) : bool
c char The character to be tested.
Результат bool

Remove() публичный Метод

Removes character from the set.
is not mapped by this instance.
public Remove ( char c ) : void
c char The character to be removed.
Результат void

RemoveRange() публичный Метод

Removes a range of characters from the set.
or are not mapped by this instance. The is less than the .
public RemoveRange ( char first, char last ) : void
first char The lower bound of the range.
last char The upper bound of the range.
Результат void

ToString() публичный Метод

Accumulates all characters contained or not contained in the set to the string in ascending order.
or are not mapped by this instance.
public ToString ( char first, char last, bool complement ) : string
first char The lower bound.
last char The upper bound.
complement bool Whether to return characters not contained in the string.
Результат string