You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mina.apache.org by "Emmanuel Lecharny (JIRA)" <ji...@apache.org> on 2010/01/08 13:38:54 UTC
[jira] Commented: (DIRMINA-754) Javadoc omission in
IoFilterChain#fireMessageSent()
[ https://issues.apache.org/jira/browse/DIRMINA-754?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12797999#action_12797999 ]
Emmanuel Lecharny commented on DIRMINA-754:
-------------------------------------------
IMO, looking at the current Javadoc, ad the current impl I think it's totally FU :/
The DefaultIoFilterChain method fireMessageSent( WriteRequest) does :
public void fireMessageSent(WriteRequest request) {
... (blah)
Entry head = this.head;
callNextMessageSent(head, session, request);
}
private void callNextMessageSent(Entry entry, IoSession session,
WriteRequest writeRequest) {
try {
IoFilter filter = entry.getFilter();
NextFilter nextFilter = entry.getNextFilter();
filter.messageSent(nextFilter, session,
writeRequest);
} catch (Throwable e) {
fireExceptionCaught(e);
}
}
We see that we move to the head of the filter chain, and call the messageSent( filter, session, request ) from he beginning.
It has nothing to do with IoHandler at this point.
I would rather replace the Javadoc by something like :
/**
* Fires a {@link IoFilter#messageSent(NextFilter, IoSession, Object)} event. Most users don't need to call
* this method at all. Please use this method only when you implement a new transport or
* fire a virtual event.
*/
wdyt ?
(The very same for all the other methods, btw)
> Javadoc omission in IoFilterChain#fireMessageSent()
> ---------------------------------------------------
>
> Key: DIRMINA-754
> URL: https://issues.apache.org/jira/browse/DIRMINA-754
> Project: MINA
> Issue Type: Improvement
> Components: Core
> Affects Versions: 2.0.0-RC1
> Environment: N/A
> Reporter: Bogdan Pistol
> Priority: Trivial
> Fix For: 2.0.0-RC1
>
>
> The javadoc of the org.apache.mina.core.filterchain.IoFilterChain#fireMessageSent() is
> /**
> * Fires a {@link IoHandler#sessionOpened(IoSession)} event. Most users don't need to call
> * this method at all. Please use this method only when you implement a new transport or
> * fire a virtual event.
> */
> public void fireMessageSent(WriteRequest request);
> And instead a better javadoc would be:
> /**
> * Fires a {@link IoHandler#messageSent(IoSession, Object)} event. Most users don't need to call
> * this method at all. Please use this method only when you implement a new transport or
> * fire a virtual event.
> */
> public void fireMessageSent(WriteRequest request);
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.