protected String naryOperator(final NAryOperator operator, final String opString) {
        final StringBuilder sb = new StringBuilder();
        int count = 0;
        final int size = operator.numberOfOperands();
        Formula last = null;
        for (final Formula op : operator) {
            if (++count == size) {
                last = op;
            } else {
                sb.append(operator.type().precedence() < op.type().precedence() ? this.toString(op) : this.bracket(op));
                sb.append(opString);
            }
        }
        if (last != null) {
            sb.append(operator.type().precedence() < last.type().precedence() ? this.toString(last) : this.bracket(last));
        }
        return sb.toString();
    }
protected String naryOperator ( final NAryOperator operator , final String opString ) { final StringBuilder sb = new StringBuilder ( ) ; int count = 0 ; final int size = operator . numberOfOperands ( ) ; Formula last = null ; for ( final Formula op : operator ) { if ( ++ count == size ) { last = op ; } else { sb . append ( operator . type ( ) . precedence ( ) < op . type ( ) . precedence ( ) ? this . toString ( op ) : this . bracket ( op ) ) ; sb . append ( opString ) ; } } if ( last != null ) { sb . append ( operator . type ( ) . precedence ( ) < last . type ( ) . precedence ( ) ? this . toString ( last ) : this . bracket ( last ) ) ; } return sb . toString ( ) ; }
Returns the string representation of an n-ary operator.

@param operator the n-ary operator
@param opString the operator string
@return the string representation