|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.alibaba.dubbo.remoting.transport.AbstractPeer
com.alibaba.dubbo.remoting.transport.AbstractEndpoint
com.alibaba.dubbo.remoting.transport.AbstractClient
public abstract class AbstractClient
AbstractClient
| Constructor Summary | |
|---|---|
AbstractClient(URL url,
ChannelHandler handler)
|
|
| Method Summary | |
|---|---|
void |
close()
close the channel. |
void |
close(int timeout)
Graceful close the channel. |
void |
disconnect()
|
Object |
getAttribute(String key)
get attribute. |
InetSocketAddress |
getConnectAddress()
|
InetSocketAddress |
getLocalAddress()
get local address. |
InetSocketAddress |
getRemoteAddress()
get remote address. |
boolean |
hasAttribute(String key)
has attribute. |
boolean |
isConnected()
is connected. |
void |
reconnect()
reconnect. |
void |
removeAttribute(String key)
remove attribute. |
void |
send(Object message,
boolean sent)
send message. |
void |
setAttribute(String key,
Object value)
set attribute. |
String |
toString()
|
| Methods inherited from class com.alibaba.dubbo.remoting.transport.AbstractEndpoint |
|---|
reset, reset |
| Methods inherited from class com.alibaba.dubbo.remoting.transport.AbstractPeer |
|---|
caught, connected, disconnected, getChannelHandler, getDelegateHandler, getHandler, getUrl, isClosed, received, send, sent |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface com.alibaba.dubbo.remoting.Client |
|---|
reset |
| Methods inherited from interface com.alibaba.dubbo.remoting.Endpoint |
|---|
getChannelHandler, getUrl, isClosed, send |
| Methods inherited from interface com.alibaba.dubbo.common.Resetable |
|---|
reset |
| Constructor Detail |
|---|
public AbstractClient(URL url,
ChannelHandler handler)
throws RemotingException
RemotingException| Method Detail |
|---|
public InetSocketAddress getConnectAddress()
public InetSocketAddress getRemoteAddress()
Channel
getRemoteAddress in interface Channelpublic InetSocketAddress getLocalAddress()
Endpoint
getLocalAddress in interface Endpointpublic boolean isConnected()
Channel
isConnected in interface Channelpublic Object getAttribute(String key)
Channel
getAttribute in interface Channelkey - key.
public void setAttribute(String key,
Object value)
Channel
setAttribute in interface Channelkey - key.value - value.public void removeAttribute(String key)
Channel
removeAttribute in interface Channelkey - key.public boolean hasAttribute(String key)
Channel
hasAttribute in interface Channelkey - key.
public void send(Object message,
boolean sent)
throws RemotingException
Endpoint
send in interface Endpointsent - 是否已发送完成
RemotingExceptionpublic void disconnect()
public void reconnect()
throws RemotingException
Client
reconnect in interface ClientRemotingExceptionpublic void close()
Endpoint
close in interface Endpointclose in class AbstractPeerpublic void close(int timeout)
Endpoint
close in interface Endpointclose in class AbstractPeerpublic String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||