/// <summary>
 /// Initializes a new instance of the <see cref="ClientHandshake"/> class.
 /// </summary>
 /// <param name="ChallengeBytes">The challenge bytes.</param>
 /// <param name="header">The header.</param>
 public ClientHandshake(Header header)
 {
     ResourcePath= header.RequestPath;
     Key         = header["sec-websocket-key"];
     SubProtocol = header["sec-websocket-protocol"];
     Origin      = header["sec-websocket-origin"];
     Host        = header["host"];
     Version     = header["sec-websocket-version"];
     Cookies     = header.Cookies;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="ClientHandshake"/> class.
 /// </summary>
 /// <param name="ChallengeBytes">The challenge bytes.</param>
 /// <param name="header">The header.</param>
 public ClientHandshake(ArraySegment<byte> challengeBytes, Header header)
 {
     ChallengeBytes = challengeBytes;
     ResourcePath = header.RequestPath;
     Key1 = header["sec-websocket-key1"];
     Key2 = header["sec-websocket-key2"];
     SubProtocol = header["sec-websocket-protocol"];
     Origin = header["origin"];
     Host = header["host"];
     Cookies = header.Cookies;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="UserContext"/> class.
 /// </summary>
 /// <param name="context">The user context.</param>
 public UserContext(Context AContext)
 {
     this.Context = AContext;
     this.Header = this.Context.Header;
 }