public interface RemotingServer
| 限定符和类型 | 方法和说明 |
|---|---|
void |
init()
已过时。
|
String |
ip()
Get the ip of the server.
|
int |
port()
Get the port of the server.
|
void |
registerDefaultExecutor(byte protocolCode,
ExecutorService executor)
Register default executor service for server.
|
void |
registerProcessor(byte protocolCode,
CommandCode commandCode,
RemotingProcessor<?> processor)
Register processor for command with the command code.
|
void |
registerUserProcessor(UserProcessor<?> processor)
Register user processor.
|
boolean |
start()
Start the server.
|
boolean |
stop()
Stop the server.
|
@Deprecated void init()
boolean start()
boolean stop()
String ip()
int port()
void registerProcessor(byte protocolCode,
CommandCode commandCode,
RemotingProcessor<?> processor)
protocolCode - protocol codecommandCode - command codeprocessor - processorvoid registerDefaultExecutor(byte protocolCode,
ExecutorService executor)
protocolCode - protocol codeexecutor - the executor service for the protocol codevoid registerUserProcessor(UserProcessor<?> processor)
processor - user processor which can be a single-interest processor or a multi-interest processorCopyright © 2021. All rights reserved.