Character Character Class

Definition

The wrapper for the primitive type char.

[Android.Runtime.Register("java/lang/Character", ApiSince=1, DoNotGenerateAcw=true)]
public sealed class Character : Java.Lang.Object, IConvertible, IDisposable, Java.IO.ISerializable, Java.Lang.IComparable
type Character = class
    inherit Object
    interface ISerializable
    interface IJavaObject
    interface IDisposable
    interface IComparable
    interface IConvertible
Inheritance
CharacterCharacter
Attributes
Implements

Remarks

Android platform documentation

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Constructors

Character(Char) Character(Char)

Constructs a new Character with the specified primitive char value.

Fields

Bytes Bytes
CombiningSpacingMark CombiningSpacingMark

Unicode category constant Mc.

ConnectorPunctuation ConnectorPunctuation

Unicode category constant Pc.

Control Control

Unicode category constant Cc.

CurrencySymbol CurrencySymbol

Unicode category constant Sc.

DashPunctuation DashPunctuation

Unicode category constant Pd.

DecimalDigitNumber DecimalDigitNumber

Unicode category constant Nd.

DirectionalityArabicNumber DirectionalityArabicNumber

Unicode bidirectional constant AN.

DirectionalityBoundaryNeutral DirectionalityBoundaryNeutral

Unicode bidirectional constant BN.

DirectionalityCommonNumberSeparator DirectionalityCommonNumberSeparator

Unicode bidirectional constant CS.

DirectionalityEuropeanNumber DirectionalityEuropeanNumber

Unicode bidirectional constant EN.

DirectionalityEuropeanNumberSeparator DirectionalityEuropeanNumberSeparator

Unicode bidirectional constant ES.

DirectionalityEuropeanNumberTerminator DirectionalityEuropeanNumberTerminator

Unicode bidirectional constant ET.

DirectionalityLeftToRight DirectionalityLeftToRight

Unicode bidirectional constant L.

DirectionalityLeftToRightEmbedding DirectionalityLeftToRightEmbedding

Unicode bidirectional constant LRE.

DirectionalityLeftToRightOverride DirectionalityLeftToRightOverride

Unicode bidirectional constant LRO.

DirectionalityNonspacingMark DirectionalityNonspacingMark

Unicode bidirectional constant NSM.

DirectionalityOtherNeutrals DirectionalityOtherNeutrals

Unicode bidirectional constant ON.

DirectionalityParagraphSeparator DirectionalityParagraphSeparator

Unicode bidirectional constant B.

DirectionalityPopDirectionalFormat DirectionalityPopDirectionalFormat

Unicode bidirectional constant PDF.

DirectionalityRightToLeft DirectionalityRightToLeft

Unicode bidirectional constant R.

DirectionalityRightToLeftArabic DirectionalityRightToLeftArabic

Unicode bidirectional constant AL.

DirectionalityRightToLeftEmbedding DirectionalityRightToLeftEmbedding

Unicode bidirectional constant RLE.

DirectionalityRightToLeftOverride DirectionalityRightToLeftOverride

Unicode bidirectional constant RLO.

DirectionalitySegmentSeparator DirectionalitySegmentSeparator

Unicode bidirectional constant S.

DirectionalityUndefined DirectionalityUndefined

Unicode bidirectional constant.

DirectionalityWhitespace DirectionalityWhitespace

Unicode bidirectional constant WS.

EnclosingMark EnclosingMark

Unicode category constant Me.

EndPunctuation EndPunctuation

Unicode category constant Pe.

FinalQuotePunctuation FinalQuotePunctuation

Unicode category constant Pf.

Format Format

Unicode category constant Cf.

InitialQuotePunctuation InitialQuotePunctuation

Unicode category constant Pi.

LetterNumber LetterNumber

Unicode category constant Nl.

LineSeparator LineSeparator

Unicode category constant Zl.

LowercaseLetter LowercaseLetter

Unicode category constant Ll.

MathSymbol MathSymbol

Unicode category constant Sm.

MaxCodePoint MaxCodePoint

The maximum code point value, U+10FFFF.

MaxHighSurrogate MaxHighSurrogate

The maximum value of a high surrogate or leading surrogate unit in UTF-16 encoding, '?'.

MaxLowSurrogate MaxLowSurrogate

The maximum value of a low surrogate or trailing surrogate unit in UTF-16 encoding, '?'.

MaxRadix MaxRadix

The maximum radix used for conversions between characters and integers.

MaxSurrogate MaxSurrogate

The maximum value of a surrogate unit in UTF-16 encoding, '?'.

MaxValue MaxValue

The maximum Character value.

MinCodePoint MinCodePoint

