Click or drag to resize

BinarySize Structure

Provides formatting, parsing and scaling for a value using binary units (e.g. MB).

Namespace:  Ookii.Jumbo
Assembly:  Ookii.Jumbo (in Ookii.Jumbo.dll) Version: 2.0.0
Syntax
[TypeConverterAttribute(typeof(BinarySizeConverter))]
public struct BinarySize : IEquatable<BinarySize>, 
	IComparable<BinarySize>, IComparable, IFormattable, IConvertible

The BinarySize type exposes the following members.

Constructors
  NameDescription
Public methodBinarySize(Int32)
Initializes a new instance of the BinarySize structure with the specified value.
Public methodBinarySize(Int64)
Initializes a new instance of the BinarySize structure with the specified value.
Public methodBinarySize(UInt32)
Initializes a new instance of the BinarySize structure with the specified value.
Public methodBinarySize(UInt64)
Initializes a new instance of the BinarySize structure with the specified value.
Top
Properties
  NameDescription
Public propertyInGigabytes
Gets the value of this instance in gigabytes.
Public propertyInKilobytes
Gets the value of this instance in kilobytes.
Public propertyInMegabytes
Gets the value of this instance in megabytes.
Public propertyInPetabytes
Gets the value of this instance in petabytes.
Public propertyInTerabytes
Gets the value of this instance in terabytes.
Public propertyValue
Gets the value of this instance, in bytes.
Public propertyStatic memberZero
Gets a zero-valued BinarySize instance.
Top
Methods
  NameDescription
