This commit is contained in:
Georgy Khatuncev 2021-05-29 16:19:31 +05:00
parent d7f0d6eb18
commit c633df4ff3
3 changed files with 13 additions and 1 deletions

Binary file not shown.

@ -11,6 +11,7 @@ namespace DataClient
public class NETClient
{
private Logger log = LogManager.GetCurrentClassLogger();
private Encoding enc;
private string ip = "127.0.0.1";
public string Ip
{
@ -45,17 +46,28 @@ namespace DataClient
dir_browse = 23,
user_flags = 26
}
//Construction
public NETClient()
{
Encoding.RegisterProvider(CodePagesEncodingProvider.Instance);
enc = Encoding.GetEncoding(866);
}
public NETClient(string ip, int port)
{
Encoding.RegisterProvider(CodePagesEncodingProvider.Instance);
enc = Encoding.GetEncoding(866);
Ip = ip;
Port = port;
}
//Work with socket functions
public byte[] CreateCode(uint code, byte[] prefix = null, string val = null, byte[] postfix = null)
{
var res = new List<byte>();
return res.ToArray();
}
//Support functions