52 references to InstanceType
System.Data.Services (52)
System\Data\Services\DataServiceConfiguration.cs (4)
906Type lambdaType = typeof(Func<,>).MakeGenericType(container.ResourceType.InstanceType, typeof(bool)); 915Type nullableLambdaType = typeof(Func<,>).MakeGenericType(container.ResourceType.InstanceType, typeof(bool?)); 1055if (!elementParameterType.IsAssignableFrom(container.ResourceType.InstanceType)) 1062container.ResourceType.InstanceType);
System\Data\Services\Internal\NeedSkipTokenVisitor.cs (1)
182if (this.rt != null && p.Type != this.rt.InstanceType)
System\Data\Services\Parsing\FunctionDescription.cs (3)
286primitiveTypes[i].InstanceType != typeof(Type), 289primitiveTypes[i].InstanceType != typeof(object), 291castSignatures.Add(new FunctionDescription(FunctionNameCast, new Type[] { primitiveTypes[i].InstanceType, typeof(Type) }, FunctionDescription.BinaryCast));
System\Data\Services\Parsing\RequestQueryParser.cs (3)
106Debug.Assert(typeForIt.InstanceType == queryElementType, "typeForIt.InstanceType == queryElementType"); 275ParameterExpression element = Expression.Parameter(this.typeForIt.InstanceType, "element"); 2503value = resourceType.InstanceType;
System\Data\Services\Providers\BasicExpandProvider.cs (5)
1083Type segmentType = property.ResourceType.InstanceType; 1253Debug.Assert(resourceType.InstanceType.IsAssignableFrom(source.Type), "Trying to access a property on expression of a wrong type."); 1264MethodInfo getter = DataServiceProviderMethods.GetSequenceValueMethodInfo.MakeGenericMethod(property.ResourceType.InstanceType); 1568Expression sourceExpression = Expression.TypeAs(source, resourceType.InstanceType); 1696(Expression)Expression.TypeIs(source, resourceType.InstanceType) :
System\Data\Services\Providers\ObjectContextServiceProvider.cs (6)
255if (set.Value.ResourceType.InstanceType.IsAssignableFrom(source.ElementType)) 352if (resourceType.InstanceType.IsAbstract) 361resource = CreateObject(this.ObjectContext, resourceType.InstanceType); 426object newInstance = CreateObject(this.ObjectContext, resourceType.InstanceType); 1396PropertyInfo propertyInfo = resourceType.InstanceType.GetProperty(member.Name); 2353MethodInfo genericMethod = typeof(ObjectContext).GetMethod("CreateQuery", WebUtil.PublicInstanceBindingFlags).MakeGenericMethod(container.ResourceType.InstanceType);
System\Data\Services\Providers\ReflectionServiceProvider.cs (8)
81ResourceSet targetSet = InternalGetContainerForResourceType(targetType.InstanceType, this.EntitySets.Values); 266Type entitySetType = entitySetInfo.Value.ResourceType.InstanceType; 611HashSet<string> propertiesToBeIgnored = new HashSet<string>(IgnorePropertiesAttribute.GetProperties(parentResourceType.InstanceType, false /*inherit*/, bindingFlags), StringComparer.Ordinal); 617PropertyInfo[] properties = parentResourceType.InstanceType.GetProperties(bindingFlags); 816if (entitySetInfo.ResourceType.InstanceType.IsAssignableFrom(type)) 866Assembly assembly = resourceType.InstanceType.Assembly; 891if (rootTypes[i].InstanceType.IsAssignableFrom(type)) 921ETagAttribute[] attributes = (ETagAttribute[])resourceType.InstanceType.GetCustomAttributes(typeof(ETagAttribute), inherit);
System\Data\Services\Providers\ResourceProperty.cs (3)
191return typeof(System.Collections.Generic.IEnumerable<>).MakeGenericType(this.propertyResourceType.InstanceType); 195return this.propertyResourceType.InstanceType; 291if (IsOfKind(kind, ResourcePropertyKind.Key) && Nullable.GetUnderlyingType(propertyResourceType.InstanceType) != null)
System\Data\Services\Providers\ResourceType.cs (5)
453WebUtil.CreateNewInstanceConstructor(this.InstanceType, this.FullName, typeof(object)); 583if (resourceType.InstanceType == type) 707foreach (EntityPropertyMappingAttribute epmAttr in currentResourceType.InstanceType.GetCustomAttributes(typeof(EntityPropertyMappingAttribute), currentResourceType.BaseType != null ? false : true)) 849currentValue = PlainXmlDeserializer.ConvertValuesForXml(propertyValue, currentSegment, propertyType.InstanceType); 1111propertyInfo = this.InstanceType.GetProperty(resourceProperty.Name, bindingFlags);
System\Data\Services\RequestQueryProcessor.cs (4)
438ParameterExpression p = Expression.Parameter(resourceType.InstanceType, "p"); 925ParameterExpression p = Expression.Parameter(this.description.LastSegmentInfo.TargetResourceType.InstanceType, "it"); 1071Debug.Assert(this.query.ElementType == rt.InstanceType, "Resource type should match query element type when in this function"); 1078ParameterExpression elementParameter = Expression.Parameter(rt.InstanceType, "element");
System\Data\Services\RequestUriProcessor.cs (1)
1069Type parameterType = operation.Parameters[i].ParameterType.InstanceType;
System\Data\Services\Serializers\JsonSerializer.cs (1)
764(resourceType.InstanceType.IsAssignableFrom(customObject.GetType())),
System\Data\Services\Serializers\PlainXmlDeserializer.cs (1)
588propertyValue = PlainXmlDeserializer.ConvertValuesForXml(propertyValue, propertyName, propertyType.InstanceType);
System\Data\Services\Serializers\PlainXmlSerializer.cs (2)
332Debug.Assert(propertyResourceType.InstanceType == value.GetType(), "propertyResourceType.Type == valueType"); 387Debug.Assert(!expectedType.InstanceType.IsValueType, "!expectedType.Type.IsValueType -- checked in the resource type constructor.");
System\Data\Services\Serializers\SyndicationSerializer.cs (2)
416Debug.Assert(!expectedType.InstanceType.IsValueType, "!expectedType.Type.IsValueType -- checked in the resource type constructor."); 914Debug.Assert(propertyResourceType.InstanceType == valueType, "propertyResourceType.Type == valueType");
System\Data\Services\WebUtil.cs (3)
344if (valueType.InstanceType == mapping.Key) 353if (valueType.InstanceType == mapping.Key) 798if (type.InstanceType == elementType)