struct Guid
Represents a globally unique identifier (GUID).
public Guid( byte[] b )
Initializes a new instance of the structure by using the specified array of bytes.
bA 16-element byte array containing values with which to initialize the GUID.
public Guid( int a, short b, short c, byte d, byte e, byte f, byte g, byte h, byte i, byte j, byte k )
Initializes a new instance of the structure by using the specified integers and bytes.
aThe first 4 bytes of the GUID.bThe next 2 bytes of the GUID.cThe next 2 bytes of the GUID.dThe next byte of the GUID.eThe next byte of the GUID.fThe next byte of the GUID.gThe next byte of the GUID.hThe next byte of the GUID.iThe next byte of the GUID.jThe next byte of the GUID.kThe next byte of the GUID.
public Guid( int a, short b, short c, byte[] d )
Initializes a new instance of the structure by using the specified integers and byte array.
aThe first 4 bytes of the GUID.bThe next 2 bytes of the GUID.cThe next 2 bytes of the GUID.dThe remaining 8 bytes of the GUID.
public Guid( string g )
Initializes a new instance of the structure by using the value represented by the specified string.
gA string that contains a GUID in one of the following formats ("d" represents a hexadecimal digit whose case is ignored): 32 contiguous digits: dddddddddddddddddddddddddddddddd -or- Groups of 8, 4, 4, 4, and 12 digits with hyphens between the groups. The entire GUID can optionally be enclosed in matching braces or parentheses: dddddddd-dddd-dddd-dddd-dddddddddddd -or- {dddddddd-dddd-dddd-dddd-dddddddddddd} -or- (dddddddd-dddd-dddd-dddd-dddddddddddd) -or- Groups of 8, 4, and 4 digits, and a subset of eight groups of 2 digits, with each group prefixed by "0x" or "0X", and separated by commas. The entire GUID, as well as the subset, is enclosed in matching braces: {0xdddddddd, 0xdddd, 0xdddd,{0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,0xdd,0xdd}} All braces, commas, and "0x" prefixes are required. All embedded spaces are ignored. All leading zeros in a group are ignored. The digits shown in a group are the maximum number of meaningful digits that can appear in that group. You can specify from 1 to the number of digits shown for a group. The specified digits are assumed to be the low-order digits of the group.
public int CompareTo( Guid value )
Compares this instance to a specified object and returns an indication of their relative values.
valueAn object to compare to this instance.- Returns A signed number indicating the relative values of this instance and . Return value Description A negative integer This instance is less than . Zero This instance is equal to . A positive integer This instance is greater than .
public int CompareTo( object value )
Compares this instance to a specified object and returns an indication of their relative values.
valueAn object to compare, or .- Returns A signed number indicating the relative values of this instance and . Return value Description A negative integer This instance is less than . Zero This instance is equal to . A positive integer This instance is greater than , or is .
public static Guid Empty
A read-only instance of the structure whose value is all zeros.
public bool Equals( Guid g )
Returns a value indicating whether this instance and a specified object represent the same value.
gAn object to compare to this instance.- Returns if is equal to this instance; otherwise, .
public bool Equals( object o )
Returns a value that indicates whether this instance is equal to a specified object.
oThe object to compare with this instance.- Returns if is a that has the same value as this instance; otherwise, .
public static bool op_Equality( Guid a, Guid b )
Indicates whether the values of two specified objects are equal.
aThe first object to compare.bThe second object to compare.- Returns if and are equal; otherwise, .
public static bool op_Inequality( Guid a, Guid b )
Indicates whether the values of two specified objects are not equal.
aThe first object to compare.bThe second object to compare.- Returns if and are not equal; otherwise, .
public static Guid Parse( string input )
Converts the string representation of a GUID to the equivalent structure.
inputThe string to convert.- Returns A structure that contains the value that was parsed.
public static Guid ParseExact( string input, string format )
Converts the string representation of a GUID to the equivalent structure, provided that the string is in the specified format.
inputThe GUID to convert.formatOne of the following specifiers that indicates the exact format to use when interpreting : "N", "D", "B", "P", or "X".- Returns A structure that contains the value that was parsed.
public string ToString( string format )
Returns a string representation of the value of this instance, according to the provided format specifier.
formatA single format specifier that indicates how to format the value of this . The parameter can be "N", "D", "B", "P", or "X". If is or an empty string (""), "D" is used.- Returns The value of this , represented as a series of lowercase hexadecimal digits in the specified format.
public string ToString( string format, IFormatProvider provider )
Returns a string representation of the value of this instance of the class, according to the provided format specifier and culture-specific format information.
formatA single format specifier that indicates how to format the value of this . The parameter can be "N", "D", "B", "P", or "X". If is or an empty string (""), "D" is used.provider(Reserved) An object that supplies culture-specific formatting information.- Returns The value of this , represented as a series of lowercase hexadecimal digits in the specified format.
public static bool TryParse( string input, ref Guid result )
Converts the string representation of a GUID to the equivalent structure.
inputThe GUID to convert.resultThe structure that will contain the parsed value. If the method returns , contains a valid . If the method returns , equals .- Returns if the parse operation was successful; otherwise, .
public static bool TryParseExact( string input, string format, ref Guid result )
Converts the string representation of a GUID to the equivalent structure, provided that the string is in the specified format.
inputThe GUID to convert.formatOne of the following specifiers that indicates the exact format to use when interpreting : "N", "D", "B", "P", or "X".resultThe structure that will contain the parsed value. If the method returns , contains a valid . If the method returns , equals .- Returns if the parse operation was successful; otherwise, .
public static Guid CreateVersion7( )
😔 No documentation found.
public Guid( ReadOnlySpan<byte> b, bool bigEndian )
😔 No documentation found.
public Type GetType( )
😔 No documentation found.
public static bool op_GreaterThanOrEqual( Guid left, Guid right )
😔 No documentation found.
public static Guid NewGuid( )
😔 No documentation found.
public Guid( uint a, ushort b, ushort c, byte d, byte e, byte f, byte g, byte h, byte i, byte j, byte k )
😔 No documentation found.
public static bool TryParse( ReadOnlySpan<char> s, IFormatProvider provider, ref Guid result )
😔 No documentation found.
public static Guid Parse( ReadOnlySpan<char> s, IFormatProvider provider )
😔 No documentation found.
public int Version { get; }
😔 No documentation found.
public int Variant { get; }
😔 No documentation found.
public static bool TryParse( string s, IFormatProvider provider, ref Guid result )
😔 No documentation found.
public static Guid Parse( string s, IFormatProvider provider )
😔 No documentation found.
public Guid( ReadOnlySpan<byte> b )
😔 No documentation found.
public static bool op_GreaterThan( Guid left, Guid right )
😔 No documentation found.
public static Guid AllBitsSet { get; }
😔 No documentation found.
public static bool op_LessThan( Guid left, Guid right )
😔 No documentation found.
public static Guid ParseExact( ReadOnlySpan<char> input, ReadOnlySpan<char> format )
😔 No documentation found.
public bool TryFormat( Span<char> destination, ref int charsWritten, ReadOnlySpan<char> format = null )
😔 No documentation found.
public string ToString( )
😔 No documentation found.
public static Guid CreateVersion7( DateTimeOffset timestamp )
😔 No documentation found.
public static Guid Parse( ReadOnlySpan<char> input )
😔 No documentation found.
public static bool TryParse( ReadOnlySpan<char> input, ref Guid result )
😔 No documentation found.
public int GetHashCode( )
😔 No documentation found.
public bool TryWriteBytes( Span<byte> destination, bool bigEndian, ref int bytesWritten )
😔 No documentation found.
public bool TryWriteBytes( Span<byte> destination )
😔 No documentation found.
public byte[] ToByteArray( bool bigEndian )
😔 No documentation found.
public byte[] ToByteArray( )
😔 No documentation found.
public static bool TryParseExact( ReadOnlySpan<char> input, ReadOnlySpan<char> format, ref Guid result )
😔 No documentation found.
public static bool op_LessThanOrEqual( Guid left, Guid right )
😔 No documentation found.
public bool TryFormat( Span<byte> utf8Destination, ref int bytesWritten, ReadOnlySpan<char> format = null )
😔 No documentation found.