The minimum code point value, U+0000.

MinHighSurrogate MinHighSurrogate

The minimum value of a high surrogate or leading surrogate unit in UTF-16 encoding, '?'.

MinLowSurrogate MinLowSurrogate

The minimum value of a low surrogate or trailing surrogate unit in UTF-16 encoding, '?'.

MinRadix MinRadix

The minimum radix used for conversions between characters and integers.

MinSupplementaryCodePoint MinSupplementaryCodePoint

The minimum value of a supplementary code point, U+010000.

MinSurrogate MinSurrogate

The minimum value of a surrogate unit in UTF-16 encoding, '?'.

MinValue MinValue

The minimum Character value.

ModifierLetter ModifierLetter

Unicode category constant Lm.

ModifierSymbol ModifierSymbol

Unicode category constant Sk.

NonSpacingMark NonSpacingMark

Unicode category constant Mn.

OtherLetter OtherLetter

Unicode category constant Lo.

OtherNumber OtherNumber

Unicode category constant No.

OtherPunctuation OtherPunctuation

Unicode category constant Po.

OtherSymbol OtherSymbol

Unicode category constant So.

ParagraphSeparator ParagraphSeparator

Unicode category constant Zp.

PrivateUse PrivateUse

Unicode category constant Co.

Size Size

The number of bits required to represent a Character value unsigned form.

SpaceSeparator SpaceSeparator

Unicode category constant Zs.

StartPunctuation StartPunctuation

Unicode category constant Ps.

Surrogate Surrogate

Unicode category constant Cs.

TitlecaseLetter TitlecaseLetter

Unicode category constant Lt.

Unassigned Unassigned

Unicode category constant Cn.

UppercaseLetter UppercaseLetter

Unicode category constant Lu.

Properties

Class Class

Returns the unique instance of Class that represents this object's class.

(Inherited from Object)
Handle Handle

The handle to the underlying Android instance.

(Inherited from Object)
IJavaObjectEx.IsProxy IJavaObjectEx.IsProxy Inherited from Object
IJavaObjectEx.KeyHandle IJavaObjectEx.KeyHandle Inherited from Object
IJavaObjectEx.NeedsActivation IJavaObjectEx.NeedsActivation Inherited from Object
IJavaPeerable.JniManagedPeerState IJavaPeerable.JniManagedPeerState Inherited from Object
JniIdentityHashCode JniIdentityHashCode Inherited from Object
JniPeerMembers JniPeerMembers
PeerReference PeerReference Inherited from Object
ThresholdClass ThresholdClass

This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.

(Inherited from Object)
ThresholdType ThresholdType

This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.

(Inherited from Object)
Type Type

The Class object that represents the primitive type char.

Methods

CharCount(Int32) CharCount(Int32)

Calculates the number of char values required to represent the specified Unicode code point.

CharValue() CharValue()

Gets the primitive value of this character.

Clone() Clone()

Creates and returns a copy of this Object.

(Inherited from Object)
CodePointAt(Char[], Int32) CodePointAt(Char[], Int32)

Returns the code point at index in the specified array of character units.

CodePointAt(Char[], Int32, Int32) CodePointAt(Char[], Int32, Int32)

Returns the code point at index in the specified array of character units, where index has to be less than limit.

CodePointAt(ICharSequence, Int32) CodePointAt(ICharSequence, Int32)

Returns the code point at index in the specified sequence of character units.

CodePointAt(String, Int32) CodePointAt(String, Int32)
CodePointBefore(Char[], Int32) CodePointBefore(Char[], Int32)

Returns the code point that precedes index in the specified array of character units.

CodePointBefore(Char[], Int32, Int32) CodePointBefore(Char[], Int32, Int32)

Returns the code point that precedes the index in the specified array of character units and is not less than start.

CodePointBefore(ICharSequence, Int32) CodePointBefore(ICharSequence, Int32)

Returns the code point that precedes index in the specified sequence of character units.

CodePointBefore(String, Int32) CodePointBefore(String, Int32)
CodePointCount(Char[], Int32, Int32) CodePointCount(Char[], Int32, Int32)

Counts the number of Unicode code points in the subsequence of the specified char array, as delineated by offset and count.

CodePointCount(ICharSequence, Int32, Int32) CodePointCount(ICharSequence, Int32, Int32)

Counts the number of Unicode code points in the subsequence of the specified character sequence, as delineated by beginIndex and endIndex.

CodePointCount(String, Int32, Int32) CodePointCount(String, Int32, Int32)
Compare(Char, Char) Compare(Char, Char)

Compares two char values.

CompareTo(Character) CompareTo(Character)

