Package randoop.types

Class ReferenceBound

    • Field Detail

      • boundType

        private final ReferenceType boundType
        The type for this bound.
    • Method Detail

      • getBoundType

        public ReferenceType getBoundType()
        Returns the ReferenceType bound of this type.
        Returns:
        the type for this bound
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object
      • substitute

        public abstract ReferenceBound substitute​(Substitution substitution)
        Description copied from class: ParameterBound
        Applies the given substitution to this type bound by replacing type variables.
        Specified by:
        substitute in class ParameterBound
        Parameters:
        substitution - the type substitution
        Returns:
        this bound with the type after the substitution has been applied
      • hasWildcard

        boolean hasWildcard()
        Description copied from class: ParameterBound
        Indicates whether the type of this bound has a wildcard type argument.
        Specified by:
        hasWildcard in class ParameterBound
        Returns:
        true, if this bound has a wildcard argument, and false otherwise
      • hasCaptureVariable

        public boolean hasCaptureVariable()
        Description copied from class: ParameterBound
        Indicates whether the type of this bound has a capture variable.
        Specified by:
        hasCaptureVariable in class ParameterBound
        Returns:
        true iff this bound has a capture variable
      • isGeneric

        public boolean isGeneric​(boolean ignoreWildcards)
        Description copied from class: ParameterBound
        Indicates whether the type of this bound is generic.
        Specified by:
        isGeneric in class ParameterBound
        Parameters:
        ignoreWildcards - if true, ignore wildcards; that is, treat wildcards as not making the operation generic
        Returns:
        true, if this bound type is generic, and false otherwise
      • isObject

        public boolean isObject()
        Description copied from class: ParameterBound
        Indicate whether this bound is Object.
        Specified by:
        isObject in class ParameterBound
        Returns:
        true if this bound is Object, false otherwise
      • isVariable

        public boolean isVariable()
        Description copied from class: ParameterBound
        Indicates whether this bound is a type variable.
        Overrides:
        isVariable in class ParameterBound
        Returns:
        true if this bound is a type variable, false otherwise