Lean
$LEAN_TAG$
OrderSubmissionData.cs
1
/*
2
* QUANTCONNECT.COM - Democratizing Finance, Empowering Individuals.
3
* Lean Algorithmic Trading Engine v2.0. Copyright 2014 QuantConnect Corporation.
4
*
5
* Licensed under the Apache License, Version 2.0 (the "License");
6
* you may not use this file except in compliance with the License.
7
* You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
8
*
9
* Unless required by applicable law or agreed to in writing, software
10
* distributed under the License is distributed on an "AS IS" BASIS,
11
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
* See the License for the specific language governing permissions and
13
* limitations under the License.
14
*/
15
16
using
Newtonsoft.Json;
17
18
namespace
QuantConnect.Orders
19
{
20
/// <summary>
21
/// The purpose of this class is to store time and price information
22
/// available at the time an order was submitted.
23
/// </summary>
24
public
class
OrderSubmissionData
25
{
26
/// <summary>
27
/// The bid price at order submission time
28
/// </summary>
29
[JsonProperty(PropertyName =
"bidPrice"
)]
30
public
decimal
BidPrice
{
get
; }
31
32
/// <summary>
33
/// The ask price at order submission time
34
/// </summary>
35
[JsonProperty(PropertyName =
"askPrice"
)]
36
public
decimal
AskPrice
{
get
; }
37
38
/// <summary>
39
/// The current price at order submission time
40
/// </summary>
41
[JsonProperty(PropertyName =
"lastPrice"
)]
42
public
decimal
LastPrice
{
get
; }
43
44
/// <summary>
45
/// Initializes a new instance of the <see cref="OrderSubmissionData"/> class
46
/// </summary>
47
/// <remarks>This method is currently only used for testing.</remarks>
48
public
OrderSubmissionData
(decimal bidPrice, decimal askPrice, decimal lastPrice)
49
{
50
BidPrice
= bidPrice;
51
AskPrice
= askPrice;
52
LastPrice
= lastPrice;
53
}
54
55
/// <summary>
56
/// Return a new instance clone of this object
57
/// </summary>
58
public
OrderSubmissionData
Clone
()
59
{
60
return
(
OrderSubmissionData
)MemberwiseClone();
61
}
62
}
63
}
Common
Orders
OrderSubmissionData.cs
Generated by
1.8.17