|
jBPM distribution 6.0.0.CR5 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jbpm.runtime.manager.impl.SimpleRuntimeEnvironment
public class SimpleRuntimeEnvironment
The most basic implementation of RuntimeEnvironment
that at the same time serves as base
implementation for all extensions. Encapsulates all important configuration that RuntimeManager
requires for execution.
RuntimeEnvironment
RuntimeEngine
RuntimeEngine
SchedulerProvider
it allows to get GlobalTimerService
if available
Field Summary | |
---|---|
protected ClassLoader |
classLoader
|
protected KieSessionConfiguration |
configuration
|
protected javax.persistence.EntityManagerFactory |
emf
|
protected Environment |
environment
|
protected KieBase |
kbase
|
protected org.kie.internal.builder.KnowledgeBuilder |
kbuilder
|
protected org.kie.internal.runtime.manager.Mapper |
mapper
|
protected org.kie.internal.runtime.manager.RegisterableItemsFactory |
registerableItemsFactory
|
protected GlobalSchedulerService |
schedulerService
|
protected Properties |
sessionConfigProperties
|
protected boolean |
usePersistence
|
protected org.kie.internal.task.api.UserGroupCallback |
userGroupCallback
|
Constructor Summary | |
---|---|
SimpleRuntimeEnvironment()
|
|
SimpleRuntimeEnvironment(org.kie.internal.runtime.manager.RegisterableItemsFactory registerableItemsFactory)
|
Method Summary | |
---|---|
void |
addAsset(Resource resource,
ResourceType type)
Adds given asset to knowledge builder to produce KieBase |
protected void |
addIfPresent(String name,
Environment copy)
|
void |
addToConfiguration(String name,
String value)
Adds configuration property that will be part of KieSessionConfiguration |
void |
addToEnvironment(String name,
Object value)
Adds element to the drools/jbpm environment - the value must be thread save as it will be shared between all RuntimeEngine instances |
void |
close()
|
protected Environment |
copyEnvironment()
|
ClassLoader |
getClassLoader()
|
KieSessionConfiguration |
getConfiguration()
|
javax.persistence.EntityManagerFactory |
getEmf()
|
Environment |
getEnvironment()
|
KieBase |
getKieBase()
|
org.kie.internal.runtime.manager.Mapper |
getMapper()
|
org.kie.internal.runtime.manager.RegisterableItemsFactory |
getRegisterableItemsFactory()
|
GlobalSchedulerService |
getSchedulerService()
Returns fully configured instance of SchedulerService ready to be used/ |
Properties |
getSessionConfigProperties()
|
org.kie.internal.task.api.UserGroupCallback |
getUserGroupCallback()
|
void |
init()
|
void |
setClassLoader(ClassLoader classLoader)
|
void |
setEmf(javax.persistence.EntityManagerFactory emf)
|
void |
setKieBase(KieBase kbase)
|
void |
setMapper(org.kie.internal.runtime.manager.Mapper mapper)
|
void |
setRegisterableItemsFactory(org.kie.internal.runtime.manager.RegisterableItemsFactory registerableItemsFactory)
|
void |
setSchedulerService(GlobalSchedulerService schedulerService)
|
void |
setSessionConfigProperties(Properties sessionConfigProperties)
|
void |
setUsePersistence(boolean usePersistence)
|
void |
setUserGroupCallback(org.kie.internal.task.api.UserGroupCallback userGroupCallback)
|
boolean |
usePersistence()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected boolean usePersistence
protected javax.persistence.EntityManagerFactory emf
protected Environment environment
protected KieSessionConfiguration configuration
protected KieBase kbase
protected org.kie.internal.builder.KnowledgeBuilder kbuilder
protected org.kie.internal.runtime.manager.RegisterableItemsFactory registerableItemsFactory
protected org.kie.internal.runtime.manager.Mapper mapper
protected org.kie.internal.task.api.UserGroupCallback userGroupCallback
protected GlobalSchedulerService schedulerService
protected ClassLoader classLoader
protected Properties sessionConfigProperties
Constructor Detail |
---|
public SimpleRuntimeEnvironment()
public SimpleRuntimeEnvironment(org.kie.internal.runtime.manager.RegisterableItemsFactory registerableItemsFactory)
Method Detail |
---|
public void init()
public void addAsset(Resource resource, ResourceType type)
resource
- asset to be addedtype
- type of the assetpublic void addToEnvironment(String name, Object value)
RuntimeEngine
instances
name
- name of the environment entryvalue
- value of the environment entrypublic void addToConfiguration(String name, String value)
KieSessionConfiguration
name
- name of the propertyvalue
- value of the propertypublic KieBase getKieBase()
getKieBase
in interface org.kie.internal.runtime.manager.RuntimeEnvironment
public Environment getEnvironment()
getEnvironment
in interface org.kie.internal.runtime.manager.RuntimeEnvironment
public KieSessionConfiguration getConfiguration()
getConfiguration
in interface org.kie.internal.runtime.manager.RuntimeEnvironment
public boolean usePersistence()
usePersistence
in interface org.kie.internal.runtime.manager.RuntimeEnvironment
public org.kie.internal.runtime.manager.RegisterableItemsFactory getRegisterableItemsFactory()
getRegisterableItemsFactory
in interface org.kie.internal.runtime.manager.RuntimeEnvironment
public void close()
close
in interface org.kie.internal.runtime.manager.RuntimeEnvironment
protected void addIfPresent(String name, Environment copy)
protected Environment copyEnvironment()
public org.kie.internal.runtime.manager.Mapper getMapper()
getMapper
in interface org.kie.internal.runtime.manager.RuntimeEnvironment
public org.kie.internal.task.api.UserGroupCallback getUserGroupCallback()
getUserGroupCallback
in interface org.kie.internal.runtime.manager.RuntimeEnvironment
public void setUserGroupCallback(org.kie.internal.task.api.UserGroupCallback userGroupCallback)
public Properties getSessionConfigProperties()
public void setSessionConfigProperties(Properties sessionConfigProperties)
public void setUsePersistence(boolean usePersistence)
public void setKieBase(KieBase kbase)
public void setMapper(org.kie.internal.runtime.manager.Mapper mapper)
public GlobalSchedulerService getSchedulerService()
SchedulerProvider
SchedulerService
ready to be used/
getSchedulerService
in interface SchedulerProvider
GlobalSchedulerService
instance configured according to environment needspublic void setSchedulerService(GlobalSchedulerService schedulerService)
public void setRegisterableItemsFactory(org.kie.internal.runtime.manager.RegisterableItemsFactory registerableItemsFactory)
public javax.persistence.EntityManagerFactory getEmf()
public void setEmf(javax.persistence.EntityManagerFactory emf)
public ClassLoader getClassLoader()
getClassLoader
in interface org.kie.internal.runtime.manager.RuntimeEnvironment
public void setClassLoader(ClassLoader classLoader)
|
jBPM distribution 6.0.0.CR5 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |