mirror of
https://github.com/vdemydiuk/mtapi.git
synced 2026-08-17 20:58:11 +00:00
Refactored MtApi4 (MT4) for working with new architecture
This commit is contained in:
Executable
+8
@@ -0,0 +1,8 @@
|
||||
namespace MtApi.MtProtocol
|
||||
{
|
||||
internal class FuncResult<T>
|
||||
{
|
||||
public bool RetVal { get; set; }
|
||||
public T? Result { get; set; }
|
||||
}
|
||||
}
|
||||
Executable
+13
@@ -0,0 +1,13 @@
|
||||
namespace MtApi.MtProtocol
|
||||
{
|
||||
namespace ICustomRequest
|
||||
{
|
||||
public enum ParametersType
|
||||
{
|
||||
Int = 0,
|
||||
Double = 1,
|
||||
String = 2,
|
||||
Boolean = 3
|
||||
}
|
||||
}
|
||||
}
|
||||
Executable
+12
@@ -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
|
||||
}
|
||||
}
|
||||
Executable
+9
@@ -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; }
|
||||
}
|
||||
}
|
||||
Executable
+10
@@ -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; }
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user