Overview | Package | Class | Use | Tree | Serialized | Deprecated | Index | Help
| ABLE 2.3.0 07/13/2005 14:21:00
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.ibm.able.rules
Class AblePredicateFact

    java.lang.Object
      com.ibm.able.rules.AbleRule
          com.ibm.able.rules.AblePredicateRule
              com.ibm.able.rules.AblePredicateFact

All Implemented Interfaces:
  java.io.Serializable

public class AblePredicateFact
extends AblePredicateRule
implements java.io.Serializable

This class represents a predicate fact, a single predicate.

See Also:
  Serialized Form

Field Summary
`protected AblePredicate` | `myAssertion` myAssertion is a predicate which can be ground or non-ground.

Fields inherited from class com.ibm.able.rules.AblePredicateRule
`copyId, myAntecedents, myConsequent, myCuts, myVariables`

Fields inherited from class com.ibm.able.rules.AbleRule
`myBooleanTruth, myBreakpoint, myComment, myEnabled, myFinalFlag, myFiredCount, myFiredFlag, myId, myLabel, myLocation, myPreConditions, myPriority, myPrompt, myProperties, myRdRefs, myRuleBlock, myRuleSet, myTemplateFlag, myTemplateName, myTemplateValues, myWrRefs, PriorityDefault, RuleIdInitial`

Constructor Summary
`AblePredicateFact(int theId, java.lang.String theLabel, AblePredicate theAssertion, AbleRuleSet theRuleSet)` Create a new predicate fact rule with a default priority.
`AblePredicateFact(int theId, java.lang.String theLabel, AbleRd thePriority, AblePredicate theAssertion, AbleRuleSet theRuleSet)` Create a new predicate fact rule with the specified priority.
`AblePredicateFact(java.lang.String theLabel, AblePredicate theAssertion, AbleRuleSet theRuleSet)` Create a new predicate fact rule with a default priority.
`AblePredicateFact(java.lang.String theLabel, AbleRd thePriority, AblePredicate theAssertion, AbleRuleSet theRuleSet)` Create a new predicate fact rule with the specified priority.

Method Summary
`java.lang.String` | `arlString()` Return a formal Able Rule Language (RL) string.
`java.lang.String` | `armlString()` Return a formal XML string.
`AblePredicateRule` | `createMatchFact()` Create a duplicate of this rule with new variables
`boolean` | `equals(AblePredicate otherPredicate)` Returns true if the facts are equal (same predicate and same args)
`boolean` | `equals(AblePredicateFact otherFact)` Returns true if the facts are equal (same predicate and same args)
`AblePredicate` | `getAssertion()` Retrieve the rule's assertion clause, if any.
`java.lang.String` | `getSignature()` Returns the signature of the rule head (consequent)
`int` | `hashCode()`
`java.lang.String` | `toString()` Retrieve a string describing (the contents of) the object.
`protected java.lang.String` | `trcString(int theTraceStringFlavor)`
`java.lang.String` | `xmlString()` Return a formal XML string.

Methods inherited from class com.ibm.able.rules.AblePredicateRule
`applyBindings, createMatchRule, displayBindings, findAllVariables, getAntecedents, getBindings, getConsequent, getCuts, getTemplateString, numberOfAntecedents, reset, resetAllVariables, setBindings, traceString`

