Top Description Inners Fields Constructors Methods
javax.faces.component

public Class UIGraphic

extends UIComponentBase
Class Inheritance
Known Direct Subclasses
javax.faces.component.html.HtmlGraphicImage
Imports
javax.el.ValueExpression, javax.faces.el.ValueBinding

UIGraphic is a UIComponent that displays a graphical image to the user. The user cannot manipulate this component; it is for display purposes only.

By default, the rendererType property must be set to "javax.faces.Image". This value can be changed by calling the setRendererType() method.

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv static enum
UIGraphic.PropertyKeys

Properties that are tracked by state saving.

Field Summary

Modifier and TypeField and Description
public static final String
COMPONENT_FAMILY

The standard component family for this component.

public static final String
COMPONENT_TYPE

The standard component type for this component.

Constructor Summary

AccessConstructor and Description
public
UIGraphic()

Create a new UIGraphic instance with default property values.

Method Summary

Modifier and TypeMethod and Description
public String
getFamily()

Implements abstract javax.faces.component.UIComponent.getFamily.

Return the identifier of the component family to which this component belongs.

public String

Returns:

the url.
getUrl
()

Return the image URL for this UIGraphic.

public Object

Returns:

the value.
getValue
()

Returns the value property of the UIGraphic.

public ValueBinding

Returns:

the value binding, or null.
getValueBinding
(String
Name of the attribute or property for which to retrieve a ValueBinding
name
)

Overrides javax.faces.component.UIComponentBase.getValueBinding.

Deprecated This has been replaced by getValueExpression(java.lang.String).

Return any ValueBinding set for value if a ValueBinding for url is requested; otherwise, perform the default superclass processing for this method.

public ValueExpression

Returns:

the value expression, or null.
getValueExpression
(String
Name of the attribute or property for which to retrieve a ValueExpression
name
)

Overrides javax.faces.component.UIComponent.getValueExpression.

Return any ValueExpression set for value if a ValueExpression for url is requested; otherwise, perform the default superclass processing for this method.

public void
setUrl(String
The new image URL
url
)

Set the image URL for this UIGraphic.

public void
setValue(Object
the new value
value
)

Sets the value property of the UIGraphic.

public void
setValueBinding(String
Name of the attribute or property for which to set a ValueBinding
name
,
ValueBinding
The ValueBinding to set, or null to remove any currently set ValueBinding
binding
)

Overrides javax.faces.component.UIComponentBase.setValueBinding.

Deprecated This has been replaced by setValueExpression.

Store any ValueBinding specified for url under value instead; otherwise, perform the default superclass processing for this method.

public void
setValueExpression(String
Name of the attribute or property for which to set a ValueExpression
name
,
ValueExpression
The ValueExpression to set, or null to remove any currently set ValueExpression
binding
)

Overrides javax.faces.component.UIComponent.setValueExpression.

Store any ValueExpression specified for url under value instead; otherwise, perform the default superclass processing for this method.

Inherited from javax.faces.component.UIComponentBase:
addClientBehavioraddFacesListenerbroadcastclearInitialStatedecodeencodeBeginencodeChildrenencodeEndfindComponentgetAttributesgetChildCountgetChildrengetClientBehaviorsgetClientIdgetDefaultEventNamegetDescriptorMapgetEventNamesgetFacesContextgetFacesListenersgetFacetgetFacetCountgetFacetsgetFacetsAndChildrengetIdgetListenersForEventClassgetParentgetPassThroughAttributesgetRenderergetRendererTypegetRendersChildreninvokeOnComponentisRenderedisTransientmarkInitialStateprocessDecodesprocessRestoreStateprocessSaveStateprocessUpdatesprocessValidatorsqueueEventremoveFacesListenerrestoreAttachedStaterestoreStatesaveAttachedStatesaveStatesetIdsetParentsetRenderedsetRendererTypesetTransientsubscribeToEventunsubscribeFromEvent

Field Detail

COMPONENT_FAMILYback to summary
public static final String COMPONENT_FAMILY

The standard component family for this component.

COMPONENT_TYPEback to summary
public static final String COMPONENT_TYPE

The standard component type for this component.

Constructor Detail

