public abstract class AssociativePropositionalFormula extends PropositionalFormula implements AssociativeFormula<PropositionalFormula>, AssociativeFormulaSupport.AssociativeSupportBridge, java.util.Collection<PropositionalFormula>
| Modifier and Type | Field and Description |
|---|---|
protected AssociativeFormulaSupport<PropositionalFormula> |
support
The inner formulas of this formula
|
| Constructor and Description |
|---|
AssociativePropositionalFormula()
Creates a new (empty) associative formula.
|
AssociativePropositionalFormula(java.util.Collection<? extends PropositionalFormula> formulas)
Creates a new associative formula with the given inner formulas.
|
AssociativePropositionalFormula(PropositionalFormula first,
PropositionalFormula second)
Creates a new associative formula with the two given formulae
|
| Modifier and Type | Method and Description |
|---|---|
void |
add(int index,
PropositionalFormula element) |
boolean |
add(PropositionalFormula f) |
boolean |
addAll(java.util.Collection<? extends PropositionalFormula> c) |
boolean |
addAll(int index,
java.util.Collection<? extends PropositionalFormula> c) |
void |
clear() |
boolean |
contains(java.lang.Object o) |
boolean |
containsAll(java.util.Collection<?> c) |
Signature |
createEmptySignature() |
boolean |
equals(java.lang.Object obj) |
PropositionalFormula |
get(int index) |
java.util.Set<Proposition> |
getAtoms()
Processes the set of all atoms which appear in this formula
|
java.util.List<PropositionalFormula> |
getFormulas() |
<C extends SimpleLogicalFormula> |
getFormulas(java.lang.Class<C> cls)
Process the formulas of type C that are children of this associative
formula
|
java.util.Set<PropositionalFormula> |
getLiterals()
Returns all literals, i.e.
|
java.util.Set<PropositionalPredicate> |
getPredicates()
Processes the set of all predicates which appear in this
formula
|
PropositionalSignature |
getSignature()
Returns the signature of the language of this formula.
|
int |
hashCode() |
int |
indexOf(java.lang.Object o) |
boolean |
isEmpty() |
java.util.Iterator<PropositionalFormula> |
iterator() |
int |
lastIndexOf(java.lang.Object o) |
java.util.ListIterator<PropositionalFormula> |
listIterator() |
java.util.ListIterator<PropositionalFormula> |
listIterator(int index) |
int |
numberOfOccurrences(Proposition p)
Returns the number of occurrences of the given proposition
within this formula
|
PropositionalFormula |
remove(int index) |
boolean |
remove(java.lang.Object o) |
boolean |
removeAll(java.util.Collection<?> c) |
boolean |
retainAll(java.util.Collection<?> c) |
PropositionalFormula |
set(int index,
PropositionalFormula element) |
int |
size() |
java.util.List<PropositionalFormula> |
subList(int fromIndex,
int toIndex) |
java.lang.Object[] |
toArray() |
java.lang.Object[] |
toArray(java.lang.Object[] a) |
java.lang.String |
toString() |
clone, collapseAssociativeFormulas, combineWithAnd, combineWithOr, complement, getModels, getModels, getPredicateCls, getPrimeImplicants, getUniformProbability, isConjunctiveClause, isLiteral, replace, resolvableWith, resolveWith, toBlakeCanonicalForm, toCnf, toDnf, toNnf, trimfinalize, getClass, notify, notifyAll, wait, wait, waitclone, getPredicateCls, isLiteralcreateEmptyFormula, getEmptySymbol, getOperatorSymbolprotected AssociativeFormulaSupport<PropositionalFormula> support
public AssociativePropositionalFormula()
public AssociativePropositionalFormula(java.util.Collection<? extends PropositionalFormula> formulas)
formulas - a collection of formulas.public AssociativePropositionalFormula(PropositionalFormula first, PropositionalFormula second)
first - a propositional formula.second - a propositional formula.public java.util.Set<PropositionalPredicate> getPredicates()
SimpleLogicalFormulagetPredicates in interface SimpleLogicalFormulagetPredicates in class PropositionalFormulapublic java.util.List<PropositionalFormula> getFormulas()
getFormulas in interface AssociativeFormula<PropositionalFormula>public <C extends SimpleLogicalFormula> java.util.Set<C> getFormulas(java.lang.Class<C> cls)
AssociativeFormulagetFormulas in interface AssociativeFormula<PropositionalFormula>cls - the class structure defining the type of formulas which
are searched.public java.util.Set<Proposition> getAtoms()
SimpleLogicalFormulagetAtoms in interface SimpleLogicalFormulagetAtoms in class PropositionalFormulapublic java.util.Set<PropositionalFormula> getLiterals()
PropositionalFormulagetLiterals in class PropositionalFormulapublic java.lang.String toString()
toString in class java.lang.Objectpublic PropositionalSignature getSignature()
FormulagetSignature in interface FormulagetSignature in class PropositionalFormulapublic Signature createEmptySignature()
createEmptySignature in interface AssociativeFormulaSupport.AssociativeSupportBridgepublic int numberOfOccurrences(Proposition p)
PropositionalFormulanumberOfOccurrences in class PropositionalFormulap - some propositionpublic int hashCode()
hashCode in interface java.util.Collection<PropositionalFormula>hashCode in interface java.util.List<PropositionalFormula>hashCode in interface SimpleLogicalFormulahashCode in class PropositionalFormulapublic boolean equals(java.lang.Object obj)
equals in interface java.util.Collection<PropositionalFormula>equals in interface java.util.List<PropositionalFormula>equals in interface SimpleLogicalFormulaequals in class PropositionalFormulapublic boolean add(PropositionalFormula f)
add in interface java.util.Collection<PropositionalFormula>add in interface java.util.List<PropositionalFormula>public boolean addAll(java.util.Collection<? extends PropositionalFormula> c)
addAll in interface java.util.Collection<PropositionalFormula>addAll in interface java.util.List<PropositionalFormula>public void clear()
clear in interface java.util.Collection<PropositionalFormula>clear in interface java.util.List<PropositionalFormula>public boolean contains(java.lang.Object o)
contains in interface java.util.Collection<PropositionalFormula>contains in interface java.util.List<PropositionalFormula>public boolean containsAll(java.util.Collection<?> c)
containsAll in interface java.util.Collection<PropositionalFormula>containsAll in interface java.util.List<PropositionalFormula>public boolean isEmpty()
isEmpty in interface java.util.Collection<PropositionalFormula>isEmpty in interface java.util.List<PropositionalFormula>public java.util.Iterator<PropositionalFormula> iterator()
iterator in interface java.lang.Iterable<PropositionalFormula>iterator in interface java.util.Collection<PropositionalFormula>iterator in interface java.util.List<PropositionalFormula>public boolean remove(java.lang.Object o)
remove in interface java.util.Collection<PropositionalFormula>remove in interface java.util.List<PropositionalFormula>public boolean removeAll(java.util.Collection<?> c)
removeAll in interface java.util.Collection<PropositionalFormula>removeAll in interface java.util.List<PropositionalFormula>public boolean retainAll(java.util.Collection<?> c)
retainAll in interface java.util.Collection<PropositionalFormula>retainAll in interface java.util.List<PropositionalFormula>public int size()
size in interface java.util.Collection<PropositionalFormula>size in interface java.util.List<PropositionalFormula>public java.lang.Object[] toArray()
toArray in interface java.util.Collection<PropositionalFormula>toArray in interface java.util.List<PropositionalFormula>public java.lang.Object[] toArray(java.lang.Object[] a)
toArray in interface java.util.Collection<PropositionalFormula>toArray in interface java.util.List<PropositionalFormula>public void add(int index,
PropositionalFormula element)
add in interface java.util.List<PropositionalFormula>public boolean addAll(int index,
java.util.Collection<? extends PropositionalFormula> c)
addAll in interface java.util.List<PropositionalFormula>public PropositionalFormula get(int index)
get in interface java.util.List<PropositionalFormula>public int indexOf(java.lang.Object o)
indexOf in interface java.util.List<PropositionalFormula>public int lastIndexOf(java.lang.Object o)
lastIndexOf in interface java.util.List<PropositionalFormula>public java.util.ListIterator<PropositionalFormula> listIterator()
listIterator in interface java.util.List<PropositionalFormula>public java.util.ListIterator<PropositionalFormula> listIterator(int index)
listIterator in interface java.util.List<PropositionalFormula>public PropositionalFormula remove(int index)
remove in interface java.util.List<PropositionalFormula>public PropositionalFormula set(int index, PropositionalFormula element)
set in interface java.util.List<PropositionalFormula>public java.util.List<PropositionalFormula> subList(int fromIndex, int toIndex)
subList in interface java.util.List<PropositionalFormula>