IsMatch() public method

public IsMatch ( Type type ) : bool
type System.Type
return bool
Example #1
0
        private static CategoryEntry GetDeepestMatch( CategoryEntry root, Type type )
        {
            if( !root.IsMatch( type ) )
                return null;

            for( int i = 0; i < root.SubCategories.Length; ++i )
            {
                CategoryEntry check = GetDeepestMatch( root.SubCategories[i], type );

                if( check != null )
                    return check;
            }

            return root;
        }
Example #2
0
        private static CategoryEntry GetDeepestMatch(CategoryEntry root, Type type)
        {
            if (!root.IsMatch(type))
            {
                return(null);
            }

            for (int i = 0; i < root.SubCategories.Length; ++i)
            {
                CategoryEntry check = GetDeepestMatch(root.SubCategories[i], type);

                if (check != null)
                {
                    return(check);
                }
            }

            return(root);
        }
Example #3
0
		private static CategoryEntry GetDeepestMatch( CategoryEntry root, Type type )
		{
			if ( !root.IsMatch( type ) )
				return null;

			for ( int i = 0; i < root.SubCategories.Length; ++i )
			{
				CategoryEntry check = GetDeepestMatch( root.SubCategories[i], type );

				if ( check != null )
					return check;
			}

			return root;
		}