src/share/classes/com/sun/mirror/type/WildcardType.java

Print this page




  24  */
  25 
  26 package com.sun.mirror.type;
  27 
  28 
  29 import java.util.Collection;
  30 
  31 
  32 /**
  33  * Represents a wildcard type argument.
  34  * Examples include:    <pre><tt>
  35  *   ?
  36  *   ? extends Number
  37  *   ? super T
  38  * </tt></pre>
  39  *
  40  * <p> A wildcard may have its upper bound explicitly set by an
  41  * <tt>extends</tt> clause, its lower bound explicitly set by a
  42  * <tt>super</tt> clause, or neither (but not both).
  43  *





  44  * @author Joseph D. Darcy
  45  * @author Scott Seligman
  46  * @since 1.5
  47  */
  48 

  49 public interface WildcardType extends TypeMirror {
  50 
  51     /**
  52      * Returns the upper bounds of this wildcard.
  53      * If no upper bound is explicitly declared, then
  54      * an empty collection is returned.
  55      *
  56      * @return the upper bounds of this wildcard
  57      */
  58     Collection<ReferenceType> getUpperBounds();
  59 
  60     /**
  61      * Returns the lower bounds of this wildcard.
  62      * If no lower bound is explicitly declared, then
  63      * an empty collection is returned.
  64      *
  65      * @return the lower bounds of this wildcard
  66      */
  67     Collection<ReferenceType> getLowerBounds();
  68 }


  24  */
  25 
  26 package com.sun.mirror.type;
  27 
  28 
  29 import java.util.Collection;
  30 
  31 
  32 /**
  33  * Represents a wildcard type argument.
  34  * Examples include:    <pre><tt>
  35  *   ?
  36  *   ? extends Number
  37  *   ? super T
  38  * </tt></pre>
  39  *
  40  * <p> A wildcard may have its upper bound explicitly set by an
  41  * <tt>extends</tt> clause, its lower bound explicitly set by a
  42  * <tt>super</tt> clause, or neither (but not both).
  43  *
  44  * @deprecated All components of this API have been superseded by the
  45  * standardized annotation processing API.  The replacement for the
  46  * functionality of this interface is {@link
  47  * javax.lang.model.type.WildcardType}.
  48  *
  49  * @author Joseph D. Darcy
  50  * @author Scott Seligman
  51  * @since 1.5
  52  */
  53 @Deprecated
  54 @SuppressWarnings("deprecation")
  55 public interface WildcardType extends TypeMirror {
  56 
  57     /**
  58      * Returns the upper bounds of this wildcard.
  59      * If no upper bound is explicitly declared, then
  60      * an empty collection is returned.
  61      *
  62      * @return the upper bounds of this wildcard
  63      */
  64     Collection<ReferenceType> getUpperBounds();
  65 
  66     /**
  67      * Returns the lower bounds of this wildcard.
  68      * If no lower bound is explicitly declared, then
  69      * an empty collection is returned.
  70      *
  71      * @return the lower bounds of this wildcard
  72      */
  73     Collection<ReferenceType> getLowerBounds();
  74 }