Nuxeo ECM Projects 5.4.3-SNAPSHOT

org.nuxeo.ecm.webapp.security
Class UserDisplayConverter

java.lang.Object
  extended by org.nuxeo.ecm.webapp.security.UserDisplayConverter
All Implemented Interfaces:
Converter

public class UserDisplayConverter
extends Object
implements Converter

JSF Converter used for rendering, transforming a user id into the user display name.

Sample usage:

 
 lt;h:outputText
  converter="#{userSuggestionActions.userConverter}">
  <f:attribute name="prefixed" value="false" />
  <f:attribute name="userDirectory" value="#{userManager.userDirectoryName}" />
  <f:attribute name="userSchema" value="#{userManager.userSchemaName}" />
  <f:attribute name="firstNameField" value="firstName" />
  <f:attribute name="lastNameField" value="lastName" />
 lt;/h:outputText>
 
 

Author:
Anahide Tchertchian

Constructor Summary
UserDisplayConverter()
           
 
Method Summary
 Object getAsObject(FacesContext context, UIComponent component, String value)
          Returns given value (does not do any reverse conversion)
 String getAsString(FacesContext context, UIComponent component, Object value)
          Tries to build the user display name according to information passed as attribute to the component holding the converter.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UserDisplayConverter

public UserDisplayConverter()
Method Detail

getAsObject

public Object getAsObject(FacesContext context,
                          UIComponent component,
                          String value)
Returns given value (does not do any reverse conversion)

Specified by:
getAsObject in interface Converter

getAsString

public String getAsString(FacesContext context,
                          UIComponent component,
                          Object value)
Tries to build the user display name according to information passed as attribute to the component holding the converter.

Handled attributes are:

Specified by:
getAsString in interface Converter

Nuxeo ECM Projects 5.4.3-SNAPSHOT

Copyright © 2011 Nuxeo SAS. All Rights Reserved.