org.gcube.data.speciesplugin
Class SpeciesLifecycle
java.lang.Object
org.gcube.data.tmf.impl.LifecycleAdapter
org.gcube.data.speciesplugin.SpeciesLifecycle
- All Implemented Interfaces:
- Serializable, org.gcube.data.tmf.api.SourceLifecycle
public class SpeciesLifecycle
- extends org.gcube.data.tmf.impl.LifecycleAdapter
- Author:
- "Federico De Faveri defaveri@isti.cnr.it", "Valentina Marioli valentina.marioli@isti.cnr.it"
- See Also:
- Serialized Form
| Methods inherited from class org.gcube.data.tmf.impl.LifecycleAdapter |
resume |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
STORAGE_LOCATION
public static final String STORAGE_LOCATION
- The storage location.
- See Also:
- Constant Field Values
db
protected static org.gcube.data.speciesplugin.requests.RequestBinder db
scientificNames
protected List<String> scientificNames
datasources
protected List<String> datasources
strictMatch
protected boolean strictMatch
lastUpdate
protected long lastUpdate
scheduled
protected transient ScheduledFuture<?> scheduled
updatePeriod
protected long updatePeriod
timeUnit
protected TimeUnit timeUnit
SpeciesLifecycle
public SpeciesLifecycle(SpeciesSource source,
List<String> scientificNames,
List<String> datasources,
boolean strictMatch,
long updatePeriod,
TimeUnit timeUnit)
- Creates an instance for a given
SpeciesSource
- Parameters:
source - the source
init
public void init()
throws Exception
-
- Specified by:
init in interface org.gcube.data.tmf.api.SourceLifecycle- Overrides:
init in class org.gcube.data.tmf.impl.LifecycleAdapter
- Throws:
Exception
scheduleRefresh
protected void scheduleRefresh()
calculateInitialRefreshDelay
protected long calculateInitialRefreshDelay()
rescheduleRefresh
protected void rescheduleRefresh()
refreshCollection
protected void refreshCollection()
loadCollection
protected void loadCollection()
throws Exception
- Throws:
Exception
reconfigure
public void reconfigure(Element DOMRequest)
throws org.gcube.common.clients.exceptions.InvalidRequestException
-
- Specified by:
reconfigure in interface org.gcube.data.tmf.api.SourceLifecycle- Overrides:
reconfigure in class org.gcube.data.tmf.impl.LifecycleAdapter
- Throws:
org.gcube.common.clients.exceptions.InvalidRequestException
terminate
public void terminate()
-
- Specified by:
terminate in interface org.gcube.data.tmf.api.SourceLifecycle- Overrides:
terminate in class org.gcube.data.tmf.impl.LifecycleAdapter
stop
public void stop()
-
- Specified by:
stop in interface org.gcube.data.tmf.api.SourceLifecycle- Overrides:
stop in class org.gcube.data.tmf.impl.LifecycleAdapter
unscheduleRefresh
protected void unscheduleRefresh()
Copyright © 2014. All Rights Reserved.