Compares this object to the specified character object to determine their relative order.

Digit(Char, Int32) Digit(Char, Int32)

Convenience method to determine the value of the specified character c in the supplied radix.

Digit(Int32, Int32) Digit(Int32, Int32)

Convenience method to determine the value of the character codePoint in the supplied radix.

Dispose() Dispose() Inherited from Object
Dispose(Boolean) Dispose(Boolean) Inherited from Object
Equals(Object) Equals(Object)

Compares this instance with the specified object and indicates if they are equal.

(Inherited from Object)
ForDigit(Int32, Int32) ForDigit(Int32, Int32)

Returns the character which represents the specified digit in the specified radix.

GetDirectionality(Char) GetDirectionality(Char)

Gets the Unicode directionality of the specified character.

GetDirectionality(Int32) GetDirectionality(Int32)

Returns the Unicode directionality of the given code point.

GetHashCode() GetHashCode()

Returns an integer hash code for this object.

(Inherited from Object)
GetName(Int32) GetName(Int32)

Returns a human-readable name for the given code point, or null if the code point is unassigned.

GetNumericValue(Char) GetNumericValue(Char)

Returns the numeric value of the specified Unicode character.

GetNumericValue(Int32) GetNumericValue(Int32)

Gets the numeric value of the specified Unicode code point.

GetType(Char) GetType(Char)

Gets the general Unicode category of the specified character.

GetType(Int32) GetType(Int32)

Gets the general Unicode category of the specified code point.

HashCode(Char) HashCode(Char)
HighSurrogate(Int32) HighSurrogate(Int32)

Returns the high surrogate for the given code point.

IsAlphabetic(Int32) IsAlphabetic(Int32)

Returns true if the given code point is alphabetic.

IsBmpCodePoint(Int32) IsBmpCodePoint(Int32)

Returns true if the given code point is in the Basic Multilingual Plane (BMP).

IsDefined(Char) IsDefined(Char)

Indicates whether the specified character is defined in the Unicode specification.

IsDefined(Int32) IsDefined(Int32)

Indicates whether the specified code point is defined in the Unicode specification.

IsDigit(Char) IsDigit(Char)

Indicates whether the specified character is a digit.

IsDigit(Int32) IsDigit(Int32)

Indicates whether the specified code point is a digit.

IsHighSurrogate(Char) IsHighSurrogate(Char)

Indicates whether ch is a high- (or leading-) surrogate code unit that is used for representing supplementary characters in UTF-16 encoding.

IsIdentifierIgnorable(Char) IsIdentifierIgnorable(Char)

Indicates whether the specified character is ignorable in a Java or Unicode identifier.

IsIdentifierIgnorable(Int32) IsIdentifierIgnorable(Int32)

Indicates whether the specified code point is ignorable in a Java or Unicode identifier.

IsIdeographic(Int32) IsIdeographic(Int32)

Returns true if the given code point is a CJKV ideographic character.

IsISOControl(Char) IsISOControl(Char)

Indicates whether the specified character is an ISO control character.

IsISOControl(Int32) IsISOControl(Int32)

Indicates whether the specified code point is an ISO control character.

IsJavaIdentifierPart(Char) IsJavaIdentifierPart(Char)

Indicates whether the specified character is a valid part of a Java identifier other than the first character.

IsJavaIdentifierPart(Int32) IsJavaIdentifierPart(Int32)

Indicates whether the specified code point is a valid part of a Java identifier other than the first character.

IsJavaIdentifierStart(Char) IsJavaIdentifierStart(Char)

Indicates whether the specified character is a valid first character for a Java identifier.

IsJavaIdentifierStart(Int32) IsJavaIdentifierStart(Int32)

Indicates whether the specified code point is a valid first character for a Java identifier.

IsJavaLetter(Char) IsJavaLetter(Char)

Indicates whether the specified character is a Java letter.

IsJavaLetterOrDigit(Char) IsJavaLetterOrDigit(Char)

Indicates whether the specified character is a Java letter or digit character.

IsLetter(Char) IsLetter(Char)

Indicates whether the specified character is a letter.

IsLetter(Int32) IsLetter(Int32)

Indicates whether the specified code point is a letter.

IsLetterOrDigit(Char) IsLetterOrDigit(Char)

Indicates whether the specified character is a letter or a digit.

IsLetterOrDigit(Int32) IsLetterOrDigit(Int32)

Indicates whether the specified code point is a letter or a digit.

IsLowerCase(Char) IsLowerCase(Char)

Indicates whether the specified character is a lower case letter.

IsLowerCase(Int32) IsLowerCase(Int32)

Indicates whether the specified code point is a lower case letter.

