Class ResourceChangeTrackerImpl
- java.lang.Object
- 
- org.apache.tapestry5.internal.event.InvalidationEventHubImpl
- 
- org.apache.tapestry5.internal.services.assets.ResourceChangeTrackerImpl
 
 
- 
- All Implemented Interfaces:
- InvalidationEventHub,- ResourceChangeTracker,- UpdateListener,- ResourceDependencies
 
 public class ResourceChangeTrackerImpl extends InvalidationEventHubImpl implements ResourceChangeTracker, UpdateListener 
- 
- 
Constructor SummaryConstructors Constructor Description ResourceChangeTrackerImpl(ClasspathURLConverter classpathURLConverter, boolean productionMode)
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddDependency(Resource dependency)Marks the dependency as an additional resource.voidcheckForUpdates()Invoked to force the receiver to check for updates to whatever underlying resources it makes use of.voidforceInvalidationEvent()Forces an invalidation event.voidregisterWithUpdateListenerHub(UpdateListenerHub hub)longtrackResource(Resource resource)Start tracking the resource (or return the last modified time of an already tracked resource).- 
Methods inherited from class org.apache.tapestry5.internal.event.InvalidationEventHubImpladdInvalidationCallback, addInvalidationListener, clearOnInvalidation, fireInvalidationEvent
 - 
Methods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 - 
Methods inherited from interface org.apache.tapestry5.commons.services.InvalidationEventHubaddInvalidationCallback, addInvalidationListener, clearOnInvalidation
 
- 
 
- 
- 
- 
Constructor Detail- 
ResourceChangeTrackerImplpublic ResourceChangeTrackerImpl(ClasspathURLConverter classpathURLConverter, @Symbol("tapestry.production-mode") boolean productionMode) 
 
- 
 - 
Method Detail- 
registerWithUpdateListenerHub@PostInjection public void registerWithUpdateListenerHub(UpdateListenerHub hub) 
 - 
trackResourcepublic long trackResource(Resource resource) Description copied from interface:ResourceChangeTrackerStart tracking the resource (or return the last modified time of an already tracked resource). Only file system resources are tracked. Resources are tracked until any resource changes, at which points listeners are notified and the internal state is cleared.- Specified by:
- trackResourcein interface- ResourceChangeTracker
- Parameters:
- resource- to track
- Returns:
- last modified time, to nearest second
- See Also:
- URLChangeTracker
 
 - 
addDependencypublic void addDependency(Resource dependency) Description copied from interface:ResourceDependenciesMarks the dependency as an additional resource. A change to the dependency is considered the same as a change to the resource being transformed.- Specified by:
- addDependencyin interface- ResourceDependencies
 
 - 
forceInvalidationEventpublic void forceInvalidationEvent() Description copied from interface:ResourceChangeTrackerForces an invalidation event. This is required in a rare case, to clear out aStreamableResourcegenerated from the component message catalog; there are some walls in place that prevent the message catalog's underlyingResources from being exposed.- Specified by:
- forceInvalidationEventin interface- ResourceChangeTracker
- See Also:
- MessageCatalogResource
 
 - 
checkForUpdatespublic void checkForUpdates() Description copied from interface:UpdateListenerInvoked to force the receiver to check for updates to whatever underlying resources it makes use of.- Specified by:
- checkForUpdatesin interface- UpdateListener
 
 
- 
 
-