Refactored MtApi4 (MT4) for working with new architecture

This commit is contained in:
Viacheslav Demydiuk
2024-06-16 13:57:50 +03:00
parent 6dd5e0190f
commit a830dc11a6
89 changed files with 1648 additions and 2390 deletions
+8
View File
@@ -0,0 +1,8 @@
namespace MtApi.MtProtocol
{
internal class FuncResult<T>
{
public bool RetVal { get; set; }
public T? Result { get; set; }
}
}
+13
View File
@@ -0,0 +1,13 @@
namespace MtApi.MtProtocol
{
namespace ICustomRequest
{
public enum ParametersType
{
Int = 0,
Double = 1,
String = 2,
Boolean = 3
}
}
}
+12
View File
@@ -0,0 +1,12 @@
namespace MtApi.MtProtocol
{
public class MtTick
{
public double Bid { get; set; } // Current Bid price
public double Ask { get; set; } // Current Ask price
public long Time { get; set; } // Time of the last prices update
public double Last { get; set; } // Price of the last deal (Last)
public ulong Volume { get; set; } // Volume for the current Last price
public double VolumeReal { get; set; } // Volume for the current Last price with greater accuracy
}
}
+9
View File
@@ -0,0 +1,9 @@
namespace MtApi.MtProtocol
{
internal class MtRpcQuote
{
public MtTick? Tick { get; set; }
public string? Instrument { get; set; }
public int ExpertHandle { get; set; }
}
}
+10
View File
@@ -0,0 +1,10 @@
namespace MtApi.MtProtocol
{
internal class Response<T>
{
public int ErrorCode { get; set; }
public string? ErrorMessage { get; set; }
public T? Value { get; set; }
}
}