UIGraphicback to summary
public UIGraphic()

Create a new UIGraphic instance with default property values.

Method Detail

getFamilyback to summary
public String getFamily()

Implements abstract javax.faces.component.UIComponent.getFamily.

Doc from javax.faces.component.UIComponent.getFamily.

Return the identifier of the component family to which this component belongs. This identifier, in conjunction with the value of the rendererType property, may be used to select the appropriate Renderer for this component instance. Note this method should NOT return null

Returns:String

the component family (not null).

Annotations
@Override
getUrlback to summary
public String getUrl()

Return the image URL for this UIGraphic. This method is a typesafe alias for getValue().

Returns:String

the url.

getValueback to summary
public Object getValue()

Returns the value property of the UIGraphic. This will typically be rendered as an URL.

Returns:Object

the value.

getValueBindingback to summary
public ValueBinding getValueBinding(String name)

Overrides javax.faces.component.UIComponentBase.getValueBinding.

Deprecated

This has been replaced by getValueExpression(java.lang.String).

Return any ValueBinding set for value if a ValueBinding for url is requested; otherwise, perform the default superclass processing for this method.

Parameters
name:String

Name of the attribute or property for which to retrieve a ValueBinding

Returns:ValueBinding

the value binding, or null.

Annotations
@Override
Exceptions
NullPointerException:
if name is null
getValueExpressionback to summary
public ValueExpression getValueExpression(String name)

Overrides javax.faces.component.UIComponent.getValueExpression.

Return any ValueExpression set for value if a ValueExpression for url is requested; otherwise, perform the default superclass processing for this method.

Parameters
name:String

Name of the attribute or property for which to retrieve a ValueExpression

Returns:ValueExpression

the value expression, or null.

Annotations
@Override
Exceptions
NullPointerException:
if name is null
Since
1.2
setUrlback to summary
public void setUrl(String url)

Set the image URL for this UIGraphic. This method is a typesafe alias for setValue().

Parameters
url:String

The new image URL

setValueback to summary
public void setValue(Object value)

Sets the value property of the UIGraphic. This will typically be rendered as an URL.

Parameters
value:Object

the new value

setValueBindingback to summary
public void setValueBinding(String name, ValueBinding binding)

Overrides javax.faces.component.UIComponentBase.setValueBinding.

Deprecated

This has been replaced by setValueExpression.

Store any ValueBinding specified for url under value instead; otherwise, perform the default superclass processing for this method. In all cases, the superclass is relied on to convert the ValueBinding to a ValueExpression.

Parameters
name:String

Name of the attribute or property for which to set a ValueBinding

binding:ValueBinding

The ValueBinding to set, or null to remove any currently set ValueBinding

Annotations
@Override
Exceptions
NullPointerException:
if name is null
setValueExpressionback to summary
public void setValueExpression(String name, ValueExpression binding)

Overrides javax.faces.component.UIComponent.setValueExpression.

Store any ValueExpression specified for url under value instead; otherwise, perform the default superclass processing for this method.

Parameters
name:String

Name of the attribute or property for which to set a ValueExpression

binding:ValueExpression

The ValueExpression to set, or null to remove any currently set ValueExpression

Annotations
@Override
Exceptions
NullPointerException:
if name is null
Since
1.2
javax.faces.component back to summary

pack-priv final Enum UIGraphic.PropertyKeys

extends Enum<UIGraphic.PropertyKeys>
Class Inheritance

Properties that are tracked by state saving.

Field Summary

Modifier and TypeField and Description
public static final UIGraphic.PropertyKeys
value

The local value of this UIComponent.

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public static UIGraphic.PropertyKeys
public static UIGraphic.PropertyKeys[]
Inherited from java.lang.Enum:
clonecompareTodescribeConstableequalsfinalizegetDeclaringClasshashCodenameordinaltoStringvalueOf

Field Detail

valueback to summary
public static final UIGraphic.PropertyKeys value

The local value of this UIComponent.

Constructor Detail

PropertyKeysback to summary
private PropertyKeys()

Method Detail

valueOfback to summary
public static UIGraphic.PropertyKeys valueOf(String name)
valuesback to summary
public static UIGraphic.PropertyKeys[] values()