Package org.jreliability.booleanfunction
Class TermUtils
java.lang.Object
org.jreliability.booleanfunction.TermUtils
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static class
-
Method Summary
Modifier and TypeMethodDescriptionstatic Term
getTermFromString
(String string) static <T> Set
<T> getVariables
(Term term) Returns the variables included in aTerm
.static <T> void
getVariables
(Term term, Set<T> set) Adds the variables included in aTerm
to a given set of variables.protected static Term
protected static Object
toObject
(TermUtils.ParseString string)
-
Method Details
-
getVariables
Returns the variables included in aTerm
.- Type Parameters:
T
- the type of the variables- Parameters:
term
- the term- Returns:
- the variables included in the term
-
getVariables
Adds the variables included in aTerm
to a given set of variables.- Type Parameters:
T
- the type of the variables- Parameters:
term
- the termset
- the set of variables
-
getTermFromString
- Parameters:
string
- the string encoding the term- Returns:
- a term from a given string
-
parse
Parses aTerm
from a given helperObject
that has been derived from the originalString
encoding theTerm
.- Parameters:
object
- the helper object- Returns:
- a term from a given helper object
-
toObject
Transforms a givenString
to a helperObject
that representsTerm
s asList
s of helperObject
s and variables asString
s.- Parameters:
string
- the string encoding theTerm
- Returns:
- a helper object to parse the given string
-