Class RawSocketChannel
java.lang.Object
io.netty.util.DefaultAttributeMap
io.netty.channel.AbstractChannel
io.netty.channel.oio.AbstractOioChannel
io.netty.channel.oio.AbstractOioByteChannel
io.netty.channel.oio.OioByteStreamChannel
org.apache.plc4x.java.utils.rawsockets.netty.RawSocketChannel
- All Implemented Interfaces:
io.netty.channel.Channel,io.netty.channel.ChannelOutboundInvoker,io.netty.util.AttributeMap,Comparable<io.netty.channel.Channel>
public class RawSocketChannel
extends io.netty.channel.oio.OioByteStreamChannel
Channel based on a Pcap4J raw-socket, allowing to actively communicate based on ethernet frames.
-
Nested Class Summary
Nested classes/interfaces inherited from class io.netty.channel.AbstractChannel
io.netty.channel.AbstractChannel.AbstractUnsafeNested classes/interfaces inherited from interface io.netty.channel.Channel
io.netty.channel.Channel.Unsafe -
Field Summary
Fields inherited from class io.netty.channel.oio.AbstractOioChannel
SO_TIMEOUT -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionio.netty.channel.ChannelConfigconfig()protected voiddoBind(SocketAddress localAddress) protected voiddoConnect(SocketAddress remoteAddress, SocketAddress localAddress) protected voidprotected intdoReadBytes(io.netty.buffer.ByteBuf buf) org.pcap4j.util.MacAddressorg.pcap4j.util.MacAddressprotected booleanbooleanisOpen()protected SocketAddressprotected io.netty.channel.AbstractChannel.AbstractUnsafeprotected SocketAddressvoidsetRemoteMacAddress(org.pcap4j.util.MacAddress remoteMacAddress) protected io.netty.channel.ChannelFutureMethods inherited from class io.netty.channel.oio.OioByteStreamChannel
activate, available, doClose, doWriteBytes, doWriteFileRegion, isActiveMethods inherited from class io.netty.channel.oio.AbstractOioByteChannel
doRead, doWrite, filterOutboundMessage, metadataMethods inherited from class io.netty.channel.oio.AbstractOioChannel
clearReadPending, doBeginRead, isCompatible, isReadPending, setReadPendingMethods inherited from class io.netty.channel.AbstractChannel
alloc, bind, bind, bytesBeforeUnwritable, bytesBeforeWritable, close, close, closeFuture, compareTo, connect, connect, connect, connect, deregister, deregister, disconnect, disconnect, doDeregister, doRegister, doShutdownOutput, equals, eventLoop, flush, hashCode, id, invalidateLocalAddress, invalidateRemoteAddress, isRegistered, isWritable, localAddress, maxMessagesPerWrite, newChannelPipeline, newFailedFuture, newId, newProgressivePromise, newPromise, newSucceededFuture, parent, pipeline, read, remoteAddress, toString, unsafe, validateFileRegion, voidPromise, write, write, writeAndFlush, writeAndFlushMethods inherited from class io.netty.util.DefaultAttributeMap
attr, hasAttrMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface io.netty.util.AttributeMap
attr, hasAttr
-
Constructor Details
-
RawSocketChannel
public RawSocketChannel()
-
-
Method Details
-
setRemoteMacAddress
public void setRemoteMacAddress(org.pcap4j.util.MacAddress remoteMacAddress) -
isInputShutdown
protected boolean isInputShutdown()- Specified by:
isInputShutdownin classio.netty.channel.oio.AbstractOioByteChannel
-
shutdownInput
protected io.netty.channel.ChannelFuture shutdownInput()- Specified by:
shutdownInputin classio.netty.channel.oio.AbstractOioByteChannel
-
doConnect
- Specified by:
doConnectin classio.netty.channel.oio.AbstractOioChannel- Throws:
Exception
-
localAddress0
- Specified by:
localAddress0in classio.netty.channel.AbstractChannel
-
remoteAddress0
- Specified by:
remoteAddress0in classio.netty.channel.AbstractChannel
-
doBind
- Specified by:
doBindin classio.netty.channel.AbstractChannel
-
doDisconnect
protected void doDisconnect()- Specified by:
doDisconnectin classio.netty.channel.AbstractChannel
-
doReadBytes
- Overrides:
doReadBytesin classio.netty.channel.oio.OioByteStreamChannel- Throws:
Exception
-
config
public io.netty.channel.ChannelConfig config() -
isOpen
public boolean isOpen() -
newUnsafe
protected io.netty.channel.AbstractChannel.AbstractUnsafe newUnsafe()- Overrides:
newUnsafein classio.netty.channel.oio.AbstractOioChannel
-
getRemoteAddress
-
getRemoteMacAddress
public org.pcap4j.util.MacAddress getRemoteMacAddress() -
getLocalAddress
-
getLocalMacAddress
public org.pcap4j.util.MacAddress getLocalMacAddress()
-