C# 클래스 DevUtils.PrimitivesExtensions.StringExtensions

Static string extensions
파일 보기 프로젝트 열기: jornfilho/.net-Dev-Utils

공개 메소드들

메소드 설명
CompareNoCase ( this valueCurrent, string valueToCompare ) : bool

Compares two string objects ignoring case.

ContainedIn ( this valueCurrent, List values ) : bool

Determines if the current string is contained in the specified list of objects.

ContainedIn ( this valueCurrent, List values ) : bool

Determines if the current string is contained in the specified list of strings.

ContainedIn ( this valueCurrent, object values ) : bool

Determines if the current string is contained in the specified array of objects.

EndsWithCurrent ( this valueCurrent, string valueToCompare ) : bool

Gets a value indicating if the string ends with the specified substring for the current culture.

EndsWithOrdinalIgnoreCase ( this valueCurrent, string valueToCompare ) : bool

Gets a value indicating if the string ends with the specified substring for ordinal ignoring case.

FormatCurrent ( this format ) : string

Formats the string with the specified objects for the current culture.

FormatCurrent ( this format, object arg0 ) : string

Formats the string with the specified object for the current culture.

FormatCurrent ( this format, object arg0, object arg1 ) : string

Formats the string with the specified objects for the current culture.

FormatCurrent ( this format, object arg0, object arg1, object arg2 ) : string

Formats the string with the specified objects for the current culture.

FormatInvariant ( this format ) : string

Formats the string with the specified objects for an invariant culture.

FormatInvariant ( this format, object arg0 ) : string

Formats the string with the specified object for an invariant culture.

FormatInvariant ( this format, object arg0, object arg1 ) : string

Formats the string with the specified objects for an invariant culture.

FormatInvariant ( this format, object arg0, object arg1, object arg2 ) : string

Formats the string with the specified objects for an invariant culture.

GetDigits ( this text ) : string

Get only number characters

IndexOfAll ( this valueCurrent, string value ) : IEnumerable

Gets the indexes of all occurrences of the specified value in the string.

IndexOfCurrent ( this valueCurrent, string value ) : int

Gets the index of the first occurrence of the specified value in the string for the current culture.

IndexOfCurrent ( this valueCurrent, string value, int startIndex ) : int

Gets the index of the first occurrence of the specified value in the string for the current culture.

IndexOfOrdinalIgnoreCase ( this valueCurrent, string value ) : int

Gets the index of the first occurrence of the specified value in the string for ordinal ignoring case.

IndexOfOrdinalIgnoreCase ( this valueCurrent, string value, int startIndex ) : int

Gets the index of the first occurrence of the specified value in the string for ordinal ignoring case.

Join ( this array, string separator ) : string

Joins all elements in the specified array together separated by the specified delimiter.

Join ( this list, string separator ) : string

Joins all elements in the specified list together separated by the specified delimiter.

Left ( this text, int length ) : string

Get first N characters from string

Right ( this text, int length ) : string

Get last N characters from string

StartsWithCurrent ( this valueCurrent, string valueToCompare ) : bool

Gets a value indicating if the string begins with the specified substring for the current culture.

StartsWithOrdinalIgnoreCase ( this valueCurrent, string valueToCompare ) : bool

Gets a value indicating if the string begins with the specified substring for ordinal ignoring case.

ToUnicode ( this text ) : string

Normalize string to unicode

Remove special characters

ToUnicodeWithoutSpace ( this text ) : string

Remove all spaces and normalize string to unicode

Remove special characters

Convert space to underscore

메소드 상세

CompareNoCase() 공개 정적인 메소드

Compares two string objects ignoring case.
public static CompareNoCase ( this valueCurrent, string valueToCompare ) : bool
valueCurrent this The current string used to compare against another string.
valueToCompare string The string to compare against the current string.
리턴 bool

ContainedIn() 공개 정적인 메소드

Determines if the current string is contained in the specified list of objects.
public static ContainedIn ( this valueCurrent, List values ) : bool
valueCurrent this The current string used to compare against the list of objects.
values List The list of objects used compare against the current string.
리턴 bool

ContainedIn() 공개 정적인 메소드

Determines if the current string is contained in the specified list of strings.
public static ContainedIn ( this valueCurrent, List values ) : bool
valueCurrent this The current string used to compare against the list of strings.
values List The list of strings used compare against the current string.
리턴 bool

ContainedIn() 공개 정적인 메소드

Determines if the current string is contained in the specified array of objects.
public static ContainedIn ( this valueCurrent, object values ) : bool
valueCurrent this The current string used to compare against the array of objects.
values object The array of objects used compare against the current string.
리턴 bool

EndsWithCurrent() 공개 정적인 메소드

Gets a value indicating if the string ends with the specified substring for the current culture.
public static EndsWithCurrent ( this valueCurrent, string valueToCompare ) : bool
valueCurrent this The current string to compare against a substring.
valueToCompare string The substring to compare against the current string.
리턴 bool

EndsWithOrdinalIgnoreCase() 공개 정적인 메소드

Gets a value indicating if the string ends with the specified substring for ordinal ignoring case.
public static EndsWithOrdinalIgnoreCase ( this valueCurrent, string valueToCompare ) : bool
valueCurrent this The current string to compare against a substring.
valueToCompare string The substring to compare against the current string.
리턴 bool

FormatCurrent() 공개 정적인 메소드

Formats the string with the specified objects for the current culture.
public static FormatCurrent ( this format ) : string
format this The string to format.
리턴 string

