Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| jBPM distribution 6.0.0.Alpha9
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.kie
Interface KieBase

All Superinterfaces:
  KieBaseEventManager

All Known Implementing Classes:
  ProcessBaseImpl

    public interface KieBase

extends KieBaseEventManager

The KieBase is a repository of all the application's knowledge definitions. It will contain rules, processes, functions, type models. The KieBase itself does not contain runtime data, instead sessions are created from the KieBase in which data can be inserted and process instances started.

Method Summary
`Set<String>` | `getEntryPointIds()` Returns the set of the entry points declared and/or used in this knowledge base
`FactType` | `getFactType(String packageName, String typeName)` Returns the FactType identified by the given package and type names.
`KiePackage` | `getKiePackage(String packageName)` Returns a reference to the KnowledgePackage identified by the given name.
`Collection<KiePackage>` | `getKiePackages()` Return an immutable collection of the packages that exist in this KieBase.
`Collection<? extends KieSession>` | `getKieSessions()` Return a collection of the StatefulKnowledgeSessions that exist in this KnowledgeBase.
`Process` | `getProcess(String processId)` Returns a referent to the Process identified by the given processId
`Collection<Process>` | `getProcesses()`
`Query` | `getQuery(String packageName, String queryName)` Returns a reference to the Rule identified by the given package and rule names.
`Rule` | `getRule(String packageName, String ruleName)` Returns a reference to the Rule identified by the given package and rule names.
`KieSession` | `newKieSession()` Create a new StatefulKnowledgeSession using the default session configuration.
`KieSession` | `newKieSession(KieSessionConfiguration conf, Environment environment)` Create a new StatefulKnowledgeSession using the given session configuration and/or environment.
`StatelessKieSession` | `newStatelessKieSession()` Create a new StatelessKnowledgeSession using the default session configuration.
`StatelessKieSession` | `newStatelessKieSession(KieSessionConfiguration conf)` Create a new StatelessKnowledgeSession using the given session configuration.
`void` | `removeFunction(String packageName, String ruleName)` Remove a function from the specified package.
`void` | `removeKiePackage(String packageName)` Remove a KnowledgePackage and all the definitions it contains from the KnowledgeBase.
`void` | `removeProcess(String processId)` Remove a process from the specified package.
`void` | `removeQuery(String packageName, String queryName)` Remove a rule from the specified package.
`void` | `removeRule(String packageName, String ruleName)` Remove a rule from the specified package.

Methods inherited from interface org.kie.event.kiebase.KieBaseEventManager
`addEventListener, getKieBaseEventListeners, removeEventListener`

Method Detail

### getKiePackages

    Collection<KiePackage> getKiePackages()

  Return an immutable collection of the packages that exist in this KieBase.

  Returns:

### getKiePackage

    KiePackage getKiePackage(String packageName)

  Returns a reference to the KnowledgePackage identified by the given name.

  Parameters:
    `packageName` - the name of the KnowledgePackage to return
  Returns:
    the KnowledgePackage identified by the the given name or null if package not found.

### removeKiePackage

    void removeKiePackage(String packageName)

  Remove a KnowledgePackage and all the definitions it contains from the KnowledgeBase.

  Parameters:
    `packageName` -

### getRule

    Rule getRule(String packageName,
                 String ruleName)

  Returns a reference to the Rule identified by the given package and rule names.

  Parameters:
    `packageName` - the package name to which the rule belongs to.
    `ruleName` - the name of the rule.
  Returns:
    the Rule object or null if not found.

### removeRule

    void removeRule(String packageName,
                    String ruleName)

  Remove a rule from the specified package.

  Parameters:
    `packageName` -
    `ruleName` -

### getQuery

    Query getQuery(String packageName,
                   String queryName)

  Returns a reference to the Rule identified by the given package and rule names.

  Parameters:
    `packageName` - the package name to which the rule belongs to.
    `ruleName` - the name of the rule.
  Returns:
    the Rule object or null if not found.

### removeQuery

    void removeQuery(String packageName,
                     String queryName)

  Remove a rule from the specified package.

  Parameters:
    `packageName` -
    `ruleName` -

### removeFunction

    void removeFunction(String packageName,
                        String ruleName)

  Remove a function from the specified package.

  Parameters:
    `packageName` -
    `ruleName` -

### getFactType

    FactType getFactType(String packageName,
                         String typeName)

  Returns the FactType identified by the given package and type names.

  Parameters:
    `packageName` - the name of the package the fact belongs to.
    `typeName` - the name of the type.
  Returns:
    the FactType identified by the parameters or null if FactType not found.

### getProcess

    Process getProcess(String processId)

  Returns a referent to the Process identified by the given processId

  Parameters:
    `processId` - the id of the process
  Returns:
    the Process identified by the given processId or null if process not found.

### removeProcess

    void removeProcess(String processId)

  Remove a process from the specified package.

  Parameters:
    `processId` -

### getProcesses

    Collection<Process> getProcesses()

### newKieSession

    KieSession newKieSession(KieSessionConfiguration conf,
                             Environment environment)

  Create a new StatefulKnowledgeSession using the given session configuration and/or environment. Either one can be null and it will use a default. Don't forget to dispose() session when you are done.

  Parameters:
    `conf` -
    `environment` -
  Returns:
    The StatefulKnowledgeSession.

### newKieSession

    KieSession newKieSession()

  Create a new StatefulKnowledgeSession using the default session configuration. Don't forget to dispose() session when you are done.

  Returns:
    The StatefulKnowledgeSession.

### getKieSessions

    Collection<? extends KieSession> getKieSessions()

  Return a collection of the StatefulKnowledgeSessions that exist in this KnowledgeBase. Be careful as sessions are not thread-safe and could be in use elsewhere.

  Returns:
    a Collection of StatefulKnowledgeSessions

### newStatelessKieSession

    StatelessKieSession newStatelessKieSession(KieSessionConfiguration conf)

  Create a new StatelessKnowledgeSession using the given session configuration. You do not need to call dispose() on this.

  Parameters:
    `conf` -
  Returns:
    The StatelessKnowledgeSession.

### newStatelessKieSession

    StatelessKieSession newStatelessKieSession()

  Create a new StatelessKnowledgeSession using the default session configuration. You do not need to call dispose() on this.

  Returns:
    The StatelessKnowledgeSession.

### getEntryPointIds

    Set<String> getEntryPointIds()

  Returns the set of the entry points declared and/or used in this knowledge base

  Returns:

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| jBPM distribution 6.0.0.Alpha9
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2001-2013 JBoss by Red Hat. All Rights Reserved.