-Explicit enum values

This commit is contained in:
James Newton-King
2014-12-02 00:43:01 +13:00
parent 4a19ecd940
commit 209c10ddde
23 changed files with 181 additions and 181 deletions
+50 -50
View File
@@ -46,52 +46,52 @@ namespace Newtonsoft.Json.Utilities
{
internal enum PrimitiveTypeCode
{
Empty,
Object,
Char,
CharNullable,
Boolean,
BooleanNullable,
SByte,
SByteNullable,
Int16,
Int16Nullable,
UInt16,
UInt16Nullable,
Int32,
Int32Nullable,
Byte,
ByteNullable,
UInt32,
UInt32Nullable,
Int64,
Int64Nullable,
UInt64,
UInt64Nullable,
Single,
SingleNullable,
Double,
DoubleNullable,
DateTime,
DateTimeNullable,
Empty = 0,
Object = 1,
Char = 2,
CharNullable = 3,
Boolean = 4,
BooleanNullable = 5,
SByte = 6,
SByteNullable = 7,
Int16 = 8,
Int16Nullable = 9,
UInt16 = 10,
UInt16Nullable = 11,
Int32 = 12,
Int32Nullable = 13,
Byte = 14,
ByteNullable = 15,
UInt32 = 16,
UInt32Nullable = 17,
Int64 = 18,
Int64Nullable = 19,
UInt64 = 20,
UInt64Nullable = 21,
Single = 22,
SingleNullable = 23,
Double = 24,
DoubleNullable = 25,
DateTime = 26,
DateTimeNullable = 27,
#if !NET20
DateTimeOffset,
DateTimeOffsetNullable,
DateTimeOffset = 28,
DateTimeOffsetNullable = 29,
#endif
Decimal,
DecimalNullable,
Guid,
GuidNullable,
TimeSpan,
TimeSpanNullable,
Decimal = 30,
DecimalNullable = 31,
Guid = 32,
GuidNullable = 33,
TimeSpan = 34,
TimeSpanNullable = 35,
#if !(PORTABLE || NET35 || NET20)
BigInteger,
BigIntegerNullable,
BigInteger = 36,
BigIntegerNullable = 37,
#endif
Uri,
String,
Bytes,
DBNull
Uri = 38,
String = 39,
Bytes = 40,
DBNull = 41
}
internal class TypeInformation
@@ -102,10 +102,10 @@ namespace Newtonsoft.Json.Utilities
internal enum ParseResult
{
None,
Success,
Overflow,
Invalid
None = 0,
Success = 1,
Overflow = 2,
Invalid = 3
}
internal static class ConvertUtils
@@ -360,10 +360,10 @@ namespace Newtonsoft.Json.Utilities
#region TryConvert
internal enum ConvertResult
{
Success,
CannotConvertNull,
NotInstantiableType,
NoValidConversion
Success = 0,
CannotConvertNull = 1,
NotInstantiableType = 2,
NoValidConversion = 3
}
public static object Convert(object initialValue, CultureInfo culture, Type targetType)