net.sourceforge.c4j
Annotation Type ContractReference


@Retention(value=CLASS)
@Target(value=TYPE)
public @interface ContractReference

This annotation links a target class to it's contract class.

Either contractClass or contractClassName is used to declare the contract implementation. If both are set, the Instrumentor will NOT instrument the target class.

Using a String instead of a Class is useful if it must be possible to compile the target class whithout the contract class on it's class path.


Optional Element Summary
 java.lang.Class contractClass
          Deprecated. 
 java.lang.String contractClassName
          A class name of a contract implementation, e.g.
 

contractClassName

public abstract java.lang.String contractClassName
A class name of a contract implementation, e.g. "org.com.TestContract".

Default:
""

contractClass

@Deprecated
public abstract java.lang.Class contractClass
Deprecated. 

A class of a contract implementation, e.g. org.com.TestContract. This field is deprecated since it may cause class loading problems in multi- class loader environments.

Default:
net.sourceforge.c4j.Null.class