org.drools.definitions.impl
Class KnowledgePackageImp

java.lang.Object
  extended by org.drools.definitions.impl.KnowledgePackageImp
All Implemented Interfaces:
Externalizable, Serializable, org.drools.definition.KnowledgePackage

public class KnowledgePackageImp
extends Object
implements org.drools.definition.KnowledgePackage, Externalizable

See Also:
Serialized Form

Field Summary
 Package pkg
           
 
Constructor Summary
KnowledgePackageImp()
           
KnowledgePackageImp(Package pkg)
           
 
Method Summary
 boolean equals(Object o)
           
 Function getFunction(String name)
          Delegate method to retrieve a Function by its name.
 String getName()
           
 Collection<org.drools.definition.process.Process> getProcesses()
           
 org.drools.definition.rule.Rule getRule(String name)
          Delegate method to retrieve a Rule by its name.
 Collection<org.drools.definition.rule.Rule> getRules()
           
 int hashCode()
           
 void readExternal(ObjectInput in)
           
 void removeFunction(String functionName)
          Delegate method to retrieve a Rule by its name.
 void removeRule(Rule rule)
          Delegate method to remove a Rule by its name.
 String toString()
           
 void writeExternal(ObjectOutput out)
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

pkg

public Package pkg
Constructor Detail

KnowledgePackageImp

public KnowledgePackageImp()

KnowledgePackageImp

public KnowledgePackageImp(Package pkg)
Method Detail

getName

public String getName()
Specified by:
getName in interface org.drools.definition.KnowledgePackage

getRules

public Collection<org.drools.definition.rule.Rule> getRules()
Specified by:
getRules in interface org.drools.definition.KnowledgePackage

getRule

public org.drools.definition.rule.Rule getRule(String name)
Delegate method to retrieve a Rule by its name.

Parameters:
name - the rule's name
Returns:
See Also:
Package.getRule(java.lang.String)

removeRule

public void removeRule(Rule rule)
Delegate method to remove a Rule by its name.

Parameters:
rule - the rule to be removed
See Also:
Package.removeRule(org.drools.rule.Rule)

getFunction

public Function getFunction(String name)
Delegate method to retrieve a Function by its name.

Parameters:
name - the function's name
Returns:
See Also:
Package.getFunctions()

removeFunction

public void removeFunction(String functionName)
Delegate method to retrieve a Rule by its name.

Parameters:
functionName - the function's name
See Also:
Package.removeFunction(java.lang.String)

getProcesses

public Collection<org.drools.definition.process.Process> getProcesses()
Specified by:
getProcesses in interface org.drools.definition.KnowledgePackage

readExternal

public void readExternal(ObjectInput in)
                  throws IOException,
                         ClassNotFoundException
Specified by:
readExternal in interface Externalizable
Throws:
IOException
ClassNotFoundException

writeExternal

public void writeExternal(ObjectOutput out)
                   throws IOException
Specified by:
writeExternal in interface Externalizable
Throws:
IOException

equals

public boolean equals(Object o)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

toString

public String toString()
Overrides:
toString in class Object


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