You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@avalon.apache.org by cz...@apache.org on 2003/01/14 08:45:10 UTC
cvs commit: jakarta-avalon-excalibur/monitor/src/java/org/apache/avalon/excalibur/monitor SourceResource.java
cziegeler 2003/01/13 23:45:10
Modified: monitor/src/java/org/apache/avalon/excalibur/monitor
SourceResource.java
Log:
Fitting latest sourceresolve
Revision Changes Path
1.9 +21 -9 jakarta-avalon-excalibur/monitor/src/java/org/apache/avalon/excalibur/monitor/SourceResource.java
Index: SourceResource.java
===================================================================
RCS file: /home/cvs/jakarta-avalon-excalibur/monitor/src/java/org/apache/avalon/excalibur/monitor/SourceResource.java,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- SourceResource.java 7 Sep 2002 12:28:36 -0000 1.8
+++ SourceResource.java 14 Jan 2003 07:45:10 -0000 1.9
@@ -54,15 +54,27 @@
}
else
{
- m_source.discardValidity();
- SourceValidity newVal = m_source.getValidity();
- if( newVal != null && m_validity.isValid( newVal ) == true )
- {
- return getPreviousModified();
+ int valid = m_validity.isValid();
+ boolean isValid = false;
+ SourceValidity newVal = null;
+ if ( valid == 0 ) {
+ m_source.discardValidity();
+ newVal = m_source.getValidity();
+ if( newVal != null)
+ {
+ valid = m_validity.isValid( newVal );
+ isValid = (valid == 1);
+ }
+ } else {
+ isValid = (valid == 1);
}
- else
- {
- m_validity = newVal;
+ if ( isValid ) {
+ return getPreviousModified();
+ } else {
+ if ( null == newVal ) {
+ m_source.discardValidity();
+ m_validity = m_source.getValidity();
+ }
return System.currentTimeMillis();
}
}
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>