コード例 #1
0
ファイル: EdmType.cs プロジェクト: dox0/DotNet471RS3
 /// <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));
 }
コード例 #2
0
ファイル: TypeUsage.cs プロジェクト: dox0/DotNet471RS3
        /// <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));
        }
コード例 #3
0
 /// <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);
 }
コード例 #4
0
 /// <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);
 }
コード例 #5
0
ファイル: TypeSemantics.cs プロジェクト: dox0/DotNet471RS3
 /// <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));
 }