internal static TypeUsage GetElementTypeUsage(TypeUsage type) { if (TypeSemantics.IsCollectionType(type)) { return(((CollectionType)type.EdmType).TypeUsage); } if (TypeSemantics.IsReferenceType(type)) { throw new NotSupportedException(String.Empty); } return(null); }
internal static TypeUsage GetElementTypeUsage(TypeUsage type) { if (TypeSemantics.IsCollectionType(type)) { return(((CollectionType)type.EdmType).TypeUsage); } if (TypeSemantics.IsReferenceType(type)) { return(TypeUsage.Create(((RefType)type.EdmType).ElementType, type.Facets)); } return(null); }