Class BGPSessionStateImpl
- java.lang.Object
-
- org.opendaylight.protocol.bgp.rib.impl.state.BGPSessionStateImpl
-
- All Implemented Interfaces:
BGPMessagesListener,BGPSessionStateListener,BGPSessionState,BGPTimersState,BGPTransportState
public final class BGPSessionStateImpl extends Object implements BGPSessionState, BGPTimersState, BGPTransportState, BGPSessionStateListener
-
-
Constructor Summary
Constructors Constructor Description BGPSessionStateImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidadvertizeCapabilities(int newHoldTimerValue, SocketAddress newRemoteAddress, SocketAddress localAddress, Set<BgpTableType> tableTypes, List<BgpParameters> bgpParameters)Advertize Session capabilities.org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.PortNumbergetLocalPort()Local Port.longgetNegotiatedHoldTime()Negotiated Hold Time.org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.IpAddressNoZonegetRemoteAddress()Remote Address.org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.PortNumbergetRemotePort()Remote Port.StategetSessionState()Internal session state.longgetUpTime()The time (MILLISECONDS) for how long session has been up or on idle state.booleanisAddPathCapabilitySupported()Additional Path capability.booleanisAsn32CapabilitySupported()AS 4 Bytes capability.booleanisGracefulRestartCapabilitySupported()Graceful Restart.booleanisMultiProtocolCapabilitySupported()Multiprotocol capability.booleanisRouterRefreshCapabilitySupported()Router Refresh Capability.voidmessageReceived(org.opendaylight.yangtools.yang.binding.Notification msg)Fired when message is received.voidmessageSent(org.opendaylight.yangtools.yang.binding.Notification msg)Fired when message is sent.voidregisterMessagesCounter(BGPMessagesListener bgpMessagesListener)voidsetSessionState(State state)Fired when session state changes.
-
-
-
Method Detail
-
messageSent
public void messageSent(org.opendaylight.yangtools.yang.binding.Notification msg)
Description copied from interface:BGPMessagesListenerFired when message is sent.- Specified by:
messageSentin interfaceBGPMessagesListener- Parameters:
msg- message
-
messageReceived
public void messageReceived(org.opendaylight.yangtools.yang.binding.Notification msg)
Description copied from interface:BGPMessagesListenerFired when message is received.- Specified by:
messageReceivedin interfaceBGPMessagesListener- Parameters:
msg- message
-
advertizeCapabilities
public void advertizeCapabilities(int newHoldTimerValue, SocketAddress newRemoteAddress, SocketAddress localAddress, Set<BgpTableType> tableTypes, List<BgpParameters> bgpParameters)Description copied from interface:BGPSessionStateListenerAdvertize Session capabilities.- Specified by:
advertizeCapabilitiesin interfaceBGPSessionStateListener- Parameters:
newHoldTimerValue- hold TimernewRemoteAddress- remote AddresslocalAddress- local AddresstableTypes- supported familiesbgpParameters- bgp capabilities
-
getSessionState
public State getSessionState()
Description copied from interface:BGPSessionStateInternal session state.- Specified by:
getSessionStatein interfaceBGPSessionState- Returns:
- Internal session state
-
setSessionState
public void setSessionState(State state)
Description copied from interface:BGPSessionStateListenerFired when session state changes.- Specified by:
setSessionStatein interfaceBGPSessionStateListener- Parameters:
state- session state
-
isAddPathCapabilitySupported
public boolean isAddPathCapabilitySupported()
Description copied from interface:BGPSessionStateAdditional Path capability.- Specified by:
isAddPathCapabilitySupportedin interfaceBGPSessionState- Returns:
- true if supported
-
isAsn32CapabilitySupported
public boolean isAsn32CapabilitySupported()
Description copied from interface:BGPSessionStateAS 4 Bytes capability.- Specified by:
isAsn32CapabilitySupportedin interfaceBGPSessionState- Returns:
- true if supported
-
isGracefulRestartCapabilitySupported
public boolean isGracefulRestartCapabilitySupported()
Description copied from interface:BGPSessionStateGraceful Restart.- Specified by:
isGracefulRestartCapabilitySupportedin interfaceBGPSessionState- Returns:
- true if supported
-
isMultiProtocolCapabilitySupported
public boolean isMultiProtocolCapabilitySupported()
Description copied from interface:BGPSessionStateMultiprotocol capability.- Specified by:
isMultiProtocolCapabilitySupportedin interfaceBGPSessionState- Returns:
- true if supported
-
isRouterRefreshCapabilitySupported
public boolean isRouterRefreshCapabilitySupported()
Description copied from interface:BGPSessionStateRouter Refresh Capability.- Specified by:
isRouterRefreshCapabilitySupportedin interfaceBGPSessionState- Returns:
- true if supported
-
getLocalPort
public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.PortNumber getLocalPort()
Description copied from interface:BGPTransportStateLocal Port.- Specified by:
getLocalPortin interfaceBGPTransportState- Returns:
- port
-
getRemoteAddress
public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.IpAddressNoZone getRemoteAddress()
Description copied from interface:BGPTransportStateRemote Address.- Specified by:
getRemoteAddressin interfaceBGPTransportState- Returns:
- IpAddress
-
getRemotePort
public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.PortNumber getRemotePort()
Description copied from interface:BGPTransportStateRemote Port.- Specified by:
getRemotePortin interfaceBGPTransportState- Returns:
- port
-
getNegotiatedHoldTime
public long getNegotiatedHoldTime()
Description copied from interface:BGPTimersStateNegotiated Hold Time.- Specified by:
getNegotiatedHoldTimein interfaceBGPTimersState- Returns:
- Hold Time
-
getUpTime
public long getUpTime()
Description copied from interface:BGPTimersStateThe time (MILLISECONDS) for how long session has been up or on idle state.- Specified by:
getUpTimein interfaceBGPTimersState- Returns:
- time
-
registerMessagesCounter
public void registerMessagesCounter(BGPMessagesListener bgpMessagesListener)
-
-