Ejemplo n.º 1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="TerraGrafInformationMessage"/> class.
 /// </summary>
 /// <param name="senderId">The sender id.</param>
 /// <param name="targetId">The target id.</param>
 /// <param name="networkInfo">The network info.</param>
 internal TerraGrafInformationMessage(string senderId, string targetId, TerraGrafNetworkInformation networkInfo)
     : this(senderId, targetId)
 {
     if (networkInfo == null)
     {
         ThrowHelper.ThrowArgumentNullException("networkInfo");
     }
     this.mNetworkInfo = networkInfo;
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="TerraGrafInformationMessage"/> class.
 /// </summary>
 /// <param name="senderId">The sender id.</param>
 /// <param name="networkInfo">The network info.</param>
 /// <param name="blackHoleContainer">The black hole container.</param>
 internal TerraGrafInformationMessage(string senderId, TerraGrafNetworkInformation networkInfo, BlackHoleContainer blackHoleContainer)
     : this(senderId, blackHoleContainer)
 {
     if (networkInfo == null)
     {
         ThrowHelper.ThrowArgumentNullException("networkInfo");
     }
     this.mNetworkInfo = networkInfo;
 }
Ejemplo n.º 3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="TerraGrafInformationMessage"/> class.
 /// </summary>
 /// <param name="senderId">The sender id.</param>
 /// <param name="messageId">The message id.</param>
 /// <param name="networkInfo">The network info.</param>
 /// <param name="targetHostRelation">The target host relation.</param>
 /// <param name="blackHoleContainer">The black hole container.</param>
 internal TerraGrafInformationMessage(string senderId, long messageId, TerraGrafNetworkInformation networkInfo, PeerRelation targetHostRelation, BlackHoleContainer blackHoleContainer)
     : base(senderId, string.Empty, MessageCodeEnum.TerraGrafInformation, messageId, MessagePriorityEnum.Normal, MessageTypeEnum.Udp)
 {
     if (networkInfo == null)
     {
         ThrowHelper.ThrowArgumentNullException("networkInfo");
     }
     this.mNetworkInfo        = networkInfo;
     this.mTargetHostRelation = targetHostRelation;
     this.mBlackHoleContainer = blackHoleContainer;
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="TerraGrafInformationMessage"/> class.
 /// </summary>
 /// <param name="senderId">The sender id.</param>
 /// <param name="networkInfo">The network info.</param>
 /// <param name="targetHostRelation">The target host relation.</param>
 internal TerraGrafInformationMessage(string senderId, TerraGrafNetworkInformation networkInfo, PeerRelation targetHostRelation) :
     this(senderId)
 {
     if (networkInfo == null)
     {
         ThrowHelper.ThrowArgumentNullException("networkInfo");
     }
     if (targetHostRelation == null)
     {
         ThrowHelper.ThrowArgumentNullException("targetHostRelation");
     }
     this.mNetworkInfo        = networkInfo;
     this.mTargetHostRelation = targetHostRelation;
 }