Top Description Fields Constructors Methods
javax.faces.convert

public Class ByteConverter

extends Object
implements Converter
Class Inheritance
All Implemented Interfaces
javax.faces.convert.Converter
Imports
javax.faces.component.UIComponent, javax.faces.context.FacesContext

Converter implementation for java.lang.Byte (and byte primitive) values.

Field Summary

Modifier and TypeField and Description
public static final String
BYTE_ID

The message identifier of the javax.faces.application.FacesMessage to be created if the conversion to Byte fails.

public static final String
CONVERTER_ID

The standard converter id for this converter.

public static final String
STRING_ID

The message identifier of the javax.faces.application.FacesMessage to be created if the conversion of the Byte value to String fails.

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public Object
getAsObject(FacesContext
FacesContext for the request being processed
context
,
UIComponent
UIComponent with which this model object value is associated
component
,
String
String value to be converted (may be null)
value
)

Implements javax.faces.convert.Converter.getAsObject.

Convert the specified string value, which is associated with the specified UIComponent, into a model data object that is appropriate for being stored during the Process Validations phase of the request processing lifecycle.

public String
getAsString(FacesContext
FacesContext for the request being processed
context
,
UIComponent
UIComponent with which this model object value is associated
component
,
Object
Model object value to be converted (may be null)
value
)

Implements javax.faces.convert.Converter.getAsString.

Convert the specified model object value, which is associated with the specified UIComponent, into a String that is suitable for being included in the response generated during the Render Response phase of the request processing lifeycle.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

BYTE_IDback to summary
public static final String BYTE_ID

The message identifier of the javax.faces.application.FacesMessage to be created if the conversion to Byte fails. The message format string for this message may optionally include the following placeholders:

  • {0} replaced by the unconverted value.
  • {1} replaced by an example value.
  • {2} replaced by a String whose value is the label of the input component that produced this message.
CONVERTER_IDback to summary
public static final String CONVERTER_ID

The standard converter id for this converter.

STRING_IDback to summary
public static final String STRING_ID

The message identifier of the javax.faces.application.FacesMessage to be created if the conversion of the Byte value to String fails. The message format string for this message may optionally include the following placeholders:

  • {0} relaced by the unconverted value.
  • {1} replaced by a String whose value is the label of the input component that produced this message.

Constructor Detail

ByteConverterback to summary
public ByteConverter()

Method Detail

getAsObjectback to summary
public Object getAsObject(FacesContext context, UIComponent component, String value)

Implements javax.faces.convert.Converter.getAsObject.

Doc from javax.faces.convert.Converter.getAsObject.

Convert the specified string value, which is associated with the specified UIComponent, into a model data object that is appropriate for being stored during the Process Validations phase of the request processing lifecycle.

Parameters
context:FacesContext

FacesContext for the request being processed

component:UIComponent

UIComponent with which this model object value is associated

value:String

String value to be converted (may be null)

Returns:Object

null if the value to convert is null, otherwise the result of the conversion

Annotations
@Override
Exceptions
ConverterException:
if conversion cannot be successfully performed
NullPointerException:
if context or component is null
getAsStringback to summary
public String getAsString(FacesContext context, UIComponent component, Object value)

Implements javax.faces.convert.Converter.getAsString.

Doc from javax.faces.convert.Converter.getAsString.

Convert the specified model object value, which is associated with the specified UIComponent, into a String that is suitable for being included in the response generated during the Render Response phase of the request processing lifeycle.

Parameters
context:FacesContext

FacesContext for the request being processed

component:UIComponent

UIComponent with which this model object value is associated

value:Object

Model object value to be converted (may be null)

Returns:String

a zero-length String if value is null, otherwise the result of the conversion

Annotations
@Override
Exceptions
ConverterException:
if conversion cannot be successfully performed
NullPointerException:
if context or component is null