Class AbstractPeer<LOCATOR,​HEADER extends P2PHeader<LOCATOR>,​TAIL extends P2PTail<LOCATOR>,​MSG extends P2PMessage<LOCATOR,​HEADER,​?,​TAIL>,​CONSUMER extends P2PMessageConsumer<MSG,​PEER>,​PEER extends Peer<LOCATOR,​HEADER,​TAIL,​MSG,​ROUTER>,​ROUTER extends PeerRouter<LOCATOR,​HEADER,​TAIL,​MSG>>

  • Type Parameters:
    ROUTER - The PeerRouter type to use when routing P2PMessage instances.
    LOCATOR - Defines the type of the locators identifying a peer.
    HEADER - The P2PHeader defines the static attributes addressed for the target of the P2PMessage (a header might be signed as it is not modified during dispatch).
    TAIL - The P2PTail describes the dynamic attributes required during dispatch of a P2PMessage (a tail is modified during dispatch by having the visited hops appended).
    MSG - The (sub-)type of the P2PMessage being processed by the according Peer (sub-)type.
    All Implemented Interfaces:
    org.refcodes.mixin.LocatorAccessor<LOCATOR>, Peer<LOCATOR,​HEADER,​TAIL,​MSG,​ROUTER>, PeerRouter<LOCATOR,​HEADER,​TAIL,​MSG>, Terminal<LOCATOR>

    public abstract class AbstractPeer<LOCATOR,​HEADER extends P2PHeader<LOCATOR>,​TAIL extends P2PTail<LOCATOR>,​MSG extends P2PMessage<LOCATOR,​HEADER,​?,​TAIL>,​CONSUMER extends P2PMessageConsumer<MSG,​PEER>,​PEER extends Peer<LOCATOR,​HEADER,​TAIL,​MSG,​ROUTER>,​ROUTER extends PeerRouter<LOCATOR,​HEADER,​TAIL,​MSG>>
    extends Object
    implements Peer<LOCATOR,​HEADER,​TAIL,​MSG,​ROUTER>
    The AbstractPeer class implements the Peer interface and is a concrete implementation of a physical Peer.