EpollDomainDatagramChannel Class — netty Architecture
Architecture documentation for the EpollDomainDatagramChannel class in EpollDomainDatagramChannel.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD 7202d69c_3d79_83a7_24dc_27b53c2f5789["EpollDomainDatagramChannel"] 3d88b450_01a2_068f_84da_0f2de76eb598["EpollDomainDatagramChannel.java"] 7202d69c_3d79_83a7_24dc_27b53c2f5789 -->|defined in| 3d88b450_01a2_068f_84da_0f2de76eb598 17c83654_336c_1864_05fc_db465079df85["EpollDomainDatagramChannel()"] 7202d69c_3d79_83a7_24dc_27b53c2f5789 -->|method| 17c83654_336c_1864_05fc_db465079df85 923f938f_90fc_d6f8_2d39_72a3b96ee3ca["EpollDomainDatagramChannelConfig()"] 7202d69c_3d79_83a7_24dc_27b53c2f5789 -->|method| 923f938f_90fc_d6f8_2d39_72a3b96ee3ca 486e3a7b_b2f0_0f85_b5a8_4310e0fda01c["doBind()"] 7202d69c_3d79_83a7_24dc_27b53c2f5789 -->|method| 486e3a7b_b2f0_0f85_b5a8_4310e0fda01c e0c15ba6_cf8f_a202_ce8f_01faa632c209["doClose()"] 7202d69c_3d79_83a7_24dc_27b53c2f5789 -->|method| e0c15ba6_cf8f_a202_ce8f_01faa632c209 d9eccf87_264d_8ac5_990f_9396ae6f98e2["doConnect()"] 7202d69c_3d79_83a7_24dc_27b53c2f5789 -->|method| d9eccf87_264d_8ac5_990f_9396ae6f98e2 09b52153_49ca_0884_7dd7_bff3a39b9a5f["doDisconnect()"] 7202d69c_3d79_83a7_24dc_27b53c2f5789 -->|method| 09b52153_49ca_0884_7dd7_bff3a39b9a5f 3097a55a_0d29_2543_f00c_0bdde3cddd90["doWrite()"] 7202d69c_3d79_83a7_24dc_27b53c2f5789 -->|method| 3097a55a_0d29_2543_f00c_0bdde3cddd90 441f6996_462b_cce7_ce87_8bf40d88c1be["doWriteMessage()"] 7202d69c_3d79_83a7_24dc_27b53c2f5789 -->|method| 441f6996_462b_cce7_ce87_8bf40d88c1be eeda9d14_0b71_dec8_8e47_ee60bca9db05["Object()"] 7202d69c_3d79_83a7_24dc_27b53c2f5789 -->|method| eeda9d14_0b71_dec8_8e47_ee60bca9db05 d6182850_aff0_6bcb_00a7_3ef564aa06c5["isActive()"] 7202d69c_3d79_83a7_24dc_27b53c2f5789 -->|method| d6182850_aff0_6bcb_00a7_3ef564aa06c5 66d21977_cd9f_f156_38fb_faeed02ba469["isConnected()"] 7202d69c_3d79_83a7_24dc_27b53c2f5789 -->|method| 66d21977_cd9f_f156_38fb_faeed02ba469 3329a13e_f62f_ed78_c129_fa9895319aba["DomainSocketAddress()"] 7202d69c_3d79_83a7_24dc_27b53c2f5789 -->|method| 3329a13e_f62f_ed78_c129_fa9895319aba 97b329ce_9149_537d_00a3_1eec385b915c["ChannelMetadata()"] 7202d69c_3d79_83a7_24dc_27b53c2f5789 -->|method| 97b329ce_9149_537d_00a3_1eec385b915c
Relationship Graph
Source Code
transport-classes-epoll/src/main/java/io/netty/channel/epoll/EpollDomainDatagramChannel.java lines 43–379
public final class EpollDomainDatagramChannel extends AbstractEpollChannel implements DomainDatagramChannel {
private static final ChannelMetadata METADATA = new ChannelMetadata(true, 16);
private static final String EXPECTED_TYPES =
" (expected: " +
StringUtil.simpleClassName(DomainDatagramPacket.class) + ", " +
StringUtil.simpleClassName(AddressedEnvelope.class) + '<' +
StringUtil.simpleClassName(ByteBuf.class) + ", " +
StringUtil.simpleClassName(DomainSocketAddress.class) + ">, " +
StringUtil.simpleClassName(ByteBuf.class) + ')';
private volatile boolean connected;
private volatile DomainSocketAddress local;
private volatile DomainSocketAddress remote;
private final EpollDomainDatagramChannelConfig config;
public EpollDomainDatagramChannel() {
this(newSocketDomainDgram(), false);
}
public EpollDomainDatagramChannel(int fd) {
this(new LinuxSocket(fd), true);
}
private EpollDomainDatagramChannel(LinuxSocket socket, boolean active) {
super(null, socket, active, EpollIoOps.valueOf(0));
config = new EpollDomainDatagramChannelConfig(this);
}
@Override
public EpollDomainDatagramChannelConfig config() {
return config;
}
@Override
protected void doBind(SocketAddress localAddress) throws Exception {
super.doBind(localAddress);
local = (DomainSocketAddress) localAddress;
active = true;
}
@Override
protected void doClose() throws Exception {
super.doClose();
connected = active = false;
local = null;
remote = null;
}
@Override
protected boolean doConnect(SocketAddress remoteAddress, SocketAddress localAddress) throws Exception {
if (super.doConnect(remoteAddress, localAddress)) {
if (localAddress != null) {
local = (DomainSocketAddress) localAddress;
}
remote = (DomainSocketAddress) remoteAddress;
connected = true;
return true;
}
return false;
}
@Override
protected void doDisconnect() throws Exception {
doClose();
}
@Override
protected void doWrite(ChannelOutboundBuffer in) throws Exception {
int maxMessagesPerWrite = maxMessagesPerWrite();
while (maxMessagesPerWrite > 0) {
Object msg = in.current();
if (msg == null) {
break;
}
try {
boolean done = false;
for (int i = config().getWriteSpinCount(); i > 0; --i) {
Defined In
Source
Frequently Asked Questions
What is the EpollDomainDatagramChannel class?
EpollDomainDatagramChannel is a class in the netty codebase, defined in transport-classes-epoll/src/main/java/io/netty/channel/epoll/EpollDomainDatagramChannel.java.
Where is EpollDomainDatagramChannel defined?
EpollDomainDatagramChannel is defined in transport-classes-epoll/src/main/java/io/netty/channel/epoll/EpollDomainDatagramChannel.java at line 43.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free