Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitc910ecb

Browse files
committed
Rename enums
1 parent14aef5e commitc910ecb

File tree

4 files changed

+23
-23
lines changed

4 files changed

+23
-23
lines changed

‎netbare-core/src/main/java/com/github/megatronking/netbare/gateway/IndexedInterceptor.java‎

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -21,54 +21,54 @@
2121
importjava.nio.ByteBuffer;
2222

2323
/**
24-
* Add the index parameter in the {@link #intercept(C1, ByteBuffer)} and
25-
* {@link #intercept(C2, ByteBuffer)}, it indicates the packet index in the session.
24+
* Add the index parameter in the {@link #intercept(ReqChain, ByteBuffer)} and
25+
* {@link #intercept(ResChain, ByteBuffer)}, it indicates the packet index in the session.
2626
* <p>
2727
* The index will be reset when the session finished.
2828
* </p>
2929
*
3030
* @author Megatron King
3131
* @since 2018-12-03 21:00
3232
*/
33-
publicabstractclassIndexedInterceptor<ReqextendsRequest,C1extendsAbstractRequestChain<Req, ?extendsInterceptor>,
34-
ResextendsResponse,C2extendsAbstractResponseChain<Res, ?extendsInterceptor>>
35-
implementsInterceptor<Req,C1,Res,C2> {
33+
publicabstractclassIndexedInterceptor<ReqextendsRequest,ReqChainextendsAbstractRequestChain<Req, ?extendsInterceptor>,
34+
ResextendsResponse,ResChainextendsAbstractResponseChain<Res, ?extendsInterceptor>>
35+
implementsInterceptor<Req,ReqChain,Res,ResChain> {
3636

3737
privateintmRequestIndex;
3838
privateintmResponseIndex;
3939

4040
/**
41-
* The same like {@link #intercept(C1, ByteBuffer)}.
41+
* The same like {@link #intercept(ReqChain, ByteBuffer)}.
4242
*
43-
* @param chain The request chain, call {@linkplainC1#process(ByteBuffer)} to
43+
* @param chain The request chain, call {@linkplainReqChain#process(ByteBuffer)} to
4444
* delivery the packet.
4545
* @param buffer A nio buffer contains the packet data.
4646
* @param index The packet index, started from 0.
4747
* @throws IOException If an I/O error has occurred.
4848
*/
49-
protectedabstractvoidintercept(@NonNullC1chain,@NonNullByteBufferbuffer,
49+
protectedabstractvoidintercept(@NonNullReqChainchain,@NonNullByteBufferbuffer,
5050
intindex)throwsIOException;
5151

5252
/**
53-
* The same like {@link #intercept(C2, ByteBuffer)}.
53+
* The same like {@link #intercept(ResChain, ByteBuffer)}.
5454
*
55-
* @param chain The response chain, call {@linkplainC2#process(ByteBuffer)} to
55+
* @param chain The response chain, call {@linkplainResChain#process(ByteBuffer)} to
5656
* delivery the packet.
5757
* @param buffer A nio buffer contains the packet data.
5858
* @param index The packet index, started from 0.
5959
* @throws IOException If an I/O error has occurred.
6060
*/
61-
protectedabstractvoidintercept(@NonNullC2chain,@NonNullByteBufferbuffer,
61+
protectedabstractvoidintercept(@NonNullResChainchain,@NonNullByteBufferbuffer,
6262
intindex)throwsIOException;
6363

6464
@Override
65-
publicfinalvoidintercept(@NonNullC1chain,@NonNullByteBufferbuffer)
65+
publicfinalvoidintercept(@NonNullReqChainchain,@NonNullByteBufferbuffer)
6666
throwsIOException {
6767
intercept(chain,buffer,mRequestIndex++);
6868
}
6969

7070
@Override
71-
publicfinalvoidintercept(@NonNullC2chain,@NonNullByteBufferbuffer)
71+
publicfinalvoidintercept(@NonNullResChainchain,@NonNullByteBufferbuffer)
7272
throwsIOException {
7373
intercept(chain,buffer,mResponseIndex++);
7474
}

‎netbare-core/src/main/java/com/github/megatronking/netbare/gateway/Interceptor.java‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@
3232
* @author Megatron King
3333
* @since 2018-11-13 23:46
3434
*/
35-
publicinterfaceInterceptor<ReqextendsRequest,C1extendsAbstractRequestChain<Req, ?extendsInterceptor>,
36-
ResextendsResponse,C2extendsAbstractResponseChain<Res, ?extendsInterceptor>> {
35+
publicinterfaceInterceptor<ReqextendsRequest,ReqChainextendsAbstractRequestChain<Req, ?extendsInterceptor>,
36+
ResextendsResponse,ResChainextendsAbstractResponseChain<Res, ?extendsInterceptor>> {
3737

3838
/**
3939
* Intercept request packet, and delivery it to next interceptor or the terminal.
@@ -47,7 +47,7 @@ public interface Interceptor<Req extends Request, C1 extends AbstractRequestChai
4747
* @param buffer A nio buffer contains the packet data.
4848
* @throws IOException If an I/O error has occurred.
4949
*/
50-
voidintercept(@NonNullC1chain,@NonNullByteBufferbuffer)throwsIOException;
50+
voidintercept(@NonNullReqChainchain,@NonNullByteBufferbuffer)throwsIOException;
5151

5252
/**
5353
* Intercept request packet, and delivery it to next interceptor or the terminal.
@@ -60,7 +60,7 @@ public interface Interceptor<Req extends Request, C1 extends AbstractRequestChai
6060
* @param buffer A nio buffer contains the packet data.
6161
* @throws IOException If an I/O error has occurred.
6262
*/
63-
voidintercept(@NonNullC2chain,@NonNullByteBufferbuffer)throwsIOException;
63+
voidintercept(@NonNullResChainchain,@NonNullByteBufferbuffer)throwsIOException;
6464

6565
/**
6666
* Invoked when a session's request has finished. It means the client has no more data sent to

‎netbare-core/src/main/java/com/github/megatronking/netbare/gateway/InterceptorFactory.java‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,15 +23,15 @@
2323
* @author Megatron King
2424
* @since 2018-11-02 23:46
2525
*/
26-
publicinterfaceInterceptorFactory<ReqextendsRequest,C1extendsAbstractRequestChain<Req, ?extendsInterceptor>,
27-
ResextendsResponse,C2extendsAbstractResponseChain<Res, ?extendsInterceptor>> {
26+
publicinterfaceInterceptorFactory<ReqextendsRequest,ReqChainextendsAbstractRequestChain<Req, ?extendsInterceptor>,
27+
ResextendsResponse,ResChainextendsAbstractResponseChain<Res, ?extendsInterceptor>> {
2828

2929
/**
3030
* Creates an interceptor instance and immediately returns it, it must not be null.
3131
*
3232
* @return A newly created interceptor.
3333
*/
3434
@NonNull
35-
Interceptor<Req,C1,Res,C2>create();
35+
Interceptor<Req,ReqChain,Res,ResChain>create();
3636

3737
}

‎netbare-core/src/main/java/com/github/megatronking/netbare/gateway/PendingIndexedInterceptor.java‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@
2828
* @author Megatron King
2929
* @since 2018-12-09 12:07
3030
*/
31-
publicabstractclassPendingIndexedInterceptor <ReqextendsRequest,C1extendsAbstractRequestChain<Req, ?extendsInterceptor>,
32-
ResextendsResponse,C2extendsAbstractResponseChain<Res, ?extendsInterceptor>>
33-
extendsIndexedInterceptor<Req,C1,Res,C2> {
31+
publicabstractclassPendingIndexedInterceptor <ReqextendsRequest,ReqChainextendsAbstractRequestChain<Req, ?extendsInterceptor>,
32+
ResextendsResponse,ResChainextendsAbstractResponseChain<Res, ?extendsInterceptor>>
33+
extendsIndexedInterceptor<Req,ReqChain,Res,ResChain> {
3434

3535
privateList<ByteBuffer>mRequestPendingBuffers;
3636
privateList<ByteBuffer>mResponsePendingBuffers;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp