C# Class TraktPlugin.Extensions.StringExtensions

Datei anzeigen Open project: trakt/Trakt-for-Mediaportal

Public Methods

Method Description
IsNumber ( this number ) : bool
RemapHighOrderChars ( this input ) : string
RemoveDiacritics ( this text ) : string
RemoveWhitespace ( this value ) : string
RemoveWhitespaceWith ( this value, string replaceValue ) : string
StripHTML ( this htmlString ) : string
StripYear ( this title, int year ) : string

Strips the title of a year if it exists

SurroundWith ( this text, string ends ) : string
SurroundWithDoubleQuotes ( this text ) : string
ToCountryName ( this twoLetterCode ) : string
ToInt ( this number ) : int
ToLogString ( this text ) : string
ToNullIfEmpty ( this text ) : string
ToNullableInt32 ( this text ) : int?
ToSlug ( this phrase ) : string
Truncate ( this value, int maxChars ) : string

Method Details

IsNumber() public static method

public static IsNumber ( this number ) : bool
number this
return bool

RemapHighOrderChars() public static method

public static RemapHighOrderChars ( this input ) : string
input this
return string

RemoveDiacritics() public static method

public static RemoveDiacritics ( this text ) : string
text this
return string

RemoveWhitespace() public static method

public static RemoveWhitespace ( this value ) : string
value this
return string

RemoveWhitespaceWith() public static method

public static RemoveWhitespaceWith ( this value, string replaceValue ) : string
value this
replaceValue string
return string

StripHTML() public static method

public static StripHTML ( this htmlString ) : string
htmlString this
return string

StripYear() public static method

Strips the title of a year if it exists
public static StripYear ( this title, int year ) : string
title this
year int
return string

SurroundWith() public static method

public static SurroundWith ( this text, string ends ) : string
text this
ends string
return string

SurroundWithDoubleQuotes() public static method

public static SurroundWithDoubleQuotes ( this text ) : string
text this
return string

ToCountryName() public static method

public static ToCountryName ( this twoLetterCode ) : string
twoLetterCode this
return string

ToInt() public static method

public static ToInt ( this number ) : int
number this
return int

ToLogString() public static method

public static ToLogString ( this text ) : string
text this
return string

ToNullIfEmpty() public static method

public static ToNullIfEmpty ( this text ) : string
text this
return string

ToNullableInt32() public static method

public static ToNullableInt32 ( this text ) : int?
text this
return int?

ToSlug() public static method

public static ToSlug ( this phrase ) : string
phrase this
return string

Truncate() public static method

public static Truncate ( this value, int maxChars ) : string
value this
maxChars int
return string