forked from quickfixgo/quickfix
/
SecurityTypeRequest.generated.go
265 lines (223 loc) · 7.47 KB
/
SecurityTypeRequest.generated.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
package securitytyperequest
import (
"github.com/quickfixgo/quickfix"
"github.com/quickfixgo/quickfix/enum"
"github.com/quickfixgo/quickfix/field"
"github.com/quickfixgo/quickfix/fixt11"
"github.com/quickfixgo/quickfix/tag"
)
//SecurityTypeRequest is the fix50sp1 SecurityTypeRequest type, MsgType = v
type SecurityTypeRequest struct {
fixt11.Header
*quickfix.Body
fixt11.Trailer
Message *quickfix.Message
}
//FromMessage creates a SecurityTypeRequest from a quickfix.Message instance
func FromMessage(m *quickfix.Message) SecurityTypeRequest {
return SecurityTypeRequest{
Header: fixt11.Header{&m.Header},
Body: &m.Body,
Trailer: fixt11.Trailer{&m.Trailer},
Message: m,
}
}
//ToMessage returns a quickfix.Message instance
func (m SecurityTypeRequest) ToMessage() *quickfix.Message {
return m.Message
}
//New returns a SecurityTypeRequest initialized with the required fields for SecurityTypeRequest
func New(securityreqid field.SecurityReqIDField) (m SecurityTypeRequest) {
m.Message = quickfix.NewMessage()
m.Header = fixt11.NewHeader(&m.Message.Header)
m.Body = &m.Message.Body
m.Trailer.Trailer = &m.Message.Trailer
m.Header.Set(field.NewMsgType("v"))
m.Set(securityreqid)
return
}
//A RouteOut is the callback type that should be implemented for routing Message
type RouteOut func(msg SecurityTypeRequest, sessionID quickfix.SessionID) quickfix.MessageRejectError
//Route returns the beginstring, message type, and MessageRoute for this Message type
func Route(router RouteOut) (string, string, quickfix.MessageRoute) {
r := func(msg *quickfix.Message, sessionID quickfix.SessionID) quickfix.MessageRejectError {
return router(FromMessage(msg), sessionID)
}
return "8", "v", r
}
//SetText sets Text, Tag 58
func (m SecurityTypeRequest) SetText(v string) {
m.Set(field.NewText(v))
}
//SetSecurityType sets SecurityType, Tag 167
func (m SecurityTypeRequest) SetSecurityType(v enum.SecurityType) {
m.Set(field.NewSecurityType(v))
}
//SetSecurityReqID sets SecurityReqID, Tag 320
func (m SecurityTypeRequest) SetSecurityReqID(v string) {
m.Set(field.NewSecurityReqID(v))
}
//SetTradingSessionID sets TradingSessionID, Tag 336
func (m SecurityTypeRequest) SetTradingSessionID(v enum.TradingSessionID) {
m.Set(field.NewTradingSessionID(v))
}
//SetEncodedTextLen sets EncodedTextLen, Tag 354
func (m SecurityTypeRequest) SetEncodedTextLen(v int) {
m.Set(field.NewEncodedTextLen(v))
}
//SetEncodedText sets EncodedText, Tag 355
func (m SecurityTypeRequest) SetEncodedText(v string) {
m.Set(field.NewEncodedText(v))
}
//SetProduct sets Product, Tag 460
func (m SecurityTypeRequest) SetProduct(v enum.Product) {
m.Set(field.NewProduct(v))
}
//SetTradingSessionSubID sets TradingSessionSubID, Tag 625
func (m SecurityTypeRequest) SetTradingSessionSubID(v enum.TradingSessionSubID) {
m.Set(field.NewTradingSessionSubID(v))
}
//SetSecuritySubType sets SecuritySubType, Tag 762
func (m SecurityTypeRequest) SetSecuritySubType(v string) {
m.Set(field.NewSecuritySubType(v))
}
//SetMarketSegmentID sets MarketSegmentID, Tag 1300
func (m SecurityTypeRequest) SetMarketSegmentID(v string) {
m.Set(field.NewMarketSegmentID(v))
}
//SetMarketID sets MarketID, Tag 1301
func (m SecurityTypeRequest) SetMarketID(v string) {
m.Set(field.NewMarketID(v))
}
//GetText gets Text, Tag 58
func (m SecurityTypeRequest) GetText() (v string, err quickfix.MessageRejectError) {
var f field.TextField
if err = m.Get(&f); err == nil {
v = f.Value()
}
return
}
//GetSecurityType gets SecurityType, Tag 167
func (m SecurityTypeRequest) GetSecurityType() (v enum.SecurityType, err quickfix.MessageRejectError) {
var f field.SecurityTypeField
if err = m.Get(&f); err == nil {
v = f.Value()
}
return
}
//GetSecurityReqID gets SecurityReqID, Tag 320
func (m SecurityTypeRequest) GetSecurityReqID() (v string, err quickfix.MessageRejectError) {
var f field.SecurityReqIDField
if err = m.Get(&f); err == nil {
v = f.Value()
}
return
}
//GetTradingSessionID gets TradingSessionID, Tag 336
func (m SecurityTypeRequest) GetTradingSessionID() (v enum.TradingSessionID, err quickfix.MessageRejectError) {
var f field.TradingSessionIDField
if err = m.Get(&f); err == nil {
v = f.Value()
}
return
}
//GetEncodedTextLen gets EncodedTextLen, Tag 354
func (m SecurityTypeRequest) GetEncodedTextLen() (v int, err quickfix.MessageRejectError) {
var f field.EncodedTextLenField
if err = m.Get(&f); err == nil {
v = f.Value()
}
return
}
//GetEncodedText gets EncodedText, Tag 355
func (m SecurityTypeRequest) GetEncodedText() (v string, err quickfix.MessageRejectError) {
var f field.EncodedTextField
if err = m.Get(&f); err == nil {
v = f.Value()
}
return
}
//GetProduct gets Product, Tag 460
func (m SecurityTypeRequest) GetProduct() (v enum.Product, err quickfix.MessageRejectError) {
var f field.ProductField
if err = m.Get(&f); err == nil {
v = f.Value()
}
return
}
//GetTradingSessionSubID gets TradingSessionSubID, Tag 625
func (m SecurityTypeRequest) GetTradingSessionSubID() (v enum.TradingSessionSubID, err quickfix.MessageRejectError) {
var f field.TradingSessionSubIDField
if err = m.Get(&f); err == nil {
v = f.Value()
}
return
}
//GetSecuritySubType gets SecuritySubType, Tag 762
func (m SecurityTypeRequest) GetSecuritySubType() (v string, err quickfix.MessageRejectError) {
var f field.SecuritySubTypeField
if err = m.Get(&f); err == nil {
v = f.Value()
}
return
}
//GetMarketSegmentID gets MarketSegmentID, Tag 1300
func (m SecurityTypeRequest) GetMarketSegmentID() (v string, err quickfix.MessageRejectError) {
var f field.MarketSegmentIDField
if err = m.Get(&f); err == nil {
v = f.Value()
}
return
}
//GetMarketID gets MarketID, Tag 1301
func (m SecurityTypeRequest) GetMarketID() (v string, err quickfix.MessageRejectError) {
var f field.MarketIDField
if err = m.Get(&f); err == nil {
v = f.Value()
}
return
}
//HasText returns true if Text is present, Tag 58
func (m SecurityTypeRequest) HasText() bool {
return m.Has(tag.Text)
}
//HasSecurityType returns true if SecurityType is present, Tag 167
func (m SecurityTypeRequest) HasSecurityType() bool {
return m.Has(tag.SecurityType)
}
//HasSecurityReqID returns true if SecurityReqID is present, Tag 320
func (m SecurityTypeRequest) HasSecurityReqID() bool {
return m.Has(tag.SecurityReqID)
}
//HasTradingSessionID returns true if TradingSessionID is present, Tag 336
func (m SecurityTypeRequest) HasTradingSessionID() bool {
return m.Has(tag.TradingSessionID)
}
//HasEncodedTextLen returns true if EncodedTextLen is present, Tag 354
func (m SecurityTypeRequest) HasEncodedTextLen() bool {
return m.Has(tag.EncodedTextLen)
}
//HasEncodedText returns true if EncodedText is present, Tag 355
func (m SecurityTypeRequest) HasEncodedText() bool {
return m.Has(tag.EncodedText)
}
//HasProduct returns true if Product is present, Tag 460
func (m SecurityTypeRequest) HasProduct() bool {
return m.Has(tag.Product)
}
//HasTradingSessionSubID returns true if TradingSessionSubID is present, Tag 625
func (m SecurityTypeRequest) HasTradingSessionSubID() bool {
return m.Has(tag.TradingSessionSubID)
}
//HasSecuritySubType returns true if SecuritySubType is present, Tag 762
func (m SecurityTypeRequest) HasSecuritySubType() bool {
return m.Has(tag.SecuritySubType)
}
//HasMarketSegmentID returns true if MarketSegmentID is present, Tag 1300
func (m SecurityTypeRequest) HasMarketSegmentID() bool {
return m.Has(tag.MarketSegmentID)
}
//HasMarketID returns true if MarketID is present, Tag 1301
func (m SecurityTypeRequest) HasMarketID() bool {
return m.Has(tag.MarketID)
}