IsLowSurrogate(Char) IsLowSurrogate(Char)

Indicates whether ch is a low- (or trailing-) surrogate code unit that is used for representing supplementary characters in UTF-16 encoding.

IsMirrored(Char) IsMirrored(Char)

Indicates whether the specified character is mirrored.

IsMirrored(Int32) IsMirrored(Int32)

Indicates whether the specified code point is mirrored.

IsSpace(Char) IsSpace(Char)

Use IsWhitespace(Char) instead.

IsSpaceChar(Char) IsSpaceChar(Char)

See IsSpaceChar(Int32).

IsSpaceChar(Int32) IsSpaceChar(Int32)

Returns true if the given code point is a Unicode space character.

IsSupplementaryCodePoint(Int32) IsSupplementaryCodePoint(Int32)

Indicates whether codePoint is within the supplementary code point range.

IsSurrogate(Char) IsSurrogate(Char)

Returns true if the given character is a high or low surrogate.

IsSurrogatePair(Char, Char) IsSurrogatePair(Char, Char)

Indicates whether the specified character pair is a valid surrogate pair.

IsTitleCase(Char) IsTitleCase(Char)

Indicates whether the specified character is a titlecase character.

IsTitleCase(Int32) IsTitleCase(Int32)

Indicates whether the specified code point is a titlecase character.

IsUnicodeIdentifierPart(Char) IsUnicodeIdentifierPart(Char)

Indicates whether the specified character is valid as part of a Unicode identifier other than the first character.

IsUnicodeIdentifierPart(Int32) IsUnicodeIdentifierPart(Int32)

Indicates whether the specified code point is valid as part of a Unicode identifier other than the first character.

IsUnicodeIdentifierStart(Char) IsUnicodeIdentifierStart(Char)

Indicates whether the specified character is a valid initial character for a Unicode identifier.

IsUnicodeIdentifierStart(Int32) IsUnicodeIdentifierStart(Int32)

Indicates whether the specified code point is a valid initial character for a Unicode identifier.

IsUpperCase(Char) IsUpperCase(Char)

Indicates whether the specified character is an upper case letter.

IsUpperCase(Int32) IsUpperCase(Int32)

Indicates whether the specified code point is an upper case letter.

IsValidCodePoint(Int32) IsValidCodePoint(Int32)

Indicates whether codePoint is a valid Unicode code point.

IsWhitespace(Char) IsWhitespace(Char)

See IsWhitespace(Int32).

IsWhitespace(Int32) IsWhitespace(Int32)

Returns true if the given code point is a Unicode whitespace character.

JavaFinalize() JavaFinalize()

Invoked when the garbage collector has detected that this instance is no longer reachable.

(Inherited from Object)
LowSurrogate(Int32) LowSurrogate(Int32)

Returns the low surrogate for the given code point.

Notify() Notify()

Causes a thread which is waiting on this object's monitor (by means of calling one of the wait() methods) to be woken up.

(Inherited from Object)
NotifyAll() NotifyAll()

Causes all threads which are waiting on this object's monitor (by means of calling one of the wait() methods) to be woken up.

(Inherited from Object)
OffsetByCodePoints(Char[], Int32, Int32, Int32, Int32) OffsetByCodePoints(Char[], Int32, Int32, Int32, Int32)

Determines the index in a subsequence of the specified character array that is offset codePointOffset code points from index.

OffsetByCodePoints(ICharSequence, Int32, Int32) OffsetByCodePoints(ICharSequence, Int32, Int32)

Determines the index in the specified character sequence that is offset codePointOffset code points from index.

OffsetByCodePoints(String, Int32, Int32) OffsetByCodePoints(String, Int32, Int32)
ReverseBytes(Char) ReverseBytes(Char)

Reverses the order of the first and second byte in the specified character.

SetHandle(IntPtr, JniHandleOwnership) SetHandle(IntPtr, JniHandleOwnership)

Sets the Handle property.

(Inherited from Object)
ToArray<T>() ToArray<T>() Inherited from Object
ToChars(Int32) ToChars(Int32)

Converts the specified Unicode code point into a UTF-16 encoded sequence and returns it as a char array.

ToChars(Int32, Char[], Int32) ToChars(Int32, Char[], Int32)

Converts the specified Unicode code point into a UTF-16 encoded sequence and copies the value(s) into the char array dst, starting at index dstIndex.

ToCodePoint(Char, Char) ToCodePoint(Char, Char)

Converts a surrogate pair into a Unicode code point.

ToLowerCase(Char) ToLowerCase(Char)

Returns the lower case equivalent for the specified character if the character is an upper case letter.

