C# Class ImageProcessor.Common.Extensions.IntegerExtensions

Encapsulates a series of time saving extension methods to the T:System.Int32 class.
Show file Open project: JimBobSquarePants/ImageProcessor

Public Methods

Method Description
ParseInvariant ( this value, string toParse ) : int

Converts the string representation of a number in a specified culture-specific format to its 32-bit signed integer equivalent using invariant culture.

ToByte ( this value ) : byte

Converts an T:System.Int32 value into a valid T:System.Byte. If the value given is less than 0 or greater than 255, the value will be constrained into those restricted ranges.

Method Details

ParseInvariant() public static method

Converts the string representation of a number in a specified culture-specific format to its 32-bit signed integer equivalent using invariant culture.
public static ParseInvariant ( this value, string toParse ) : int
value this The integer.
toParse string A string containing a number to convert.
return int

ToByte() public static method

Converts an T:System.Int32 value into a valid T:System.Byte. If the value given is less than 0 or greater than 255, the value will be constrained into those restricted ranges.
public static ToByte ( this value ) : byte
value this /// The to convert. ///
return byte