global.sandbox.xmlutilities
Enum OutputFormat.OutputMethod

java.lang.Object
  extended by java.lang.Enum<OutputFormat.OutputMethod>
      extended by global.sandbox.xmlutilities.OutputFormat.OutputMethod
All Implemented Interfaces:
OutputFormat.ConfigurationValue, Serializable, Comparable<OutputFormat.OutputMethod>
Enclosing class:
OutputFormat

public static enum OutputFormat.OutputMethod
extends Enum<OutputFormat.OutputMethod>
implements OutputFormat.ConfigurationValue

Typed representation of output method with appropriate and expected values by Transformer.

Version:
1.2
Author:
Petr Hadraba

Enum Constant Summary
CUSTOM
          Custom method.
HTML
          HTML output method.
TEXT
          Plain text output method.
XML
          XML output method.
 
Field Summary
private  String defaultCode
          Default code.
private  String value
          Used for custom value.
 
Method Summary
 String getValue()
          Returns code required by Transformer#setOutputProperties(java.util.Properties).
 void setValue(String code)
          Sets value for custom method.
static OutputFormat.OutputMethod valueOf(String name)
          Returns the enum constant of this type with the specified name.
static OutputFormat.OutputMethod[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

XML

public static final OutputFormat.OutputMethod XML
XML output method.


HTML

public static final OutputFormat.OutputMethod HTML
HTML output method.


TEXT

public static final OutputFormat.OutputMethod TEXT
Plain text output method.


CUSTOM

public static final OutputFormat.OutputMethod CUSTOM
Custom method.

Field Detail

defaultCode

private final String defaultCode
Default code.


value

private String value
Used for custom value.

Method Detail

values

public static OutputFormat.OutputMethod[] 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 (OutputFormat.OutputMethod c : OutputFormat.OutputMethod.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static OutputFormat.OutputMethod valueOf(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:
IllegalArgumentException - if this enum type has no constant with the specified name
NullPointerException - if the argument is null

getValue

public String getValue()
Returns code required by Transformer#setOutputProperties(java.util.Properties).

Specified by:
getValue in interface OutputFormat.ConfigurationValue
Returns:
text

setValue

public void setValue(String code)
Sets value for custom method.

Parameters:
code - code


Copyright © 2006–2018. All rights reserved.