ToLowerCase(Int32) ToLowerCase(Int32)

Returns the lower case equivalent for the specified code point if it is an upper case letter.

ToString() ToString()

Returns a string containing a concise, human-readable description of this object.

(Inherited from Object)
ToString(Char) ToString(Char)

Converts the specified character to its string representation.

ToTitleCase(Char) ToTitleCase(Char)

Returns the title case equivalent for the specified character if it exists.

ToTitleCase(Int32) ToTitleCase(Int32)

Returns the title case equivalent for the specified code point if it exists.

ToUpperCase(Char) ToUpperCase(Char)

Returns the upper case equivalent for the specified character if the character is a lower case letter.

ToUpperCase(Int32) ToUpperCase(Int32)

Returns the upper case equivalent for the specified code point if the code point is a lower case letter.

UnregisterFromRuntime() UnregisterFromRuntime() Inherited from Object
ValueOf(Char) ValueOf(Char)

Returns a Character instance for the char value passed.

Wait() Wait()

Causes the calling thread to wait until another thread calls the notify() or notifyAll() method of this object.

(Inherited from Object)
Wait(Int64) Wait(Int64)

Causes the calling thread to wait until another thread calls the notify() or notifyAll() method of this object or until the specified timeout expires.

(Inherited from Object)
Wait(Int64, Int32) Wait(Int64, Int32)

Causes the calling thread to wait until another thread calls the notify() or notifyAll() method of this object or until the specified timeout expires.

(Inherited from Object)

Operators

Explicit(Character to Char) Explicit(Character to Char)

Explicit Interface Implementations

IComparable.CompareTo(Object) IComparable.CompareTo(Object)
IConvertible.GetTypeCode() IConvertible.GetTypeCode()
IConvertible.ToBoolean(IFormatProvider) IConvertible.ToBoolean(IFormatProvider)
IConvertible.ToByte(IFormatProvider) IConvertible.ToByte(IFormatProvider)
IConvertible.ToChar(IFormatProvider) IConvertible.ToChar(IFormatProvider)
IConvertible.ToDateTime(IFormatProvider) IConvertible.ToDateTime(IFormatProvider)
IConvertible.ToDecimal(IFormatProvider) IConvertible.ToDecimal(IFormatProvider)
IConvertible.ToDouble(IFormatProvider) IConvertible.ToDouble(IFormatProvider)
IConvertible.ToInt16(IFormatProvider) IConvertible.ToInt16(IFormatProvider)
IConvertible.ToInt32(IFormatProvider) IConvertible.ToInt32(IFormatProvider)
IConvertible.ToInt64(IFormatProvider) IConvertible.ToInt64(IFormatProvider)
IConvertible.ToSByte(IFormatProvider) IConvertible.ToSByte(IFormatProvider)
IConvertible.ToSingle(IFormatProvider) IConvertible.ToSingle(IFormatProvider)
IConvertible.ToString(IFormatProvider) IConvertible.ToString(IFormatProvider)
IConvertible.ToType(Type, IFormatProvider) IConvertible.ToType(Type, IFormatProvider)
IConvertible.ToUInt16(IFormatProvider) IConvertible.ToUInt16(IFormatProvider)
IConvertible.ToUInt32(IFormatProvider) IConvertible.ToUInt32(IFormatProvider)
IConvertible.ToUInt64(IFormatProvider) IConvertible.ToUInt64(IFormatProvider)
IJavaObjectEx.ToLocalJniHandle() IJavaObjectEx.ToLocalJniHandle() Inherited from Object
IJavaPeerable.Disposed() IJavaPeerable.Disposed() Inherited from Object
IJavaPeerable.DisposeUnlessReferenced() IJavaPeerable.DisposeUnlessReferenced() Inherited from Object
IJavaPeerable.Finalized() IJavaPeerable.Finalized() Inherited from Object
IJavaPeerable.SetJniIdentityHashCode(Int32) IJavaPeerable.SetJniIdentityHashCode(Int32) Inherited from Object
IJavaPeerable.SetJniManagedPeerState(JniManagedPeerStates) IJavaPeerable.SetJniManagedPeerState(JniManagedPeerStates) Inherited from Object
IJavaPeerable.SetPeerReference(JniObjectReference) IJavaPeerable.SetPeerReference(JniObjectReference) Inherited from Object

Extension Methods

JavaCast<TResult>(IJavaObject) JavaCast<TResult>(IJavaObject)

Performs an Android runtime-checked type conversion.

JavaCast<TResult>(IJavaObject) JavaCast<TResult>(IJavaObject)
GetJniTypeName(IJavaPeerable) GetJniTypeName(IJavaPeerable)

Applies to