C# 클래스 Brunet.Simulator.Transport.ConeNat

Supports a very simple Cone NAT. Once the node has learned its own address and it has a stable connection to another peer, it allows inbound connections. Incoming messages are allow so long as there is an existing NAT mapping.
상속: INat
파일 보기 프로젝트 열기: pstjuste/brunet 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
_allow_inbound bool
_allowed bool>.TimeBasedCache
_external_ta Brunet.Transport.TransportAddress[]
_internal_ta Brunet.Transport.TransportAddress[]
_known_tas Brunet.Transport.TransportAddress[]

공개 메소드들

메소드 설명
ConeNat ( TransportAddress ta, int timeout ) : System.Collections
Incoming ( TransportAddress ta ) : bool
Outgoing ( TransportAddress ta ) : bool
UpdateTAs ( TransportAddress remote_ta, TransportAddress local_ta ) : void

비공개 메소드들

메소드 설명
HandleEviction ( object sender, bool>.TimeBasedCache ea ) : void

If there are no more entries in the cache, our mapping has, we will no longer allow inbound connections.

메소드 상세

ConeNat() 공개 메소드

public ConeNat ( TransportAddress ta, int timeout ) : System.Collections
ta Brunet.Transport.TransportAddress
timeout int
리턴 System.Collections

Incoming() 공개 메소드

public Incoming ( TransportAddress ta ) : bool
ta Brunet.Transport.TransportAddress
리턴 bool

Outgoing() 공개 메소드

public Outgoing ( TransportAddress ta ) : bool
ta Brunet.Transport.TransportAddress
리턴 bool

UpdateTAs() 공개 메소드

public UpdateTAs ( TransportAddress remote_ta, TransportAddress local_ta ) : void
remote_ta Brunet.Transport.TransportAddress
local_ta Brunet.Transport.TransportAddress
리턴 void

프로퍼티 상세

_allow_inbound 보호되어 있는 프로퍼티

protected bool _allow_inbound
리턴 bool

_allowed 보호되어 있는 프로퍼티

protected TimeBasedCache _allowed
리턴 bool>.TimeBasedCache

_external_ta 보호되어 있는 프로퍼티

protected TransportAddress[],Brunet.Transport _external_ta
리턴 Brunet.Transport.TransportAddress[]

_internal_ta 보호되어 있는 프로퍼티

protected TransportAddress[],Brunet.Transport _internal_ta
리턴 Brunet.Transport.TransportAddress[]

_known_tas 보호되어 있는 프로퍼티

protected TransportAddress[],Brunet.Transport _known_tas
리턴 Brunet.Transport.TransportAddress[]