Enum ExprPrinter
- java.lang.Object
-
- java.lang.Enum<ExprPrinter>
-
- ru.ispras.fortress.expression.printer.ExprPrinter
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<ExprPrinter>
,ExprTreePrinter
public enum ExprPrinter extends java.lang.Enum<ExprPrinter> implements ExprTreePrinter
This enumeration contains identifiers of particular expression tree printers.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description JAVA
The expression tree printer that produces Java code.SMT
The expression tree printer that produces SMT-LIB code.TEXT
The expression tree printer that produces well-formatted human readable expression text.VERILOG
The Verilog-style expression tree printer.VHDL
The VHDL-style expression tree printer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ExprTreePrinter
getExprPrinter(java.lang.String name)
Returns expression printer with the specified name.static java.lang.String[]
names()
Returns an array of expression tree printer names.java.lang.String
toString(Node node)
Returns the string representation of the given expression tree.static ExprPrinter
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static ExprPrinter[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
TEXT
public static final ExprPrinter TEXT
The expression tree printer that produces well-formatted human readable expression text.
-
JAVA
public static final ExprPrinter JAVA
The expression tree printer that produces Java code.
-
SMT
public static final ExprPrinter SMT
The expression tree printer that produces SMT-LIB code.
-
VHDL
public static final ExprPrinter VHDL
The VHDL-style expression tree printer.
-
VERILOG
public static final ExprPrinter VERILOG
The Verilog-style expression tree printer.
-
-
Method Detail
-
values
public static ExprPrinter[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (ExprPrinter c : ExprPrinter.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static ExprPrinter valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
names
public static java.lang.String[] names()
Returns an array of expression tree printer names.- Returns:
- printer names
-
getExprPrinter
public static ExprTreePrinter getExprPrinter(java.lang.String name)
Returns expression printer with the specified name.- Parameters:
name
- printer name- Returns:
ExprTreePrinter
expression printer object ornull
if there is no printer with such name
-
toString
public java.lang.String toString(Node node)
Description copied from interface:ExprTreePrinter
Returns the string representation of the given expression tree.- Specified by:
toString
in interfaceExprTreePrinter
- Parameters:
node
- the expression tree to be printed.- Returns:
- the string representation of the expression tree.
-
-