Public methodAdd
Returns a new BinarySize object whose value is the sum of the specified BinarySize object and this instance.
Public methodCompareTo(BinarySize)
Compares this instance to a specified BinarySize and returns an indication of their relative values.
Public methodCompareTo(Object)
Compares this instance to a specified object and returns an indication of their relative values.
Public methodDivide
Returns a new BinarySize object whose value is the division of the specified Int64 object and this instance.
Public methodEquals(BinarySize)
Returns a value indicating whether this instance is equal to a specified BinarySize value.
Public methodEquals(Object)
Returns a value indicating whether this instance is equal to a specified object.
(Overrides ValueTypeEquals(Object).)
Public methodGetHashCode
Returns the hash code for this BinarySize.
(Overrides ValueTypeGetHashCode.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodMultiply
Returns a new BinarySize object whose value is the product of the specified Int64 object and this instance.
Public methodNegate
Returns a new BinarySize object whose value is the negation of this instance.
Public methodStatic memberParse(String)
Converts the string representation of a byte size into a BinarySize structure.
Public methodStatic memberParse(String, IFormatProvider)
Converts the string representation of a byte size in a specified culture-specific format into a BinarySize structure.
Public methodSubtract
Returns a new BinarySize object whose value is the difference of the specified BinarySize object and this instance.
Public methodToByte
Performs an explicit conversion from BinarySize to Byte.
Public methodToDecimal
Performs an explicit conversion from BinarySize to Decimal.
Public methodToDouble
Performs an explicit conversion from BinarySize to Double.
Public methodToInt16
Performs an explicit conversion from BinarySize to Int16.
Public methodToInt32
Performs an explicit conversion from BinarySize to Int32.
Public methodToInt64
Performs an explicit conversion from BinarySize to Int64.
Public methodToSByte
Performs an explicit conversion from BinarySize to SByte.
Public methodToSingle
Performs an explicit conversion from BinarySize to Single.
Public methodToString
Returns a String that represents this instance.
(Overrides ValueTypeToString.)
Public methodToString(IFormatProvider)
Returns a String that represents this instance.
Public methodToString(String)
Returns a String that represents this instance.
Public methodToString(String, IFormatProvider)
Returns a String that represents this instance.
Public methodToUInt16
Performs an explicit conversion from BinarySize to UInt16.
Public methodToUInt32
Performs an explicit conversion from BinarySize to UInt32.
Public methodToUInt64
Performs an explicit conversion from BinarySize to UInt64.
Top
Operators
  NameDescription
Public operatorStatic memberAddition
Implements the operator +.
Public operatorStatic memberDivision
Implements the operator /.
Public operatorStatic memberEquality
Determines whether two specified BinarySize values are the same.
Public operatorStatic member(BinarySize to Byte)
Performs an explicit conversion from BinarySize to Byte.
Public operatorStatic member(BinarySize to Decimal)
Performs an explicit conversion from BinarySize to Decimal.
Public operatorStatic member(BinarySize to Double)
Performs an explicit conversion from BinarySize to Double.
Public operatorStatic member(BinarySize to Int16)
Performs an explicit conversion from BinarySize to Int16.
Public operatorStatic member(BinarySize to Int32)
Performs an explicit conversion from BinarySize to Int32.
Public operatorStatic member(BinarySize to Int64)
Performs an explicit conversion from BinarySize to Int16.
Public operatorStatic member(BinarySize to SByte)
Performs an explicit conversion from BinarySize to SByte.
Public operatorStatic member(BinarySize to Single)
Performs an explicit conversion from BinarySize to Single.
Public operatorStatic member(BinarySize to UInt16)
Performs an explicit conversion from BinarySize to UInt16.
Public operatorStatic member(BinarySize to UInt32)
Performs an explicit conversion from BinarySize to UInt32.
Public operatorStatic member(BinarySize to UInt64)
Performs an explicit conversion from BinarySize to UInt64.
Public operatorStatic memberGreaterThan
Returns a value indicating whether a specified BinarySize is greater than another BinarySize.
Public operatorStatic memberGreaterThanOrEqual
Returns a value indicating whether a specified BinarySize is greater than or equal to another BinarySize.
Public operatorStatic member(Byte to BinarySize)
Performs an implicit conversion from Byte to BinarySize.
Public operatorStatic member(Decimal to BinarySize)
Performs an implicit conversion from Decimal to BinarySize.
Public operatorStatic member(Double to BinarySize)
Performs an implicit conversion from Double to BinarySize.
Public operatorStatic member(Int16 to BinarySize)
Performs an implicit conversion from Int16 to BinarySize.
Public operatorStatic member(Int32 to BinarySize)
Performs an implicit conversion from Int32 to BinarySize.
Public operatorStatic member(Int64 to BinarySize)
Performs an implicit conversion from Int64 to BinarySize.
Public operatorStatic member(SByte to BinarySize)
Performs an implicit conversion from SByte to BinarySize.
Public operatorStatic member(Single to BinarySize)
Performs an implicit conversion from Single to BinarySize.
Public operatorStatic member(UInt16 to BinarySize)
Performs an implicit conversion from UInt16 to BinarySize.
Public operatorStatic member(UInt32 to BinarySize)
Performs an implicit conversion from UInt32 to BinarySize.
Public operatorStatic member(UInt64 to BinarySize)
Performs an implicit conversion from UInt64 to BinarySize.
Public operatorStatic memberInequality
Determines whether two specified BinarySize values are different.
Public operatorStatic memberLessThan
Returns a value indicating whether a specified BinarySize is less than another BinarySize.
Public operatorStatic memberLessThanOrEqual
Returns a value indicating whether a specified BinarySize is less than or equal to another BinarySize.
Public operatorStatic memberMultiply
Implements the operator *.
Public operatorStatic memberSubtraction
Implements the operator -.
Public operatorStatic memberUnaryNegation
Implements the unary operator -.
Top
Fields
  NameDescription
Public fieldStatic memberByte
The size of a byte, 1 byte.
Public fieldStatic memberGigabyte
The size of a gigabyte, 1073741824 bytes.
Public fieldStatic memberKilobyte
The size of a kilobyte, 1024 bytes.
Public fieldStatic memberMegabyte
The size of a megabyte, 1048576 bytes.
Public fieldStatic memberPetabyte
The size of a PetaByte, 1125899906842624 bytes.
Public fieldStatic memberTerabyte
The size of a TeraByte, 1099511627776 bytes.
Top
See Also