public class SimplePatternDefinitionRepository extends BaseConfigurationRepository<PatternDefinition,PatternDefinitionLoader,PatternDefinitionWriter> implements PatternDefinitionRepository
| 限定符和类型 | 字段和说明 |
|---|---|
protected int |
reloadIntervalInSeconds
units: seconds
scan interval, if <=0, will not refresh
|
comparator, eventFactory, eventPublisher, loader, writerinited| 构造器和说明 |
|---|
SimplePatternDefinitionRepository() |
| 限定符和类型 | 方法和说明 |
|---|---|
PatternDefinition |
add(PatternDefinition configuration,
boolean sync) |
protected void |
doInit() |
protected void |
doStart()
Subclasses must implement this method with the start behavior.
|
protected void |
doStop()
Subclasses must implement this method with the stop behavior.
|
Map<String,PatternDefinition> |
getAll() |
PatternDefinition |
getById(String id)
Get a configuration bean by a specified id
|
void |
removeById(String id,
boolean sync)
Remove a configuration by id
|
void |
setReloadIntervalInSeconds(int reloadIntervalInSeconds) |
void |
update(PatternDefinition configuration,
boolean sync)
update the configuration to storage
|
add, getComparator, getConfigurationLoader, getConfigurationWriter, getEventPublisher, logMutation, reload, removeById, setComparator, setConfigurationLoader, setConfigurationWriter, setEventFactory, setEventPublisher, updategetName, isRunning, setName, shutdown, startup, stopAndExecute, toStringinitclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitadd, getConfigurationLoader, getConfigurationWriter, setConfigurationLoader, setConfigurationWriter, updategetName, removeById, setNamegetEventPublisher, setEventPublisherinitprotected int reloadIntervalInSeconds
public void setReloadIntervalInSeconds(int reloadIntervalInSeconds)
protected void doStart()
AbstractLifecycleAbstractLifecycle.lifecycleLock.doStart 在类中 AbstractLifecycleprotected void doStop()
AbstractLifecycleAbstractLifecycle.lifecycleLock.public PatternDefinition getById(String id)
ConfigurationRepositorygetById 在接口中 ConfigurationRepository<PatternDefinition,PatternDefinitionLoader,PatternDefinitionWriter>getById 在接口中 Repository<PatternDefinition,String>getById 在接口中 PatternDefinitionRepositoryid - the idpublic void removeById(String id, boolean sync)
ConfigurationRepositoryremoveById 在接口中 ConfigurationRepository<PatternDefinition,PatternDefinitionLoader,PatternDefinitionWriter>id - the configuration idsync - whether sync to the real storage or notpublic PatternDefinition add(PatternDefinition configuration, boolean sync)
add 在接口中 ConfigurationRepository<PatternDefinition,PatternDefinitionLoader,PatternDefinitionWriter>add 在接口中 PatternDefinitionRepositoryconfiguration - the configurationsync - whether sync to the real storage or notpublic void update(PatternDefinition configuration, boolean sync)
ConfigurationRepositoryupdate 在接口中 ConfigurationRepository<PatternDefinition,PatternDefinitionLoader,PatternDefinitionWriter>update 在接口中 PatternDefinitionRepositoryconfiguration - the configuration beansync - whether sync to the real storage or notprotected void doInit()
public Map<String,PatternDefinition> getAll()
Copyright © 2022. All rights reserved.