C# Class Nyan.Core.Factories.ShortGuid

Afficher le fichier Open project: bucknellu/Nyan

Méthodes publiques

Свойство Type Description
Empty ShortGuid

Méthodes publiques

Méthode Description
Decode ( string value ) : System.Guid

Decodes the given base64 string

Encode ( System.Guid guid ) : string

Encodes the given Guid as a base64 string that is 22 characters long.

Encode ( string value ) : string

Creates a new instance of a Guid using the string value, then returns the base64 encoded version of the Guid.

Equals ( object obj ) : bool

Returns a value indicating whether this instance and a specified Object represent the same type and value.

GetHashCode ( ) : int

Returns the HashCode for underlying Guid.

NewGuid ( ) : ShortGuid

Initialises a new instance of the ShortGuid class

ShortGuid ( System.Guid guid ) : System

Creates a ShortGuid from a Guid

ShortGuid ( string value ) : System

Creates a ShortGuid from a base64 encoded string

ToString ( ) : string

Returns the base64 encoded guid as a string

operator ( ) : bool

Determines if both ShortGuids do not have the same underlying Guid value.

Method Details

Decode() public static méthode

Decodes the given base64 string
public static Decode ( string value ) : System.Guid
value string The base64 encoded string of a Guid
Résultat System.Guid

Encode() public static méthode

Encodes the given Guid as a base64 string that is 22 characters long.
public static Encode ( System.Guid guid ) : string
guid System.Guid The Guid to encode
Résultat string

Encode() public static méthode

Creates a new instance of a Guid using the string value, then returns the base64 encoded version of the Guid.
public static Encode ( string value ) : string
value string An actual Guid string (i.e. not a ShortGuid)
Résultat string

Equals() public méthode

Returns a value indicating whether this instance and a specified Object represent the same type and value.
public Equals ( object obj ) : bool
obj object The object to compare
Résultat bool

GetHashCode() public méthode

Returns the HashCode for underlying Guid.
public GetHashCode ( ) : int
Résultat int

NewGuid() public static méthode

Initialises a new instance of the ShortGuid class
public static NewGuid ( ) : ShortGuid
Résultat ShortGuid

ShortGuid() public méthode

Creates a ShortGuid from a Guid
public ShortGuid ( System.Guid guid ) : System
guid System.Guid The Guid to encode
Résultat System

ShortGuid() public méthode

Creates a ShortGuid from a base64 encoded string
public ShortGuid ( string value ) : System
value string The encoded guid as a /// base64 string
Résultat System

ToString() public méthode

Returns the base64 encoded guid as a string
public ToString ( ) : string
Résultat string

operator() public static méthode

Determines if both ShortGuids do not have the same underlying Guid value.
public static operator ( ) : bool
Résultat bool

Property Details

Empty public_oe static_oe property

A read-only instance of the ShortGuid class whose value is guaranteed to be all zeroes.
public static ShortGuid,Nyan.Core.Factories Empty
Résultat ShortGuid