FormatCurrent() 공개 정적인 메소드

Formats the string with the specified object for the current culture.
public static FormatCurrent ( this format, object arg0 ) : string
format this The string to format.
arg0 object The object in which to format in the string.
리턴 string

FormatCurrent() 공개 정적인 메소드

Formats the string with the specified objects for the current culture.
public static FormatCurrent ( this format, object arg0, object arg1 ) : string
format this The string to format.
arg0 object The first object in which to format in the string.
arg1 object The second object in which to format in the string.
리턴 string

FormatCurrent() 공개 정적인 메소드

Formats the string with the specified objects for the current culture.
public static FormatCurrent ( this format, object arg0, object arg1, object arg2 ) : string
format this The string to format.
arg0 object The first object in which to format in the string.
arg1 object The second object in which to format in the string.
arg2 object The third object in which to format in the string.
리턴 string

FormatInvariant() 공개 정적인 메소드

Formats the string with the specified objects for an invariant culture.
public static FormatInvariant ( this format ) : string
format this The string to format.
리턴 string

FormatInvariant() 공개 정적인 메소드

Formats the string with the specified object for an invariant culture.
public static FormatInvariant ( this format, object arg0 ) : string
format this The string to format.
arg0 object The object in which to format in the string.
리턴 string

FormatInvariant() 공개 정적인 메소드

Formats the string with the specified objects for an invariant culture.
public static FormatInvariant ( this format, object arg0, object arg1 ) : string
format this The string to format.
arg0 object The first object in which to format in the string.
arg1 object The second object in which to format in the string.
리턴 string

FormatInvariant() 공개 정적인 메소드

Formats the string with the specified objects for an invariant culture.
public static FormatInvariant ( this format, object arg0, object arg1, object arg2 ) : string
format this The string to format.
arg0 object The first object in which to format in the string.
arg1 object The second object in which to format in the string.
arg2 object The third object in which to format in the string.
리턴 string

GetDigits() 공개 정적인 메소드

Get only number characters
public static GetDigits ( this text ) : string
text this strign to get numbers
리턴 string

IndexOfAll() 공개 정적인 메소드

Gets the indexes of all occurrences of the specified value in the string.
public static IndexOfAll ( this valueCurrent, string value ) : IEnumerable
valueCurrent this The current string in which to obtain all indexes of.
value string The value to seek for all occurrences of.
리턴 IEnumerable

IndexOfCurrent() 공개 정적인 메소드

Gets the index of the first occurrence of the specified value in the string for the current culture.
public static IndexOfCurrent ( this valueCurrent, string value ) : int
valueCurrent this The current string in which to obtain the index of.
value string The value to seek.
리턴 int

IndexOfCurrent() 공개 정적인 메소드

Gets the index of the first occurrence of the specified value in the string for the current culture.
public static IndexOfCurrent ( this valueCurrent, string value, int startIndex ) : int
valueCurrent this The current string in which to obtain the index of.
value string The value to seek.
startIndex int The search starting position.
리턴 int

IndexOfOrdinalIgnoreCase() 공개 정적인 메소드

Gets the index of the first occurrence of the specified value in the string for ordinal ignoring case.
public static IndexOfOrdinalIgnoreCase ( this valueCurrent, string value ) : int
valueCurrent this The current string in which to obtain the index of.
value string The value to seek.
리턴 int

IndexOfOrdinalIgnoreCase() 공개 정적인 메소드

Gets the index of the first occurrence of the specified value in the string for ordinal ignoring case.
public static IndexOfOrdinalIgnoreCase ( this valueCurrent, string value, int startIndex ) : int
valueCurrent this The current string in which to obtain the index of.
value string The value to seek.
startIndex int The search starting position.
리턴 int

Join() 공개 정적인 메소드

Joins all elements in the specified array together separated by the specified delimiter.
public static Join ( this array, string separator ) : string
array this An array of elements.
separator string The separator for each element.
리턴 string

Join() 공개 정적인 메소드

Joins all elements in the specified list together separated by the specified delimiter.
public static Join ( this list, string separator ) : string
list this A list of elements.
separator string The separator for each element.
리턴 string

Left() 공개 정적인 메소드

Get first N characters from string
public static Left ( this text, int length ) : string
text this string text
length int characters length
리턴 string

Right() 공개 정적인 메소드

Get last N characters from string
public static Right ( this text, int length ) : string
text this string text
length int characters length
리턴 string

StartsWithCurrent() 공개 정적인 메소드

Gets a value indicating if the string begins with the specified substring for the current culture.
public static StartsWithCurrent ( this valueCurrent, string valueToCompare ) : bool
valueCurrent this The current string to compare against a substring.
valueToCompare string The substring to compare against the current string.
리턴 bool

StartsWithOrdinalIgnoreCase() 공개 정적인 메소드

Gets a value indicating if the string begins with the specified substring for ordinal ignoring case.
public static StartsWithOrdinalIgnoreCase ( this valueCurrent, string valueToCompare ) : bool
valueCurrent this The current string to compare against a substring.
valueToCompare string The substring to compare against the current string.
리턴 bool

ToUnicode() 공개 정적인 메소드

Normalize string to unicode

Remove special characters

public static ToUnicode ( this text ) : string
text this string to normalize
리턴 string

ToUnicodeWithoutSpace() 공개 정적인 메소드

Remove all spaces and normalize string to unicode

Remove special characters

Convert space to underscore

public static ToUnicodeWithoutSpace ( this text ) : string
text this strign to normalize
리턴 string