org.hibernate.annotations.common.reflection.java.generics
Class CompoundTypeEnvironment

java.lang.Object
  extended by org.hibernate.annotations.common.reflection.java.generics.CompoundTypeEnvironment
All Implemented Interfaces:
TypeEnvironment

public class CompoundTypeEnvironment
extends Object
implements TypeEnvironment

A composition of two TypeEnvironment functions.

Author:
Davide Marchignoli, Paolo Perrotta

Method Summary
 Type bind(Type type)
          Binds as many generic components of the given type as possible in this context.
static TypeEnvironment create(TypeEnvironment f, TypeEnvironment g)
           
 boolean equals(Object o)
           
 int hashCode()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Method Detail

create

public static TypeEnvironment create(TypeEnvironment f,
                                     TypeEnvironment g)

bind

public Type bind(Type type)
Description copied from interface: TypeEnvironment
Binds as many generic components of the given type as possible in this context.

Warning: if the returned Type is a Class, then it's guaranteed to be a regular Java Class. In all other cases, this method might return a custom implementation of some interface that extends Type. Be sure not to mix these objects with Java's implementations of Type to avoid potential identity problems.

This class does not support bindings involving inner classes or upper/lower bounds.

Specified by:
bind in interface TypeEnvironment
Returns:
a type where the generic arguments have been replaced by raw classes whenever this is possible.

equals

public boolean equals(Object o)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2011. All Rights Reserved.