Class TransportLayerImpl

    • Field Detail

      • supportedModes

        protected final Map<Long,​Mode> supportedModes
        the modes supported by this layer
    • Constructor Detail

      • TransportLayerImpl

        protected TransportLayerImpl​(IdGroupingToken tokenId)
        Constructor
        Parameters:
        tokenId - to generate id for this instance for
      • TransportLayerImpl

        protected TransportLayerImpl​(TransportLayerImpl transportLayerImpl)
        Copy constructor
        Parameters:
        transportLayerImpl - to copy
    • Method Detail

      • generateId

        protected static long generateId​(IdGroupingToken tokenId)
        generate unique node id
        Parameters:
        tokenId - contiguous id generation within this group for instances of this class
        Returns:
        nodeId
      • registerSupportedMode

        public boolean registerSupportedMode​(Mode supportedMode)
        register a mode as supported by this layer
        Specified by:
        registerSupportedMode in interface TransportLayer
        Parameters:
        supportedMode - to support
        Returns:
        true when successful false otherwise
      • registerSupportedModes

        public boolean registerSupportedModes​(Collection<Mode> supportedModes)
        register modes as supported by this layer
        Specified by:
        registerSupportedModes in interface TransportLayer
        Parameters:
        supportedModes - to support
        Returns:
        true when successful false otherwise
      • getSupportedModes

        public Collection<Mode> getSupportedModes()
        collect the modes supported by this infrastructure layer
        Specified by:
        getSupportedModes in interface TransportLayer
        Returns:
        the supported modes for at least some part of the available infrastructure
      • logInfo

        public void logInfo​(String prefix)
        invoked by entities inquiring about general information about the layer to display to users
        Specified by:
        logInfo in interface TransportLayer
        Parameters:
        prefix - optional prefix to include in each line of logging
      • recreateManagedIds

        public long recreateManagedIds​(IdGroupingToken tokenId)
        recreate the internal id(s) and set them including the Idable id
        Specified by:
        recreateManagedIds in interface ManagedId
        Parameters:
        tokenId - to use
        Returns:
        the updated internal id
      • reset

        public void reset()
        Reset the layer
        Specified by:
        reset in interface TransportLayer