Skip to main content

fixer_fix/fix50/
security_status.rs

1// Code generated by fixer-gen. DO NOT EDIT.
2#![allow(clippy::new_without_default)]
3#![allow(clippy::needless_pass_by_value)]
4#![allow(clippy::too_many_arguments)]
5#![allow(unused_imports)]
6
7use fixer::message::Message;
8use fixer::fix_string::FIXString;
9use fixer::errors::MessageRejectErrorEnum;
10use fixer::session::session_id::SessionID;
11
12use rust_decimal::Decimal;
13
14
15use jiff::Timestamp;
16
17use crate::field;
18use crate::tag;
19
20/// `SecurityStatus` is the `fix50` `SecurityStatus` type, `MsgType` = f.
21pub struct SecurityStatus {
22    pub message: Message,
23}
24
25impl SecurityStatus {
26    /// Creates a new `SecurityStatus` with required fields.
27    pub fn new() -> Self {
28        let mut msg = Message::new();
29        msg.header.set_field(tag::MSG_TYPE, FIXString::from("f".to_string()));
30
31        Self { message: msg }
32    }
33
34    /// Creates a `SecurityStatus` from an existing `Message`.
35    pub fn from_message(msg: Message) -> Self {
36        Self { message: msg }
37    }
38
39    /// Returns the underlying `Message`.
40    pub fn to_message(self) -> Message {
41        self.message
42    }
43
44
45
46
47    /// Sets `Adjustment`, Tag 334.
48    pub fn set_adjustment(&mut self, v: isize) {
49        self.message.body.set_field(tag::ADJUSTMENT, fixer::fix_int::FIXInt::from(v));
50    }
51
52    /// Gets `Adjustment`, Tag 334.
53    pub fn get_adjustment(&self) -> Result<isize, MessageRejectErrorEnum> {
54        let mut fld = field::AdjustmentField::new(0);
55        self.message.body.get_field(tag::ADJUSTMENT, &mut fld.0)?;
56        Ok(fld.value())
57    }
58
59
60    /// Returns true if `Adjustment` is present, Tag 334.
61    pub fn has_adjustment(&self) -> bool {
62        self.message.body.has(tag::ADJUSTMENT)
63    }
64
65
66
67
68    /// Sets `BuyVolume`, Tag 330.
69    pub fn set_buy_volume(&mut self, val: Decimal, scale: i32) {
70        self.message.body.set_field(tag::BUY_VOLUME, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
71    }
72
73    /// Gets `BuyVolume`, Tag 330.
74    pub fn get_buy_volume(&self) -> Result<Decimal, MessageRejectErrorEnum> {
75        let mut fld = field::BuyVolumeField::new(Decimal::ZERO, 0);
76        self.message.body.get_field(tag::BUY_VOLUME, &mut fld.0)?;
77        Ok(fld.value())
78    }
79
80
81    /// Returns true if `BuyVolume` is present, Tag 330.
82    pub fn has_buy_volume(&self) -> bool {
83        self.message.body.has(tag::BUY_VOLUME)
84    }
85
86
87
88
89    /// Sets `CFICode`, Tag 461.
90    pub fn set_cfi_code(&mut self, v: String) {
91        self.message.body.set_field(tag::CFI_CODE, FIXString::from(v));
92    }
93
94    /// Gets `CFICode`, Tag 461.
95    pub fn get_cfi_code(&self) -> Result<String, MessageRejectErrorEnum> {
96        let mut fld = field::CFICodeField::new(String::new());
97        self.message.body.get_field(tag::CFI_CODE, &mut fld.0)?;
98        Ok(fld.value().to_string())
99    }
100
101
102    /// Returns true if `CFICode` is present, Tag 461.
103    pub fn has_cfi_code(&self) -> bool {
104        self.message.body.has(tag::CFI_CODE)
105    }
106
107
108
109
110    /// Sets `CPProgram`, Tag 875.
111    pub fn set_cp_program(&mut self, v: isize) {
112        self.message.body.set_field(tag::CP_PROGRAM, fixer::fix_int::FIXInt::from(v));
113    }
114
115    /// Gets `CPProgram`, Tag 875.
116    pub fn get_cp_program(&self) -> Result<isize, MessageRejectErrorEnum> {
117        let mut fld = field::CPProgramField::new(0);
118        self.message.body.get_field(tag::CP_PROGRAM, &mut fld.0)?;
119        Ok(fld.value())
120    }
121
122
123    /// Returns true if `CPProgram` is present, Tag 875.
124    pub fn has_cp_program(&self) -> bool {
125        self.message.body.has(tag::CP_PROGRAM)
126    }
127
128
129
130
131    /// Sets `CPRegType`, Tag 876.
132    pub fn set_cp_reg_type(&mut self, v: String) {
133        self.message.body.set_field(tag::CP_REG_TYPE, FIXString::from(v));
134    }
135
136    /// Gets `CPRegType`, Tag 876.
137    pub fn get_cp_reg_type(&self) -> Result<String, MessageRejectErrorEnum> {
138        let mut fld = field::CPRegTypeField::new(String::new());
139        self.message.body.get_field(tag::CP_REG_TYPE, &mut fld.0)?;
140        Ok(fld.value().to_string())
141    }
142
143
144    /// Returns true if `CPRegType` is present, Tag 876.
145    pub fn has_cp_reg_type(&self) -> bool {
146        self.message.body.has(tag::CP_REG_TYPE)
147    }
148
149
150
151
152    /// Sets `ContractMultiplier`, Tag 231.
153    pub fn set_contract_multiplier(&mut self, val: Decimal, scale: i32) {
154        self.message.body.set_field(tag::CONTRACT_MULTIPLIER, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
155    }
156
157    /// Gets `ContractMultiplier`, Tag 231.
158    pub fn get_contract_multiplier(&self) -> Result<Decimal, MessageRejectErrorEnum> {
159        let mut fld = field::ContractMultiplierField::new(Decimal::ZERO, 0);
160        self.message.body.get_field(tag::CONTRACT_MULTIPLIER, &mut fld.0)?;
161        Ok(fld.value())
162    }
163
164
165    /// Returns true if `ContractMultiplier` is present, Tag 231.
166    pub fn has_contract_multiplier(&self) -> bool {
167        self.message.body.has(tag::CONTRACT_MULTIPLIER)
168    }
169
170
171
172
173    /// Sets `ContractSettlMonth`, Tag 667.
174    pub fn set_contract_settl_month(&mut self, v: String) {
175        self.message.body.set_field(tag::CONTRACT_SETTL_MONTH, FIXString::from(v));
176    }
177
178    /// Gets `ContractSettlMonth`, Tag 667.
179    pub fn get_contract_settl_month(&self) -> Result<String, MessageRejectErrorEnum> {
180        let mut fld = field::ContractSettlMonthField::new(String::new());
181        self.message.body.get_field(tag::CONTRACT_SETTL_MONTH, &mut fld.0)?;
182        Ok(fld.value().to_string())
183    }
184
185
186    /// Returns true if `ContractSettlMonth` is present, Tag 667.
187    pub fn has_contract_settl_month(&self) -> bool {
188        self.message.body.has(tag::CONTRACT_SETTL_MONTH)
189    }
190
191
192
193
194    /// Sets `CorporateAction`, Tag 292.
195    pub fn set_corporate_action(&mut self, v: String) {
196        self.message.body.set_field(tag::CORPORATE_ACTION, FIXString::from(v));
197    }
198
199    /// Gets `CorporateAction`, Tag 292.
200    pub fn get_corporate_action(&self) -> Result<String, MessageRejectErrorEnum> {
201        let mut fld = field::CorporateActionField::new(String::new());
202        self.message.body.get_field(tag::CORPORATE_ACTION, &mut fld.0)?;
203        Ok(fld.value().to_string())
204    }
205
206
207    /// Returns true if `CorporateAction` is present, Tag 292.
208    pub fn has_corporate_action(&self) -> bool {
209        self.message.body.has(tag::CORPORATE_ACTION)
210    }
211
212
213
214
215    /// Sets `CountryOfIssue`, Tag 470.
216    pub fn set_country_of_issue(&mut self, v: String) {
217        self.message.body.set_field(tag::COUNTRY_OF_ISSUE, FIXString::from(v));
218    }
219
220    /// Gets `CountryOfIssue`, Tag 470.
221    pub fn get_country_of_issue(&self) -> Result<String, MessageRejectErrorEnum> {
222        let mut fld = field::CountryOfIssueField::new(String::new());
223        self.message.body.get_field(tag::COUNTRY_OF_ISSUE, &mut fld.0)?;
224        Ok(fld.value().to_string())
225    }
226
227
228    /// Returns true if `CountryOfIssue` is present, Tag 470.
229    pub fn has_country_of_issue(&self) -> bool {
230        self.message.body.has(tag::COUNTRY_OF_ISSUE)
231    }
232
233
234
235
236    /// Sets `CouponPaymentDate`, Tag 224.
237    pub fn set_coupon_payment_date(&mut self, v: String) {
238        self.message.body.set_field(tag::COUPON_PAYMENT_DATE, FIXString::from(v));
239    }
240
241    /// Gets `CouponPaymentDate`, Tag 224.
242    pub fn get_coupon_payment_date(&self) -> Result<String, MessageRejectErrorEnum> {
243        let mut fld = field::CouponPaymentDateField::new(String::new());
244        self.message.body.get_field(tag::COUPON_PAYMENT_DATE, &mut fld.0)?;
245        Ok(fld.value().to_string())
246    }
247
248
249    /// Returns true if `CouponPaymentDate` is present, Tag 224.
250    pub fn has_coupon_payment_date(&self) -> bool {
251        self.message.body.has(tag::COUPON_PAYMENT_DATE)
252    }
253
254
255
256
257    /// Sets `CouponRate`, Tag 223.
258    pub fn set_coupon_rate(&mut self, val: Decimal, scale: i32) {
259        self.message.body.set_field(tag::COUPON_RATE, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
260    }
261
262    /// Gets `CouponRate`, Tag 223.
263    pub fn get_coupon_rate(&self) -> Result<Decimal, MessageRejectErrorEnum> {
264        let mut fld = field::CouponRateField::new(Decimal::ZERO, 0);
265        self.message.body.get_field(tag::COUPON_RATE, &mut fld.0)?;
266        Ok(fld.value())
267    }
268
269
270    /// Returns true if `CouponRate` is present, Tag 223.
271    pub fn has_coupon_rate(&self) -> bool {
272        self.message.body.has(tag::COUPON_RATE)
273    }
274
275
276
277
278    /// Sets `CreditRating`, Tag 255.
279    pub fn set_credit_rating(&mut self, v: String) {
280        self.message.body.set_field(tag::CREDIT_RATING, FIXString::from(v));
281    }
282
283    /// Gets `CreditRating`, Tag 255.
284    pub fn get_credit_rating(&self) -> Result<String, MessageRejectErrorEnum> {
285        let mut fld = field::CreditRatingField::new(String::new());
286        self.message.body.get_field(tag::CREDIT_RATING, &mut fld.0)?;
287        Ok(fld.value().to_string())
288    }
289
290
291    /// Returns true if `CreditRating` is present, Tag 255.
292    pub fn has_credit_rating(&self) -> bool {
293        self.message.body.has(tag::CREDIT_RATING)
294    }
295
296
297
298
299    /// Sets `Currency`, Tag 15.
300    pub fn set_currency(&mut self, v: String) {
301        self.message.body.set_field(tag::CURRENCY, FIXString::from(v));
302    }
303
304    /// Gets `Currency`, Tag 15.
305    pub fn get_currency(&self) -> Result<String, MessageRejectErrorEnum> {
306        let mut fld = field::CurrencyField::new(String::new());
307        self.message.body.get_field(tag::CURRENCY, &mut fld.0)?;
308        Ok(fld.value().to_string())
309    }
310
311
312    /// Returns true if `Currency` is present, Tag 15.
313    pub fn has_currency(&self) -> bool {
314        self.message.body.has(tag::CURRENCY)
315    }
316
317
318
319
320    /// Sets `DatedDate`, Tag 873.
321    pub fn set_dated_date(&mut self, v: String) {
322        self.message.body.set_field(tag::DATED_DATE, FIXString::from(v));
323    }
324
325    /// Gets `DatedDate`, Tag 873.
326    pub fn get_dated_date(&self) -> Result<String, MessageRejectErrorEnum> {
327        let mut fld = field::DatedDateField::new(String::new());
328        self.message.body.get_field(tag::DATED_DATE, &mut fld.0)?;
329        Ok(fld.value().to_string())
330    }
331
332
333    /// Returns true if `DatedDate` is present, Tag 873.
334    pub fn has_dated_date(&self) -> bool {
335        self.message.body.has(tag::DATED_DATE)
336    }
337
338
339
340
341    /// Sets `DeliveryForm`, Tag 668.
342    pub fn set_delivery_form(&mut self, v: isize) {
343        self.message.body.set_field(tag::DELIVERY_FORM, fixer::fix_int::FIXInt::from(v));
344    }
345
346    /// Gets `DeliveryForm`, Tag 668.
347    pub fn get_delivery_form(&self) -> Result<isize, MessageRejectErrorEnum> {
348        let mut fld = field::DeliveryFormField::new(0);
349        self.message.body.get_field(tag::DELIVERY_FORM, &mut fld.0)?;
350        Ok(fld.value())
351    }
352
353
354    /// Returns true if `DeliveryForm` is present, Tag 668.
355    pub fn has_delivery_form(&self) -> bool {
356        self.message.body.has(tag::DELIVERY_FORM)
357    }
358
359
360
361
362    /// Sets `DueToRelated`, Tag 329.
363    pub fn set_due_to_related(&mut self, v: bool) {
364        self.message.body.set_field(tag::DUE_TO_RELATED, fixer::fix_boolean::FIXBoolean::from(v));
365    }
366
367    /// Gets `DueToRelated`, Tag 329.
368    pub fn get_due_to_related(&self) -> Result<bool, MessageRejectErrorEnum> {
369        let mut fld = field::DueToRelatedField::new(false);
370        self.message.body.get_field(tag::DUE_TO_RELATED, &mut fld.0)?;
371        Ok(fld.value())
372    }
373
374
375    /// Returns true if `DueToRelated` is present, Tag 329.
376    pub fn has_due_to_related(&self) -> bool {
377        self.message.body.has(tag::DUE_TO_RELATED)
378    }
379
380
381
382
383    /// Sets `EncodedIssuer`, Tag 349.
384    pub fn set_encoded_issuer(&mut self, v: String) {
385        self.message.body.set_field(tag::ENCODED_ISSUER, FIXString::from(v));
386    }
387
388    /// Gets `EncodedIssuer`, Tag 349.
389    pub fn get_encoded_issuer(&self) -> Result<String, MessageRejectErrorEnum> {
390        let mut fld = field::EncodedIssuerField::new(String::new());
391        self.message.body.get_field(tag::ENCODED_ISSUER, &mut fld.0)?;
392        Ok(fld.value().to_string())
393    }
394
395
396    /// Returns true if `EncodedIssuer` is present, Tag 349.
397    pub fn has_encoded_issuer(&self) -> bool {
398        self.message.body.has(tag::ENCODED_ISSUER)
399    }
400
401
402
403
404    /// Sets `EncodedIssuerLen`, Tag 348.
405    pub fn set_encoded_issuer_len(&mut self, v: isize) {
406        self.message.body.set_field(tag::ENCODED_ISSUER_LEN, fixer::fix_int::FIXInt::from(v));
407    }
408
409    /// Gets `EncodedIssuerLen`, Tag 348.
410    pub fn get_encoded_issuer_len(&self) -> Result<isize, MessageRejectErrorEnum> {
411        let mut fld = field::EncodedIssuerLenField::new(0);
412        self.message.body.get_field(tag::ENCODED_ISSUER_LEN, &mut fld.0)?;
413        Ok(fld.value())
414    }
415
416
417    /// Returns true if `EncodedIssuerLen` is present, Tag 348.
418    pub fn has_encoded_issuer_len(&self) -> bool {
419        self.message.body.has(tag::ENCODED_ISSUER_LEN)
420    }
421
422
423
424
425    /// Sets `EncodedSecurityDesc`, Tag 351.
426    pub fn set_encoded_security_desc(&mut self, v: String) {
427        self.message.body.set_field(tag::ENCODED_SECURITY_DESC, FIXString::from(v));
428    }
429
430    /// Gets `EncodedSecurityDesc`, Tag 351.
431    pub fn get_encoded_security_desc(&self) -> Result<String, MessageRejectErrorEnum> {
432        let mut fld = field::EncodedSecurityDescField::new(String::new());
433        self.message.body.get_field(tag::ENCODED_SECURITY_DESC, &mut fld.0)?;
434        Ok(fld.value().to_string())
435    }
436
437
438    /// Returns true if `EncodedSecurityDesc` is present, Tag 351.
439    pub fn has_encoded_security_desc(&self) -> bool {
440        self.message.body.has(tag::ENCODED_SECURITY_DESC)
441    }
442
443
444
445
446    /// Sets `EncodedSecurityDescLen`, Tag 350.
447    pub fn set_encoded_security_desc_len(&mut self, v: isize) {
448        self.message.body.set_field(tag::ENCODED_SECURITY_DESC_LEN, fixer::fix_int::FIXInt::from(v));
449    }
450
451    /// Gets `EncodedSecurityDescLen`, Tag 350.
452    pub fn get_encoded_security_desc_len(&self) -> Result<isize, MessageRejectErrorEnum> {
453        let mut fld = field::EncodedSecurityDescLenField::new(0);
454        self.message.body.get_field(tag::ENCODED_SECURITY_DESC_LEN, &mut fld.0)?;
455        Ok(fld.value())
456    }
457
458
459    /// Returns true if `EncodedSecurityDescLen` is present, Tag 350.
460    pub fn has_encoded_security_desc_len(&self) -> bool {
461        self.message.body.has(tag::ENCODED_SECURITY_DESC_LEN)
462    }
463
464
465
466
467    /// Sets `EncodedText`, Tag 355.
468    pub fn set_encoded_text(&mut self, v: String) {
469        self.message.body.set_field(tag::ENCODED_TEXT, FIXString::from(v));
470    }
471
472    /// Gets `EncodedText`, Tag 355.
473    pub fn get_encoded_text(&self) -> Result<String, MessageRejectErrorEnum> {
474        let mut fld = field::EncodedTextField::new(String::new());
475        self.message.body.get_field(tag::ENCODED_TEXT, &mut fld.0)?;
476        Ok(fld.value().to_string())
477    }
478
479
480    /// Returns true if `EncodedText` is present, Tag 355.
481    pub fn has_encoded_text(&self) -> bool {
482        self.message.body.has(tag::ENCODED_TEXT)
483    }
484
485
486
487
488    /// Sets `EncodedTextLen`, Tag 354.
489    pub fn set_encoded_text_len(&mut self, v: isize) {
490        self.message.body.set_field(tag::ENCODED_TEXT_LEN, fixer::fix_int::FIXInt::from(v));
491    }
492
493    /// Gets `EncodedTextLen`, Tag 354.
494    pub fn get_encoded_text_len(&self) -> Result<isize, MessageRejectErrorEnum> {
495        let mut fld = field::EncodedTextLenField::new(0);
496        self.message.body.get_field(tag::ENCODED_TEXT_LEN, &mut fld.0)?;
497        Ok(fld.value())
498    }
499
500
501    /// Returns true if `EncodedTextLen` is present, Tag 354.
502    pub fn has_encoded_text_len(&self) -> bool {
503        self.message.body.has(tag::ENCODED_TEXT_LEN)
504    }
505
506
507
508
509    /// Sets `Factor`, Tag 228.
510    pub fn set_factor(&mut self, val: Decimal, scale: i32) {
511        self.message.body.set_field(tag::FACTOR, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
512    }
513
514    /// Gets `Factor`, Tag 228.
515    pub fn get_factor(&self) -> Result<Decimal, MessageRejectErrorEnum> {
516        let mut fld = field::FactorField::new(Decimal::ZERO, 0);
517        self.message.body.get_field(tag::FACTOR, &mut fld.0)?;
518        Ok(fld.value())
519    }
520
521
522    /// Returns true if `Factor` is present, Tag 228.
523    pub fn has_factor(&self) -> bool {
524        self.message.body.has(tag::FACTOR)
525    }
526
527
528
529
530    /// Sets `FinancialStatus`, Tag 291.
531    pub fn set_financial_status(&mut self, v: String) {
532        self.message.body.set_field(tag::FINANCIAL_STATUS, FIXString::from(v));
533    }
534
535    /// Gets `FinancialStatus`, Tag 291.
536    pub fn get_financial_status(&self) -> Result<String, MessageRejectErrorEnum> {
537        let mut fld = field::FinancialStatusField::new(String::new());
538        self.message.body.get_field(tag::FINANCIAL_STATUS, &mut fld.0)?;
539        Ok(fld.value().to_string())
540    }
541
542
543    /// Returns true if `FinancialStatus` is present, Tag 291.
544    pub fn has_financial_status(&self) -> bool {
545        self.message.body.has(tag::FINANCIAL_STATUS)
546    }
547
548
549
550
551    /// Sets `FirstPx`, Tag 1025.
552    pub fn set_first_px(&mut self, val: Decimal, scale: i32) {
553        self.message.body.set_field(tag::FIRST_PX, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
554    }
555
556    /// Gets `FirstPx`, Tag 1025.
557    pub fn get_first_px(&self) -> Result<Decimal, MessageRejectErrorEnum> {
558        let mut fld = field::FirstPxField::new(Decimal::ZERO, 0);
559        self.message.body.get_field(tag::FIRST_PX, &mut fld.0)?;
560        Ok(fld.value())
561    }
562
563
564    /// Returns true if `FirstPx` is present, Tag 1025.
565    pub fn has_first_px(&self) -> bool {
566        self.message.body.has(tag::FIRST_PX)
567    }
568
569
570
571
572    /// Sets `HaltReasonChar`, Tag 327.
573    pub fn set_halt_reason_char(&mut self, v: String) {
574        self.message.body.set_field(tag::HALT_REASON_CHAR, FIXString::from(v));
575    }
576
577    /// Gets `HaltReasonChar`, Tag 327.
578    pub fn get_halt_reason_char(&self) -> Result<String, MessageRejectErrorEnum> {
579        let mut fld = field::HaltReasonCharField::new(String::new());
580        self.message.body.get_field(tag::HALT_REASON_CHAR, &mut fld.0)?;
581        Ok(fld.value().to_string())
582    }
583
584
585    /// Returns true if `HaltReasonChar` is present, Tag 327.
586    pub fn has_halt_reason_char(&self) -> bool {
587        self.message.body.has(tag::HALT_REASON_CHAR)
588    }
589
590
591
592
593    /// Sets `HighPx`, Tag 332.
594    pub fn set_high_px(&mut self, val: Decimal, scale: i32) {
595        self.message.body.set_field(tag::HIGH_PX, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
596    }
597
598    /// Gets `HighPx`, Tag 332.
599    pub fn get_high_px(&self) -> Result<Decimal, MessageRejectErrorEnum> {
600        let mut fld = field::HighPxField::new(Decimal::ZERO, 0);
601        self.message.body.get_field(tag::HIGH_PX, &mut fld.0)?;
602        Ok(fld.value())
603    }
604
605
606    /// Returns true if `HighPx` is present, Tag 332.
607    pub fn has_high_px(&self) -> bool {
608        self.message.body.has(tag::HIGH_PX)
609    }
610
611
612
613
614    /// Sets `InViewOfCommon`, Tag 328.
615    pub fn set_in_view_of_common(&mut self, v: bool) {
616        self.message.body.set_field(tag::IN_VIEW_OF_COMMON, fixer::fix_boolean::FIXBoolean::from(v));
617    }
618
619    /// Gets `InViewOfCommon`, Tag 328.
620    pub fn get_in_view_of_common(&self) -> Result<bool, MessageRejectErrorEnum> {
621        let mut fld = field::InViewOfCommonField::new(false);
622        self.message.body.get_field(tag::IN_VIEW_OF_COMMON, &mut fld.0)?;
623        Ok(fld.value())
624    }
625
626
627    /// Returns true if `InViewOfCommon` is present, Tag 328.
628    pub fn has_in_view_of_common(&self) -> bool {
629        self.message.body.has(tag::IN_VIEW_OF_COMMON)
630    }
631
632
633
634
635    /// Sets `InstrRegistry`, Tag 543.
636    pub fn set_instr_registry(&mut self, v: String) {
637        self.message.body.set_field(tag::INSTR_REGISTRY, FIXString::from(v));
638    }
639
640    /// Gets `InstrRegistry`, Tag 543.
641    pub fn get_instr_registry(&self) -> Result<String, MessageRejectErrorEnum> {
642        let mut fld = field::InstrRegistryField::new(String::new());
643        self.message.body.get_field(tag::INSTR_REGISTRY, &mut fld.0)?;
644        Ok(fld.value().to_string())
645    }
646
647
648    /// Returns true if `InstrRegistry` is present, Tag 543.
649    pub fn has_instr_registry(&self) -> bool {
650        self.message.body.has(tag::INSTR_REGISTRY)
651    }
652
653
654
655
656    /// Sets `InstrmtAssignmentMethod`, Tag 1049.
657    pub fn set_instrmt_assignment_method(&mut self, v: String) {
658        self.message.body.set_field(tag::INSTRMT_ASSIGNMENT_METHOD, FIXString::from(v));
659    }
660
661    /// Gets `InstrmtAssignmentMethod`, Tag 1049.
662    pub fn get_instrmt_assignment_method(&self) -> Result<String, MessageRejectErrorEnum> {
663        let mut fld = field::InstrmtAssignmentMethodField::new(String::new());
664        self.message.body.get_field(tag::INSTRMT_ASSIGNMENT_METHOD, &mut fld.0)?;
665        Ok(fld.value().to_string())
666    }
667
668
669    /// Returns true if `InstrmtAssignmentMethod` is present, Tag 1049.
670    pub fn has_instrmt_assignment_method(&self) -> bool {
671        self.message.body.has(tag::INSTRMT_ASSIGNMENT_METHOD)
672    }
673
674
675
676
677    /// Sets `InterestAccrualDate`, Tag 874.
678    pub fn set_interest_accrual_date(&mut self, v: String) {
679        self.message.body.set_field(tag::INTEREST_ACCRUAL_DATE, FIXString::from(v));
680    }
681
682    /// Gets `InterestAccrualDate`, Tag 874.
683    pub fn get_interest_accrual_date(&self) -> Result<String, MessageRejectErrorEnum> {
684        let mut fld = field::InterestAccrualDateField::new(String::new());
685        self.message.body.get_field(tag::INTEREST_ACCRUAL_DATE, &mut fld.0)?;
686        Ok(fld.value().to_string())
687    }
688
689
690    /// Returns true if `InterestAccrualDate` is present, Tag 874.
691    pub fn has_interest_accrual_date(&self) -> bool {
692        self.message.body.has(tag::INTEREST_ACCRUAL_DATE)
693    }
694
695
696
697
698    /// Sets `IssueDate`, Tag 225.
699    pub fn set_issue_date(&mut self, v: String) {
700        self.message.body.set_field(tag::ISSUE_DATE, FIXString::from(v));
701    }
702
703    /// Gets `IssueDate`, Tag 225.
704    pub fn get_issue_date(&self) -> Result<String, MessageRejectErrorEnum> {
705        let mut fld = field::IssueDateField::new(String::new());
706        self.message.body.get_field(tag::ISSUE_DATE, &mut fld.0)?;
707        Ok(fld.value().to_string())
708    }
709
710
711    /// Returns true if `IssueDate` is present, Tag 225.
712    pub fn has_issue_date(&self) -> bool {
713        self.message.body.has(tag::ISSUE_DATE)
714    }
715
716
717
718
719    /// Sets `Issuer`, Tag 106.
720    pub fn set_issuer(&mut self, v: String) {
721        self.message.body.set_field(tag::ISSUER, FIXString::from(v));
722    }
723
724    /// Gets `Issuer`, Tag 106.
725    pub fn get_issuer(&self) -> Result<String, MessageRejectErrorEnum> {
726        let mut fld = field::IssuerField::new(String::new());
727        self.message.body.get_field(tag::ISSUER, &mut fld.0)?;
728        Ok(fld.value().to_string())
729    }
730
731
732    /// Returns true if `Issuer` is present, Tag 106.
733    pub fn has_issuer(&self) -> bool {
734        self.message.body.has(tag::ISSUER)
735    }
736
737
738
739
740    /// Sets `LastPx`, Tag 31.
741    pub fn set_last_px(&mut self, val: Decimal, scale: i32) {
742        self.message.body.set_field(tag::LAST_PX, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
743    }
744
745    /// Gets `LastPx`, Tag 31.
746    pub fn get_last_px(&self) -> Result<Decimal, MessageRejectErrorEnum> {
747        let mut fld = field::LastPxField::new(Decimal::ZERO, 0);
748        self.message.body.get_field(tag::LAST_PX, &mut fld.0)?;
749        Ok(fld.value())
750    }
751
752
753    /// Returns true if `LastPx` is present, Tag 31.
754    pub fn has_last_px(&self) -> bool {
755        self.message.body.has(tag::LAST_PX)
756    }
757
758
759
760
761    /// Sets `LocaleOfIssue`, Tag 472.
762    pub fn set_locale_of_issue(&mut self, v: String) {
763        self.message.body.set_field(tag::LOCALE_OF_ISSUE, FIXString::from(v));
764    }
765
766    /// Gets `LocaleOfIssue`, Tag 472.
767    pub fn get_locale_of_issue(&self) -> Result<String, MessageRejectErrorEnum> {
768        let mut fld = field::LocaleOfIssueField::new(String::new());
769        self.message.body.get_field(tag::LOCALE_OF_ISSUE, &mut fld.0)?;
770        Ok(fld.value().to_string())
771    }
772
773
774    /// Returns true if `LocaleOfIssue` is present, Tag 472.
775    pub fn has_locale_of_issue(&self) -> bool {
776        self.message.body.has(tag::LOCALE_OF_ISSUE)
777    }
778
779
780
781
782    /// Sets `LowPx`, Tag 333.
783    pub fn set_low_px(&mut self, val: Decimal, scale: i32) {
784        self.message.body.set_field(tag::LOW_PX, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
785    }
786
787    /// Gets `LowPx`, Tag 333.
788    pub fn get_low_px(&self) -> Result<Decimal, MessageRejectErrorEnum> {
789        let mut fld = field::LowPxField::new(Decimal::ZERO, 0);
790        self.message.body.get_field(tag::LOW_PX, &mut fld.0)?;
791        Ok(fld.value())
792    }
793
794
795    /// Returns true if `LowPx` is present, Tag 333.
796    pub fn has_low_px(&self) -> bool {
797        self.message.body.has(tag::LOW_PX)
798    }
799
800
801
802
803    /// Sets `MaturityDate`, Tag 541.
804    pub fn set_maturity_date(&mut self, v: String) {
805        self.message.body.set_field(tag::MATURITY_DATE, FIXString::from(v));
806    }
807
808    /// Gets `MaturityDate`, Tag 541.
809    pub fn get_maturity_date(&self) -> Result<String, MessageRejectErrorEnum> {
810        let mut fld = field::MaturityDateField::new(String::new());
811        self.message.body.get_field(tag::MATURITY_DATE, &mut fld.0)?;
812        Ok(fld.value().to_string())
813    }
814
815
816    /// Returns true if `MaturityDate` is present, Tag 541.
817    pub fn has_maturity_date(&self) -> bool {
818        self.message.body.has(tag::MATURITY_DATE)
819    }
820
821
822
823
824    /// Sets `MaturityMonthYear`, Tag 200.
825    pub fn set_maturity_month_year(&mut self, v: String) {
826        self.message.body.set_field(tag::MATURITY_MONTH_YEAR, FIXString::from(v));
827    }
828
829    /// Gets `MaturityMonthYear`, Tag 200.
830    pub fn get_maturity_month_year(&self) -> Result<String, MessageRejectErrorEnum> {
831        let mut fld = field::MaturityMonthYearField::new(String::new());
832        self.message.body.get_field(tag::MATURITY_MONTH_YEAR, &mut fld.0)?;
833        Ok(fld.value().to_string())
834    }
835
836
837    /// Returns true if `MaturityMonthYear` is present, Tag 200.
838    pub fn has_maturity_month_year(&self) -> bool {
839        self.message.body.has(tag::MATURITY_MONTH_YEAR)
840    }
841
842
843
844
845    /// Sets `MaturityTime`, Tag 1079.
846    pub fn set_maturity_time(&mut self, v: String) {
847        self.message.body.set_field(tag::MATURITY_TIME, FIXString::from(v));
848    }
849
850    /// Gets `MaturityTime`, Tag 1079.
851    pub fn get_maturity_time(&self) -> Result<String, MessageRejectErrorEnum> {
852        let mut fld = field::MaturityTimeField::new(String::new());
853        self.message.body.get_field(tag::MATURITY_TIME, &mut fld.0)?;
854        Ok(fld.value().to_string())
855    }
856
857
858    /// Returns true if `MaturityTime` is present, Tag 1079.
859    pub fn has_maturity_time(&self) -> bool {
860        self.message.body.has(tag::MATURITY_TIME)
861    }
862
863
864
865
866    /// Sets `MinPriceIncrement`, Tag 969.
867    pub fn set_min_price_increment(&mut self, val: Decimal, scale: i32) {
868        self.message.body.set_field(tag::MIN_PRICE_INCREMENT, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
869    }
870
871    /// Gets `MinPriceIncrement`, Tag 969.
872    pub fn get_min_price_increment(&self) -> Result<Decimal, MessageRejectErrorEnum> {
873        let mut fld = field::MinPriceIncrementField::new(Decimal::ZERO, 0);
874        self.message.body.get_field(tag::MIN_PRICE_INCREMENT, &mut fld.0)?;
875        Ok(fld.value())
876    }
877
878
879    /// Returns true if `MinPriceIncrement` is present, Tag 969.
880    pub fn has_min_price_increment(&self) -> bool {
881        self.message.body.has(tag::MIN_PRICE_INCREMENT)
882    }
883
884
885
886
887    /// Sets `NTPositionLimit`, Tag 971.
888    pub fn set_nt_position_limit(&mut self, v: isize) {
889        self.message.body.set_field(tag::NT_POSITION_LIMIT, fixer::fix_int::FIXInt::from(v));
890    }
891
892    /// Gets `NTPositionLimit`, Tag 971.
893    pub fn get_nt_position_limit(&self) -> Result<isize, MessageRejectErrorEnum> {
894        let mut fld = field::NTPositionLimitField::new(0);
895        self.message.body.get_field(tag::NT_POSITION_LIMIT, &mut fld.0)?;
896        Ok(fld.value())
897    }
898
899
900    /// Returns true if `NTPositionLimit` is present, Tag 971.
901    pub fn has_nt_position_limit(&self) -> bool {
902        self.message.body.has(tag::NT_POSITION_LIMIT)
903    }
904
905
906
907
908    /// Sets `NoEvents`, Tag 864.
909    pub fn set_no_events(&mut self, v: isize) {
910        self.message.body.set_field(tag::NO_EVENTS, fixer::fix_int::FIXInt::from(v));
911    }
912
913    /// Gets `NoEvents`, Tag 864.
914    pub fn get_no_events(&self) -> Result<isize, MessageRejectErrorEnum> {
915        let mut fld = field::NoEventsField::new(0);
916        self.message.body.get_field(tag::NO_EVENTS, &mut fld.0)?;
917        Ok(fld.value())
918    }
919
920
921    /// Returns true if `NoEvents` is present, Tag 864.
922    pub fn has_no_events(&self) -> bool {
923        self.message.body.has(tag::NO_EVENTS)
924    }
925
926
927
928
929    /// Sets `NoInstrAttrib`, Tag 870.
930    pub fn set_no_instr_attrib(&mut self, v: isize) {
931        self.message.body.set_field(tag::NO_INSTR_ATTRIB, fixer::fix_int::FIXInt::from(v));
932    }
933
934    /// Gets `NoInstrAttrib`, Tag 870.
935    pub fn get_no_instr_attrib(&self) -> Result<isize, MessageRejectErrorEnum> {
936        let mut fld = field::NoInstrAttribField::new(0);
937        self.message.body.get_field(tag::NO_INSTR_ATTRIB, &mut fld.0)?;
938        Ok(fld.value())
939    }
940
941
942    /// Returns true if `NoInstrAttrib` is present, Tag 870.
943    pub fn has_no_instr_attrib(&self) -> bool {
944        self.message.body.has(tag::NO_INSTR_ATTRIB)
945    }
946
947
948
949
950    /// Sets `NoInstrumentParties`, Tag 1018.
951    pub fn set_no_instrument_parties(&mut self, v: isize) {
952        self.message.body.set_field(tag::NO_INSTRUMENT_PARTIES, fixer::fix_int::FIXInt::from(v));
953    }
954
955    /// Gets `NoInstrumentParties`, Tag 1018.
956    pub fn get_no_instrument_parties(&self) -> Result<isize, MessageRejectErrorEnum> {
957        let mut fld = field::NoInstrumentPartiesField::new(0);
958        self.message.body.get_field(tag::NO_INSTRUMENT_PARTIES, &mut fld.0)?;
959        Ok(fld.value())
960    }
961
962
963    /// Returns true if `NoInstrumentParties` is present, Tag 1018.
964    pub fn has_no_instrument_parties(&self) -> bool {
965        self.message.body.has(tag::NO_INSTRUMENT_PARTIES)
966    }
967
968
969
970
971    /// Sets `NoLegs`, Tag 555.
972    pub fn set_no_legs(&mut self, v: isize) {
973        self.message.body.set_field(tag::NO_LEGS, fixer::fix_int::FIXInt::from(v));
974    }
975
976    /// Gets `NoLegs`, Tag 555.
977    pub fn get_no_legs(&self) -> Result<isize, MessageRejectErrorEnum> {
978        let mut fld = field::NoLegsField::new(0);
979        self.message.body.get_field(tag::NO_LEGS, &mut fld.0)?;
980        Ok(fld.value())
981    }
982
983
984    /// Returns true if `NoLegs` is present, Tag 555.
985    pub fn has_no_legs(&self) -> bool {
986        self.message.body.has(tag::NO_LEGS)
987    }
988
989
990
991
992    /// Sets `NoSecurityAltID`, Tag 454.
993    pub fn set_no_security_alt_id(&mut self, v: isize) {
994        self.message.body.set_field(tag::NO_SECURITY_ALT_ID, fixer::fix_int::FIXInt::from(v));
995    }
996
997    /// Gets `NoSecurityAltID`, Tag 454.
998    pub fn get_no_security_alt_id(&self) -> Result<isize, MessageRejectErrorEnum> {
999        let mut fld = field::NoSecurityAltIDField::new(0);
1000        self.message.body.get_field(tag::NO_SECURITY_ALT_ID, &mut fld.0)?;
1001        Ok(fld.value())
1002    }
1003
1004
1005    /// Returns true if `NoSecurityAltID` is present, Tag 454.
1006    pub fn has_no_security_alt_id(&self) -> bool {
1007        self.message.body.has(tag::NO_SECURITY_ALT_ID)
1008    }
1009
1010
1011
1012
1013    /// Sets `NoUnderlyings`, Tag 711.
1014    pub fn set_no_underlyings(&mut self, v: isize) {
1015        self.message.body.set_field(tag::NO_UNDERLYINGS, fixer::fix_int::FIXInt::from(v));
1016    }
1017
1018    /// Gets `NoUnderlyings`, Tag 711.
1019    pub fn get_no_underlyings(&self) -> Result<isize, MessageRejectErrorEnum> {
1020        let mut fld = field::NoUnderlyingsField::new(0);
1021        self.message.body.get_field(tag::NO_UNDERLYINGS, &mut fld.0)?;
1022        Ok(fld.value())
1023    }
1024
1025
1026    /// Returns true if `NoUnderlyings` is present, Tag 711.
1027    pub fn has_no_underlyings(&self) -> bool {
1028        self.message.body.has(tag::NO_UNDERLYINGS)
1029    }
1030
1031
1032
1033
1034    /// Sets `OptAttribute`, Tag 206.
1035    pub fn set_opt_attribute(&mut self, v: String) {
1036        self.message.body.set_field(tag::OPT_ATTRIBUTE, FIXString::from(v));
1037    }
1038
1039    /// Gets `OptAttribute`, Tag 206.
1040    pub fn get_opt_attribute(&self) -> Result<String, MessageRejectErrorEnum> {
1041        let mut fld = field::OptAttributeField::new(String::new());
1042        self.message.body.get_field(tag::OPT_ATTRIBUTE, &mut fld.0)?;
1043        Ok(fld.value().to_string())
1044    }
1045
1046
1047    /// Returns true if `OptAttribute` is present, Tag 206.
1048    pub fn has_opt_attribute(&self) -> bool {
1049        self.message.body.has(tag::OPT_ATTRIBUTE)
1050    }
1051
1052
1053
1054
1055    /// Sets `PctAtRisk`, Tag 869.
1056    pub fn set_pct_at_risk(&mut self, val: Decimal, scale: i32) {
1057        self.message.body.set_field(tag::PCT_AT_RISK, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
1058    }
1059
1060    /// Gets `PctAtRisk`, Tag 869.
1061    pub fn get_pct_at_risk(&self) -> Result<Decimal, MessageRejectErrorEnum> {
1062        let mut fld = field::PctAtRiskField::new(Decimal::ZERO, 0);
1063        self.message.body.get_field(tag::PCT_AT_RISK, &mut fld.0)?;
1064        Ok(fld.value())
1065    }
1066
1067
1068    /// Returns true if `PctAtRisk` is present, Tag 869.
1069    pub fn has_pct_at_risk(&self) -> bool {
1070        self.message.body.has(tag::PCT_AT_RISK)
1071    }
1072
1073
1074
1075
1076    /// Sets `Pool`, Tag 691.
1077    pub fn set_pool(&mut self, v: String) {
1078        self.message.body.set_field(tag::POOL, FIXString::from(v));
1079    }
1080
1081    /// Gets `Pool`, Tag 691.
1082    pub fn get_pool(&self) -> Result<String, MessageRejectErrorEnum> {
1083        let mut fld = field::PoolField::new(String::new());
1084        self.message.body.get_field(tag::POOL, &mut fld.0)?;
1085        Ok(fld.value().to_string())
1086    }
1087
1088
1089    /// Returns true if `Pool` is present, Tag 691.
1090    pub fn has_pool(&self) -> bool {
1091        self.message.body.has(tag::POOL)
1092    }
1093
1094
1095
1096
1097    /// Sets `PositionLimit`, Tag 970.
1098    pub fn set_position_limit(&mut self, v: isize) {
1099        self.message.body.set_field(tag::POSITION_LIMIT, fixer::fix_int::FIXInt::from(v));
1100    }
1101
1102    /// Gets `PositionLimit`, Tag 970.
1103    pub fn get_position_limit(&self) -> Result<isize, MessageRejectErrorEnum> {
1104        let mut fld = field::PositionLimitField::new(0);
1105        self.message.body.get_field(tag::POSITION_LIMIT, &mut fld.0)?;
1106        Ok(fld.value())
1107    }
1108
1109
1110    /// Returns true if `PositionLimit` is present, Tag 970.
1111    pub fn has_position_limit(&self) -> bool {
1112        self.message.body.has(tag::POSITION_LIMIT)
1113    }
1114
1115
1116
1117
1118    /// Sets `Product`, Tag 460.
1119    pub fn set_product(&mut self, v: isize) {
1120        self.message.body.set_field(tag::PRODUCT, fixer::fix_int::FIXInt::from(v));
1121    }
1122
1123    /// Gets `Product`, Tag 460.
1124    pub fn get_product(&self) -> Result<isize, MessageRejectErrorEnum> {
1125        let mut fld = field::ProductField::new(0);
1126        self.message.body.get_field(tag::PRODUCT, &mut fld.0)?;
1127        Ok(fld.value())
1128    }
1129
1130
1131    /// Returns true if `Product` is present, Tag 460.
1132    pub fn has_product(&self) -> bool {
1133        self.message.body.has(tag::PRODUCT)
1134    }
1135
1136
1137
1138
1139    /// Sets `RedemptionDate`, Tag 240.
1140    pub fn set_redemption_date(&mut self, v: String) {
1141        self.message.body.set_field(tag::REDEMPTION_DATE, FIXString::from(v));
1142    }
1143
1144    /// Gets `RedemptionDate`, Tag 240.
1145    pub fn get_redemption_date(&self) -> Result<String, MessageRejectErrorEnum> {
1146        let mut fld = field::RedemptionDateField::new(String::new());
1147        self.message.body.get_field(tag::REDEMPTION_DATE, &mut fld.0)?;
1148        Ok(fld.value().to_string())
1149    }
1150
1151
1152    /// Returns true if `RedemptionDate` is present, Tag 240.
1153    pub fn has_redemption_date(&self) -> bool {
1154        self.message.body.has(tag::REDEMPTION_DATE)
1155    }
1156
1157
1158
1159
1160    /// Sets `RepoCollateralSecurityType`, Tag 239.
1161    pub fn set_repo_collateral_security_type(&mut self, v: isize) {
1162        self.message.body.set_field(tag::REPO_COLLATERAL_SECURITY_TYPE, fixer::fix_int::FIXInt::from(v));
1163    }
1164
1165    /// Gets `RepoCollateralSecurityType`, Tag 239.
1166    pub fn get_repo_collateral_security_type(&self) -> Result<isize, MessageRejectErrorEnum> {
1167        let mut fld = field::RepoCollateralSecurityTypeField::new(0);
1168        self.message.body.get_field(tag::REPO_COLLATERAL_SECURITY_TYPE, &mut fld.0)?;
1169        Ok(fld.value())
1170    }
1171
1172
1173    /// Returns true if `RepoCollateralSecurityType` is present, Tag 239.
1174    pub fn has_repo_collateral_security_type(&self) -> bool {
1175        self.message.body.has(tag::REPO_COLLATERAL_SECURITY_TYPE)
1176    }
1177
1178
1179
1180
1181    /// Sets `RepurchaseRate`, Tag 227.
1182    pub fn set_repurchase_rate(&mut self, val: Decimal, scale: i32) {
1183        self.message.body.set_field(tag::REPURCHASE_RATE, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
1184    }
1185
1186    /// Gets `RepurchaseRate`, Tag 227.
1187    pub fn get_repurchase_rate(&self) -> Result<Decimal, MessageRejectErrorEnum> {
1188        let mut fld = field::RepurchaseRateField::new(Decimal::ZERO, 0);
1189        self.message.body.get_field(tag::REPURCHASE_RATE, &mut fld.0)?;
1190        Ok(fld.value())
1191    }
1192
1193
1194    /// Returns true if `RepurchaseRate` is present, Tag 227.
1195    pub fn has_repurchase_rate(&self) -> bool {
1196        self.message.body.has(tag::REPURCHASE_RATE)
1197    }
1198
1199
1200
1201
1202    /// Sets `RepurchaseTerm`, Tag 226.
1203    pub fn set_repurchase_term(&mut self, v: isize) {
1204        self.message.body.set_field(tag::REPURCHASE_TERM, fixer::fix_int::FIXInt::from(v));
1205    }
1206
1207    /// Gets `RepurchaseTerm`, Tag 226.
1208    pub fn get_repurchase_term(&self) -> Result<isize, MessageRejectErrorEnum> {
1209        let mut fld = field::RepurchaseTermField::new(0);
1210        self.message.body.get_field(tag::REPURCHASE_TERM, &mut fld.0)?;
1211        Ok(fld.value())
1212    }
1213
1214
1215    /// Returns true if `RepurchaseTerm` is present, Tag 226.
1216    pub fn has_repurchase_term(&self) -> bool {
1217        self.message.body.has(tag::REPURCHASE_TERM)
1218    }
1219
1220
1221
1222
1223    /// Sets `SecurityDesc`, Tag 107.
1224    pub fn set_security_desc(&mut self, v: String) {
1225        self.message.body.set_field(tag::SECURITY_DESC, FIXString::from(v));
1226    }
1227
1228    /// Gets `SecurityDesc`, Tag 107.
1229    pub fn get_security_desc(&self) -> Result<String, MessageRejectErrorEnum> {
1230        let mut fld = field::SecurityDescField::new(String::new());
1231        self.message.body.get_field(tag::SECURITY_DESC, &mut fld.0)?;
1232        Ok(fld.value().to_string())
1233    }
1234
1235
1236    /// Returns true if `SecurityDesc` is present, Tag 107.
1237    pub fn has_security_desc(&self) -> bool {
1238        self.message.body.has(tag::SECURITY_DESC)
1239    }
1240
1241
1242
1243
1244    /// Sets `SecurityExchange`, Tag 207.
1245    pub fn set_security_exchange(&mut self, v: String) {
1246        self.message.body.set_field(tag::SECURITY_EXCHANGE, FIXString::from(v));
1247    }
1248
1249    /// Gets `SecurityExchange`, Tag 207.
1250    pub fn get_security_exchange(&self) -> Result<String, MessageRejectErrorEnum> {
1251        let mut fld = field::SecurityExchangeField::new(String::new());
1252        self.message.body.get_field(tag::SECURITY_EXCHANGE, &mut fld.0)?;
1253        Ok(fld.value().to_string())
1254    }
1255
1256
1257    /// Returns true if `SecurityExchange` is present, Tag 207.
1258    pub fn has_security_exchange(&self) -> bool {
1259        self.message.body.has(tag::SECURITY_EXCHANGE)
1260    }
1261
1262
1263
1264
1265    /// Sets `SecurityID`, Tag 48.
1266    pub fn set_security_id(&mut self, v: String) {
1267        self.message.body.set_field(tag::SECURITY_ID, FIXString::from(v));
1268    }
1269
1270    /// Gets `SecurityID`, Tag 48.
1271    pub fn get_security_id(&self) -> Result<String, MessageRejectErrorEnum> {
1272        let mut fld = field::SecurityIDField::new(String::new());
1273        self.message.body.get_field(tag::SECURITY_ID, &mut fld.0)?;
1274        Ok(fld.value().to_string())
1275    }
1276
1277
1278    /// Returns true if `SecurityID` is present, Tag 48.
1279    pub fn has_security_id(&self) -> bool {
1280        self.message.body.has(tag::SECURITY_ID)
1281    }
1282
1283
1284
1285
1286    /// Sets `SecurityIDSource`, Tag 22.
1287    pub fn set_security_id_source(&mut self, v: String) {
1288        self.message.body.set_field(tag::SECURITY_ID_SOURCE, FIXString::from(v));
1289    }
1290
1291    /// Gets `SecurityIDSource`, Tag 22.
1292    pub fn get_security_id_source(&self) -> Result<String, MessageRejectErrorEnum> {
1293        let mut fld = field::SecurityIDSourceField::new(String::new());
1294        self.message.body.get_field(tag::SECURITY_ID_SOURCE, &mut fld.0)?;
1295        Ok(fld.value().to_string())
1296    }
1297
1298
1299    /// Returns true if `SecurityIDSource` is present, Tag 22.
1300    pub fn has_security_id_source(&self) -> bool {
1301        self.message.body.has(tag::SECURITY_ID_SOURCE)
1302    }
1303
1304
1305
1306
1307    /// Sets `SecurityStatus`, Tag 965.
1308    pub fn set_security_status(&mut self, v: String) {
1309        self.message.body.set_field(tag::SECURITY_STATUS, FIXString::from(v));
1310    }
1311
1312    /// Gets `SecurityStatus`, Tag 965.
1313    pub fn get_security_status(&self) -> Result<String, MessageRejectErrorEnum> {
1314        let mut fld = field::SecurityStatusField::new(String::new());
1315        self.message.body.get_field(tag::SECURITY_STATUS, &mut fld.0)?;
1316        Ok(fld.value().to_string())
1317    }
1318
1319
1320    /// Returns true if `SecurityStatus` is present, Tag 965.
1321    pub fn has_security_status(&self) -> bool {
1322        self.message.body.has(tag::SECURITY_STATUS)
1323    }
1324
1325
1326
1327
1328    /// Sets `SecurityStatusReqID`, Tag 324.
1329    pub fn set_security_status_req_id(&mut self, v: String) {
1330        self.message.body.set_field(tag::SECURITY_STATUS_REQ_ID, FIXString::from(v));
1331    }
1332
1333    /// Gets `SecurityStatusReqID`, Tag 324.
1334    pub fn get_security_status_req_id(&self) -> Result<String, MessageRejectErrorEnum> {
1335        let mut fld = field::SecurityStatusReqIDField::new(String::new());
1336        self.message.body.get_field(tag::SECURITY_STATUS_REQ_ID, &mut fld.0)?;
1337        Ok(fld.value().to_string())
1338    }
1339
1340
1341    /// Returns true if `SecurityStatusReqID` is present, Tag 324.
1342    pub fn has_security_status_req_id(&self) -> bool {
1343        self.message.body.has(tag::SECURITY_STATUS_REQ_ID)
1344    }
1345
1346
1347
1348
1349    /// Sets `SecuritySubType`, Tag 762.
1350    pub fn set_security_sub_type(&mut self, v: String) {
1351        self.message.body.set_field(tag::SECURITY_SUB_TYPE, FIXString::from(v));
1352    }
1353
1354    /// Gets `SecuritySubType`, Tag 762.
1355    pub fn get_security_sub_type(&self) -> Result<String, MessageRejectErrorEnum> {
1356        let mut fld = field::SecuritySubTypeField::new(String::new());
1357        self.message.body.get_field(tag::SECURITY_SUB_TYPE, &mut fld.0)?;
1358        Ok(fld.value().to_string())
1359    }
1360
1361
1362    /// Returns true if `SecuritySubType` is present, Tag 762.
1363    pub fn has_security_sub_type(&self) -> bool {
1364        self.message.body.has(tag::SECURITY_SUB_TYPE)
1365    }
1366
1367
1368
1369
1370    /// Sets `SecurityTradingStatus`, Tag 326.
1371    pub fn set_security_trading_status(&mut self, v: isize) {
1372        self.message.body.set_field(tag::SECURITY_TRADING_STATUS, fixer::fix_int::FIXInt::from(v));
1373    }
1374
1375    /// Gets `SecurityTradingStatus`, Tag 326.
1376    pub fn get_security_trading_status(&self) -> Result<isize, MessageRejectErrorEnum> {
1377        let mut fld = field::SecurityTradingStatusField::new(0);
1378        self.message.body.get_field(tag::SECURITY_TRADING_STATUS, &mut fld.0)?;
1379        Ok(fld.value())
1380    }
1381
1382
1383    /// Returns true if `SecurityTradingStatus` is present, Tag 326.
1384    pub fn has_security_trading_status(&self) -> bool {
1385        self.message.body.has(tag::SECURITY_TRADING_STATUS)
1386    }
1387
1388
1389
1390
1391    /// Sets `SecurityType`, Tag 167.
1392    pub fn set_security_type(&mut self, v: String) {
1393        self.message.body.set_field(tag::SECURITY_TYPE, FIXString::from(v));
1394    }
1395
1396    /// Gets `SecurityType`, Tag 167.
1397    pub fn get_security_type(&self) -> Result<String, MessageRejectErrorEnum> {
1398        let mut fld = field::SecurityTypeField::new(String::new());
1399        self.message.body.get_field(tag::SECURITY_TYPE, &mut fld.0)?;
1400        Ok(fld.value().to_string())
1401    }
1402
1403
1404    /// Returns true if `SecurityType` is present, Tag 167.
1405    pub fn has_security_type(&self) -> bool {
1406        self.message.body.has(tag::SECURITY_TYPE)
1407    }
1408
1409
1410
1411
1412    /// Sets `SellVolume`, Tag 331.
1413    pub fn set_sell_volume(&mut self, val: Decimal, scale: i32) {
1414        self.message.body.set_field(tag::SELL_VOLUME, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
1415    }
1416
1417    /// Gets `SellVolume`, Tag 331.
1418    pub fn get_sell_volume(&self) -> Result<Decimal, MessageRejectErrorEnum> {
1419        let mut fld = field::SellVolumeField::new(Decimal::ZERO, 0);
1420        self.message.body.get_field(tag::SELL_VOLUME, &mut fld.0)?;
1421        Ok(fld.value())
1422    }
1423
1424
1425    /// Returns true if `SellVolume` is present, Tag 331.
1426    pub fn has_sell_volume(&self) -> bool {
1427        self.message.body.has(tag::SELL_VOLUME)
1428    }
1429
1430
1431
1432
1433    /// Sets `SettleOnOpenFlag`, Tag 966.
1434    pub fn set_settle_on_open_flag(&mut self, v: String) {
1435        self.message.body.set_field(tag::SETTLE_ON_OPEN_FLAG, FIXString::from(v));
1436    }
1437
1438    /// Gets `SettleOnOpenFlag`, Tag 966.
1439    pub fn get_settle_on_open_flag(&self) -> Result<String, MessageRejectErrorEnum> {
1440        let mut fld = field::SettleOnOpenFlagField::new(String::new());
1441        self.message.body.get_field(tag::SETTLE_ON_OPEN_FLAG, &mut fld.0)?;
1442        Ok(fld.value().to_string())
1443    }
1444
1445
1446    /// Returns true if `SettleOnOpenFlag` is present, Tag 966.
1447    pub fn has_settle_on_open_flag(&self) -> bool {
1448        self.message.body.has(tag::SETTLE_ON_OPEN_FLAG)
1449    }
1450
1451
1452
1453
1454    /// Sets `StateOrProvinceOfIssue`, Tag 471.
1455    pub fn set_state_or_province_of_issue(&mut self, v: String) {
1456        self.message.body.set_field(tag::STATE_OR_PROVINCE_OF_ISSUE, FIXString::from(v));
1457    }
1458
1459    /// Gets `StateOrProvinceOfIssue`, Tag 471.
1460    pub fn get_state_or_province_of_issue(&self) -> Result<String, MessageRejectErrorEnum> {
1461        let mut fld = field::StateOrProvinceOfIssueField::new(String::new());
1462        self.message.body.get_field(tag::STATE_OR_PROVINCE_OF_ISSUE, &mut fld.0)?;
1463        Ok(fld.value().to_string())
1464    }
1465
1466
1467    /// Returns true if `StateOrProvinceOfIssue` is present, Tag 471.
1468    pub fn has_state_or_province_of_issue(&self) -> bool {
1469        self.message.body.has(tag::STATE_OR_PROVINCE_OF_ISSUE)
1470    }
1471
1472
1473
1474
1475    /// Sets `StrikeCurrency`, Tag 947.
1476    pub fn set_strike_currency(&mut self, v: String) {
1477        self.message.body.set_field(tag::STRIKE_CURRENCY, FIXString::from(v));
1478    }
1479
1480    /// Gets `StrikeCurrency`, Tag 947.
1481    pub fn get_strike_currency(&self) -> Result<String, MessageRejectErrorEnum> {
1482        let mut fld = field::StrikeCurrencyField::new(String::new());
1483        self.message.body.get_field(tag::STRIKE_CURRENCY, &mut fld.0)?;
1484        Ok(fld.value().to_string())
1485    }
1486
1487
1488    /// Returns true if `StrikeCurrency` is present, Tag 947.
1489    pub fn has_strike_currency(&self) -> bool {
1490        self.message.body.has(tag::STRIKE_CURRENCY)
1491    }
1492
1493
1494
1495
1496    /// Sets `StrikeMultiplier`, Tag 967.
1497    pub fn set_strike_multiplier(&mut self, val: Decimal, scale: i32) {
1498        self.message.body.set_field(tag::STRIKE_MULTIPLIER, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
1499    }
1500
1501    /// Gets `StrikeMultiplier`, Tag 967.
1502    pub fn get_strike_multiplier(&self) -> Result<Decimal, MessageRejectErrorEnum> {
1503        let mut fld = field::StrikeMultiplierField::new(Decimal::ZERO, 0);
1504        self.message.body.get_field(tag::STRIKE_MULTIPLIER, &mut fld.0)?;
1505        Ok(fld.value())
1506    }
1507
1508
1509    /// Returns true if `StrikeMultiplier` is present, Tag 967.
1510    pub fn has_strike_multiplier(&self) -> bool {
1511        self.message.body.has(tag::STRIKE_MULTIPLIER)
1512    }
1513
1514
1515
1516
1517    /// Sets `StrikePrice`, Tag 202.
1518    pub fn set_strike_price(&mut self, val: Decimal, scale: i32) {
1519        self.message.body.set_field(tag::STRIKE_PRICE, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
1520    }
1521
1522    /// Gets `StrikePrice`, Tag 202.
1523    pub fn get_strike_price(&self) -> Result<Decimal, MessageRejectErrorEnum> {
1524        let mut fld = field::StrikePriceField::new(Decimal::ZERO, 0);
1525        self.message.body.get_field(tag::STRIKE_PRICE, &mut fld.0)?;
1526        Ok(fld.value())
1527    }
1528
1529
1530    /// Returns true if `StrikePrice` is present, Tag 202.
1531    pub fn has_strike_price(&self) -> bool {
1532        self.message.body.has(tag::STRIKE_PRICE)
1533    }
1534
1535
1536
1537
1538    /// Sets `StrikeValue`, Tag 968.
1539    pub fn set_strike_value(&mut self, val: Decimal, scale: i32) {
1540        self.message.body.set_field(tag::STRIKE_VALUE, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
1541    }
1542
1543    /// Gets `StrikeValue`, Tag 968.
1544    pub fn get_strike_value(&self) -> Result<Decimal, MessageRejectErrorEnum> {
1545        let mut fld = field::StrikeValueField::new(Decimal::ZERO, 0);
1546        self.message.body.get_field(tag::STRIKE_VALUE, &mut fld.0)?;
1547        Ok(fld.value())
1548    }
1549
1550
1551    /// Returns true if `StrikeValue` is present, Tag 968.
1552    pub fn has_strike_value(&self) -> bool {
1553        self.message.body.has(tag::STRIKE_VALUE)
1554    }
1555
1556
1557
1558
1559    /// Sets `Symbol`, Tag 55.
1560    pub fn set_symbol(&mut self, v: String) {
1561        self.message.body.set_field(tag::SYMBOL, FIXString::from(v));
1562    }
1563
1564    /// Gets `Symbol`, Tag 55.
1565    pub fn get_symbol(&self) -> Result<String, MessageRejectErrorEnum> {
1566        let mut fld = field::SymbolField::new(String::new());
1567        self.message.body.get_field(tag::SYMBOL, &mut fld.0)?;
1568        Ok(fld.value().to_string())
1569    }
1570
1571
1572    /// Returns true if `Symbol` is present, Tag 55.
1573    pub fn has_symbol(&self) -> bool {
1574        self.message.body.has(tag::SYMBOL)
1575    }
1576
1577
1578
1579
1580    /// Sets `SymbolSfx`, Tag 65.
1581    pub fn set_symbol_sfx(&mut self, v: String) {
1582        self.message.body.set_field(tag::SYMBOL_SFX, FIXString::from(v));
1583    }
1584
1585    /// Gets `SymbolSfx`, Tag 65.
1586    pub fn get_symbol_sfx(&self) -> Result<String, MessageRejectErrorEnum> {
1587        let mut fld = field::SymbolSfxField::new(String::new());
1588        self.message.body.get_field(tag::SYMBOL_SFX, &mut fld.0)?;
1589        Ok(fld.value().to_string())
1590    }
1591
1592
1593    /// Returns true if `SymbolSfx` is present, Tag 65.
1594    pub fn has_symbol_sfx(&self) -> bool {
1595        self.message.body.has(tag::SYMBOL_SFX)
1596    }
1597
1598
1599
1600
1601    /// Sets `Text`, Tag 58.
1602    pub fn set_text(&mut self, v: String) {
1603        self.message.body.set_field(tag::TEXT, FIXString::from(v));
1604    }
1605
1606    /// Gets `Text`, Tag 58.
1607    pub fn get_text(&self) -> Result<String, MessageRejectErrorEnum> {
1608        let mut fld = field::TextField::new(String::new());
1609        self.message.body.get_field(tag::TEXT, &mut fld.0)?;
1610        Ok(fld.value().to_string())
1611    }
1612
1613
1614    /// Returns true if `Text` is present, Tag 58.
1615    pub fn has_text(&self) -> bool {
1616        self.message.body.has(tag::TEXT)
1617    }
1618
1619
1620
1621
1622    /// Sets `TimeUnit`, Tag 997.
1623    pub fn set_time_unit(&mut self, v: String) {
1624        self.message.body.set_field(tag::TIME_UNIT, FIXString::from(v));
1625    }
1626
1627    /// Gets `TimeUnit`, Tag 997.
1628    pub fn get_time_unit(&self) -> Result<String, MessageRejectErrorEnum> {
1629        let mut fld = field::TimeUnitField::new(String::new());
1630        self.message.body.get_field(tag::TIME_UNIT, &mut fld.0)?;
1631        Ok(fld.value().to_string())
1632    }
1633
1634
1635    /// Returns true if `TimeUnit` is present, Tag 997.
1636    pub fn has_time_unit(&self) -> bool {
1637        self.message.body.has(tag::TIME_UNIT)
1638    }
1639
1640
1641
1642
1643    /// Sets `TradingSessionID`, Tag 336.
1644    pub fn set_trading_session_id(&mut self, v: String) {
1645        self.message.body.set_field(tag::TRADING_SESSION_ID, FIXString::from(v));
1646    }
1647
1648    /// Gets `TradingSessionID`, Tag 336.
1649    pub fn get_trading_session_id(&self) -> Result<String, MessageRejectErrorEnum> {
1650        let mut fld = field::TradingSessionIDField::new(String::new());
1651        self.message.body.get_field(tag::TRADING_SESSION_ID, &mut fld.0)?;
1652        Ok(fld.value().to_string())
1653    }
1654
1655
1656    /// Returns true if `TradingSessionID` is present, Tag 336.
1657    pub fn has_trading_session_id(&self) -> bool {
1658        self.message.body.has(tag::TRADING_SESSION_ID)
1659    }
1660
1661
1662
1663
1664    /// Sets `TradingSessionSubID`, Tag 625.
1665    pub fn set_trading_session_sub_id(&mut self, v: String) {
1666        self.message.body.set_field(tag::TRADING_SESSION_SUB_ID, FIXString::from(v));
1667    }
1668
1669    /// Gets `TradingSessionSubID`, Tag 625.
1670    pub fn get_trading_session_sub_id(&self) -> Result<String, MessageRejectErrorEnum> {
1671        let mut fld = field::TradingSessionSubIDField::new(String::new());
1672        self.message.body.get_field(tag::TRADING_SESSION_SUB_ID, &mut fld.0)?;
1673        Ok(fld.value().to_string())
1674    }
1675
1676
1677    /// Returns true if `TradingSessionSubID` is present, Tag 625.
1678    pub fn has_trading_session_sub_id(&self) -> bool {
1679        self.message.body.has(tag::TRADING_SESSION_SUB_ID)
1680    }
1681
1682
1683
1684
1685    /// Sets `TransactTime`, Tag 60.
1686    pub fn set_transact_time(&mut self, v: Timestamp) {
1687        self.message.body.set_field(tag::TRANSACT_TIME, fixer::fix_utc_timestamp::FIXUTCTimestamp {
1688            time: v,
1689            precision: fixer::fix_utc_timestamp::TimestampPrecision::Millis,
1690        });
1691    }
1692
1693    /// Gets `TransactTime`, Tag 60.
1694    pub fn get_transact_time(&self) -> Result<Timestamp, MessageRejectErrorEnum> {
1695        let mut fld = field::TransactTimeField::new(Timestamp::UNIX_EPOCH);
1696        self.message.body.get_field(tag::TRANSACT_TIME, &mut fld.0)?;
1697        Ok(fld.value())
1698    }
1699
1700
1701    /// Returns true if `TransactTime` is present, Tag 60.
1702    pub fn has_transact_time(&self) -> bool {
1703        self.message.body.has(tag::TRANSACT_TIME)
1704    }
1705
1706
1707
1708
1709    /// Sets `UnitOfMeasure`, Tag 996.
1710    pub fn set_unit_of_measure(&mut self, v: String) {
1711        self.message.body.set_field(tag::UNIT_OF_MEASURE, FIXString::from(v));
1712    }
1713
1714    /// Gets `UnitOfMeasure`, Tag 996.
1715    pub fn get_unit_of_measure(&self) -> Result<String, MessageRejectErrorEnum> {
1716        let mut fld = field::UnitOfMeasureField::new(String::new());
1717        self.message.body.get_field(tag::UNIT_OF_MEASURE, &mut fld.0)?;
1718        Ok(fld.value().to_string())
1719    }
1720
1721
1722    /// Returns true if `UnitOfMeasure` is present, Tag 996.
1723    pub fn has_unit_of_measure(&self) -> bool {
1724        self.message.body.has(tag::UNIT_OF_MEASURE)
1725    }
1726
1727
1728
1729
1730    /// Sets `UnsolicitedIndicator`, Tag 325.
1731    pub fn set_unsolicited_indicator(&mut self, v: bool) {
1732        self.message.body.set_field(tag::UNSOLICITED_INDICATOR, fixer::fix_boolean::FIXBoolean::from(v));
1733    }
1734
1735    /// Gets `UnsolicitedIndicator`, Tag 325.
1736    pub fn get_unsolicited_indicator(&self) -> Result<bool, MessageRejectErrorEnum> {
1737        let mut fld = field::UnsolicitedIndicatorField::new(false);
1738        self.message.body.get_field(tag::UNSOLICITED_INDICATOR, &mut fld.0)?;
1739        Ok(fld.value())
1740    }
1741
1742
1743    /// Returns true if `UnsolicitedIndicator` is present, Tag 325.
1744    pub fn has_unsolicited_indicator(&self) -> bool {
1745        self.message.body.has(tag::UNSOLICITED_INDICATOR)
1746    }
1747
1748
1749}
1750
1751/// `RouteOut` is the callback type for routing `SecurityStatus` messages.
1752pub type RouteOut = fn(msg: SecurityStatus, session_id: SessionID) -> Result<(), MessageRejectErrorEnum>;
1753
1754/// Route type returned by the `route` function.
1755pub type Route = (&'static str, &'static str, Box<dyn Fn(&Message, SessionID) -> Result<(), MessageRejectErrorEnum> + Send>);
1756
1757/// Returns the begin string, message type, and route function for `SecurityStatus`.
1758pub fn route(router: RouteOut) -> Route {
1759    let r = move |msg: &Message, session_id: SessionID| -> Result<(), MessageRejectErrorEnum> {
1760        router(SecurityStatus::from_message(msg.clone()), session_id)
1761    };
1762    ("7", "f", Box::new(r))
1763}