public abstract class UIHandler extends Callee
UIHandler
s together with
shared code. Only instances of this class can handle UIRequest
s. The
convention of the IUIBus
regarding the registration parameters is the
following:
UIHandler
s provide only at the registration time info about
themselvesbusResourceURI, owner, theBus
Modifier | Constructor and Description |
---|---|
protected |
UIHandler(ModuleContext context,
UIHandlerProfile initialSubscription)
Instantiates a new
UIHandler . |
protected |
UIHandler(ModuleContext context,
UIHandlerProfile[] initialSubscriptions)
Instantiates a new
UIHandler . |
Modifier and Type | Method and Description |
---|---|
abstract void |
adaptationParametersChanged(String dialogID,
String changedProp,
Object newVal)
Adaptation parameters changed.
|
void |
addNewRegParams(UIHandlerProfile newSubscription)
Adds the new
UIHandler registration parameters. |
void |
busDyingOut(AbstractBus b)
This method is called when the bus is stopped to announce this to the bus
members.
|
abstract void |
communicationChannelBroken()
Method to be called when the communication of the
UIHandler with
the IDialogManager is lost. |
abstract Resource |
cutDialog(String dialogID)
Cut dialog.
|
void |
dialogFinished(UIResponse uiResponse)
Dialog finished.
|
String |
getMyID()
|
List<UIHandlerProfile> |
getRealizedHandlerProfiles() |
void |
handleRequest(BusMessage msg)
Handle request.
|
abstract void |
handleUICall(UIRequest uiRequest)
Handle ui call (
UIRequest ). |
protected void |
removeMatchingRegParams(UIHandlerProfile oldSubscription)
Removes the matching registration parameters.
|
void |
userLoggedIn(Resource user,
AbsLocation loginLocation)
User logged in.
|
close, getComment, getLabel, getType, getURI, setComment, setLabel
protected UIHandler(ModuleContext context, UIHandlerProfile initialSubscription)
UIHandler
.context
- the contextinitialSubscription
- the initial subscriptionNullPointerException
- if initialSubscription is null or one of the elements of that
array is nullprotected UIHandler(ModuleContext context, UIHandlerProfile[] initialSubscriptions)
UIHandler
.context
- the contextinitialSubscription
- the initial subscriptionNullPointerException
- if initialSubscriptions is null or one of the elements of
that array is nullpublic abstract void adaptationParametersChanged(String dialogID, String changedProp, Object newVal)
dialogID
- the dialog idchangedProp
- the changed propnewVal
- the new valpublic final void addNewRegParams(UIHandlerProfile newSubscription)
UIHandler
registration parameters.newSubscription
- the new subscription - as a UIHandlerProfile
NullPointerException
- if newSubscription is nullpublic final void busDyingOut(AbstractBus b)
BusMember
busDyingOut
in class BusMember
b
- bus on which this member has been registeredBusMember.busDyingOut(AbstractBus)
public abstract void communicationChannelBroken()
UIHandler
with
the IDialogManager
is lost. All dialogs must be de-renderized
(handlers may whant to inform the user about why de dialogs are being
de-renderized). The bus will automatically resend all HandlerProfiles.public abstract Resource cutDialog(String dialogID)
dialogID
- the dialog idForm
filled by the user up to
the moment this call is performed.public final void dialogFinished(UIResponse uiResponse)
Submit
or a SubdialogTrigger
.uiResponse
- the UIResponse
public final void handleRequest(BusMessage msg)
msg
- the messagepublic abstract void handleUICall(UIRequest uiRequest)
uiRequest
- the UIRequest
protected final void removeMatchingRegParams(UIHandlerProfile oldSubscription)
oldSubscription
- the old subscriptionpublic final void userLoggedIn(Resource user, AbsLocation loginLocation)
user
- the User
, It is declared as Resource because the type
User is defined in the Profiling Ontology. The type is not
needed for for matchmaking Either.loginLocation
- the login locationpublic List<UIHandlerProfile> getRealizedHandlerProfiles()
UIHandlerProfile
sCopyright © 2018 universAAL Consortium. All rights reserved.