@Retention(value=RUNTIME)
@Target(value=TYPE)
@Documented
public @interface EReplyInfo
ERequestMessage
. This annotation contains
the EReplyMessage
classes which may be sent in reply
to this request. The class EReplyMessage
does not
need to be listed since it that message is allowed for all
request messages.
This annotation is cumulative from ERequestMessage
down through extending request message classes. Since
ERequestMessage
defines EReplyInfo
to allow
EReplyMessage
as a reply. This means
EReplyMessage
may be sent in reply to any request.
As of eBus release 5.6.0 this annotation was modified to
contain two more attributes: mayCancel
and
cancelRequest
. These attributes are used to mark
whether a request may be unilaterally canceled by calling
ERequestFeed.ERequest.close
and, if not, then
whether request may be canceled using a separate cancel
request message. The point behind using a cancel request
message is to allow the replier a chance to reject that cancel
request.
By default a request may be unilaterally close
ed.
Otherwise there are two cases for using this annotation:
@EReplyInfo(mayClose = false)
.
Note that the cancelRequest
is not set.
@EReplyInfo(mayClose = false, cancelRequest = ECancelRequest.class)
.
Modifier and Type | Required Element and Description |
---|---|
java.lang.Class<? extends EReplyMessage>[] |
replyMessageClasses
Returns the message classes which may be sent in reply
to a request message.
|
Modifier and Type | Optional Element and Description |
---|---|
boolean |
mayClose
|
public abstract java.lang.Class<? extends EReplyMessage>[] replyMessageClasses
public abstract boolean mayClose
true
if
ERequestFeed.ERequest.inactivate()
may be used to
cancel ERequestMessage
. Returns false
if
inactivate()
may not be used to cancel request.
false
is generally returned if:
inactivate
.
Default value is true
which means the request may
be directly closed.
true
if request can be inactivated and
false
if inactivation is not allowed.Copyright © 2001 - 2024. Charles W. Rapp. All rights reserved.