public class CallbackHandlerPolicyContextHandler extends Object implements PolicyContextHandler
Constructor and Description |
---|
CallbackHandlerPolicyContextHandler() |
Modifier and Type | Method and Description |
---|---|
Object |
getContext(String key,
Object data)
Access the CallbackHandler policy context data.
|
String[] |
getKeys()
This public method returns the keys identifying the context objects supported by the handler.
|
static void |
setCallbackHandler(CallbackHandler bean) |
boolean |
supports(String key)
This public method returns a boolean result indicating whether or not the handler supports the context object
identified by the (case-sensitive) key value.
|
public static void setCallbackHandler(CallbackHandler bean)
public Object getContext(String key, Object data) throws PolicyContextException
getContext
in interface PolicyContextHandler
key
- - "org.jboss.security.auth.spi.CallbackHandler"data
- currently unusedPolicyContextException
public String[] getKeys() throws PolicyContextException
PolicyContextHandler
This public method returns the keys identifying the context objects supported by the handler. The value of each
key supported by a handler must be a non-null String
value.
getKeys
in interface PolicyContextHandler
String
values identifying the context objects supported by the handler. The
array must not contain duplicate key values. In the unlikely case that the Handler supports no keys, the
handler must return a zero length array. The value null must never be returned by this method.PolicyContextException
- - if the implementation throws a checked exception that has not been accounted for by the method
signature. The exception thrown by the implementation class will be encapsulated (during construction)
in the thrown PolicyContextException
.public boolean supports(String key) throws PolicyContextException
PolicyContextHandler
This public method returns a boolean result indicating whether or not the handler supports the context object identified by the (case-sensitive) key value.
supports
in interface PolicyContextHandler
key
- - a String
value identifying a context object that could be supported by the handler. The value
of this parameter must not be null.PolicyContextException
- - if the implementation throws a checked exception that has not been accounted for by the method
signature. The exception thrown by the implementation class will be encapsulated (during construction)
in the thrown PolicyContextException
.Copyright © 2019 JBoss by Red Hat. All rights reserved.