Initial project commit
This commit is contained in:
33
TorControlLibrary/Responses/StreamStatusResponse.cs
Normal file
33
TorControlLibrary/Responses/StreamStatusResponse.cs
Normal file
@@ -0,0 +1,33 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Net;
|
||||
namespace TorControlLibrary.Responses
|
||||
{
|
||||
public class StreamStatusResponse : CommandResponse
|
||||
{
|
||||
public static StreamStatusResponse Parse(String line)
|
||||
{
|
||||
StreamStatusResponse resp = new StreamStatusResponse();
|
||||
resp.PopulateData(line, resp);
|
||||
return resp;
|
||||
}
|
||||
[Obsolete()]
|
||||
protected IPEndPoint ParseIPEndPoint(String data)
|
||||
{
|
||||
return new IPEndPoint(IPAddress.Parse(data.Substring(0, data.IndexOf(':'))),
|
||||
Int32.Parse(data.Substring(data.IndexOf(':') + 1)));
|
||||
}
|
||||
[ParseAttribute(1)]
|
||||
public Int32 StreamID { get; set; }
|
||||
[ParseAttribute(2)]
|
||||
public String StreamStatus { get; set; }
|
||||
[ParseAttribute(3)]
|
||||
public Int32 CircuitID { get; set; }
|
||||
[ParseAttribute(4)]
|
||||
public String Target { get; set; }
|
||||
//[ParseAttribute(4, CustomParser="ParseIPEndPoint")]
|
||||
//public IPEndPoint Target { get; set; }
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user