Methods inherited from class com.ibm.able.rules.AbleRule
`addHeaderRdReferences, addRdReference, addRdReferences, addWrReference, addWrReferences, arlActionBlockString, arlPreConditionsString, armlPreConditionsString, armlPriorityString, armlPropertiesString, checkTimePeriodPreConditions, clearBreakpoint, getArlComment, getBooleanTruth, getBreakpoint, getComment, getId, getIdLabelString, getLabel, getLocation, getMetaData, getPreConditions, getPriority, getPrompt, getPromptString, getProperties, getProperty, getRdReferences, getTemplateActionBlockString, getTemplateHeaderString, getTemplateName, getTemplateValues, getTemplateVars, getWrReferences, isDefaultPriority, isEnabled, isFinal, isFired, isGeneratedFromTemplate, isTemplate, logTrace, removeProperty, setBooleanTruth, setBreakpoint, setComment, setEnabled, setFinal, setFired, setId, setLocation, setMetaData, setPreConditions, setPriority, setPrompt, setProperties, setProperty, setTemplate, setTemplateName, setTemplateValues, xmlPreConditionsString, xmlPriorityString`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, notify, notifyAll, wait, wait, wait`

Field Detail

### myAssertion

    protected AblePredicate myAssertion

  myAssertion is a predicate which can be ground or non-ground.

Constructor Detail

### AblePredicateFact

    public AblePredicateFact(java.lang.String theLabel,
                             AblePredicate theAssertion,
                             AbleRuleSet theRuleSet)

  Create a new predicate fact rule with a default priority.

Parameters:
  `theLabel` - The unique label, or name, of this rule.

  `theAssertion` - A single predicate that defines this fact.
  `theRuleSet` - A ruleset object to which this predicate belongs.

### AblePredicateFact

    public AblePredicateFact(java.lang.String theLabel,
                             AbleRd thePriority,
                             AblePredicate theAssertion,
                             AbleRuleSet theRuleSet)

  Create a new predicate fact rule with the specified priority.

Parameters:
  `theLabel` - The unique label, or name, of this rule.

  `thePriority` - The priority of this rule.

  `theAssertion` - A single predicate that defines this fact.

### AblePredicateFact

    public AblePredicateFact(int theId,
                             java.lang.String theLabel,
                             AblePredicate theAssertion,
                             AbleRuleSet theRuleSet)

  Create a new predicate fact rule with a default priority.

Parameters:
  `theId` - The unique Id of this rule.

  `theLabel` - The unique label, or name, of this rule.

  `theAssertion` - A single predicate that defines this fact.

  `theRuleSet` - A ruleset object to which this rule belongs.

### AblePredicateFact

    public AblePredicateFact(int theId,
                             java.lang.String theLabel,
                             AbleRd thePriority,
                             AblePredicate theAssertion,
                             AbleRuleSet theRuleSet)

  Create a new predicate fact rule with the specified priority.

Parameters:
  `theId` - The unique Id of this rule.

  `theLabel` - The unique label, or name, of this rule.

  `thePriority` - The priority of this rule. (not used in the predicate engine)

  `theAssertion` - A single predicate that defines this fact.

  `theRuleSet` - A ruleset object to which this rule belongs.

Method Detail

### createMatchFact

    public AblePredicateRule createMatchFact()

  Create a duplicate of this rule with new variables

### getAssertion

    public AblePredicate getAssertion()

  Retrieve the rule's assertion clause, if any.

  Returns:
    The assertion clause (predicate) of the rule.

### getSignature

    public java.lang.String getSignature()

  Returns the signature of the rule head (consequent)

  Overrides:
    `getSignature` in class `AblePredicateRule`

### arlString

    public java.lang.String arlString()

  Return a formal Able Rule Language (RL) string.

  Overrides:
    `arlString` in class `AblePredicateRule`
  Returns:
    A String describing the object in Able rule language.

### xmlString

    public java.lang.String xmlString()

  Return a formal XML string.

  Overrides:
    `xmlString` in class `AblePredicateRule`
  Returns:
    A String describing the object in XML.

### armlString

    public java.lang.String armlString()

  Return a formal XML string.

  Overrides:
    `armlString` in class `AblePredicateRule`
  Returns:
    A String describing the object in XML.

### equals

    public boolean equals(AblePredicateFact otherFact)

  Returns true if the facts are equal (same predicate and same args)

### equals

    public boolean equals(AblePredicate otherPredicate)

  Returns true if the facts are equal (same predicate and same args)

### hashCode

    public int hashCode()

### toString

    public java.lang.String toString()

  Retrieve a string describing (the contents of) the object.

  Overrides:
    `toString` in class `AblePredicateRule`
  Returns:
    A String containing the current contents of the object.

### trcString

    protected java.lang.String trcString(int theTraceStringFlavor)

  Overrides:
    `trcString` in class `AblePredicateRule`

Overview | Package | Class | Use | Tree | Serialized | Deprecated | Index | Help
| ABLE 2.3.0 07/13/2005 14:21:00
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

(C) Copyright IBM Corporation 1999, 2005