com.caucho.make
Class ClassDependency

java.lang.Object
  extended by com.caucho.make.ClassDependency
All Implemented Interfaces:
Dependency, PersistentDependency

public class ClassDependency
extends java.lang.Object
implements PersistentDependency

Representing a class that might change.


Constructor Summary
ClassDependency(java.lang.Class cl)
          Creates the class dependency.
ClassDependency(java.lang.String className, long digest)
          Create a new dependency with a given digest.
 
Method Summary
 boolean equals(java.lang.Object o)
           
 long getDigest()
          Calculates a MD5 digest of the class.
 java.lang.String getJavaCreateString()
          Returns a string which will recreate the dependency.
 int hashCode()
           
 boolean isModified()
          Returns true if the underlying resource has changed.
 boolean logModified(java.util.logging.Logger log)
          Returns true if the underlying resource has changed.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ClassDependency

public ClassDependency(java.lang.Class cl)
Creates the class dependency.


ClassDependency

public ClassDependency(java.lang.String className,
                       long digest)
Create a new dependency with a given digest.

Parameters:
cl - the source class
digest - the MD5 digest
Method Detail

isModified

public boolean isModified()
Returns true if the underlying resource has changed.

Specified by:
isModified in interface Dependency

logModified

public boolean logModified(java.util.logging.Logger log)
Returns true if the underlying resource has changed.

Specified by:
logModified in interface Dependency

getDigest

public long getDigest()
Calculates a MD5 digest of the class.


getJavaCreateString

public java.lang.String getJavaCreateString()
Returns a string which will recreate the dependency.

Specified by:
getJavaCreateString in interface PersistentDependency

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object