org.jboss.security.propertyeditor
Class SecurityDomainEditor
java.lang.Object
java.beans.PropertyEditorSupport
org.jboss.security.propertyeditor.SecurityDomainEditor
- All Implemented Interfaces:
- java.beans.PropertyEditor
- public class SecurityDomainEditor
- extends java.beans.PropertyEditorSupport
A property editor for org.jboss.security.SecurityDomain types. This editor
transforms a jndi name string to a SecurityDomain by looking up the binding.
The only unusual aspect of this editor is that the jndi name is usually of
the form java:/jaas/xxx and the java:/jaas context is a dynamic ObjectFactory
that will create a binding for any xxx. If there is an attempt to lookup a
binding before it has been created by the underlying service that provides
the SecurityDomain, the lookup will return the default security service
which typically does not implement SecurityDomain. In this case, the editor
will create a proxy that delays the lookup of the SecurityDomain until the
first method invocation against the proxy.
Method Summary |
java.lang.String |
getAsText()
Return the original security domain jndi name since we cannot get
this back from the SecurityDomain itself. |
void |
setAsText(java.lang.String text)
Get the SecurityDomain from the text which is the jndi name of the
SecurityDomain binding. |
Methods inherited from class java.beans.PropertyEditorSupport |
addPropertyChangeListener, firePropertyChange, getCustomEditor, getJavaInitializationString, getTags, getValue, isPaintable, paintValue, removePropertyChangeListener, setValue, supportsCustomEditor |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SecurityDomainEditor
public SecurityDomainEditor()
setAsText
public void setAsText(java.lang.String text)
- Get the SecurityDomain from the text which is the jndi name of the
SecurityDomain binding. This may have to create a proxy if the current
value of the binding is not a SecurityDomain.
- Parameters:
text
- - the name of the Principal
getAsText
public java.lang.String getAsText()
- Return the original security domain jndi name since we cannot get
this back from the SecurityDomain itself.
- Returns: