code: final boolean allowsChildWithType( JcrNodeType childPrimaryType ) {
          if (childPrimaryType == null) {
              // The definition must have a default primary type ...
              if (defaultPrimaryTypeName != null) {
                  return true;
              }
              return false;
          }
          // The supplied primary type must be or extend all of the required primary types ...
          for (Name requiredPrimaryTypeName : requiredPrimaryTypeNameSet) {
              if (!childPrimaryType.isNodeType(requiredPrimaryTypeName)) return false;
          }
          return true;
      }
docs: Determine if this node definition will allow a child with the supplied primary type. This method checks this definition's
  {@link #getRequiredPrimaryTypes()} against the supplied primary type and its supertypes. The supplied primary type for the
  child must be or extend all of the types defined by the {@link #getRequiredPrimaryTypes() required primary types}.
  
  @param childPrimaryType the primary type of the child
  @return true if the primary type of the child (or one of its supertypes) is one of the types required by this definition,
  or false otherwise