// <summary> // check to see if otherType is among the sub-types, // </summary> // <returns> if otherType is among the sub-types, returns true, otherwise returns false. when othertype is same as the current type, return false. </returns> internal virtual bool IsBaseTypeOf(EdmType otherType) { if (otherType == null) { return(false); } return(otherType.IsSubtypeOf(this)); }
/// <summary> /// check if "this" is a subtype of the specified TypeUsage /// </summary> /// <param name="typeUsage"> The typeUsage to be checked </param> /// <returns> true if this typeUsage is a subtype of the specified typeUsage </returns> public bool IsSubtypeOf(TypeUsage typeUsage) { if (EdmType == null || typeUsage == null) { return(false); } return(EdmType.IsSubtypeOf(typeUsage.EdmType)); }
// <summary> // determines if subType EdmType is a sub-type of superType EdmType. // </summary> // <returns> true if subType is a sub-type of superType, false otherwise </returns> internal static bool IsSubTypeOf(EdmType subEdmType, EdmType superEdmType) { return(subEdmType.IsSubtypeOf(superEdmType)); }
/// <summary> /// determines if subType EdmType is a sub-type of superType EdmType. /// </summary> /// <param name="subEdmType"> </param> /// <param name="superEdmType"> </param> /// <returns> true if subType is a sub-type of superType, false otherwise </returns> internal static bool IsSubTypeOf(EdmType subEdmType, EdmType superEdmType) { return subEdmType.IsSubtypeOf(superEdmType); }
/// <summary> /// check to see if otherType is among the sub-types, /// </summary> /// <param name="otherType"></param> /// <returns> /// if otherType is among the sub-types, returns true, /// otherwise returns false. /// when othertype is same as the current type, return false. /// </returns> internal virtual bool IsBaseTypeOf(EdmType otherType) { if (otherType == null) { return false; } return otherType.IsSubtypeOf(this); }