C# Class IdleLandsRedux.Common.StringHelper

Afficher le fichier Open project: IdleLands/IdleLandsRedux

Méthodes publiques

Méthode Description
Capitalize ( this @string, int offset ) : string
ContainsAny ( this haystack ) : bool

Contains any of the given needles.

GetGenderPronoun ( string gender, string input ) : string

Gets the gender pronoun.

SanitizeString ( string str, bool punctuation = false ) : string

Sanitizes the string.

Private Methods

Méthode Description
ReplaceGenderPronoun ( this builder, string gender, string input ) : StringBuilder

Method Details

Capitalize() public static méthode

public static Capitalize ( this @string, int offset ) : string
@string this
offset int
Résultat string

ContainsAny() public static méthode

Contains any of the given needles.
public static ContainsAny ( this haystack ) : bool
haystack this Haystack.
Résultat bool

GetGenderPronoun() public static méthode

Gets the gender pronoun.
public static GetGenderPronoun ( string gender, string input ) : string
gender string Gender. e.g. 'Male' or 'Female'
input string Input. e.g. '%hisher' or 'she'
Résultat string

SanitizeString() public static méthode

Sanitizes the string.
public static SanitizeString ( string str, bool punctuation = false ) : string
str string Input to be sanitized.
punctuation bool If set to true, allows for punctuation. Otherwise it is also sanitized.
Résultat string