com.caucho.env.deploy
Class RepositoryDependency

java.lang.Object
  extended by com.caucho.env.deploy.RepositoryDependency
All Implemented Interfaces:
Dependency, PersistentDependency

public class RepositoryDependency
extends java.lang.Object
implements PersistentDependency

Class for keeping track of modifications.


Constructor Summary
RepositoryDependency(java.lang.String tag, java.lang.String sha1)
          Create a new dependency with an already known modified time and length.
 
Method Summary
 boolean equals(java.lang.Object obj)
          Returns true if the test Dependency has the same tag as this dependency.
 java.lang.String getJavaCreateString()
          Returns a string to recreate the dependency.
 boolean isModified()
          If the source modified date changes at all, treat it as a modification.
 boolean logModified(java.util.logging.Logger log)
          Log the reason for modification
 java.lang.String toString()
          Returns a printable version of the dependency.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RepositoryDependency

public RepositoryDependency(java.lang.String tag,
                            java.lang.String sha1)
Create a new dependency with an already known modified time and length.

Parameters:
source - the source file
Method Detail

isModified

public boolean isModified()
If the source modified date changes at all, treat it as a modification. This protects against the case where multiple computers have misaligned dates and a '<' comparison may fail.

Specified by:
isModified in interface Dependency

logModified

public boolean logModified(java.util.logging.Logger log)
Log the reason for modification

Specified by:
logModified in interface Dependency

equals

public boolean equals(java.lang.Object obj)
Returns true if the test Dependency has the same tag as this dependency.

Overrides:
equals in class java.lang.Object

getJavaCreateString

public java.lang.String getJavaCreateString()
Description copied from interface: PersistentDependency
Returns a string to recreate the dependency.

Specified by:
getJavaCreateString in interface PersistentDependency

toString

public java.lang.String toString()
Returns a printable version of the dependency.

Overrides:
toString in class java.lang.Object