Exemplo n.º 1
0
 /// <summary>
 /// Constructs a new <see cref="FudgeMsg"/> using a given context, and populates with a set of fields.
 /// </summary>
 /// <param name="context"><see cref="FudgeContext"/> to use for the message.</param>
 /// <param name="fields">Fields to populate the message.</param>
 public FudgeMsg(FudgeContext context, params IFudgeField[] fields)
     : this(context)
 {
     foreach (var field in fields)
     {
         Add(field);
     }
 }
Exemplo n.º 2
0
 /// <summary>
 /// Constructs a new <see cref="FudgeStreamParser"/>.
 /// </summary>
 /// <param name="fudgeContext"></param>
 public FudgeStreamParser(FudgeContext fudgeContext)
 {
     if (fudgeContext == null)
     {
         throw new ArgumentNullException("fudgeContext", "Must provide a fudge context.");
     }
     this.fudgeContext = fudgeContext;
 }
Exemplo n.º 3
0
 /// <summary>
 /// Constructs a new <see cref="FudgeMsg"/> using a given <see cref="FudgeContext"/>.
 /// </summary>
 /// <param name="context">Context to use for the message.</param>
 public FudgeMsg(FudgeContext context)
 {
     if (context == null)
     {
         throw new ArgumentNullException("context", "Context must be provided");
     }
     this.context = context;
 }
Exemplo n.º 4
0
 /// <summary>
 /// Constructs a new <see cref="FudgeStreamParser"/>.
 /// </summary>
 /// <param name="fudgeContext"></param>
 public FudgeStreamParser(FudgeContext fudgeContext)
 {
     if (fudgeContext == null)
     {
         throw new ArgumentNullException("fudgeContext", "Must provide a fudge context.");
     }
     this.fudgeContext = fudgeContext;
 }
Exemplo n.º 5
0
 /// <summary>
 /// Creates a new <c>FudgeMsg</c> object as a copy of another.
 /// </summary>
 /// <param name="other">an existing <c>FudgeMsg</c> object to copy</param>
 public FudgeMsg(FudgeMsg other)
 {
     if (other == null)
     {
         throw new ArgumentNullException("Cannot initialize from a null other FudgeMsg");
     }
     this.context = other.context;
     InitializeFromByteArray(other.ToByteArray());
 }