Class ChannelDelegate
java.lang.Object
org.apache.dubbo.remoting.transport.ChannelDelegate
ChannelDelegate
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
close the channel.void
close
(int timeout) Graceful close the channel.getAttribute
(String key) get attribute.get channel handler.get local address.get remote address.getUrl()
get url.boolean
hasAttribute
(String key) has attribute.boolean
isClosed()
is closed.boolean
is connected.void
removeAttribute
(String key) remove attribute.void
send message.void
send message.void
setAttribute
(String key, Object value) set attribute.void
setChannel
(Channel channel) void
-
Constructor Details
-
ChannelDelegate
public ChannelDelegate() -
ChannelDelegate
-
-
Method Details
-
getChannel
-
setChannel
-
getUrl
Description copied from interface:Endpoint
get url. -
getRemoteAddress
Description copied from interface:Channel
get remote address.- Specified by:
getRemoteAddress
in interfaceChannel
- Returns:
- remote address.
-
getChannelHandler
Description copied from interface:Endpoint
get channel handler.- Specified by:
getChannelHandler
in interfaceEndpoint
- Returns:
- channel handler
-
isConnected
public boolean isConnected()Description copied from interface:Channel
is connected.- Specified by:
isConnected
in interfaceChannel
- Returns:
- connected
-
getLocalAddress
Description copied from interface:Endpoint
get local address.- Specified by:
getLocalAddress
in interfaceEndpoint
- Returns:
- local address.
-
hasAttribute
Description copied from interface:Channel
has attribute.- Specified by:
hasAttribute
in interfaceChannel
- Parameters:
key
- key.- Returns:
- has or has not.
-
send
Description copied from interface:Endpoint
send message.- Specified by:
send
in interfaceEndpoint
- Parameters:
message
-- Throws:
RemotingException
-
getAttribute
Description copied from interface:Channel
get attribute.- Specified by:
getAttribute
in interfaceChannel
- Parameters:
key
- key.- Returns:
- value.
-
setAttribute
Description copied from interface:Channel
set attribute.- Specified by:
setAttribute
in interfaceChannel
- Parameters:
key
- key.value
- value.
-
send
Description copied from interface:Endpoint
send message.- Specified by:
send
in interfaceEndpoint
- Parameters:
message
-sent
- already sent to socket?- Throws:
RemotingException
-
removeAttribute
Description copied from interface:Channel
remove attribute.- Specified by:
removeAttribute
in interfaceChannel
- Parameters:
key
- key.
-
close
public void close()Description copied from interface:Endpoint
close the channel. -
close
public void close(int timeout) Description copied from interface:Endpoint
Graceful close the channel. -
startClose
public void startClose()- Specified by:
startClose
in interfaceEndpoint
-
isClosed
public boolean isClosed()Description copied from interface:Endpoint
is closed.
-