671 references to Enum
ComSvcConfig (2)
mscorlib (144)
system\runtime\remoting\lease.cs (13)
110throw new RemotingException(Environment.GetResourceString("Remoting_Lifetime_InitialStateRenewOnCall", ((Enum)state).ToString()));
128throw new RemotingException(Environment.GetResourceString("Remoting_Lifetime_InitialStateSponsorshipTimeout", ((Enum)state).ToString()));
146BCLDebug.Trace("REMOTE", "Lease Set InitialLeaseTime Property ",managedObject," "+InitialLeaseTime+", current state "+((Enum)state).ToString());
149throw new RemotingException(Environment.GetResourceString("Remoting_Lifetime_InitialStateInitialLeaseTime", ((Enum)state).ToString()));
179BCLDebug.Trace("REMOTE", "Lease "+id+" Register Sponsor renewalTime ",renewalTime," state ",((Enum)state).ToString());
203BCLDebug.Trace("REMOTE", "Lease",id," Unregister state ",((Enum)state).ToString());
261BCLDebug.Trace("REMOTE","Lease ",id," Renew ",renewalTime," state ",((Enum)state).ToString());
272BCLDebug.Trace("REMOTE","Lease ",id," Remove state ",((Enum)state).ToString());
284BCLDebug.Trace("REMOTE","Lease ",id," Cancel Managed Object ",managedObject," state ",((Enum)state).ToString());
326BCLDebug.Trace("REMOTE","Lease ",id," LeaseExpired state ",((Enum)state).ToString());
347BCLDebug.Trace("REMOTE","Lease ",id," SponsorCall state ",((Enum)state).ToString());
401BCLDebug.Trace("REMOTE","Lease ",id," SponsorTimeout sponsorState ",((Enum)sponsorStateInfo.sponsorState).ToString());
464BCLDebug.Trace("REMOTE","Lease ",id," SponsorCallback IAsyncResult ",iar," state ",((Enum)state).ToString());
system\runtime\serialization\formatters\binary\binarycommonclasses.cs (20)
99SerTrace.Log( "BinaryConverter", "GetBinaryTypeInfo Exit ",((Enum)binaryTypeEnum).ToString(),", typeInformation ",typeInformation," assemId ",assemId);
141SerTrace.Log( "BinaryConverter", "GetParserBinaryTypeInfo Exit ",((Enum)binaryTypeEnum).ToString(),", typeInformation ",typeInformation);
148SerTrace.Log( "BinaryConverter", "WriteTypeInfo Entry ",((Enum)binaryTypeEnum).ToString()," ",typeInformation," assemId ",assemId);
172throw new SerializationException(Environment.GetResourceString("Serialization_TypeWrite",((Enum)binaryTypeEnum).ToString()));
180SerTrace.Log( "BinaryConverter", "ReadTypeInfo Entry ",((Enum)binaryTypeEnum).ToString());
203throw new SerializationException(Environment.GetResourceString("Serialization_TypeRead",((Enum)binaryTypeEnum).ToString()));
221SerTrace.Log( "BinaryConverter", "TypeFromInfo Entry ",((Enum)binaryTypeEnum).ToString());
268throw new SerializationException(Environment.GetResourceString("Serialization_TypeRead",((Enum)binaryTypeEnum).ToString()));
485BinaryUtil.NVTraceI("binaryHeaderEnum (Byte)", ((Enum)binaryHeaderEnum).ToString());
873BinaryUtil.NVTraceI("messageEnum (Int32)", ((Enum)messageEnum).ToString());
1153BinaryUtil.NVTraceI("messageEnum (Int32)", ((Enum)messageEnum).ToString());
1324SerTrace.Log(this, "MemberPrimitiveTyped Set ",((Enum)primitiveTypeEnum).ToString()," ",value);
1356BinaryUtil.NVTraceI("primitiveTypeEnum (Byte)", ((Enum)primitiveTypeEnum).ToString());
1444BinaryUtil.NVTraceI("binaryHeaderEnum (Byte)", ((Enum)binaryHeaderEnum).ToString());
1633SerTrace.Log( this, "BinaryArray Constructor 2 ", ((Enum)binaryHeaderEnum).ToString());
1640SerTrace.Log( this, "BinaryArray Set objectId ",objectId," rank ",rank," ",((Enum)binaryTypeEnum).ToString(),", assemId ",assemId);
1660SerTrace.Log( this, "BinaryArray Set Exit ",((Enum)binaryHeaderEnum).ToString());
1923BinaryUtil.NVTraceI("binaryHeaderEnum (Byte)", ((Enum)BinaryHeaderEnum.MemberReference).ToString());
2299SerTrace.Log( this, "GetNext Array Exit ",((Enum)outBinaryTypeEnum).ToString()," ",outTypeInformation);
2322SerTrace.Log( this, "GetNext Member Exit ",((Enum)outBinaryTypeEnum).ToString()," ",outTypeInformation," memberName ",name);
system\runtime\serialization\formatters\binary\binaryconverter.cs (7)
59SerTrace.Log("Converter", "ToCode Exit " , ((Enum)code).ToString());
139SerTrace.Log("Converter", "GetNameSpaceEnum Entry ",((Enum)code).ToString()," type ",type);
197SerTrace.Log("Converter", "GetNameSpaceEnum Exit ", ((Enum)nameSpaceEnum).ToString()," typeName ",typeName);
205SerTrace.Log("Converter", "ToType Entry ", ((Enum)code).ToString());
267SerTrace.Log("Converter", "ToType Entry ", ((Enum)code).ToString());
394SerTrace.Log("Converter", "ToComType Entry ", ((Enum)code).ToString());
478SerTrace.Log( "Converter", "FromString Entry ",value," " , ((Enum)code).ToString());
system\runtime\serialization\formatters\binary\binaryformatterwriter.cs (3)
302,memberNames[i],", memberType ",memberTypes[i]," binaryTypeEnum ",((Enum)binaryTypeEnumA[i]).ToString()
718SerTrace.Log( this, "WriteValue Entry ",((Enum)code).ToString()," " , ((value==null)?"<null>":value.GetType().ToString()) , " ",value);
768throw new SerializationException(Environment.GetResourceString("Serialization_TypeCode",((Enum)code).ToString()));
system\runtime\serialization\formatters\binary\binaryparser.cs (12)
114SerTrace.Log( this, "Run loop ",((Enum)expectedType).ToString());
218SerTrace.Log( this, "Run loop opName ",op.name,", expectedType ",((Enum)expectedType).ToString()," expectedTypeInformation, ",expectedTypeInformation);
494throw new SerializationException(Environment.GetResourceString("Serialization_Map",((Enum)objectOp.objectTypeEnum).ToString()));
625throw new SerializationException(Environment.GetResourceString("Serialization_ObjectTypeEnum",((Enum)objectOp.objectTypeEnum).ToString()));
720throw new SerializationException(Environment.GetResourceString("Serialization_ObjectTypeEnum",((Enum)objectOp.objectTypeEnum).ToString()));
807throw new SerializationException(Environment.GetResourceString("Serialization_ObjectTypeEnum",((Enum)objectOp.objectTypeEnum).ToString()));
864throw new SerializationException(Environment.GetResourceString("Serialization_ObjectTypeEnum",((Enum)objectOp.objectTypeEnum).ToString()));
931throw new SerializationException(Environment.GetResourceString("Serialization_ObjectTypeEnum",((Enum)objectOp.objectTypeEnum).ToString()));
985throw new SerializationException(Environment.GetResourceString("Serialization_ArrayType",((Enum)record.binaryArrayTypeEnum).ToString()));
995SerTrace.Log( this, "ReadArray ",((Enum)record.binaryArrayTypeEnum).ToString()," length ",op.numItems);
1179SerTrace.Log( this, "ReadValue ",((Enum)code).ToString());
1230throw new SerializationException(Environment.GetResourceString("Serialization_TypeCode",((Enum)code).ToString()));
PresentationBuildTasks (2)
PresentationCore (9)
PresentationFramework (13)
System (65)
compmod\system\componentmodel\EnumConverter.cs (31)
23/// <para>Provides a type converter to convert <see cref='System.Enum'/>
84if (sourceType == typeof(string) || sourceType == typeof(Enum[])) {
95if (destinationType == typeof(InstanceDescriptor) || destinationType == typeof(Enum[])) {
124convertedValue |= Convert.ToInt64((Enum)Enum.Parse(type, v, true), culture);
126return Enum.ToObject(type, convertedValue);
129return Enum.Parse(type, strValue, true);
136else if (value is Enum[]) {
138foreach(Enum e in (Enum[])value) {
141return Enum.ToObject(type, finalValue);
162Type underlyingType = Enum.GetUnderlyingType(type);
166if (!type.IsDefined(typeof(FlagsAttribute), false) && !Enum.IsDefined(type, value)) {
170return Enum.Format(type, value, "G");
181Type underlyingType = Enum.GetUnderlyingType(type);
185MethodInfo method = typeof(Enum).GetMethod("ToObject", new Type[] {typeof(Type), underlyingType});
198if (destinationType == typeof(Enum[]) && value != null) {
200List<Enum> flagValues = new List<Enum>();
202Array objValues = Enum.GetValues(type);
205ulValues[idx] = Convert.ToInt64((Enum)objValues.GetValue(idx), culture);
208long longValue = Convert.ToInt64((Enum)value, culture);
214flagValues.Add((Enum)Enum.ToObject(type, ul));
227flagValues.Add((Enum)Enum.ToObject(type, longValue));
233return new Enum[] {(Enum)Enum.ToObject(type, value)};
275value = Enum.Parse(type, field.Name);
327return Enum.IsDefined(type, value);
misc\ClientUtils.cs (5)
68public static bool IsEnumValid(Enum enumValue, int value, int minValue, int maxValue)
85public static bool IsEnumValid(Enum enumValue, int value, int minValue, int maxValue, int maxNumberOfBitsOn) {
105public static bool IsEnumValid_Masked(Enum enumValue, int value, UInt32 mask) {
133public static bool IsEnumValid_NotSequential(System.Enum enumValue, int value, params int[] enumValues) {
134System.Diagnostics.Debug.Assert(Enum.GetValues(enumValue.GetType()).Length == enumValues.Length, "Not all the enum members were passed in.");
System.Activities (2)
System.Activities.Core.Presentation (1)
System.Activities.Presentation (7)
System.ComponentModel.DataAnnotations (6)
System.Configuration (3)
System.Core (7)
System.Data (36)
fx\src\data\System\Data\Common\DbConnectionStringCommon.cs (11)
333Debug.Assert(Enum.GetNames(typeof(PoolBlockingPeriod)).Length == 3, "PoolBlockingPeriod enum has changed, update needed");
360Debug.Assert(Enum.GetNames(typeof(PoolBlockingPeriod)).Length == 3, "PoolBlockingPeriod enum has changed, update needed");
440eValue = (PoolBlockingPeriod)Enum.ToObject(typeof(PoolBlockingPeriod), value);
468Debug.Assert(Enum.GetNames(typeof(ApplicationIntent)).Length == 2, "ApplicationIntent enum has changed, update needed");
490Debug.Assert(Enum.GetNames(typeof(ApplicationIntent)).Length == 2, "ApplicationIntent enum has changed, update needed");
565eValue = (ApplicationIntent)Enum.ToObject(typeof(ApplicationIntent), value);
594Debug.Assert(Enum.GetNames(typeof(SqlAuthenticationMethod)).Length == 5, "SqlAuthenticationMethod enum has changed, update needed");
660Debug.Assert(Enum.GetNames(typeof(SqlConnectionColumnEncryptionSetting)).Length == 2, "SqlConnectionColumnEncryptionSetting enum has changed, update needed");
684Debug.Assert(Enum.GetNames(typeof(SqlAuthenticationMethod)).Length == 5, "SqlAuthenticationMethod enum has changed, update needed");
759eValue = (SqlAuthenticationMethod)Enum.ToObject(typeof(SqlAuthenticationMethod), value);
825eValue = (SqlConnectionColumnEncryptionSetting)Enum.ToObject(typeof(SqlConnectionColumnEncryptionSetting), value);
System.Data.Entity (40)
System\Data\Query\PlanCompiler\CTreeGenerator.cs (4)
634PlanCompiler.Assert(retExpr != null, string.Format(CultureInfo.InvariantCulture, "Unresolvable Var used in Command: VarType={0}, Id={1}", Enum.GetName(typeof(VarType), referencedVar.VarType), referencedVar.Id));
789PlanCompiler.Assert(resultExpr != null, string.Format(CultureInfo.InvariantCulture, "ArithmeticOp OpType not recognized: {0}", Enum.GetName(typeof(OpType), op.OpType)));
897PlanCompiler.Assert(compExpr != null, string.Format(CultureInfo.InvariantCulture, "ComparisonOp OpType not recognized: {0}", Enum.GetName(typeof(OpType), op.OpType)));
956PlanCompiler.Assert(condExpr != null, string.Format(CultureInfo.InvariantCulture, "ConditionalOp OpType not recognized: {0}", Enum.GetName(typeof(OpType), op.OpType)));
System\Data\SqlClient\SqlGen\SqlGenerator.cs (6)
1092throw EntityUtil.NotSupported(System.Data.Entity.Strings.SqlGen_TypedNaNNotSupported(Enum.GetName(typeof(PrimitiveTypeKind), PrimitiveTypeKind.Double)));
1096throw EntityUtil.NotSupported(System.Data.Entity.Strings.SqlGen_TypedPositiveInfinityNotSupported(Enum.GetName(typeof(PrimitiveTypeKind), PrimitiveTypeKind.Double), typeof(Double).Name));
1100throw EntityUtil.NotSupported(System.Data.Entity.Strings.SqlGen_TypedNegativeInfinityNotSupported(Enum.GetName(typeof(PrimitiveTypeKind), PrimitiveTypeKind.Double), typeof(Double).Name));
1113throw EntityUtil.NotSupported(System.Data.Entity.Strings.SqlGen_TypedNaNNotSupported(Enum.GetName(typeof(PrimitiveTypeKind), PrimitiveTypeKind.Single)));
1117throw EntityUtil.NotSupported(System.Data.Entity.Strings.SqlGen_TypedPositiveInfinityNotSupported(Enum.GetName(typeof(PrimitiveTypeKind), PrimitiveTypeKind.Single), typeof(Single).Name));
1121throw EntityUtil.NotSupported(System.Data.Entity.Strings.SqlGen_TypedNegativeInfinityNotSupported(Enum.GetName(typeof(PrimitiveTypeKind), PrimitiveTypeKind.Single), typeof(Single).Name));
System.Data.Entity.Design (1)
System.Data.Linq (12)
System.Data.Services (3)
System.Data.Services.Design (3)
System.Data.SqlXml (8)
System.Drawing (9)
misc\ClientUtils.cs (5)
68public static bool IsEnumValid(Enum enumValue, int value, int minValue, int maxValue)
85public static bool IsEnumValid(Enum enumValue, int value, int minValue, int maxValue, int maxNumberOfBitsOn) {
105public static bool IsEnumValid_Masked(Enum enumValue, int value, UInt32 mask) {
133public static bool IsEnumValid_NotSequential(System.Enum enumValue, int value, params int[] enumValues) {
134System.Diagnostics.Debug.Assert(Enum.GetValues(enumValue.GetType()).Length == enumValues.Length, "Not all the enum members were passed in.");
System.IdentityModel (2)
System.Management (1)
System.Messaging (5)
System.Runtime.Remoting (29)
System.Runtime.Serialization (12)
System.Security (1)
System.ServiceModel (31)
System\ServiceModel\ComIntegration\ChannelCredentials.cs (11)
108StoreLocation location = (StoreLocation)Enum.Parse(typeof(StoreLocation), storeLocation);
109X509RevocationMode mode = (X509RevocationMode)Enum.Parse(typeof(X509RevocationMode), revocationMode);
113validationMode = (X509CertificateValidationMode)Enum.Parse(typeof(X509CertificateValidationMode), certificationValidationMode);
132StoreLocation location = (StoreLocation)Enum.Parse(typeof(StoreLocation), storeLocation);
133StoreName name = (StoreName)Enum.Parse(typeof(StoreName), storeName);
134X509FindType type = (X509FindType)Enum.Parse(typeof(X509FindType), findType);
161X509KeyStorageFlags flags = (X509KeyStorageFlags)Enum.Parse(typeof(X509KeyStorageFlags), keyStorageFlags);
182StoreLocation location = (StoreLocation)Enum.Parse(typeof(StoreLocation), storeLocation);
183StoreName name = (StoreName)Enum.Parse(typeof(StoreName), storeName);
184X509FindType type = (X509FindType)Enum.Parse(typeof(X509FindType), findType);
210X509KeyStorageFlags flags = (X509KeyStorageFlags)Enum.Parse(typeof(X509KeyStorageFlags), keyStorageFlags);
System.ServiceModel.Internals (2)
System.ServiceModel.Web (5)
System.Web (22)
System.Web.DataVisualization (22)
Common\ChartTypes\FunnelChart.cs (6)
2119 labelStyle = (FunnelLabelStyle)Enum.Parse(typeof(FunnelLabelStyle), attrValue, true);
2496 drawingStyle = (FunnelStyle)Enum.Parse(typeof(FunnelStyle), attrValue, true);
2523 placement = (FunnelLabelPlacement)Enum.Parse(typeof(FunnelLabelPlacement), attrValue, true);
2549 alignment = (FunnelLabelVerticalAlignment)Enum.Parse(typeof(FunnelLabelVerticalAlignment), attrValue, true);
2576 drawingStyle = (Funnel3DDrawingStyle)Enum.Parse(typeof(Funnel3DDrawingStyle), attrValue, true);
2725 valueType = (PyramidValueType)Enum.Parse(typeof(PyramidValueType), attrValue, true);
System.Web.DynamicData (3)
System.Web.Entity (1)
System.Web.Extensions (8)
System.Web.Mobile (18)
System.Web.Services (9)
System\Web\Services\Description\SoapProtocolImporter.cs (3)
767AddMetadataProperty("Use", new CodeFieldReferenceExpression(new CodeTypeReferenceExpression(typeof(SoapBindingUse).FullName), Enum.Format(typeof(SoapBindingUse), soapRequestBinding.Use, "G")));
772AddMetadataProperty("Use", new CodeFieldReferenceExpression(new CodeTypeReferenceExpression(typeof(SoapBindingUse).FullName), Enum.Format(typeof(SoapBindingUse), soapRequestBinding.Use, "G")));
773AddMetadataProperty("ParameterStyle", new CodeFieldReferenceExpression(new CodeTypeReferenceExpression(typeof(SoapParameterStyle).FullName), Enum.Format(typeof(SoapParameterStyle), hasWrapper ? SoapParameterStyle.Wrapped : SoapParameterStyle.Bare, "G")));
System.Windows.Forms (33)
System.Windows.Forms.DataVisualization (21)
System.Workflow.Activities (13)
EventHandlingScope.cs (2)
250return new ValidationError(SR.GetString(SR.Error_DynamicActivity2, activity.QualifiedName, Enum.GetName(typeof(ActivityExecutionStatus), activity.ExecutionStatus), activity.GetType().FullName), ErrorNumbers.Error_DynamicActivity2);
254return new ValidationError(SR.GetString(SR.Error_DynamicActivity3, activity.QualifiedName, Enum.GetName(typeof(ActivityExecutionStatus), activity.ExecutionStatus), activity.GetType().FullName), ErrorNumbers.Error_DynamicActivity2);
System.Workflow.ComponentModel (12)
System.Workflow.Runtime (7)
System.Xml (17)
UIAutomationClient (1)
UIAutomationClientsideProviders (2)
WindowsBase (19)
XamlBuildTask (2)