Class TcpIpPort

    • Field Detail

      • linkPathStruct

        protected final CipStruct linkPathStruct
      • peercxmaps

        protected final java.util.Map<java.net.InetAddress,​java.util.Map<java.lang.Integer,​ConxMapItem>> peercxmaps
      • selfport

        protected final PortSeg selfport
      • starter

        public final java.util.concurrent.ScheduledFuture<?> starter
      • encapBoss

        protected io.netty.channel.EventLoopGroup encapBoss
      • udpWork

        protected io.netty.channel.EventLoopGroup udpWork
      • encapServer

        protected io.netty.channel.ChannelFuture encapServer
      • encapUdp

        protected io.netty.channel.ChannelFuture encapUdp
      • udpIO

        protected io.netty.channel.ChannelFuture udpIO
      • coreAddress

        protected java.net.InetSocketAddress coreAddress
      • starterLock

        protected java.lang.Object starterLock
      • started

        protected boolean started
    • Constructor Detail

      • TcpIpPort

        public TcpIpPort​(PortMgr parent,
                         int port,
                         java.net.InetAddress addr)
      • TcpIpPort

        public TcpIpPort​(InstanceSeg seg,
                         PortMgr parent,
                         int port,
                         java.net.InetAddress addr)
      • TcpIpPort

        public TcpIpPort​(InstanceSeg seg,
                         PortMgr parent,
                         int port,
                         java.net.InetAddress addr,
                         int threads)
        Construct a TCP/IP port with the given properties. Bus devices will be accessed with implicit connections (no actual message buffering).
        Parameters:
        seg - Indicates the instance number to create/replace, or null to use the lowest available instance.
        parent - A Port Manager class object
        port - The port number in the parent device. Non-zero.
        addr - The address on the network to occupy.
        threads - The number of threads to use in the produced I/O data scheduler.
      • TcpIpPort

        protected TcpIpPort​(InstanceSeg seg,
                            PortMgr parent,
                            int port,
                            java.lang.String name,
                            java.net.InetAddress addr,
                            int threads)
    • Method Detail

      • shutdownELG

        public void shutdownELG()
      • createListIDReply

        public EncapList createListIDReply​(Encap packet)
      • getInterface

        public java.net.NetworkInterface getInterface()
      • getCXMap

        public java.util.Map<java.lang.Integer,​ConxMapItem> getCXMap​(java.net.InetSocketAddress peer)
      • mcastToPeer

        public java.net.InetAddress mcastToPeer()
        Ethernet/IP Class 0 and 1 Multicast addresses are allocated from Administrative Local Scope (RFC-2365) beginning at 239.192.1.0. Each host device will choose from a block of 32 addresses beginning with its own IP address's lower 10 bits, shifted right by 5, added to the multicast base.

        This library distributes the multicast addresses to balance total packet rate for a given address.

        Returns:
        The chosen multicast address or null if the address could not be computed.