Example #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Subscriber" /> class.
 /// </summary>
 public Publisher()
 {
     _config = new ServerConfig() {
         Host = "localhost",
         Port = 8080,
         Route = "/",
         Debug = true
     };
 }
Example #2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="Subscriber" /> class.
        /// </summary>
        public Subscriber()
        {
            this.UniqueID = Guid.NewGuid();

            _config = new ServerConfig() {
                Host = "localhost",
                Port = 8080,
                Route = "/",
                Debug = true
            };
        }
Example #3
0
 /// <summary>
 /// Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
 /// </summary>
 public void Dispose()
 {
     if (_socket != null) _socket.Close();
     if (_socket != null) _socket = null;
     if (_config != null) _config = null;
 }
Example #4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Subscriber" /> class.
 /// </summary>
 /// <param name="id">The id.</param>
 /// <param name="config">The config.</param>
 public Subscriber(Guid id, ServerConfig config)
     : this()
 {
     this.UniqueID = id;
     this._config = config;
 }
Example #5
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Subscriber" /> class.
 /// </summary>
 /// <param name="id">The id.</param>
 /// <param name="config">The config.</param>
 public Publisher(ServerConfig config)
     : this()
 {
     this._config = config;
 }