메소드 | 설명 | |
---|---|---|
AlphaCharactersOnly ( this input ) : string |
Keeps only alpha characters
|
|
AlphaNumericOnly ( this input ) : string |
Keeps only alphanumeric characters
|
|
AppendLineFormat ( this builder, string format ) : StringBuilder |
Does an AppendFormat and then an AppendLine on the StringBuilder
|
|
Center ( this input, int length, string padding = " " ) : string |
Centers the input string (if it's longer than the length) and pads it using the padding string
|
|
Encode ( this input, |
Converts a string to a string of another encoding
|
|
ExpandTabs ( this input, int tabSize = 4 ) : string |
Expands tabs and replaces them with spaces
|
|
FilterOutText ( this input, string filter ) : string |
Removes the filter text from the input.
|
|
FormatString ( this input ) : string |
Formats a string based on the key/value pairs that are sent in
|
|
FormatString ( this input, object Object, string startSeperator = "{", string endSeperator = "}" ) : string |
Formats a string based on the object's properties
|
|
FormatString ( this input, string format, IStringFormatter provider = null ) : string |
Formats a string based on a format string passed in. The default formatter uses the following format: # = digits @ = alpha characters \ = escape char
|
|
FromBase64 ( this input ) : byte[] |
Converts base 64 string to a byte array
|
|
FromBase64 ( this input, |
Converts base 64 string based on the encoding passed in
|
|
IsAnagram ( this input1, string input2 ) : bool |
Determines if the two strings are anagrams or not
|
|
IsCreditCard ( this creditCardNumber ) : bool |
Checks if a credit card number is valid
|
|
IsUnicode ( this input ) : bool |
Determines if a string is unicode
|
|
KeepFilterText ( this input, string filter ) : string |
Removes everything that is not in the filter text from the input.
|
|
Left ( this input, int length ) : string |
Gets the first x number of characters from the left hand side
|
|
MaskLeft ( this input, int endPosition = 4, char mask = '#' ) : string |
Masks characters to the left ending at a specific character
|
|
MaskRight ( this input, int startPosition = 4, char mask = '#' ) : string |
Masks characters to the right starting at a specific character
|
|
NextSequence ( this sequence, char min = ' ', char max = '~' ) : string |
Function that is useful for generating a string in a series. so a becomes b, b becomes c, etc. and after hitting the max character, it goes to two characters (so ~ becomes aa, then ab, ac, etc).
|
|
NumberTimesOccurs ( this input, string match ) : int |
returns the number of times a string occurs within the text
|
|
NumericOnly ( this input, bool keepNumericPunctuation = true ) : string |
Keeps only numeric characters
|
|
Pluralize ( this word, |
Pluralizes a word
|
|
RegexFormat ( this input, string format, string outputFormat, RegexOptions options = RegexOptions.None ) : string |
Uses a regex to format the input string
|
|
RemoveExtraSpaces ( this input ) : string |
Removes multiple spaces from a string and replaces it with a single space
|
|
Reverse ( this input ) : string |
Reverses a string
|
|
Right ( this input, int length ) : string |
Gets the last x number of characters from the right hand side
|
|
Singularize ( this word, |
Singularizes a word
|
|
StripIllegalXml ( this content ) : string |
Strips illegal characters for XML content
|
|
StripLeft ( this input, string characters = " " ) : string |
Strips out any of the characters specified starting on the left side of the input string (stops when a character not in the list is found)
|
|
StripRight ( this input, string characters = " " ) : string |
Strips out any of the characters specified starting on the right side of the input string (stops when a character not in the list is found)
|
|
ToBase64 ( this input, |
Converts from the specified encoding to a base 64 string
|
|
ToByteArray ( this input, |
Converts a string to a byte array
|
|
ToFirstCharacterUpperCase ( this input ) : string |
Takes the first character of an input string and makes it uppercase
|
|
ToSentenceCapitalize ( this input ) : string |
Capitalizes each sentence within the string
|
|
ToTitleCase ( this input ) : string |
Capitalizes the first character of each word
|
메소드 | 설명 | |
---|---|---|
LevenshteinDistance ( this value1, string value2 ) : int |
public static AlphaCharactersOnly ( this input ) : string | ||
input | this | Input string |
리턴 | string |
public static AlphaNumericOnly ( this input ) : string | ||
input | this | Input string |
리턴 | string |
public static AppendLineFormat ( this builder, string format ) : StringBuilder | ||
builder | this | Builder object |
format | string | Format string |
리턴 | StringBuilder |
public static Center ( this input, int length, string padding = " " ) : string | ||
input | this | |
length | int | |
padding | string | |
리턴 | string |
public static Encode ( this input, |
||
input | this | input string |
originalEncodingUsing | The type of encoding the string is currently using (defaults to ASCII) | |
encodingUsing | The type of encoding the string is converted into (defaults to UTF8) | |
리턴 | string |
public static ExpandTabs ( this input, int tabSize = 4 ) : string | ||
input | this | Input string |
tabSize | int | Number of spaces |
리턴 | string |
public static FilterOutText ( this input, string filter ) : string | ||
input | this | Input text |
filter | string | Regex expression of text to filter out |
리턴 | string |
public static FormatString ( this input ) : string | ||
input | this | Input string |
리턴 | string |
public static FormatString ( this input, object Object, string startSeperator = "{", string endSeperator = "}" ) : string | ||
input | this | Input string |
Object | object | Object to use to format the string |
startSeperator | string | Seperator character/string to use to describe the start of the property name |
endSeperator | string | Seperator character/string to use to describe the end of the property name |
리턴 | string |
public static FormatString ( this input, string format, IStringFormatter provider = null ) : string | ||
input | this | Input string |
format | string | Format of the output string |
provider | IStringFormatter | String formatter provider (defaults to GenericStringFormatter) |
리턴 | string |
public static FromBase64 ( this input ) : byte[] | ||
input | this | Input string |
리턴 | byte[] |
public static FromBase64 ( this input, |
||
input | this | Input string |
encodingUsing | The type of encoding the string is using (defaults to UTF8) | |
리턴 | string |
public static IsAnagram ( this input1, string input2 ) : bool | ||
input1 | this | Input 1 |
input2 | string | Input 2 |
리턴 | bool |
public static IsCreditCard ( this creditCardNumber ) : bool | ||
creditCardNumber | this | Number to check |
리턴 | bool |
public static IsUnicode ( this input ) : bool | ||
input | this | Input string |
리턴 | bool |
public static KeepFilterText ( this input, string filter ) : string | ||
input | this | Input text |
filter | string | Regex expression of text to keep |
리턴 | string |
public static Left ( this input, int length ) : string | ||
input | this | Input string |
length | int | x number of characters to return |
리턴 | string |
public static MaskLeft ( this input, int endPosition = 4, char mask = '#' ) : string | ||
input | this | Input string |
endPosition | int | End position (counting from the left) |
mask | char | Mask character to use |
리턴 | string |
public static MaskRight ( this input, int startPosition = 4, char mask = '#' ) : string | ||
input | this | Input string |
startPosition | int | Start position (counting from the left) |
mask | char | Mask character to use |
리턴 | string |
public static NextSequence ( this sequence, char min = ' ', char max = '~' ) : string | ||
sequence | this | Current sequence |
min | char | Min character |
max | char | Max character |
리턴 | string |
public static NumberTimesOccurs ( this input, string match ) : int | ||
input | this | input text |
match | string | The string to match (can be regex) |
리턴 | int |
public static NumericOnly ( this input, bool keepNumericPunctuation = true ) : string | ||
input | this | Input string |
keepNumericPunctuation | bool | Determines if decimal places should be kept |
리턴 | string |
public static Pluralize ( this word, |
||
word | this | Word to pluralize |
culture | Culture info used to pluralize the word (defaults to current culture) | |
리턴 | string |
public static RegexFormat ( this input, string format, string outputFormat, RegexOptions options = RegexOptions.None ) : string | ||
input | this | Input string |
format | string | Regex string used to |
outputFormat | string | Output format |
options | RegexOptions | Regex options |
리턴 | string |
public static RemoveExtraSpaces ( this input ) : string | ||
input | this | Input string |
리턴 | string |
public static Reverse ( this input ) : string | ||
input | this | Input string |
리턴 | string |
public static Right ( this input, int length ) : string | ||
input | this | Input string |
length | int | x number of characters to return |
리턴 | string |
public static Singularize ( this word, |
||
word | this | Word to singularize |
culture | Culture info used to singularize the word (defaults to current culture) | |
리턴 | string |
public static StripIllegalXml ( this content ) : string | ||
content | this | Content |
리턴 | string |
public static StripLeft ( this input, string characters = " " ) : string | ||
input | this | Input string |
characters | string | Characters to string (defaults to a space) |
리턴 | string |
public static StripRight ( this input, string characters = " " ) : string | ||
input | this | Input string |
characters | string | Characters to string (defaults to a space) |
리턴 | string |
public static ToBase64 ( this input, |
||
input | this | Input string |
originalEncodingUsing | The type of encoding the string is using (defaults to UTF8) | |
리턴 | string |
public static ToByteArray ( this input, |
||
input | this | input string |
encodingUsing | The type of encoding the string is using (defaults to UTF8) | |
리턴 | byte[] |
public static ToFirstCharacterUpperCase ( this input ) : string | ||
input | this | Input string |
리턴 | string |
public static ToSentenceCapitalize ( this input ) : string | ||
input | this | Input string |
리턴 | string |
public static ToTitleCase ( this input ) : string | ||
input | this | Input string |
리턴 | string |