Skip to main content

fixer_fix/fix44/
allocation_report.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/// `AllocationReport` is the `fix44` `AllocationReport` type, `MsgType` = AS.
21pub struct AllocationReport {
22    pub message: Message,
23}
24
25impl AllocationReport {
26    /// Creates a new `AllocationReport` with required fields.
27    pub fn new(alloc_report_id: field::AllocReportIDField, alloc_trans_type: field::AllocTransTypeField, alloc_report_type: field::AllocReportTypeField, alloc_status: field::AllocStatusField, alloc_no_orders_type: field::AllocNoOrdersTypeField, side: field::SideField, quantity: field::QuantityField, avg_px: field::AvgPxField, trade_date: field::TradeDateField) -> Self {
28        let mut msg = Message::new();
29        msg.header.set_field(tag::MSG_TYPE, FIXString::from("AS".to_string()));
30
31        msg.body.set_field(tag::ALLOC_REPORT_ID, alloc_report_id.0);
32
33        msg.body.set_field(tag::ALLOC_TRANS_TYPE, alloc_trans_type.0);
34
35        msg.body.set_field(tag::ALLOC_REPORT_TYPE, alloc_report_type.0);
36
37        msg.body.set_field(tag::ALLOC_STATUS, alloc_status.0);
38
39        msg.body.set_field(tag::ALLOC_NO_ORDERS_TYPE, alloc_no_orders_type.0);
40
41        msg.body.set_field(tag::SIDE, side.0);
42
43        msg.body.set_field(tag::QUANTITY, quantity.0);
44
45        msg.body.set_field(tag::AVG_PX, avg_px.0);
46
47        msg.body.set_field(tag::TRADE_DATE, trade_date.0);
48
49        Self { message: msg }
50    }
51
52    /// Creates a `AllocationReport` from an existing `Message`.
53    pub fn from_message(msg: Message) -> Self {
54        Self { message: msg }
55    }
56
57    /// Returns the underlying `Message`.
58    pub fn to_message(self) -> Message {
59        self.message
60    }
61
62
63
64
65    /// Sets `AccruedInterestAmt`, Tag 159.
66    pub fn set_accrued_interest_amt(&mut self, val: Decimal, scale: i32) {
67        self.message.body.set_field(tag::ACCRUED_INTEREST_AMT, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
68    }
69
70    /// Gets `AccruedInterestAmt`, Tag 159.
71    pub fn get_accrued_interest_amt(&self) -> Result<Decimal, MessageRejectErrorEnum> {
72        let mut fld = field::AccruedInterestAmtField::new(Decimal::ZERO, 0);
73        self.message.body.get_field(tag::ACCRUED_INTEREST_AMT, &mut fld.0)?;
74        Ok(fld.value())
75    }
76
77
78    /// Returns true if `AccruedInterestAmt` is present, Tag 159.
79    pub fn has_accrued_interest_amt(&self) -> bool {
80        self.message.body.has(tag::ACCRUED_INTEREST_AMT)
81    }
82
83
84
85
86    /// Sets `AccruedInterestRate`, Tag 158.
87    pub fn set_accrued_interest_rate(&mut self, val: Decimal, scale: i32) {
88        self.message.body.set_field(tag::ACCRUED_INTEREST_RATE, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
89    }
90
91    /// Gets `AccruedInterestRate`, Tag 158.
92    pub fn get_accrued_interest_rate(&self) -> Result<Decimal, MessageRejectErrorEnum> {
93        let mut fld = field::AccruedInterestRateField::new(Decimal::ZERO, 0);
94        self.message.body.get_field(tag::ACCRUED_INTEREST_RATE, &mut fld.0)?;
95        Ok(fld.value())
96    }
97
98
99    /// Returns true if `AccruedInterestRate` is present, Tag 158.
100    pub fn has_accrued_interest_rate(&self) -> bool {
101        self.message.body.has(tag::ACCRUED_INTEREST_RATE)
102    }
103
104
105
106
107    /// Sets `AgreementCurrency`, Tag 918.
108    pub fn set_agreement_currency(&mut self, v: String) {
109        self.message.body.set_field(tag::AGREEMENT_CURRENCY, FIXString::from(v));
110    }
111
112    /// Gets `AgreementCurrency`, Tag 918.
113    pub fn get_agreement_currency(&self) -> Result<String, MessageRejectErrorEnum> {
114        let mut fld = field::AgreementCurrencyField::new(String::new());
115        self.message.body.get_field(tag::AGREEMENT_CURRENCY, &mut fld.0)?;
116        Ok(fld.value().to_string())
117    }
118
119
120    /// Returns true if `AgreementCurrency` is present, Tag 918.
121    pub fn has_agreement_currency(&self) -> bool {
122        self.message.body.has(tag::AGREEMENT_CURRENCY)
123    }
124
125
126
127
128    /// Sets `AgreementDate`, Tag 915.
129    pub fn set_agreement_date(&mut self, v: String) {
130        self.message.body.set_field(tag::AGREEMENT_DATE, FIXString::from(v));
131    }
132
133    /// Gets `AgreementDate`, Tag 915.
134    pub fn get_agreement_date(&self) -> Result<String, MessageRejectErrorEnum> {
135        let mut fld = field::AgreementDateField::new(String::new());
136        self.message.body.get_field(tag::AGREEMENT_DATE, &mut fld.0)?;
137        Ok(fld.value().to_string())
138    }
139
140
141    /// Returns true if `AgreementDate` is present, Tag 915.
142    pub fn has_agreement_date(&self) -> bool {
143        self.message.body.has(tag::AGREEMENT_DATE)
144    }
145
146
147
148
149    /// Sets `AgreementDesc`, Tag 913.
150    pub fn set_agreement_desc(&mut self, v: String) {
151        self.message.body.set_field(tag::AGREEMENT_DESC, FIXString::from(v));
152    }
153
154    /// Gets `AgreementDesc`, Tag 913.
155    pub fn get_agreement_desc(&self) -> Result<String, MessageRejectErrorEnum> {
156        let mut fld = field::AgreementDescField::new(String::new());
157        self.message.body.get_field(tag::AGREEMENT_DESC, &mut fld.0)?;
158        Ok(fld.value().to_string())
159    }
160
161
162    /// Returns true if `AgreementDesc` is present, Tag 913.
163    pub fn has_agreement_desc(&self) -> bool {
164        self.message.body.has(tag::AGREEMENT_DESC)
165    }
166
167
168
169
170    /// Sets `AgreementID`, Tag 914.
171    pub fn set_agreement_id(&mut self, v: String) {
172        self.message.body.set_field(tag::AGREEMENT_ID, FIXString::from(v));
173    }
174
175    /// Gets `AgreementID`, Tag 914.
176    pub fn get_agreement_id(&self) -> Result<String, MessageRejectErrorEnum> {
177        let mut fld = field::AgreementIDField::new(String::new());
178        self.message.body.get_field(tag::AGREEMENT_ID, &mut fld.0)?;
179        Ok(fld.value().to_string())
180    }
181
182
183    /// Returns true if `AgreementID` is present, Tag 914.
184    pub fn has_agreement_id(&self) -> bool {
185        self.message.body.has(tag::AGREEMENT_ID)
186    }
187
188
189
190
191    /// Sets `AllocCancReplaceReason`, Tag 796.
192    pub fn set_alloc_canc_replace_reason(&mut self, v: isize) {
193        self.message.body.set_field(tag::ALLOC_CANC_REPLACE_REASON, fixer::fix_int::FIXInt::from(v));
194    }
195
196    /// Gets `AllocCancReplaceReason`, Tag 796.
197    pub fn get_alloc_canc_replace_reason(&self) -> Result<isize, MessageRejectErrorEnum> {
198        let mut fld = field::AllocCancReplaceReasonField::new(0);
199        self.message.body.get_field(tag::ALLOC_CANC_REPLACE_REASON, &mut fld.0)?;
200        Ok(fld.value())
201    }
202
203
204    /// Returns true if `AllocCancReplaceReason` is present, Tag 796.
205    pub fn has_alloc_canc_replace_reason(&self) -> bool {
206        self.message.body.has(tag::ALLOC_CANC_REPLACE_REASON)
207    }
208
209
210
211
212    /// Sets `AllocID`, Tag 70.
213    pub fn set_alloc_id(&mut self, v: String) {
214        self.message.body.set_field(tag::ALLOC_ID, FIXString::from(v));
215    }
216
217    /// Gets `AllocID`, Tag 70.
218    pub fn get_alloc_id(&self) -> Result<String, MessageRejectErrorEnum> {
219        let mut fld = field::AllocIDField::new(String::new());
220        self.message.body.get_field(tag::ALLOC_ID, &mut fld.0)?;
221        Ok(fld.value().to_string())
222    }
223
224
225    /// Returns true if `AllocID` is present, Tag 70.
226    pub fn has_alloc_id(&self) -> bool {
227        self.message.body.has(tag::ALLOC_ID)
228    }
229
230
231
232
233    /// Sets `AllocIntermedReqType`, Tag 808.
234    pub fn set_alloc_intermed_req_type(&mut self, v: isize) {
235        self.message.body.set_field(tag::ALLOC_INTERMED_REQ_TYPE, fixer::fix_int::FIXInt::from(v));
236    }
237
238    /// Gets `AllocIntermedReqType`, Tag 808.
239    pub fn get_alloc_intermed_req_type(&self) -> Result<isize, MessageRejectErrorEnum> {
240        let mut fld = field::AllocIntermedReqTypeField::new(0);
241        self.message.body.get_field(tag::ALLOC_INTERMED_REQ_TYPE, &mut fld.0)?;
242        Ok(fld.value())
243    }
244
245
246    /// Returns true if `AllocIntermedReqType` is present, Tag 808.
247    pub fn has_alloc_intermed_req_type(&self) -> bool {
248        self.message.body.has(tag::ALLOC_INTERMED_REQ_TYPE)
249    }
250
251
252
253
254    /// Sets `AllocLinkID`, Tag 196.
255    pub fn set_alloc_link_id(&mut self, v: String) {
256        self.message.body.set_field(tag::ALLOC_LINK_ID, FIXString::from(v));
257    }
258
259    /// Gets `AllocLinkID`, Tag 196.
260    pub fn get_alloc_link_id(&self) -> Result<String, MessageRejectErrorEnum> {
261        let mut fld = field::AllocLinkIDField::new(String::new());
262        self.message.body.get_field(tag::ALLOC_LINK_ID, &mut fld.0)?;
263        Ok(fld.value().to_string())
264    }
265
266
267    /// Returns true if `AllocLinkID` is present, Tag 196.
268    pub fn has_alloc_link_id(&self) -> bool {
269        self.message.body.has(tag::ALLOC_LINK_ID)
270    }
271
272
273
274
275    /// Sets `AllocLinkType`, Tag 197.
276    pub fn set_alloc_link_type(&mut self, v: isize) {
277        self.message.body.set_field(tag::ALLOC_LINK_TYPE, fixer::fix_int::FIXInt::from(v));
278    }
279
280    /// Gets `AllocLinkType`, Tag 197.
281    pub fn get_alloc_link_type(&self) -> Result<isize, MessageRejectErrorEnum> {
282        let mut fld = field::AllocLinkTypeField::new(0);
283        self.message.body.get_field(tag::ALLOC_LINK_TYPE, &mut fld.0)?;
284        Ok(fld.value())
285    }
286
287
288    /// Returns true if `AllocLinkType` is present, Tag 197.
289    pub fn has_alloc_link_type(&self) -> bool {
290        self.message.body.has(tag::ALLOC_LINK_TYPE)
291    }
292
293
294
295
296    /// Sets `AllocNoOrdersType`, Tag 857.
297    pub fn set_alloc_no_orders_type(&mut self, v: isize) {
298        self.message.body.set_field(tag::ALLOC_NO_ORDERS_TYPE, fixer::fix_int::FIXInt::from(v));
299    }
300
301    /// Gets `AllocNoOrdersType`, Tag 857.
302    pub fn get_alloc_no_orders_type(&self) -> Result<isize, MessageRejectErrorEnum> {
303        let mut fld = field::AllocNoOrdersTypeField::new(0);
304        self.message.body.get_field(tag::ALLOC_NO_ORDERS_TYPE, &mut fld.0)?;
305        Ok(fld.value())
306    }
307
308
309    /// Returns true if `AllocNoOrdersType` is present, Tag 857.
310    pub fn has_alloc_no_orders_type(&self) -> bool {
311        self.message.body.has(tag::ALLOC_NO_ORDERS_TYPE)
312    }
313
314
315
316
317    /// Sets `AllocRejCode`, Tag 88.
318    pub fn set_alloc_rej_code(&mut self, v: isize) {
319        self.message.body.set_field(tag::ALLOC_REJ_CODE, fixer::fix_int::FIXInt::from(v));
320    }
321
322    /// Gets `AllocRejCode`, Tag 88.
323    pub fn get_alloc_rej_code(&self) -> Result<isize, MessageRejectErrorEnum> {
324        let mut fld = field::AllocRejCodeField::new(0);
325        self.message.body.get_field(tag::ALLOC_REJ_CODE, &mut fld.0)?;
326        Ok(fld.value())
327    }
328
329
330    /// Returns true if `AllocRejCode` is present, Tag 88.
331    pub fn has_alloc_rej_code(&self) -> bool {
332        self.message.body.has(tag::ALLOC_REJ_CODE)
333    }
334
335
336
337
338    /// Sets `AllocReportID`, Tag 755.
339    pub fn set_alloc_report_id(&mut self, v: String) {
340        self.message.body.set_field(tag::ALLOC_REPORT_ID, FIXString::from(v));
341    }
342
343    /// Gets `AllocReportID`, Tag 755.
344    pub fn get_alloc_report_id(&self) -> Result<String, MessageRejectErrorEnum> {
345        let mut fld = field::AllocReportIDField::new(String::new());
346        self.message.body.get_field(tag::ALLOC_REPORT_ID, &mut fld.0)?;
347        Ok(fld.value().to_string())
348    }
349
350
351    /// Returns true if `AllocReportID` is present, Tag 755.
352    pub fn has_alloc_report_id(&self) -> bool {
353        self.message.body.has(tag::ALLOC_REPORT_ID)
354    }
355
356
357
358
359    /// Sets `AllocReportRefID`, Tag 795.
360    pub fn set_alloc_report_ref_id(&mut self, v: String) {
361        self.message.body.set_field(tag::ALLOC_REPORT_REF_ID, FIXString::from(v));
362    }
363
364    /// Gets `AllocReportRefID`, Tag 795.
365    pub fn get_alloc_report_ref_id(&self) -> Result<String, MessageRejectErrorEnum> {
366        let mut fld = field::AllocReportRefIDField::new(String::new());
367        self.message.body.get_field(tag::ALLOC_REPORT_REF_ID, &mut fld.0)?;
368        Ok(fld.value().to_string())
369    }
370
371
372    /// Returns true if `AllocReportRefID` is present, Tag 795.
373    pub fn has_alloc_report_ref_id(&self) -> bool {
374        self.message.body.has(tag::ALLOC_REPORT_REF_ID)
375    }
376
377
378
379
380    /// Sets `AllocReportType`, Tag 794.
381    pub fn set_alloc_report_type(&mut self, v: isize) {
382        self.message.body.set_field(tag::ALLOC_REPORT_TYPE, fixer::fix_int::FIXInt::from(v));
383    }
384
385    /// Gets `AllocReportType`, Tag 794.
386    pub fn get_alloc_report_type(&self) -> Result<isize, MessageRejectErrorEnum> {
387        let mut fld = field::AllocReportTypeField::new(0);
388        self.message.body.get_field(tag::ALLOC_REPORT_TYPE, &mut fld.0)?;
389        Ok(fld.value())
390    }
391
392
393    /// Returns true if `AllocReportType` is present, Tag 794.
394    pub fn has_alloc_report_type(&self) -> bool {
395        self.message.body.has(tag::ALLOC_REPORT_TYPE)
396    }
397
398
399
400
401    /// Sets `AllocStatus`, Tag 87.
402    pub fn set_alloc_status(&mut self, v: isize) {
403        self.message.body.set_field(tag::ALLOC_STATUS, fixer::fix_int::FIXInt::from(v));
404    }
405
406    /// Gets `AllocStatus`, Tag 87.
407    pub fn get_alloc_status(&self) -> Result<isize, MessageRejectErrorEnum> {
408        let mut fld = field::AllocStatusField::new(0);
409        self.message.body.get_field(tag::ALLOC_STATUS, &mut fld.0)?;
410        Ok(fld.value())
411    }
412
413
414    /// Returns true if `AllocStatus` is present, Tag 87.
415    pub fn has_alloc_status(&self) -> bool {
416        self.message.body.has(tag::ALLOC_STATUS)
417    }
418
419
420
421
422    /// Sets `AllocTransType`, Tag 71.
423    pub fn set_alloc_trans_type(&mut self, v: String) {
424        self.message.body.set_field(tag::ALLOC_TRANS_TYPE, FIXString::from(v));
425    }
426
427    /// Gets `AllocTransType`, Tag 71.
428    pub fn get_alloc_trans_type(&self) -> Result<String, MessageRejectErrorEnum> {
429        let mut fld = field::AllocTransTypeField::new(String::new());
430        self.message.body.get_field(tag::ALLOC_TRANS_TYPE, &mut fld.0)?;
431        Ok(fld.value().to_string())
432    }
433
434
435    /// Returns true if `AllocTransType` is present, Tag 71.
436    pub fn has_alloc_trans_type(&self) -> bool {
437        self.message.body.has(tag::ALLOC_TRANS_TYPE)
438    }
439
440
441
442
443    /// Sets `AutoAcceptIndicator`, Tag 754.
444    pub fn set_auto_accept_indicator(&mut self, v: bool) {
445        self.message.body.set_field(tag::AUTO_ACCEPT_INDICATOR, fixer::fix_boolean::FIXBoolean::from(v));
446    }
447
448    /// Gets `AutoAcceptIndicator`, Tag 754.
449    pub fn get_auto_accept_indicator(&self) -> Result<bool, MessageRejectErrorEnum> {
450        let mut fld = field::AutoAcceptIndicatorField::new(false);
451        self.message.body.get_field(tag::AUTO_ACCEPT_INDICATOR, &mut fld.0)?;
452        Ok(fld.value())
453    }
454
455
456    /// Returns true if `AutoAcceptIndicator` is present, Tag 754.
457    pub fn has_auto_accept_indicator(&self) -> bool {
458        self.message.body.has(tag::AUTO_ACCEPT_INDICATOR)
459    }
460
461
462
463
464    /// Sets `AvgParPx`, Tag 860.
465    pub fn set_avg_par_px(&mut self, val: Decimal, scale: i32) {
466        self.message.body.set_field(tag::AVG_PAR_PX, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
467    }
468
469    /// Gets `AvgParPx`, Tag 860.
470    pub fn get_avg_par_px(&self) -> Result<Decimal, MessageRejectErrorEnum> {
471        let mut fld = field::AvgParPxField::new(Decimal::ZERO, 0);
472        self.message.body.get_field(tag::AVG_PAR_PX, &mut fld.0)?;
473        Ok(fld.value())
474    }
475
476
477    /// Returns true if `AvgParPx` is present, Tag 860.
478    pub fn has_avg_par_px(&self) -> bool {
479        self.message.body.has(tag::AVG_PAR_PX)
480    }
481
482
483
484
485    /// Sets `AvgPx`, Tag 6.
486    pub fn set_avg_px(&mut self, val: Decimal, scale: i32) {
487        self.message.body.set_field(tag::AVG_PX, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
488    }
489
490    /// Gets `AvgPx`, Tag 6.
491    pub fn get_avg_px(&self) -> Result<Decimal, MessageRejectErrorEnum> {
492        let mut fld = field::AvgPxField::new(Decimal::ZERO, 0);
493        self.message.body.get_field(tag::AVG_PX, &mut fld.0)?;
494        Ok(fld.value())
495    }
496
497
498    /// Returns true if `AvgPx` is present, Tag 6.
499    pub fn has_avg_px(&self) -> bool {
500        self.message.body.has(tag::AVG_PX)
501    }
502
503
504
505
506    /// Sets `AvgPxPrecision`, Tag 74.
507    pub fn set_avg_px_precision(&mut self, v: isize) {
508        self.message.body.set_field(tag::AVG_PX_PRECISION, fixer::fix_int::FIXInt::from(v));
509    }
510
511    /// Gets `AvgPxPrecision`, Tag 74.
512    pub fn get_avg_px_precision(&self) -> Result<isize, MessageRejectErrorEnum> {
513        let mut fld = field::AvgPxPrecisionField::new(0);
514        self.message.body.get_field(tag::AVG_PX_PRECISION, &mut fld.0)?;
515        Ok(fld.value())
516    }
517
518
519    /// Returns true if `AvgPxPrecision` is present, Tag 74.
520    pub fn has_avg_px_precision(&self) -> bool {
521        self.message.body.has(tag::AVG_PX_PRECISION)
522    }
523
524
525
526
527    /// Sets `BenchmarkCurveCurrency`, Tag 220.
528    pub fn set_benchmark_curve_currency(&mut self, v: String) {
529        self.message.body.set_field(tag::BENCHMARK_CURVE_CURRENCY, FIXString::from(v));
530    }
531
532    /// Gets `BenchmarkCurveCurrency`, Tag 220.
533    pub fn get_benchmark_curve_currency(&self) -> Result<String, MessageRejectErrorEnum> {
534        let mut fld = field::BenchmarkCurveCurrencyField::new(String::new());
535        self.message.body.get_field(tag::BENCHMARK_CURVE_CURRENCY, &mut fld.0)?;
536        Ok(fld.value().to_string())
537    }
538
539
540    /// Returns true if `BenchmarkCurveCurrency` is present, Tag 220.
541    pub fn has_benchmark_curve_currency(&self) -> bool {
542        self.message.body.has(tag::BENCHMARK_CURVE_CURRENCY)
543    }
544
545
546
547
548    /// Sets `BenchmarkCurveName`, Tag 221.
549    pub fn set_benchmark_curve_name(&mut self, v: String) {
550        self.message.body.set_field(tag::BENCHMARK_CURVE_NAME, FIXString::from(v));
551    }
552
553    /// Gets `BenchmarkCurveName`, Tag 221.
554    pub fn get_benchmark_curve_name(&self) -> Result<String, MessageRejectErrorEnum> {
555        let mut fld = field::BenchmarkCurveNameField::new(String::new());
556        self.message.body.get_field(tag::BENCHMARK_CURVE_NAME, &mut fld.0)?;
557        Ok(fld.value().to_string())
558    }
559
560
561    /// Returns true if `BenchmarkCurveName` is present, Tag 221.
562    pub fn has_benchmark_curve_name(&self) -> bool {
563        self.message.body.has(tag::BENCHMARK_CURVE_NAME)
564    }
565
566
567
568
569    /// Sets `BenchmarkCurvePoint`, Tag 222.
570    pub fn set_benchmark_curve_point(&mut self, v: String) {
571        self.message.body.set_field(tag::BENCHMARK_CURVE_POINT, FIXString::from(v));
572    }
573
574    /// Gets `BenchmarkCurvePoint`, Tag 222.
575    pub fn get_benchmark_curve_point(&self) -> Result<String, MessageRejectErrorEnum> {
576        let mut fld = field::BenchmarkCurvePointField::new(String::new());
577        self.message.body.get_field(tag::BENCHMARK_CURVE_POINT, &mut fld.0)?;
578        Ok(fld.value().to_string())
579    }
580
581
582    /// Returns true if `BenchmarkCurvePoint` is present, Tag 222.
583    pub fn has_benchmark_curve_point(&self) -> bool {
584        self.message.body.has(tag::BENCHMARK_CURVE_POINT)
585    }
586
587
588
589
590    /// Sets `BenchmarkPrice`, Tag 662.
591    pub fn set_benchmark_price(&mut self, val: Decimal, scale: i32) {
592        self.message.body.set_field(tag::BENCHMARK_PRICE, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
593    }
594
595    /// Gets `BenchmarkPrice`, Tag 662.
596    pub fn get_benchmark_price(&self) -> Result<Decimal, MessageRejectErrorEnum> {
597        let mut fld = field::BenchmarkPriceField::new(Decimal::ZERO, 0);
598        self.message.body.get_field(tag::BENCHMARK_PRICE, &mut fld.0)?;
599        Ok(fld.value())
600    }
601
602
603    /// Returns true if `BenchmarkPrice` is present, Tag 662.
604    pub fn has_benchmark_price(&self) -> bool {
605        self.message.body.has(tag::BENCHMARK_PRICE)
606    }
607
608
609
610
611    /// Sets `BenchmarkPriceType`, Tag 663.
612    pub fn set_benchmark_price_type(&mut self, v: isize) {
613        self.message.body.set_field(tag::BENCHMARK_PRICE_TYPE, fixer::fix_int::FIXInt::from(v));
614    }
615
616    /// Gets `BenchmarkPriceType`, Tag 663.
617    pub fn get_benchmark_price_type(&self) -> Result<isize, MessageRejectErrorEnum> {
618        let mut fld = field::BenchmarkPriceTypeField::new(0);
619        self.message.body.get_field(tag::BENCHMARK_PRICE_TYPE, &mut fld.0)?;
620        Ok(fld.value())
621    }
622
623
624    /// Returns true if `BenchmarkPriceType` is present, Tag 663.
625    pub fn has_benchmark_price_type(&self) -> bool {
626        self.message.body.has(tag::BENCHMARK_PRICE_TYPE)
627    }
628
629
630
631
632    /// Sets `BenchmarkSecurityID`, Tag 699.
633    pub fn set_benchmark_security_id(&mut self, v: String) {
634        self.message.body.set_field(tag::BENCHMARK_SECURITY_ID, FIXString::from(v));
635    }
636
637    /// Gets `BenchmarkSecurityID`, Tag 699.
638    pub fn get_benchmark_security_id(&self) -> Result<String, MessageRejectErrorEnum> {
639        let mut fld = field::BenchmarkSecurityIDField::new(String::new());
640        self.message.body.get_field(tag::BENCHMARK_SECURITY_ID, &mut fld.0)?;
641        Ok(fld.value().to_string())
642    }
643
644
645    /// Returns true if `BenchmarkSecurityID` is present, Tag 699.
646    pub fn has_benchmark_security_id(&self) -> bool {
647        self.message.body.has(tag::BENCHMARK_SECURITY_ID)
648    }
649
650
651
652
653    /// Sets `BenchmarkSecurityIDSource`, Tag 761.
654    pub fn set_benchmark_security_id_source(&mut self, v: String) {
655        self.message.body.set_field(tag::BENCHMARK_SECURITY_ID_SOURCE, FIXString::from(v));
656    }
657
658    /// Gets `BenchmarkSecurityIDSource`, Tag 761.
659    pub fn get_benchmark_security_id_source(&self) -> Result<String, MessageRejectErrorEnum> {
660        let mut fld = field::BenchmarkSecurityIDSourceField::new(String::new());
661        self.message.body.get_field(tag::BENCHMARK_SECURITY_ID_SOURCE, &mut fld.0)?;
662        Ok(fld.value().to_string())
663    }
664
665
666    /// Returns true if `BenchmarkSecurityIDSource` is present, Tag 761.
667    pub fn has_benchmark_security_id_source(&self) -> bool {
668        self.message.body.has(tag::BENCHMARK_SECURITY_ID_SOURCE)
669    }
670
671
672
673
674    /// Sets `BookingRefID`, Tag 466.
675    pub fn set_booking_ref_id(&mut self, v: String) {
676        self.message.body.set_field(tag::BOOKING_REF_ID, FIXString::from(v));
677    }
678
679    /// Gets `BookingRefID`, Tag 466.
680    pub fn get_booking_ref_id(&self) -> Result<String, MessageRejectErrorEnum> {
681        let mut fld = field::BookingRefIDField::new(String::new());
682        self.message.body.get_field(tag::BOOKING_REF_ID, &mut fld.0)?;
683        Ok(fld.value().to_string())
684    }
685
686
687    /// Returns true if `BookingRefID` is present, Tag 466.
688    pub fn has_booking_ref_id(&self) -> bool {
689        self.message.body.has(tag::BOOKING_REF_ID)
690    }
691
692
693
694
695    /// Sets `BookingType`, Tag 775.
696    pub fn set_booking_type(&mut self, v: isize) {
697        self.message.body.set_field(tag::BOOKING_TYPE, fixer::fix_int::FIXInt::from(v));
698    }
699
700    /// Gets `BookingType`, Tag 775.
701    pub fn get_booking_type(&self) -> Result<isize, MessageRejectErrorEnum> {
702        let mut fld = field::BookingTypeField::new(0);
703        self.message.body.get_field(tag::BOOKING_TYPE, &mut fld.0)?;
704        Ok(fld.value())
705    }
706
707
708    /// Returns true if `BookingType` is present, Tag 775.
709    pub fn has_booking_type(&self) -> bool {
710        self.message.body.has(tag::BOOKING_TYPE)
711    }
712
713
714
715
716    /// Sets `CFICode`, Tag 461.
717    pub fn set_cfi_code(&mut self, v: String) {
718        self.message.body.set_field(tag::CFI_CODE, FIXString::from(v));
719    }
720
721    /// Gets `CFICode`, Tag 461.
722    pub fn get_cfi_code(&self) -> Result<String, MessageRejectErrorEnum> {
723        let mut fld = field::CFICodeField::new(String::new());
724        self.message.body.get_field(tag::CFI_CODE, &mut fld.0)?;
725        Ok(fld.value().to_string())
726    }
727
728
729    /// Returns true if `CFICode` is present, Tag 461.
730    pub fn has_cfi_code(&self) -> bool {
731        self.message.body.has(tag::CFI_CODE)
732    }
733
734
735
736
737    /// Sets `CPProgram`, Tag 875.
738    pub fn set_cp_program(&mut self, v: isize) {
739        self.message.body.set_field(tag::CP_PROGRAM, fixer::fix_int::FIXInt::from(v));
740    }
741
742    /// Gets `CPProgram`, Tag 875.
743    pub fn get_cp_program(&self) -> Result<isize, MessageRejectErrorEnum> {
744        let mut fld = field::CPProgramField::new(0);
745        self.message.body.get_field(tag::CP_PROGRAM, &mut fld.0)?;
746        Ok(fld.value())
747    }
748
749
750    /// Returns true if `CPProgram` is present, Tag 875.
751    pub fn has_cp_program(&self) -> bool {
752        self.message.body.has(tag::CP_PROGRAM)
753    }
754
755
756
757
758    /// Sets `CPRegType`, Tag 876.
759    pub fn set_cp_reg_type(&mut self, v: String) {
760        self.message.body.set_field(tag::CP_REG_TYPE, FIXString::from(v));
761    }
762
763    /// Gets `CPRegType`, Tag 876.
764    pub fn get_cp_reg_type(&self) -> Result<String, MessageRejectErrorEnum> {
765        let mut fld = field::CPRegTypeField::new(String::new());
766        self.message.body.get_field(tag::CP_REG_TYPE, &mut fld.0)?;
767        Ok(fld.value().to_string())
768    }
769
770
771    /// Returns true if `CPRegType` is present, Tag 876.
772    pub fn has_cp_reg_type(&self) -> bool {
773        self.message.body.has(tag::CP_REG_TYPE)
774    }
775
776
777
778
779    /// Sets `Concession`, Tag 238.
780    pub fn set_concession(&mut self, val: Decimal, scale: i32) {
781        self.message.body.set_field(tag::CONCESSION, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
782    }
783
784    /// Gets `Concession`, Tag 238.
785    pub fn get_concession(&self) -> Result<Decimal, MessageRejectErrorEnum> {
786        let mut fld = field::ConcessionField::new(Decimal::ZERO, 0);
787        self.message.body.get_field(tag::CONCESSION, &mut fld.0)?;
788        Ok(fld.value())
789    }
790
791
792    /// Returns true if `Concession` is present, Tag 238.
793    pub fn has_concession(&self) -> bool {
794        self.message.body.has(tag::CONCESSION)
795    }
796
797
798
799
800    /// Sets `ContractMultiplier`, Tag 231.
801    pub fn set_contract_multiplier(&mut self, val: Decimal, scale: i32) {
802        self.message.body.set_field(tag::CONTRACT_MULTIPLIER, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
803    }
804
805    /// Gets `ContractMultiplier`, Tag 231.
806    pub fn get_contract_multiplier(&self) -> Result<Decimal, MessageRejectErrorEnum> {
807        let mut fld = field::ContractMultiplierField::new(Decimal::ZERO, 0);
808        self.message.body.get_field(tag::CONTRACT_MULTIPLIER, &mut fld.0)?;
809        Ok(fld.value())
810    }
811
812
813    /// Returns true if `ContractMultiplier` is present, Tag 231.
814    pub fn has_contract_multiplier(&self) -> bool {
815        self.message.body.has(tag::CONTRACT_MULTIPLIER)
816    }
817
818
819
820
821    /// Sets `ContractSettlMonth`, Tag 667.
822    pub fn set_contract_settl_month(&mut self, v: String) {
823        self.message.body.set_field(tag::CONTRACT_SETTL_MONTH, FIXString::from(v));
824    }
825
826    /// Gets `ContractSettlMonth`, Tag 667.
827    pub fn get_contract_settl_month(&self) -> Result<String, MessageRejectErrorEnum> {
828        let mut fld = field::ContractSettlMonthField::new(String::new());
829        self.message.body.get_field(tag::CONTRACT_SETTL_MONTH, &mut fld.0)?;
830        Ok(fld.value().to_string())
831    }
832
833
834    /// Returns true if `ContractSettlMonth` is present, Tag 667.
835    pub fn has_contract_settl_month(&self) -> bool {
836        self.message.body.has(tag::CONTRACT_SETTL_MONTH)
837    }
838
839
840
841
842    /// Sets `CountryOfIssue`, Tag 470.
843    pub fn set_country_of_issue(&mut self, v: String) {
844        self.message.body.set_field(tag::COUNTRY_OF_ISSUE, FIXString::from(v));
845    }
846
847    /// Gets `CountryOfIssue`, Tag 470.
848    pub fn get_country_of_issue(&self) -> Result<String, MessageRejectErrorEnum> {
849        let mut fld = field::CountryOfIssueField::new(String::new());
850        self.message.body.get_field(tag::COUNTRY_OF_ISSUE, &mut fld.0)?;
851        Ok(fld.value().to_string())
852    }
853
854
855    /// Returns true if `CountryOfIssue` is present, Tag 470.
856    pub fn has_country_of_issue(&self) -> bool {
857        self.message.body.has(tag::COUNTRY_OF_ISSUE)
858    }
859
860
861
862
863    /// Sets `CouponPaymentDate`, Tag 224.
864    pub fn set_coupon_payment_date(&mut self, v: String) {
865        self.message.body.set_field(tag::COUPON_PAYMENT_DATE, FIXString::from(v));
866    }
867
868    /// Gets `CouponPaymentDate`, Tag 224.
869    pub fn get_coupon_payment_date(&self) -> Result<String, MessageRejectErrorEnum> {
870        let mut fld = field::CouponPaymentDateField::new(String::new());
871        self.message.body.get_field(tag::COUPON_PAYMENT_DATE, &mut fld.0)?;
872        Ok(fld.value().to_string())
873    }
874
875
876    /// Returns true if `CouponPaymentDate` is present, Tag 224.
877    pub fn has_coupon_payment_date(&self) -> bool {
878        self.message.body.has(tag::COUPON_PAYMENT_DATE)
879    }
880
881
882
883
884    /// Sets `CouponRate`, Tag 223.
885    pub fn set_coupon_rate(&mut self, val: Decimal, scale: i32) {
886        self.message.body.set_field(tag::COUPON_RATE, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
887    }
888
889    /// Gets `CouponRate`, Tag 223.
890    pub fn get_coupon_rate(&self) -> Result<Decimal, MessageRejectErrorEnum> {
891        let mut fld = field::CouponRateField::new(Decimal::ZERO, 0);
892        self.message.body.get_field(tag::COUPON_RATE, &mut fld.0)?;
893        Ok(fld.value())
894    }
895
896
897    /// Returns true if `CouponRate` is present, Tag 223.
898    pub fn has_coupon_rate(&self) -> bool {
899        self.message.body.has(tag::COUPON_RATE)
900    }
901
902
903
904
905    /// Sets `CreditRating`, Tag 255.
906    pub fn set_credit_rating(&mut self, v: String) {
907        self.message.body.set_field(tag::CREDIT_RATING, FIXString::from(v));
908    }
909
910    /// Gets `CreditRating`, Tag 255.
911    pub fn get_credit_rating(&self) -> Result<String, MessageRejectErrorEnum> {
912        let mut fld = field::CreditRatingField::new(String::new());
913        self.message.body.get_field(tag::CREDIT_RATING, &mut fld.0)?;
914        Ok(fld.value().to_string())
915    }
916
917
918    /// Returns true if `CreditRating` is present, Tag 255.
919    pub fn has_credit_rating(&self) -> bool {
920        self.message.body.has(tag::CREDIT_RATING)
921    }
922
923
924
925
926    /// Sets `Currency`, Tag 15.
927    pub fn set_currency(&mut self, v: String) {
928        self.message.body.set_field(tag::CURRENCY, FIXString::from(v));
929    }
930
931    /// Gets `Currency`, Tag 15.
932    pub fn get_currency(&self) -> Result<String, MessageRejectErrorEnum> {
933        let mut fld = field::CurrencyField::new(String::new());
934        self.message.body.get_field(tag::CURRENCY, &mut fld.0)?;
935        Ok(fld.value().to_string())
936    }
937
938
939    /// Returns true if `Currency` is present, Tag 15.
940    pub fn has_currency(&self) -> bool {
941        self.message.body.has(tag::CURRENCY)
942    }
943
944
945
946
947    /// Sets `DatedDate`, Tag 873.
948    pub fn set_dated_date(&mut self, v: String) {
949        self.message.body.set_field(tag::DATED_DATE, FIXString::from(v));
950    }
951
952    /// Gets `DatedDate`, Tag 873.
953    pub fn get_dated_date(&self) -> Result<String, MessageRejectErrorEnum> {
954        let mut fld = field::DatedDateField::new(String::new());
955        self.message.body.get_field(tag::DATED_DATE, &mut fld.0)?;
956        Ok(fld.value().to_string())
957    }
958
959
960    /// Returns true if `DatedDate` is present, Tag 873.
961    pub fn has_dated_date(&self) -> bool {
962        self.message.body.has(tag::DATED_DATE)
963    }
964
965
966
967
968    /// Sets `DeliveryForm`, Tag 668.
969    pub fn set_delivery_form(&mut self, v: isize) {
970        self.message.body.set_field(tag::DELIVERY_FORM, fixer::fix_int::FIXInt::from(v));
971    }
972
973    /// Gets `DeliveryForm`, Tag 668.
974    pub fn get_delivery_form(&self) -> Result<isize, MessageRejectErrorEnum> {
975        let mut fld = field::DeliveryFormField::new(0);
976        self.message.body.get_field(tag::DELIVERY_FORM, &mut fld.0)?;
977        Ok(fld.value())
978    }
979
980
981    /// Returns true if `DeliveryForm` is present, Tag 668.
982    pub fn has_delivery_form(&self) -> bool {
983        self.message.body.has(tag::DELIVERY_FORM)
984    }
985
986
987
988
989    /// Sets `DeliveryType`, Tag 919.
990    pub fn set_delivery_type(&mut self, v: isize) {
991        self.message.body.set_field(tag::DELIVERY_TYPE, fixer::fix_int::FIXInt::from(v));
992    }
993
994    /// Gets `DeliveryType`, Tag 919.
995    pub fn get_delivery_type(&self) -> Result<isize, MessageRejectErrorEnum> {
996        let mut fld = field::DeliveryTypeField::new(0);
997        self.message.body.get_field(tag::DELIVERY_TYPE, &mut fld.0)?;
998        Ok(fld.value())
999    }
1000
1001
1002    /// Returns true if `DeliveryType` is present, Tag 919.
1003    pub fn has_delivery_type(&self) -> bool {
1004        self.message.body.has(tag::DELIVERY_TYPE)
1005    }
1006
1007
1008
1009
1010    /// Sets `EncodedIssuer`, Tag 349.
1011    pub fn set_encoded_issuer(&mut self, v: String) {
1012        self.message.body.set_field(tag::ENCODED_ISSUER, FIXString::from(v));
1013    }
1014
1015    /// Gets `EncodedIssuer`, Tag 349.
1016    pub fn get_encoded_issuer(&self) -> Result<String, MessageRejectErrorEnum> {
1017        let mut fld = field::EncodedIssuerField::new(String::new());
1018        self.message.body.get_field(tag::ENCODED_ISSUER, &mut fld.0)?;
1019        Ok(fld.value().to_string())
1020    }
1021
1022
1023    /// Returns true if `EncodedIssuer` is present, Tag 349.
1024    pub fn has_encoded_issuer(&self) -> bool {
1025        self.message.body.has(tag::ENCODED_ISSUER)
1026    }
1027
1028
1029
1030
1031    /// Sets `EncodedIssuerLen`, Tag 348.
1032    pub fn set_encoded_issuer_len(&mut self, v: isize) {
1033        self.message.body.set_field(tag::ENCODED_ISSUER_LEN, fixer::fix_int::FIXInt::from(v));
1034    }
1035
1036    /// Gets `EncodedIssuerLen`, Tag 348.
1037    pub fn get_encoded_issuer_len(&self) -> Result<isize, MessageRejectErrorEnum> {
1038        let mut fld = field::EncodedIssuerLenField::new(0);
1039        self.message.body.get_field(tag::ENCODED_ISSUER_LEN, &mut fld.0)?;
1040        Ok(fld.value())
1041    }
1042
1043
1044    /// Returns true if `EncodedIssuerLen` is present, Tag 348.
1045    pub fn has_encoded_issuer_len(&self) -> bool {
1046        self.message.body.has(tag::ENCODED_ISSUER_LEN)
1047    }
1048
1049
1050
1051
1052    /// Sets `EncodedSecurityDesc`, Tag 351.
1053    pub fn set_encoded_security_desc(&mut self, v: String) {
1054        self.message.body.set_field(tag::ENCODED_SECURITY_DESC, FIXString::from(v));
1055    }
1056
1057    /// Gets `EncodedSecurityDesc`, Tag 351.
1058    pub fn get_encoded_security_desc(&self) -> Result<String, MessageRejectErrorEnum> {
1059        let mut fld = field::EncodedSecurityDescField::new(String::new());
1060        self.message.body.get_field(tag::ENCODED_SECURITY_DESC, &mut fld.0)?;
1061        Ok(fld.value().to_string())
1062    }
1063
1064
1065    /// Returns true if `EncodedSecurityDesc` is present, Tag 351.
1066    pub fn has_encoded_security_desc(&self) -> bool {
1067        self.message.body.has(tag::ENCODED_SECURITY_DESC)
1068    }
1069
1070
1071
1072
1073    /// Sets `EncodedSecurityDescLen`, Tag 350.
1074    pub fn set_encoded_security_desc_len(&mut self, v: isize) {
1075        self.message.body.set_field(tag::ENCODED_SECURITY_DESC_LEN, fixer::fix_int::FIXInt::from(v));
1076    }
1077
1078    /// Gets `EncodedSecurityDescLen`, Tag 350.
1079    pub fn get_encoded_security_desc_len(&self) -> Result<isize, MessageRejectErrorEnum> {
1080        let mut fld = field::EncodedSecurityDescLenField::new(0);
1081        self.message.body.get_field(tag::ENCODED_SECURITY_DESC_LEN, &mut fld.0)?;
1082        Ok(fld.value())
1083    }
1084
1085
1086    /// Returns true if `EncodedSecurityDescLen` is present, Tag 350.
1087    pub fn has_encoded_security_desc_len(&self) -> bool {
1088        self.message.body.has(tag::ENCODED_SECURITY_DESC_LEN)
1089    }
1090
1091
1092
1093
1094    /// Sets `EncodedText`, Tag 355.
1095    pub fn set_encoded_text(&mut self, v: String) {
1096        self.message.body.set_field(tag::ENCODED_TEXT, FIXString::from(v));
1097    }
1098
1099    /// Gets `EncodedText`, Tag 355.
1100    pub fn get_encoded_text(&self) -> Result<String, MessageRejectErrorEnum> {
1101        let mut fld = field::EncodedTextField::new(String::new());
1102        self.message.body.get_field(tag::ENCODED_TEXT, &mut fld.0)?;
1103        Ok(fld.value().to_string())
1104    }
1105
1106
1107    /// Returns true if `EncodedText` is present, Tag 355.
1108    pub fn has_encoded_text(&self) -> bool {
1109        self.message.body.has(tag::ENCODED_TEXT)
1110    }
1111
1112
1113
1114
1115    /// Sets `EncodedTextLen`, Tag 354.
1116    pub fn set_encoded_text_len(&mut self, v: isize) {
1117        self.message.body.set_field(tag::ENCODED_TEXT_LEN, fixer::fix_int::FIXInt::from(v));
1118    }
1119
1120    /// Gets `EncodedTextLen`, Tag 354.
1121    pub fn get_encoded_text_len(&self) -> Result<isize, MessageRejectErrorEnum> {
1122        let mut fld = field::EncodedTextLenField::new(0);
1123        self.message.body.get_field(tag::ENCODED_TEXT_LEN, &mut fld.0)?;
1124        Ok(fld.value())
1125    }
1126
1127
1128    /// Returns true if `EncodedTextLen` is present, Tag 354.
1129    pub fn has_encoded_text_len(&self) -> bool {
1130        self.message.body.has(tag::ENCODED_TEXT_LEN)
1131    }
1132
1133
1134
1135
1136    /// Sets `EndAccruedInterestAmt`, Tag 920.
1137    pub fn set_end_accrued_interest_amt(&mut self, val: Decimal, scale: i32) {
1138        self.message.body.set_field(tag::END_ACCRUED_INTEREST_AMT, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
1139    }
1140
1141    /// Gets `EndAccruedInterestAmt`, Tag 920.
1142    pub fn get_end_accrued_interest_amt(&self) -> Result<Decimal, MessageRejectErrorEnum> {
1143        let mut fld = field::EndAccruedInterestAmtField::new(Decimal::ZERO, 0);
1144        self.message.body.get_field(tag::END_ACCRUED_INTEREST_AMT, &mut fld.0)?;
1145        Ok(fld.value())
1146    }
1147
1148
1149    /// Returns true if `EndAccruedInterestAmt` is present, Tag 920.
1150    pub fn has_end_accrued_interest_amt(&self) -> bool {
1151        self.message.body.has(tag::END_ACCRUED_INTEREST_AMT)
1152    }
1153
1154
1155
1156
1157    /// Sets `EndCash`, Tag 922.
1158    pub fn set_end_cash(&mut self, val: Decimal, scale: i32) {
1159        self.message.body.set_field(tag::END_CASH, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
1160    }
1161
1162    /// Gets `EndCash`, Tag 922.
1163    pub fn get_end_cash(&self) -> Result<Decimal, MessageRejectErrorEnum> {
1164        let mut fld = field::EndCashField::new(Decimal::ZERO, 0);
1165        self.message.body.get_field(tag::END_CASH, &mut fld.0)?;
1166        Ok(fld.value())
1167    }
1168
1169
1170    /// Returns true if `EndCash` is present, Tag 922.
1171    pub fn has_end_cash(&self) -> bool {
1172        self.message.body.has(tag::END_CASH)
1173    }
1174
1175
1176
1177
1178    /// Sets `EndDate`, Tag 917.
1179    pub fn set_end_date(&mut self, v: String) {
1180        self.message.body.set_field(tag::END_DATE, FIXString::from(v));
1181    }
1182
1183    /// Gets `EndDate`, Tag 917.
1184    pub fn get_end_date(&self) -> Result<String, MessageRejectErrorEnum> {
1185        let mut fld = field::EndDateField::new(String::new());
1186        self.message.body.get_field(tag::END_DATE, &mut fld.0)?;
1187        Ok(fld.value().to_string())
1188    }
1189
1190
1191    /// Returns true if `EndDate` is present, Tag 917.
1192    pub fn has_end_date(&self) -> bool {
1193        self.message.body.has(tag::END_DATE)
1194    }
1195
1196
1197
1198
1199    /// Sets `Factor`, Tag 228.
1200    pub fn set_factor(&mut self, val: Decimal, scale: i32) {
1201        self.message.body.set_field(tag::FACTOR, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
1202    }
1203
1204    /// Gets `Factor`, Tag 228.
1205    pub fn get_factor(&self) -> Result<Decimal, MessageRejectErrorEnum> {
1206        let mut fld = field::FactorField::new(Decimal::ZERO, 0);
1207        self.message.body.get_field(tag::FACTOR, &mut fld.0)?;
1208        Ok(fld.value())
1209    }
1210
1211
1212    /// Returns true if `Factor` is present, Tag 228.
1213    pub fn has_factor(&self) -> bool {
1214        self.message.body.has(tag::FACTOR)
1215    }
1216
1217
1218
1219
1220    /// Sets `GrossTradeAmt`, Tag 381.
1221    pub fn set_gross_trade_amt(&mut self, val: Decimal, scale: i32) {
1222        self.message.body.set_field(tag::GROSS_TRADE_AMT, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
1223    }
1224
1225    /// Gets `GrossTradeAmt`, Tag 381.
1226    pub fn get_gross_trade_amt(&self) -> Result<Decimal, MessageRejectErrorEnum> {
1227        let mut fld = field::GrossTradeAmtField::new(Decimal::ZERO, 0);
1228        self.message.body.get_field(tag::GROSS_TRADE_AMT, &mut fld.0)?;
1229        Ok(fld.value())
1230    }
1231
1232
1233    /// Returns true if `GrossTradeAmt` is present, Tag 381.
1234    pub fn has_gross_trade_amt(&self) -> bool {
1235        self.message.body.has(tag::GROSS_TRADE_AMT)
1236    }
1237
1238
1239
1240
1241    /// Sets `InstrRegistry`, Tag 543.
1242    pub fn set_instr_registry(&mut self, v: String) {
1243        self.message.body.set_field(tag::INSTR_REGISTRY, FIXString::from(v));
1244    }
1245
1246    /// Gets `InstrRegistry`, Tag 543.
1247    pub fn get_instr_registry(&self) -> Result<String, MessageRejectErrorEnum> {
1248        let mut fld = field::InstrRegistryField::new(String::new());
1249        self.message.body.get_field(tag::INSTR_REGISTRY, &mut fld.0)?;
1250        Ok(fld.value().to_string())
1251    }
1252
1253
1254    /// Returns true if `InstrRegistry` is present, Tag 543.
1255    pub fn has_instr_registry(&self) -> bool {
1256        self.message.body.has(tag::INSTR_REGISTRY)
1257    }
1258
1259
1260
1261
1262    /// Sets `InterestAccrualDate`, Tag 874.
1263    pub fn set_interest_accrual_date(&mut self, v: String) {
1264        self.message.body.set_field(tag::INTEREST_ACCRUAL_DATE, FIXString::from(v));
1265    }
1266
1267    /// Gets `InterestAccrualDate`, Tag 874.
1268    pub fn get_interest_accrual_date(&self) -> Result<String, MessageRejectErrorEnum> {
1269        let mut fld = field::InterestAccrualDateField::new(String::new());
1270        self.message.body.get_field(tag::INTEREST_ACCRUAL_DATE, &mut fld.0)?;
1271        Ok(fld.value().to_string())
1272    }
1273
1274
1275    /// Returns true if `InterestAccrualDate` is present, Tag 874.
1276    pub fn has_interest_accrual_date(&self) -> bool {
1277        self.message.body.has(tag::INTEREST_ACCRUAL_DATE)
1278    }
1279
1280
1281
1282
1283    /// Sets `InterestAtMaturity`, Tag 738.
1284    pub fn set_interest_at_maturity(&mut self, val: Decimal, scale: i32) {
1285        self.message.body.set_field(tag::INTEREST_AT_MATURITY, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
1286    }
1287
1288    /// Gets `InterestAtMaturity`, Tag 738.
1289    pub fn get_interest_at_maturity(&self) -> Result<Decimal, MessageRejectErrorEnum> {
1290        let mut fld = field::InterestAtMaturityField::new(Decimal::ZERO, 0);
1291        self.message.body.get_field(tag::INTEREST_AT_MATURITY, &mut fld.0)?;
1292        Ok(fld.value())
1293    }
1294
1295
1296    /// Returns true if `InterestAtMaturity` is present, Tag 738.
1297    pub fn has_interest_at_maturity(&self) -> bool {
1298        self.message.body.has(tag::INTEREST_AT_MATURITY)
1299    }
1300
1301
1302
1303
1304    /// Sets `IssueDate`, Tag 225.
1305    pub fn set_issue_date(&mut self, v: String) {
1306        self.message.body.set_field(tag::ISSUE_DATE, FIXString::from(v));
1307    }
1308
1309    /// Gets `IssueDate`, Tag 225.
1310    pub fn get_issue_date(&self) -> Result<String, MessageRejectErrorEnum> {
1311        let mut fld = field::IssueDateField::new(String::new());
1312        self.message.body.get_field(tag::ISSUE_DATE, &mut fld.0)?;
1313        Ok(fld.value().to_string())
1314    }
1315
1316
1317    /// Returns true if `IssueDate` is present, Tag 225.
1318    pub fn has_issue_date(&self) -> bool {
1319        self.message.body.has(tag::ISSUE_DATE)
1320    }
1321
1322
1323
1324
1325    /// Sets `Issuer`, Tag 106.
1326    pub fn set_issuer(&mut self, v: String) {
1327        self.message.body.set_field(tag::ISSUER, FIXString::from(v));
1328    }
1329
1330    /// Gets `Issuer`, Tag 106.
1331    pub fn get_issuer(&self) -> Result<String, MessageRejectErrorEnum> {
1332        let mut fld = field::IssuerField::new(String::new());
1333        self.message.body.get_field(tag::ISSUER, &mut fld.0)?;
1334        Ok(fld.value().to_string())
1335    }
1336
1337
1338    /// Returns true if `Issuer` is present, Tag 106.
1339    pub fn has_issuer(&self) -> bool {
1340        self.message.body.has(tag::ISSUER)
1341    }
1342
1343
1344
1345
1346    /// Sets `LastFragment`, Tag 893.
1347    pub fn set_last_fragment(&mut self, v: bool) {
1348        self.message.body.set_field(tag::LAST_FRAGMENT, fixer::fix_boolean::FIXBoolean::from(v));
1349    }
1350
1351    /// Gets `LastFragment`, Tag 893.
1352    pub fn get_last_fragment(&self) -> Result<bool, MessageRejectErrorEnum> {
1353        let mut fld = field::LastFragmentField::new(false);
1354        self.message.body.get_field(tag::LAST_FRAGMENT, &mut fld.0)?;
1355        Ok(fld.value())
1356    }
1357
1358
1359    /// Returns true if `LastFragment` is present, Tag 893.
1360    pub fn has_last_fragment(&self) -> bool {
1361        self.message.body.has(tag::LAST_FRAGMENT)
1362    }
1363
1364
1365
1366
1367    /// Sets `LastMkt`, Tag 30.
1368    pub fn set_last_mkt(&mut self, v: String) {
1369        self.message.body.set_field(tag::LAST_MKT, FIXString::from(v));
1370    }
1371
1372    /// Gets `LastMkt`, Tag 30.
1373    pub fn get_last_mkt(&self) -> Result<String, MessageRejectErrorEnum> {
1374        let mut fld = field::LastMktField::new(String::new());
1375        self.message.body.get_field(tag::LAST_MKT, &mut fld.0)?;
1376        Ok(fld.value().to_string())
1377    }
1378
1379
1380    /// Returns true if `LastMkt` is present, Tag 30.
1381    pub fn has_last_mkt(&self) -> bool {
1382        self.message.body.has(tag::LAST_MKT)
1383    }
1384
1385
1386
1387
1388    /// Sets `LegalConfirm`, Tag 650.
1389    pub fn set_legal_confirm(&mut self, v: bool) {
1390        self.message.body.set_field(tag::LEGAL_CONFIRM, fixer::fix_boolean::FIXBoolean::from(v));
1391    }
1392
1393    /// Gets `LegalConfirm`, Tag 650.
1394    pub fn get_legal_confirm(&self) -> Result<bool, MessageRejectErrorEnum> {
1395        let mut fld = field::LegalConfirmField::new(false);
1396        self.message.body.get_field(tag::LEGAL_CONFIRM, &mut fld.0)?;
1397        Ok(fld.value())
1398    }
1399
1400
1401    /// Returns true if `LegalConfirm` is present, Tag 650.
1402    pub fn has_legal_confirm(&self) -> bool {
1403        self.message.body.has(tag::LEGAL_CONFIRM)
1404    }
1405
1406
1407
1408
1409    /// Sets `LocaleOfIssue`, Tag 472.
1410    pub fn set_locale_of_issue(&mut self, v: String) {
1411        self.message.body.set_field(tag::LOCALE_OF_ISSUE, FIXString::from(v));
1412    }
1413
1414    /// Gets `LocaleOfIssue`, Tag 472.
1415    pub fn get_locale_of_issue(&self) -> Result<String, MessageRejectErrorEnum> {
1416        let mut fld = field::LocaleOfIssueField::new(String::new());
1417        self.message.body.get_field(tag::LOCALE_OF_ISSUE, &mut fld.0)?;
1418        Ok(fld.value().to_string())
1419    }
1420
1421
1422    /// Returns true if `LocaleOfIssue` is present, Tag 472.
1423    pub fn has_locale_of_issue(&self) -> bool {
1424        self.message.body.has(tag::LOCALE_OF_ISSUE)
1425    }
1426
1427
1428
1429
1430    /// Sets `MarginRatio`, Tag 898.
1431    pub fn set_margin_ratio(&mut self, val: Decimal, scale: i32) {
1432        self.message.body.set_field(tag::MARGIN_RATIO, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
1433    }
1434
1435    /// Gets `MarginRatio`, Tag 898.
1436    pub fn get_margin_ratio(&self) -> Result<Decimal, MessageRejectErrorEnum> {
1437        let mut fld = field::MarginRatioField::new(Decimal::ZERO, 0);
1438        self.message.body.get_field(tag::MARGIN_RATIO, &mut fld.0)?;
1439        Ok(fld.value())
1440    }
1441
1442
1443    /// Returns true if `MarginRatio` is present, Tag 898.
1444    pub fn has_margin_ratio(&self) -> bool {
1445        self.message.body.has(tag::MARGIN_RATIO)
1446    }
1447
1448
1449
1450
1451    /// Sets `MatchType`, Tag 574.
1452    pub fn set_match_type(&mut self, v: String) {
1453        self.message.body.set_field(tag::MATCH_TYPE, FIXString::from(v));
1454    }
1455
1456    /// Gets `MatchType`, Tag 574.
1457    pub fn get_match_type(&self) -> Result<String, MessageRejectErrorEnum> {
1458        let mut fld = field::MatchTypeField::new(String::new());
1459        self.message.body.get_field(tag::MATCH_TYPE, &mut fld.0)?;
1460        Ok(fld.value().to_string())
1461    }
1462
1463
1464    /// Returns true if `MatchType` is present, Tag 574.
1465    pub fn has_match_type(&self) -> bool {
1466        self.message.body.has(tag::MATCH_TYPE)
1467    }
1468
1469
1470
1471
1472    /// Sets `MaturityDate`, Tag 541.
1473    pub fn set_maturity_date(&mut self, v: String) {
1474        self.message.body.set_field(tag::MATURITY_DATE, FIXString::from(v));
1475    }
1476
1477    /// Gets `MaturityDate`, Tag 541.
1478    pub fn get_maturity_date(&self) -> Result<String, MessageRejectErrorEnum> {
1479        let mut fld = field::MaturityDateField::new(String::new());
1480        self.message.body.get_field(tag::MATURITY_DATE, &mut fld.0)?;
1481        Ok(fld.value().to_string())
1482    }
1483
1484
1485    /// Returns true if `MaturityDate` is present, Tag 541.
1486    pub fn has_maturity_date(&self) -> bool {
1487        self.message.body.has(tag::MATURITY_DATE)
1488    }
1489
1490
1491
1492
1493    /// Sets `MaturityMonthYear`, Tag 200.
1494    pub fn set_maturity_month_year(&mut self, v: String) {
1495        self.message.body.set_field(tag::MATURITY_MONTH_YEAR, FIXString::from(v));
1496    }
1497
1498    /// Gets `MaturityMonthYear`, Tag 200.
1499    pub fn get_maturity_month_year(&self) -> Result<String, MessageRejectErrorEnum> {
1500        let mut fld = field::MaturityMonthYearField::new(String::new());
1501        self.message.body.get_field(tag::MATURITY_MONTH_YEAR, &mut fld.0)?;
1502        Ok(fld.value().to_string())
1503    }
1504
1505
1506    /// Returns true if `MaturityMonthYear` is present, Tag 200.
1507    pub fn has_maturity_month_year(&self) -> bool {
1508        self.message.body.has(tag::MATURITY_MONTH_YEAR)
1509    }
1510
1511
1512
1513
1514    /// Sets `NetMoney`, Tag 118.
1515    pub fn set_net_money(&mut self, val: Decimal, scale: i32) {
1516        self.message.body.set_field(tag::NET_MONEY, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
1517    }
1518
1519    /// Gets `NetMoney`, Tag 118.
1520    pub fn get_net_money(&self) -> Result<Decimal, MessageRejectErrorEnum> {
1521        let mut fld = field::NetMoneyField::new(Decimal::ZERO, 0);
1522        self.message.body.get_field(tag::NET_MONEY, &mut fld.0)?;
1523        Ok(fld.value())
1524    }
1525
1526
1527    /// Returns true if `NetMoney` is present, Tag 118.
1528    pub fn has_net_money(&self) -> bool {
1529        self.message.body.has(tag::NET_MONEY)
1530    }
1531
1532
1533
1534
1535    /// Sets `NoAllocs`, Tag 78.
1536    pub fn set_no_allocs(&mut self, v: isize) {
1537        self.message.body.set_field(tag::NO_ALLOCS, fixer::fix_int::FIXInt::from(v));
1538    }
1539
1540    /// Gets `NoAllocs`, Tag 78.
1541    pub fn get_no_allocs(&self) -> Result<isize, MessageRejectErrorEnum> {
1542        let mut fld = field::NoAllocsField::new(0);
1543        self.message.body.get_field(tag::NO_ALLOCS, &mut fld.0)?;
1544        Ok(fld.value())
1545    }
1546
1547
1548    /// Returns true if `NoAllocs` is present, Tag 78.
1549    pub fn has_no_allocs(&self) -> bool {
1550        self.message.body.has(tag::NO_ALLOCS)
1551    }
1552
1553
1554
1555
1556    /// Sets `NoEvents`, Tag 864.
1557    pub fn set_no_events(&mut self, v: isize) {
1558        self.message.body.set_field(tag::NO_EVENTS, fixer::fix_int::FIXInt::from(v));
1559    }
1560
1561    /// Gets `NoEvents`, Tag 864.
1562    pub fn get_no_events(&self) -> Result<isize, MessageRejectErrorEnum> {
1563        let mut fld = field::NoEventsField::new(0);
1564        self.message.body.get_field(tag::NO_EVENTS, &mut fld.0)?;
1565        Ok(fld.value())
1566    }
1567
1568
1569    /// Returns true if `NoEvents` is present, Tag 864.
1570    pub fn has_no_events(&self) -> bool {
1571        self.message.body.has(tag::NO_EVENTS)
1572    }
1573
1574
1575
1576
1577    /// Sets `NoExecs`, Tag 124.
1578    pub fn set_no_execs(&mut self, v: isize) {
1579        self.message.body.set_field(tag::NO_EXECS, fixer::fix_int::FIXInt::from(v));
1580    }
1581
1582    /// Gets `NoExecs`, Tag 124.
1583    pub fn get_no_execs(&self) -> Result<isize, MessageRejectErrorEnum> {
1584        let mut fld = field::NoExecsField::new(0);
1585        self.message.body.get_field(tag::NO_EXECS, &mut fld.0)?;
1586        Ok(fld.value())
1587    }
1588
1589
1590    /// Returns true if `NoExecs` is present, Tag 124.
1591    pub fn has_no_execs(&self) -> bool {
1592        self.message.body.has(tag::NO_EXECS)
1593    }
1594
1595
1596
1597
1598    /// Sets `NoInstrAttrib`, Tag 870.
1599    pub fn set_no_instr_attrib(&mut self, v: isize) {
1600        self.message.body.set_field(tag::NO_INSTR_ATTRIB, fixer::fix_int::FIXInt::from(v));
1601    }
1602
1603    /// Gets `NoInstrAttrib`, Tag 870.
1604    pub fn get_no_instr_attrib(&self) -> Result<isize, MessageRejectErrorEnum> {
1605        let mut fld = field::NoInstrAttribField::new(0);
1606        self.message.body.get_field(tag::NO_INSTR_ATTRIB, &mut fld.0)?;
1607        Ok(fld.value())
1608    }
1609
1610
1611    /// Returns true if `NoInstrAttrib` is present, Tag 870.
1612    pub fn has_no_instr_attrib(&self) -> bool {
1613        self.message.body.has(tag::NO_INSTR_ATTRIB)
1614    }
1615
1616
1617
1618
1619    /// Sets `NoLegs`, Tag 555.
1620    pub fn set_no_legs(&mut self, v: isize) {
1621        self.message.body.set_field(tag::NO_LEGS, fixer::fix_int::FIXInt::from(v));
1622    }
1623
1624    /// Gets `NoLegs`, Tag 555.
1625    pub fn get_no_legs(&self) -> Result<isize, MessageRejectErrorEnum> {
1626        let mut fld = field::NoLegsField::new(0);
1627        self.message.body.get_field(tag::NO_LEGS, &mut fld.0)?;
1628        Ok(fld.value())
1629    }
1630
1631
1632    /// Returns true if `NoLegs` is present, Tag 555.
1633    pub fn has_no_legs(&self) -> bool {
1634        self.message.body.has(tag::NO_LEGS)
1635    }
1636
1637
1638
1639
1640    /// Sets `NoOrders`, Tag 73.
1641    pub fn set_no_orders(&mut self, v: isize) {
1642        self.message.body.set_field(tag::NO_ORDERS, fixer::fix_int::FIXInt::from(v));
1643    }
1644
1645    /// Gets `NoOrders`, Tag 73.
1646    pub fn get_no_orders(&self) -> Result<isize, MessageRejectErrorEnum> {
1647        let mut fld = field::NoOrdersField::new(0);
1648        self.message.body.get_field(tag::NO_ORDERS, &mut fld.0)?;
1649        Ok(fld.value())
1650    }
1651
1652
1653    /// Returns true if `NoOrders` is present, Tag 73.
1654    pub fn has_no_orders(&self) -> bool {
1655        self.message.body.has(tag::NO_ORDERS)
1656    }
1657
1658
1659
1660
1661    /// Sets `NoPartyIDs`, Tag 453.
1662    pub fn set_no_party_i_ds(&mut self, v: isize) {
1663        self.message.body.set_field(tag::NO_PARTY_I_DS, fixer::fix_int::FIXInt::from(v));
1664    }
1665
1666    /// Gets `NoPartyIDs`, Tag 453.
1667    pub fn get_no_party_i_ds(&self) -> Result<isize, MessageRejectErrorEnum> {
1668        let mut fld = field::NoPartyIDsField::new(0);
1669        self.message.body.get_field(tag::NO_PARTY_I_DS, &mut fld.0)?;
1670        Ok(fld.value())
1671    }
1672
1673
1674    /// Returns true if `NoPartyIDs` is present, Tag 453.
1675    pub fn has_no_party_i_ds(&self) -> bool {
1676        self.message.body.has(tag::NO_PARTY_I_DS)
1677    }
1678
1679
1680
1681
1682    /// Sets `NoSecurityAltID`, Tag 454.
1683    pub fn set_no_security_alt_id(&mut self, v: isize) {
1684        self.message.body.set_field(tag::NO_SECURITY_ALT_ID, fixer::fix_int::FIXInt::from(v));
1685    }
1686
1687    /// Gets `NoSecurityAltID`, Tag 454.
1688    pub fn get_no_security_alt_id(&self) -> Result<isize, MessageRejectErrorEnum> {
1689        let mut fld = field::NoSecurityAltIDField::new(0);
1690        self.message.body.get_field(tag::NO_SECURITY_ALT_ID, &mut fld.0)?;
1691        Ok(fld.value())
1692    }
1693
1694
1695    /// Returns true if `NoSecurityAltID` is present, Tag 454.
1696    pub fn has_no_security_alt_id(&self) -> bool {
1697        self.message.body.has(tag::NO_SECURITY_ALT_ID)
1698    }
1699
1700
1701
1702
1703    /// Sets `NoStipulations`, Tag 232.
1704    pub fn set_no_stipulations(&mut self, v: isize) {
1705        self.message.body.set_field(tag::NO_STIPULATIONS, fixer::fix_int::FIXInt::from(v));
1706    }
1707
1708    /// Gets `NoStipulations`, Tag 232.
1709    pub fn get_no_stipulations(&self) -> Result<isize, MessageRejectErrorEnum> {
1710        let mut fld = field::NoStipulationsField::new(0);
1711        self.message.body.get_field(tag::NO_STIPULATIONS, &mut fld.0)?;
1712        Ok(fld.value())
1713    }
1714
1715
1716    /// Returns true if `NoStipulations` is present, Tag 232.
1717    pub fn has_no_stipulations(&self) -> bool {
1718        self.message.body.has(tag::NO_STIPULATIONS)
1719    }
1720
1721
1722
1723
1724    /// Sets `NoUnderlyings`, Tag 711.
1725    pub fn set_no_underlyings(&mut self, v: isize) {
1726        self.message.body.set_field(tag::NO_UNDERLYINGS, fixer::fix_int::FIXInt::from(v));
1727    }
1728
1729    /// Gets `NoUnderlyings`, Tag 711.
1730    pub fn get_no_underlyings(&self) -> Result<isize, MessageRejectErrorEnum> {
1731        let mut fld = field::NoUnderlyingsField::new(0);
1732        self.message.body.get_field(tag::NO_UNDERLYINGS, &mut fld.0)?;
1733        Ok(fld.value())
1734    }
1735
1736
1737    /// Returns true if `NoUnderlyings` is present, Tag 711.
1738    pub fn has_no_underlyings(&self) -> bool {
1739        self.message.body.has(tag::NO_UNDERLYINGS)
1740    }
1741
1742
1743
1744
1745    /// Sets `NumDaysInterest`, Tag 157.
1746    pub fn set_num_days_interest(&mut self, v: isize) {
1747        self.message.body.set_field(tag::NUM_DAYS_INTEREST, fixer::fix_int::FIXInt::from(v));
1748    }
1749
1750    /// Gets `NumDaysInterest`, Tag 157.
1751    pub fn get_num_days_interest(&self) -> Result<isize, MessageRejectErrorEnum> {
1752        let mut fld = field::NumDaysInterestField::new(0);
1753        self.message.body.get_field(tag::NUM_DAYS_INTEREST, &mut fld.0)?;
1754        Ok(fld.value())
1755    }
1756
1757
1758    /// Returns true if `NumDaysInterest` is present, Tag 157.
1759    pub fn has_num_days_interest(&self) -> bool {
1760        self.message.body.has(tag::NUM_DAYS_INTEREST)
1761    }
1762
1763
1764
1765
1766    /// Sets `OptAttribute`, Tag 206.
1767    pub fn set_opt_attribute(&mut self, v: String) {
1768        self.message.body.set_field(tag::OPT_ATTRIBUTE, FIXString::from(v));
1769    }
1770
1771    /// Gets `OptAttribute`, Tag 206.
1772    pub fn get_opt_attribute(&self) -> Result<String, MessageRejectErrorEnum> {
1773        let mut fld = field::OptAttributeField::new(String::new());
1774        self.message.body.get_field(tag::OPT_ATTRIBUTE, &mut fld.0)?;
1775        Ok(fld.value().to_string())
1776    }
1777
1778
1779    /// Returns true if `OptAttribute` is present, Tag 206.
1780    pub fn has_opt_attribute(&self) -> bool {
1781        self.message.body.has(tag::OPT_ATTRIBUTE)
1782    }
1783
1784
1785
1786
1787    /// Sets `PctAtRisk`, Tag 869.
1788    pub fn set_pct_at_risk(&mut self, val: Decimal, scale: i32) {
1789        self.message.body.set_field(tag::PCT_AT_RISK, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
1790    }
1791
1792    /// Gets `PctAtRisk`, Tag 869.
1793    pub fn get_pct_at_risk(&self) -> Result<Decimal, MessageRejectErrorEnum> {
1794        let mut fld = field::PctAtRiskField::new(Decimal::ZERO, 0);
1795        self.message.body.get_field(tag::PCT_AT_RISK, &mut fld.0)?;
1796        Ok(fld.value())
1797    }
1798
1799
1800    /// Returns true if `PctAtRisk` is present, Tag 869.
1801    pub fn has_pct_at_risk(&self) -> bool {
1802        self.message.body.has(tag::PCT_AT_RISK)
1803    }
1804
1805
1806
1807
1808    /// Sets `Pool`, Tag 691.
1809    pub fn set_pool(&mut self, v: String) {
1810        self.message.body.set_field(tag::POOL, FIXString::from(v));
1811    }
1812
1813    /// Gets `Pool`, Tag 691.
1814    pub fn get_pool(&self) -> Result<String, MessageRejectErrorEnum> {
1815        let mut fld = field::PoolField::new(String::new());
1816        self.message.body.get_field(tag::POOL, &mut fld.0)?;
1817        Ok(fld.value().to_string())
1818    }
1819
1820
1821    /// Returns true if `Pool` is present, Tag 691.
1822    pub fn has_pool(&self) -> bool {
1823        self.message.body.has(tag::POOL)
1824    }
1825
1826
1827
1828
1829    /// Sets `PositionEffect`, Tag 77.
1830    pub fn set_position_effect(&mut self, v: String) {
1831        self.message.body.set_field(tag::POSITION_EFFECT, FIXString::from(v));
1832    }
1833
1834    /// Gets `PositionEffect`, Tag 77.
1835    pub fn get_position_effect(&self) -> Result<String, MessageRejectErrorEnum> {
1836        let mut fld = field::PositionEffectField::new(String::new());
1837        self.message.body.get_field(tag::POSITION_EFFECT, &mut fld.0)?;
1838        Ok(fld.value().to_string())
1839    }
1840
1841
1842    /// Returns true if `PositionEffect` is present, Tag 77.
1843    pub fn has_position_effect(&self) -> bool {
1844        self.message.body.has(tag::POSITION_EFFECT)
1845    }
1846
1847
1848
1849
1850    /// Sets `PreviouslyReported`, Tag 570.
1851    pub fn set_previously_reported(&mut self, v: bool) {
1852        self.message.body.set_field(tag::PREVIOUSLY_REPORTED, fixer::fix_boolean::FIXBoolean::from(v));
1853    }
1854
1855    /// Gets `PreviouslyReported`, Tag 570.
1856    pub fn get_previously_reported(&self) -> Result<bool, MessageRejectErrorEnum> {
1857        let mut fld = field::PreviouslyReportedField::new(false);
1858        self.message.body.get_field(tag::PREVIOUSLY_REPORTED, &mut fld.0)?;
1859        Ok(fld.value())
1860    }
1861
1862
1863    /// Returns true if `PreviouslyReported` is present, Tag 570.
1864    pub fn has_previously_reported(&self) -> bool {
1865        self.message.body.has(tag::PREVIOUSLY_REPORTED)
1866    }
1867
1868
1869
1870
1871    /// Sets `PriceType`, Tag 423.
1872    pub fn set_price_type(&mut self, v: isize) {
1873        self.message.body.set_field(tag::PRICE_TYPE, fixer::fix_int::FIXInt::from(v));
1874    }
1875
1876    /// Gets `PriceType`, Tag 423.
1877    pub fn get_price_type(&self) -> Result<isize, MessageRejectErrorEnum> {
1878        let mut fld = field::PriceTypeField::new(0);
1879        self.message.body.get_field(tag::PRICE_TYPE, &mut fld.0)?;
1880        Ok(fld.value())
1881    }
1882
1883
1884    /// Returns true if `PriceType` is present, Tag 423.
1885    pub fn has_price_type(&self) -> bool {
1886        self.message.body.has(tag::PRICE_TYPE)
1887    }
1888
1889
1890
1891
1892    /// Sets `Product`, Tag 460.
1893    pub fn set_product(&mut self, v: isize) {
1894        self.message.body.set_field(tag::PRODUCT, fixer::fix_int::FIXInt::from(v));
1895    }
1896
1897    /// Gets `Product`, Tag 460.
1898    pub fn get_product(&self) -> Result<isize, MessageRejectErrorEnum> {
1899        let mut fld = field::ProductField::new(0);
1900        self.message.body.get_field(tag::PRODUCT, &mut fld.0)?;
1901        Ok(fld.value())
1902    }
1903
1904
1905    /// Returns true if `Product` is present, Tag 460.
1906    pub fn has_product(&self) -> bool {
1907        self.message.body.has(tag::PRODUCT)
1908    }
1909
1910
1911
1912
1913    /// Sets `QtyType`, Tag 854.
1914    pub fn set_qty_type(&mut self, v: isize) {
1915        self.message.body.set_field(tag::QTY_TYPE, fixer::fix_int::FIXInt::from(v));
1916    }
1917
1918    /// Gets `QtyType`, Tag 854.
1919    pub fn get_qty_type(&self) -> Result<isize, MessageRejectErrorEnum> {
1920        let mut fld = field::QtyTypeField::new(0);
1921        self.message.body.get_field(tag::QTY_TYPE, &mut fld.0)?;
1922        Ok(fld.value())
1923    }
1924
1925
1926    /// Returns true if `QtyType` is present, Tag 854.
1927    pub fn has_qty_type(&self) -> bool {
1928        self.message.body.has(tag::QTY_TYPE)
1929    }
1930
1931
1932
1933
1934    /// Sets `Quantity`, Tag 53.
1935    pub fn set_quantity(&mut self, val: Decimal, scale: i32) {
1936        self.message.body.set_field(tag::QUANTITY, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
1937    }
1938
1939    /// Gets `Quantity`, Tag 53.
1940    pub fn get_quantity(&self) -> Result<Decimal, MessageRejectErrorEnum> {
1941        let mut fld = field::QuantityField::new(Decimal::ZERO, 0);
1942        self.message.body.get_field(tag::QUANTITY, &mut fld.0)?;
1943        Ok(fld.value())
1944    }
1945
1946
1947    /// Returns true if `Quantity` is present, Tag 53.
1948    pub fn has_quantity(&self) -> bool {
1949        self.message.body.has(tag::QUANTITY)
1950    }
1951
1952
1953
1954
1955    /// Sets `RedemptionDate`, Tag 240.
1956    pub fn set_redemption_date(&mut self, v: String) {
1957        self.message.body.set_field(tag::REDEMPTION_DATE, FIXString::from(v));
1958    }
1959
1960    /// Gets `RedemptionDate`, Tag 240.
1961    pub fn get_redemption_date(&self) -> Result<String, MessageRejectErrorEnum> {
1962        let mut fld = field::RedemptionDateField::new(String::new());
1963        self.message.body.get_field(tag::REDEMPTION_DATE, &mut fld.0)?;
1964        Ok(fld.value().to_string())
1965    }
1966
1967
1968    /// Returns true if `RedemptionDate` is present, Tag 240.
1969    pub fn has_redemption_date(&self) -> bool {
1970        self.message.body.has(tag::REDEMPTION_DATE)
1971    }
1972
1973
1974
1975
1976    /// Sets `RefAllocID`, Tag 72.
1977    pub fn set_ref_alloc_id(&mut self, v: String) {
1978        self.message.body.set_field(tag::REF_ALLOC_ID, FIXString::from(v));
1979    }
1980
1981    /// Gets `RefAllocID`, Tag 72.
1982    pub fn get_ref_alloc_id(&self) -> Result<String, MessageRejectErrorEnum> {
1983        let mut fld = field::RefAllocIDField::new(String::new());
1984        self.message.body.get_field(tag::REF_ALLOC_ID, &mut fld.0)?;
1985        Ok(fld.value().to_string())
1986    }
1987
1988
1989    /// Returns true if `RefAllocID` is present, Tag 72.
1990    pub fn has_ref_alloc_id(&self) -> bool {
1991        self.message.body.has(tag::REF_ALLOC_ID)
1992    }
1993
1994
1995
1996
1997    /// Sets `RepoCollateralSecurityType`, Tag 239.
1998    pub fn set_repo_collateral_security_type(&mut self, v: isize) {
1999        self.message.body.set_field(tag::REPO_COLLATERAL_SECURITY_TYPE, fixer::fix_int::FIXInt::from(v));
2000    }
2001
2002    /// Gets `RepoCollateralSecurityType`, Tag 239.
2003    pub fn get_repo_collateral_security_type(&self) -> Result<isize, MessageRejectErrorEnum> {
2004        let mut fld = field::RepoCollateralSecurityTypeField::new(0);
2005        self.message.body.get_field(tag::REPO_COLLATERAL_SECURITY_TYPE, &mut fld.0)?;
2006        Ok(fld.value())
2007    }
2008
2009
2010    /// Returns true if `RepoCollateralSecurityType` is present, Tag 239.
2011    pub fn has_repo_collateral_security_type(&self) -> bool {
2012        self.message.body.has(tag::REPO_COLLATERAL_SECURITY_TYPE)
2013    }
2014
2015
2016
2017
2018    /// Sets `RepurchaseRate`, Tag 227.
2019    pub fn set_repurchase_rate(&mut self, val: Decimal, scale: i32) {
2020        self.message.body.set_field(tag::REPURCHASE_RATE, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
2021    }
2022
2023    /// Gets `RepurchaseRate`, Tag 227.
2024    pub fn get_repurchase_rate(&self) -> Result<Decimal, MessageRejectErrorEnum> {
2025        let mut fld = field::RepurchaseRateField::new(Decimal::ZERO, 0);
2026        self.message.body.get_field(tag::REPURCHASE_RATE, &mut fld.0)?;
2027        Ok(fld.value())
2028    }
2029
2030
2031    /// Returns true if `RepurchaseRate` is present, Tag 227.
2032    pub fn has_repurchase_rate(&self) -> bool {
2033        self.message.body.has(tag::REPURCHASE_RATE)
2034    }
2035
2036
2037
2038
2039    /// Sets `RepurchaseTerm`, Tag 226.
2040    pub fn set_repurchase_term(&mut self, v: isize) {
2041        self.message.body.set_field(tag::REPURCHASE_TERM, fixer::fix_int::FIXInt::from(v));
2042    }
2043
2044    /// Gets `RepurchaseTerm`, Tag 226.
2045    pub fn get_repurchase_term(&self) -> Result<isize, MessageRejectErrorEnum> {
2046        let mut fld = field::RepurchaseTermField::new(0);
2047        self.message.body.get_field(tag::REPURCHASE_TERM, &mut fld.0)?;
2048        Ok(fld.value())
2049    }
2050
2051
2052    /// Returns true if `RepurchaseTerm` is present, Tag 226.
2053    pub fn has_repurchase_term(&self) -> bool {
2054        self.message.body.has(tag::REPURCHASE_TERM)
2055    }
2056
2057
2058
2059
2060    /// Sets `ReversalIndicator`, Tag 700.
2061    pub fn set_reversal_indicator(&mut self, v: bool) {
2062        self.message.body.set_field(tag::REVERSAL_INDICATOR, fixer::fix_boolean::FIXBoolean::from(v));
2063    }
2064
2065    /// Gets `ReversalIndicator`, Tag 700.
2066    pub fn get_reversal_indicator(&self) -> Result<bool, MessageRejectErrorEnum> {
2067        let mut fld = field::ReversalIndicatorField::new(false);
2068        self.message.body.get_field(tag::REVERSAL_INDICATOR, &mut fld.0)?;
2069        Ok(fld.value())
2070    }
2071
2072
2073    /// Returns true if `ReversalIndicator` is present, Tag 700.
2074    pub fn has_reversal_indicator(&self) -> bool {
2075        self.message.body.has(tag::REVERSAL_INDICATOR)
2076    }
2077
2078
2079
2080
2081    /// Sets `SecondaryAllocID`, Tag 793.
2082    pub fn set_secondary_alloc_id(&mut self, v: String) {
2083        self.message.body.set_field(tag::SECONDARY_ALLOC_ID, FIXString::from(v));
2084    }
2085
2086    /// Gets `SecondaryAllocID`, Tag 793.
2087    pub fn get_secondary_alloc_id(&self) -> Result<String, MessageRejectErrorEnum> {
2088        let mut fld = field::SecondaryAllocIDField::new(String::new());
2089        self.message.body.get_field(tag::SECONDARY_ALLOC_ID, &mut fld.0)?;
2090        Ok(fld.value().to_string())
2091    }
2092
2093
2094    /// Returns true if `SecondaryAllocID` is present, Tag 793.
2095    pub fn has_secondary_alloc_id(&self) -> bool {
2096        self.message.body.has(tag::SECONDARY_ALLOC_ID)
2097    }
2098
2099
2100
2101
2102    /// Sets `SecurityDesc`, Tag 107.
2103    pub fn set_security_desc(&mut self, v: String) {
2104        self.message.body.set_field(tag::SECURITY_DESC, FIXString::from(v));
2105    }
2106
2107    /// Gets `SecurityDesc`, Tag 107.
2108    pub fn get_security_desc(&self) -> Result<String, MessageRejectErrorEnum> {
2109        let mut fld = field::SecurityDescField::new(String::new());
2110        self.message.body.get_field(tag::SECURITY_DESC, &mut fld.0)?;
2111        Ok(fld.value().to_string())
2112    }
2113
2114
2115    /// Returns true if `SecurityDesc` is present, Tag 107.
2116    pub fn has_security_desc(&self) -> bool {
2117        self.message.body.has(tag::SECURITY_DESC)
2118    }
2119
2120
2121
2122
2123    /// Sets `SecurityExchange`, Tag 207.
2124    pub fn set_security_exchange(&mut self, v: String) {
2125        self.message.body.set_field(tag::SECURITY_EXCHANGE, FIXString::from(v));
2126    }
2127
2128    /// Gets `SecurityExchange`, Tag 207.
2129    pub fn get_security_exchange(&self) -> Result<String, MessageRejectErrorEnum> {
2130        let mut fld = field::SecurityExchangeField::new(String::new());
2131        self.message.body.get_field(tag::SECURITY_EXCHANGE, &mut fld.0)?;
2132        Ok(fld.value().to_string())
2133    }
2134
2135
2136    /// Returns true if `SecurityExchange` is present, Tag 207.
2137    pub fn has_security_exchange(&self) -> bool {
2138        self.message.body.has(tag::SECURITY_EXCHANGE)
2139    }
2140
2141
2142
2143
2144    /// Sets `SecurityID`, Tag 48.
2145    pub fn set_security_id(&mut self, v: String) {
2146        self.message.body.set_field(tag::SECURITY_ID, FIXString::from(v));
2147    }
2148
2149    /// Gets `SecurityID`, Tag 48.
2150    pub fn get_security_id(&self) -> Result<String, MessageRejectErrorEnum> {
2151        let mut fld = field::SecurityIDField::new(String::new());
2152        self.message.body.get_field(tag::SECURITY_ID, &mut fld.0)?;
2153        Ok(fld.value().to_string())
2154    }
2155
2156
2157    /// Returns true if `SecurityID` is present, Tag 48.
2158    pub fn has_security_id(&self) -> bool {
2159        self.message.body.has(tag::SECURITY_ID)
2160    }
2161
2162
2163
2164
2165    /// Sets `SecurityIDSource`, Tag 22.
2166    pub fn set_security_id_source(&mut self, v: String) {
2167        self.message.body.set_field(tag::SECURITY_ID_SOURCE, FIXString::from(v));
2168    }
2169
2170    /// Gets `SecurityIDSource`, Tag 22.
2171    pub fn get_security_id_source(&self) -> Result<String, MessageRejectErrorEnum> {
2172        let mut fld = field::SecurityIDSourceField::new(String::new());
2173        self.message.body.get_field(tag::SECURITY_ID_SOURCE, &mut fld.0)?;
2174        Ok(fld.value().to_string())
2175    }
2176
2177
2178    /// Returns true if `SecurityIDSource` is present, Tag 22.
2179    pub fn has_security_id_source(&self) -> bool {
2180        self.message.body.has(tag::SECURITY_ID_SOURCE)
2181    }
2182
2183
2184
2185
2186    /// Sets `SecuritySubType`, Tag 762.
2187    pub fn set_security_sub_type(&mut self, v: String) {
2188        self.message.body.set_field(tag::SECURITY_SUB_TYPE, FIXString::from(v));
2189    }
2190
2191    /// Gets `SecuritySubType`, Tag 762.
2192    pub fn get_security_sub_type(&self) -> Result<String, MessageRejectErrorEnum> {
2193        let mut fld = field::SecuritySubTypeField::new(String::new());
2194        self.message.body.get_field(tag::SECURITY_SUB_TYPE, &mut fld.0)?;
2195        Ok(fld.value().to_string())
2196    }
2197
2198
2199    /// Returns true if `SecuritySubType` is present, Tag 762.
2200    pub fn has_security_sub_type(&self) -> bool {
2201        self.message.body.has(tag::SECURITY_SUB_TYPE)
2202    }
2203
2204
2205
2206
2207    /// Sets `SecurityType`, Tag 167.
2208    pub fn set_security_type(&mut self, v: String) {
2209        self.message.body.set_field(tag::SECURITY_TYPE, FIXString::from(v));
2210    }
2211
2212    /// Gets `SecurityType`, Tag 167.
2213    pub fn get_security_type(&self) -> Result<String, MessageRejectErrorEnum> {
2214        let mut fld = field::SecurityTypeField::new(String::new());
2215        self.message.body.get_field(tag::SECURITY_TYPE, &mut fld.0)?;
2216        Ok(fld.value().to_string())
2217    }
2218
2219
2220    /// Returns true if `SecurityType` is present, Tag 167.
2221    pub fn has_security_type(&self) -> bool {
2222        self.message.body.has(tag::SECURITY_TYPE)
2223    }
2224
2225
2226
2227
2228    /// Sets `SettlDate`, Tag 64.
2229    pub fn set_settl_date(&mut self, v: String) {
2230        self.message.body.set_field(tag::SETTL_DATE, FIXString::from(v));
2231    }
2232
2233    /// Gets `SettlDate`, Tag 64.
2234    pub fn get_settl_date(&self) -> Result<String, MessageRejectErrorEnum> {
2235        let mut fld = field::SettlDateField::new(String::new());
2236        self.message.body.get_field(tag::SETTL_DATE, &mut fld.0)?;
2237        Ok(fld.value().to_string())
2238    }
2239
2240
2241    /// Returns true if `SettlDate` is present, Tag 64.
2242    pub fn has_settl_date(&self) -> bool {
2243        self.message.body.has(tag::SETTL_DATE)
2244    }
2245
2246
2247
2248
2249    /// Sets `SettlType`, Tag 63.
2250    pub fn set_settl_type(&mut self, v: String) {
2251        self.message.body.set_field(tag::SETTL_TYPE, FIXString::from(v));
2252    }
2253
2254    /// Gets `SettlType`, Tag 63.
2255    pub fn get_settl_type(&self) -> Result<String, MessageRejectErrorEnum> {
2256        let mut fld = field::SettlTypeField::new(String::new());
2257        self.message.body.get_field(tag::SETTL_TYPE, &mut fld.0)?;
2258        Ok(fld.value().to_string())
2259    }
2260
2261
2262    /// Returns true if `SettlType` is present, Tag 63.
2263    pub fn has_settl_type(&self) -> bool {
2264        self.message.body.has(tag::SETTL_TYPE)
2265    }
2266
2267
2268
2269
2270    /// Sets `Side`, Tag 54.
2271    pub fn set_side(&mut self, v: String) {
2272        self.message.body.set_field(tag::SIDE, FIXString::from(v));
2273    }
2274
2275    /// Gets `Side`, Tag 54.
2276    pub fn get_side(&self) -> Result<String, MessageRejectErrorEnum> {
2277        let mut fld = field::SideField::new(String::new());
2278        self.message.body.get_field(tag::SIDE, &mut fld.0)?;
2279        Ok(fld.value().to_string())
2280    }
2281
2282
2283    /// Returns true if `Side` is present, Tag 54.
2284    pub fn has_side(&self) -> bool {
2285        self.message.body.has(tag::SIDE)
2286    }
2287
2288
2289
2290
2291    /// Sets `Spread`, Tag 218.
2292    pub fn set_spread(&mut self, val: Decimal, scale: i32) {
2293        self.message.body.set_field(tag::SPREAD, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
2294    }
2295
2296    /// Gets `Spread`, Tag 218.
2297    pub fn get_spread(&self) -> Result<Decimal, MessageRejectErrorEnum> {
2298        let mut fld = field::SpreadField::new(Decimal::ZERO, 0);
2299        self.message.body.get_field(tag::SPREAD, &mut fld.0)?;
2300        Ok(fld.value())
2301    }
2302
2303
2304    /// Returns true if `Spread` is present, Tag 218.
2305    pub fn has_spread(&self) -> bool {
2306        self.message.body.has(tag::SPREAD)
2307    }
2308
2309
2310
2311
2312    /// Sets `StartCash`, Tag 921.
2313    pub fn set_start_cash(&mut self, val: Decimal, scale: i32) {
2314        self.message.body.set_field(tag::START_CASH, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
2315    }
2316
2317    /// Gets `StartCash`, Tag 921.
2318    pub fn get_start_cash(&self) -> Result<Decimal, MessageRejectErrorEnum> {
2319        let mut fld = field::StartCashField::new(Decimal::ZERO, 0);
2320        self.message.body.get_field(tag::START_CASH, &mut fld.0)?;
2321        Ok(fld.value())
2322    }
2323
2324
2325    /// Returns true if `StartCash` is present, Tag 921.
2326    pub fn has_start_cash(&self) -> bool {
2327        self.message.body.has(tag::START_CASH)
2328    }
2329
2330
2331
2332
2333    /// Sets `StartDate`, Tag 916.
2334    pub fn set_start_date(&mut self, v: String) {
2335        self.message.body.set_field(tag::START_DATE, FIXString::from(v));
2336    }
2337
2338    /// Gets `StartDate`, Tag 916.
2339    pub fn get_start_date(&self) -> Result<String, MessageRejectErrorEnum> {
2340        let mut fld = field::StartDateField::new(String::new());
2341        self.message.body.get_field(tag::START_DATE, &mut fld.0)?;
2342        Ok(fld.value().to_string())
2343    }
2344
2345
2346    /// Returns true if `StartDate` is present, Tag 916.
2347    pub fn has_start_date(&self) -> bool {
2348        self.message.body.has(tag::START_DATE)
2349    }
2350
2351
2352
2353
2354    /// Sets `StateOrProvinceOfIssue`, Tag 471.
2355    pub fn set_state_or_province_of_issue(&mut self, v: String) {
2356        self.message.body.set_field(tag::STATE_OR_PROVINCE_OF_ISSUE, FIXString::from(v));
2357    }
2358
2359    /// Gets `StateOrProvinceOfIssue`, Tag 471.
2360    pub fn get_state_or_province_of_issue(&self) -> Result<String, MessageRejectErrorEnum> {
2361        let mut fld = field::StateOrProvinceOfIssueField::new(String::new());
2362        self.message.body.get_field(tag::STATE_OR_PROVINCE_OF_ISSUE, &mut fld.0)?;
2363        Ok(fld.value().to_string())
2364    }
2365
2366
2367    /// Returns true if `StateOrProvinceOfIssue` is present, Tag 471.
2368    pub fn has_state_or_province_of_issue(&self) -> bool {
2369        self.message.body.has(tag::STATE_OR_PROVINCE_OF_ISSUE)
2370    }
2371
2372
2373
2374
2375    /// Sets `StrikeCurrency`, Tag 947.
2376    pub fn set_strike_currency(&mut self, v: String) {
2377        self.message.body.set_field(tag::STRIKE_CURRENCY, FIXString::from(v));
2378    }
2379
2380    /// Gets `StrikeCurrency`, Tag 947.
2381    pub fn get_strike_currency(&self) -> Result<String, MessageRejectErrorEnum> {
2382        let mut fld = field::StrikeCurrencyField::new(String::new());
2383        self.message.body.get_field(tag::STRIKE_CURRENCY, &mut fld.0)?;
2384        Ok(fld.value().to_string())
2385    }
2386
2387
2388    /// Returns true if `StrikeCurrency` is present, Tag 947.
2389    pub fn has_strike_currency(&self) -> bool {
2390        self.message.body.has(tag::STRIKE_CURRENCY)
2391    }
2392
2393
2394
2395
2396    /// Sets `StrikePrice`, Tag 202.
2397    pub fn set_strike_price(&mut self, val: Decimal, scale: i32) {
2398        self.message.body.set_field(tag::STRIKE_PRICE, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
2399    }
2400
2401    /// Gets `StrikePrice`, Tag 202.
2402    pub fn get_strike_price(&self) -> Result<Decimal, MessageRejectErrorEnum> {
2403        let mut fld = field::StrikePriceField::new(Decimal::ZERO, 0);
2404        self.message.body.get_field(tag::STRIKE_PRICE, &mut fld.0)?;
2405        Ok(fld.value())
2406    }
2407
2408
2409    /// Returns true if `StrikePrice` is present, Tag 202.
2410    pub fn has_strike_price(&self) -> bool {
2411        self.message.body.has(tag::STRIKE_PRICE)
2412    }
2413
2414
2415
2416
2417    /// Sets `Symbol`, Tag 55.
2418    pub fn set_symbol(&mut self, v: String) {
2419        self.message.body.set_field(tag::SYMBOL, FIXString::from(v));
2420    }
2421
2422    /// Gets `Symbol`, Tag 55.
2423    pub fn get_symbol(&self) -> Result<String, MessageRejectErrorEnum> {
2424        let mut fld = field::SymbolField::new(String::new());
2425        self.message.body.get_field(tag::SYMBOL, &mut fld.0)?;
2426        Ok(fld.value().to_string())
2427    }
2428
2429
2430    /// Returns true if `Symbol` is present, Tag 55.
2431    pub fn has_symbol(&self) -> bool {
2432        self.message.body.has(tag::SYMBOL)
2433    }
2434
2435
2436
2437
2438    /// Sets `SymbolSfx`, Tag 65.
2439    pub fn set_symbol_sfx(&mut self, v: String) {
2440        self.message.body.set_field(tag::SYMBOL_SFX, FIXString::from(v));
2441    }
2442
2443    /// Gets `SymbolSfx`, Tag 65.
2444    pub fn get_symbol_sfx(&self) -> Result<String, MessageRejectErrorEnum> {
2445        let mut fld = field::SymbolSfxField::new(String::new());
2446        self.message.body.get_field(tag::SYMBOL_SFX, &mut fld.0)?;
2447        Ok(fld.value().to_string())
2448    }
2449
2450
2451    /// Returns true if `SymbolSfx` is present, Tag 65.
2452    pub fn has_symbol_sfx(&self) -> bool {
2453        self.message.body.has(tag::SYMBOL_SFX)
2454    }
2455
2456
2457
2458
2459    /// Sets `TerminationType`, Tag 788.
2460    pub fn set_termination_type(&mut self, v: isize) {
2461        self.message.body.set_field(tag::TERMINATION_TYPE, fixer::fix_int::FIXInt::from(v));
2462    }
2463
2464    /// Gets `TerminationType`, Tag 788.
2465    pub fn get_termination_type(&self) -> Result<isize, MessageRejectErrorEnum> {
2466        let mut fld = field::TerminationTypeField::new(0);
2467        self.message.body.get_field(tag::TERMINATION_TYPE, &mut fld.0)?;
2468        Ok(fld.value())
2469    }
2470
2471
2472    /// Returns true if `TerminationType` is present, Tag 788.
2473    pub fn has_termination_type(&self) -> bool {
2474        self.message.body.has(tag::TERMINATION_TYPE)
2475    }
2476
2477
2478
2479
2480    /// Sets `Text`, Tag 58.
2481    pub fn set_text(&mut self, v: String) {
2482        self.message.body.set_field(tag::TEXT, FIXString::from(v));
2483    }
2484
2485    /// Gets `Text`, Tag 58.
2486    pub fn get_text(&self) -> Result<String, MessageRejectErrorEnum> {
2487        let mut fld = field::TextField::new(String::new());
2488        self.message.body.get_field(tag::TEXT, &mut fld.0)?;
2489        Ok(fld.value().to_string())
2490    }
2491
2492
2493    /// Returns true if `Text` is present, Tag 58.
2494    pub fn has_text(&self) -> bool {
2495        self.message.body.has(tag::TEXT)
2496    }
2497
2498
2499
2500
2501    /// Sets `TotNoAllocs`, Tag 892.
2502    pub fn set_tot_no_allocs(&mut self, v: isize) {
2503        self.message.body.set_field(tag::TOT_NO_ALLOCS, fixer::fix_int::FIXInt::from(v));
2504    }
2505
2506    /// Gets `TotNoAllocs`, Tag 892.
2507    pub fn get_tot_no_allocs(&self) -> Result<isize, MessageRejectErrorEnum> {
2508        let mut fld = field::TotNoAllocsField::new(0);
2509        self.message.body.get_field(tag::TOT_NO_ALLOCS, &mut fld.0)?;
2510        Ok(fld.value())
2511    }
2512
2513
2514    /// Returns true if `TotNoAllocs` is present, Tag 892.
2515    pub fn has_tot_no_allocs(&self) -> bool {
2516        self.message.body.has(tag::TOT_NO_ALLOCS)
2517    }
2518
2519
2520
2521
2522    /// Sets `TotalAccruedInterestAmt`, Tag 540.
2523    pub fn set_total_accrued_interest_amt(&mut self, val: Decimal, scale: i32) {
2524        self.message.body.set_field(tag::TOTAL_ACCRUED_INTEREST_AMT, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
2525    }
2526
2527    /// Gets `TotalAccruedInterestAmt`, Tag 540.
2528    pub fn get_total_accrued_interest_amt(&self) -> Result<Decimal, MessageRejectErrorEnum> {
2529        let mut fld = field::TotalAccruedInterestAmtField::new(Decimal::ZERO, 0);
2530        self.message.body.get_field(tag::TOTAL_ACCRUED_INTEREST_AMT, &mut fld.0)?;
2531        Ok(fld.value())
2532    }
2533
2534
2535    /// Returns true if `TotalAccruedInterestAmt` is present, Tag 540.
2536    pub fn has_total_accrued_interest_amt(&self) -> bool {
2537        self.message.body.has(tag::TOTAL_ACCRUED_INTEREST_AMT)
2538    }
2539
2540
2541
2542
2543    /// Sets `TotalTakedown`, Tag 237.
2544    pub fn set_total_takedown(&mut self, val: Decimal, scale: i32) {
2545        self.message.body.set_field(tag::TOTAL_TAKEDOWN, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
2546    }
2547
2548    /// Gets `TotalTakedown`, Tag 237.
2549    pub fn get_total_takedown(&self) -> Result<Decimal, MessageRejectErrorEnum> {
2550        let mut fld = field::TotalTakedownField::new(Decimal::ZERO, 0);
2551        self.message.body.get_field(tag::TOTAL_TAKEDOWN, &mut fld.0)?;
2552        Ok(fld.value())
2553    }
2554
2555
2556    /// Returns true if `TotalTakedown` is present, Tag 237.
2557    pub fn has_total_takedown(&self) -> bool {
2558        self.message.body.has(tag::TOTAL_TAKEDOWN)
2559    }
2560
2561
2562
2563
2564    /// Sets `TradeDate`, Tag 75.
2565    pub fn set_trade_date(&mut self, v: String) {
2566        self.message.body.set_field(tag::TRADE_DATE, FIXString::from(v));
2567    }
2568
2569    /// Gets `TradeDate`, Tag 75.
2570    pub fn get_trade_date(&self) -> Result<String, MessageRejectErrorEnum> {
2571        let mut fld = field::TradeDateField::new(String::new());
2572        self.message.body.get_field(tag::TRADE_DATE, &mut fld.0)?;
2573        Ok(fld.value().to_string())
2574    }
2575
2576
2577    /// Returns true if `TradeDate` is present, Tag 75.
2578    pub fn has_trade_date(&self) -> bool {
2579        self.message.body.has(tag::TRADE_DATE)
2580    }
2581
2582
2583
2584
2585    /// Sets `TradeOriginationDate`, Tag 229.
2586    pub fn set_trade_origination_date(&mut self, v: String) {
2587        self.message.body.set_field(tag::TRADE_ORIGINATION_DATE, FIXString::from(v));
2588    }
2589
2590    /// Gets `TradeOriginationDate`, Tag 229.
2591    pub fn get_trade_origination_date(&self) -> Result<String, MessageRejectErrorEnum> {
2592        let mut fld = field::TradeOriginationDateField::new(String::new());
2593        self.message.body.get_field(tag::TRADE_ORIGINATION_DATE, &mut fld.0)?;
2594        Ok(fld.value().to_string())
2595    }
2596
2597
2598    /// Returns true if `TradeOriginationDate` is present, Tag 229.
2599    pub fn has_trade_origination_date(&self) -> bool {
2600        self.message.body.has(tag::TRADE_ORIGINATION_DATE)
2601    }
2602
2603
2604
2605
2606    /// Sets `TradingSessionID`, Tag 336.
2607    pub fn set_trading_session_id(&mut self, v: String) {
2608        self.message.body.set_field(tag::TRADING_SESSION_ID, FIXString::from(v));
2609    }
2610
2611    /// Gets `TradingSessionID`, Tag 336.
2612    pub fn get_trading_session_id(&self) -> Result<String, MessageRejectErrorEnum> {
2613        let mut fld = field::TradingSessionIDField::new(String::new());
2614        self.message.body.get_field(tag::TRADING_SESSION_ID, &mut fld.0)?;
2615        Ok(fld.value().to_string())
2616    }
2617
2618
2619    /// Returns true if `TradingSessionID` is present, Tag 336.
2620    pub fn has_trading_session_id(&self) -> bool {
2621        self.message.body.has(tag::TRADING_SESSION_ID)
2622    }
2623
2624
2625
2626
2627    /// Sets `TradingSessionSubID`, Tag 625.
2628    pub fn set_trading_session_sub_id(&mut self, v: String) {
2629        self.message.body.set_field(tag::TRADING_SESSION_SUB_ID, FIXString::from(v));
2630    }
2631
2632    /// Gets `TradingSessionSubID`, Tag 625.
2633    pub fn get_trading_session_sub_id(&self) -> Result<String, MessageRejectErrorEnum> {
2634        let mut fld = field::TradingSessionSubIDField::new(String::new());
2635        self.message.body.get_field(tag::TRADING_SESSION_SUB_ID, &mut fld.0)?;
2636        Ok(fld.value().to_string())
2637    }
2638
2639
2640    /// Returns true if `TradingSessionSubID` is present, Tag 625.
2641    pub fn has_trading_session_sub_id(&self) -> bool {
2642        self.message.body.has(tag::TRADING_SESSION_SUB_ID)
2643    }
2644
2645
2646
2647
2648    /// Sets `TransactTime`, Tag 60.
2649    pub fn set_transact_time(&mut self, v: Timestamp) {
2650        self.message.body.set_field(tag::TRANSACT_TIME, fixer::fix_utc_timestamp::FIXUTCTimestamp {
2651            time: v,
2652            precision: fixer::fix_utc_timestamp::TimestampPrecision::Millis,
2653        });
2654    }
2655
2656    /// Gets `TransactTime`, Tag 60.
2657    pub fn get_transact_time(&self) -> Result<Timestamp, MessageRejectErrorEnum> {
2658        let mut fld = field::TransactTimeField::new(Timestamp::UNIX_EPOCH);
2659        self.message.body.get_field(tag::TRANSACT_TIME, &mut fld.0)?;
2660        Ok(fld.value())
2661    }
2662
2663
2664    /// Returns true if `TransactTime` is present, Tag 60.
2665    pub fn has_transact_time(&self) -> bool {
2666        self.message.body.has(tag::TRANSACT_TIME)
2667    }
2668
2669
2670
2671
2672    /// Sets `Yield`, Tag 236.
2673    pub fn set_yield(&mut self, val: Decimal, scale: i32) {
2674        self.message.body.set_field(tag::YIELD, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
2675    }
2676
2677    /// Gets `Yield`, Tag 236.
2678    pub fn get_yield(&self) -> Result<Decimal, MessageRejectErrorEnum> {
2679        let mut fld = field::YieldField::new(Decimal::ZERO, 0);
2680        self.message.body.get_field(tag::YIELD, &mut fld.0)?;
2681        Ok(fld.value())
2682    }
2683
2684
2685    /// Returns true if `Yield` is present, Tag 236.
2686    pub fn has_yield(&self) -> bool {
2687        self.message.body.has(tag::YIELD)
2688    }
2689
2690
2691
2692
2693    /// Sets `YieldCalcDate`, Tag 701.
2694    pub fn set_yield_calc_date(&mut self, v: String) {
2695        self.message.body.set_field(tag::YIELD_CALC_DATE, FIXString::from(v));
2696    }
2697
2698    /// Gets `YieldCalcDate`, Tag 701.
2699    pub fn get_yield_calc_date(&self) -> Result<String, MessageRejectErrorEnum> {
2700        let mut fld = field::YieldCalcDateField::new(String::new());
2701        self.message.body.get_field(tag::YIELD_CALC_DATE, &mut fld.0)?;
2702        Ok(fld.value().to_string())
2703    }
2704
2705
2706    /// Returns true if `YieldCalcDate` is present, Tag 701.
2707    pub fn has_yield_calc_date(&self) -> bool {
2708        self.message.body.has(tag::YIELD_CALC_DATE)
2709    }
2710
2711
2712
2713
2714    /// Sets `YieldRedemptionDate`, Tag 696.
2715    pub fn set_yield_redemption_date(&mut self, v: String) {
2716        self.message.body.set_field(tag::YIELD_REDEMPTION_DATE, FIXString::from(v));
2717    }
2718
2719    /// Gets `YieldRedemptionDate`, Tag 696.
2720    pub fn get_yield_redemption_date(&self) -> Result<String, MessageRejectErrorEnum> {
2721        let mut fld = field::YieldRedemptionDateField::new(String::new());
2722        self.message.body.get_field(tag::YIELD_REDEMPTION_DATE, &mut fld.0)?;
2723        Ok(fld.value().to_string())
2724    }
2725
2726
2727    /// Returns true if `YieldRedemptionDate` is present, Tag 696.
2728    pub fn has_yield_redemption_date(&self) -> bool {
2729        self.message.body.has(tag::YIELD_REDEMPTION_DATE)
2730    }
2731
2732
2733
2734
2735    /// Sets `YieldRedemptionPrice`, Tag 697.
2736    pub fn set_yield_redemption_price(&mut self, val: Decimal, scale: i32) {
2737        self.message.body.set_field(tag::YIELD_REDEMPTION_PRICE, fixer::fix_decimal::FIXDecimal { decimal: val, scale });
2738    }
2739
2740    /// Gets `YieldRedemptionPrice`, Tag 697.
2741    pub fn get_yield_redemption_price(&self) -> Result<Decimal, MessageRejectErrorEnum> {
2742        let mut fld = field::YieldRedemptionPriceField::new(Decimal::ZERO, 0);
2743        self.message.body.get_field(tag::YIELD_REDEMPTION_PRICE, &mut fld.0)?;
2744        Ok(fld.value())
2745    }
2746
2747
2748    /// Returns true if `YieldRedemptionPrice` is present, Tag 697.
2749    pub fn has_yield_redemption_price(&self) -> bool {
2750        self.message.body.has(tag::YIELD_REDEMPTION_PRICE)
2751    }
2752
2753
2754
2755
2756    /// Sets `YieldRedemptionPriceType`, Tag 698.
2757    pub fn set_yield_redemption_price_type(&mut self, v: isize) {
2758        self.message.body.set_field(tag::YIELD_REDEMPTION_PRICE_TYPE, fixer::fix_int::FIXInt::from(v));
2759    }
2760
2761    /// Gets `YieldRedemptionPriceType`, Tag 698.
2762    pub fn get_yield_redemption_price_type(&self) -> Result<isize, MessageRejectErrorEnum> {
2763        let mut fld = field::YieldRedemptionPriceTypeField::new(0);
2764        self.message.body.get_field(tag::YIELD_REDEMPTION_PRICE_TYPE, &mut fld.0)?;
2765        Ok(fld.value())
2766    }
2767
2768
2769    /// Returns true if `YieldRedemptionPriceType` is present, Tag 698.
2770    pub fn has_yield_redemption_price_type(&self) -> bool {
2771        self.message.body.has(tag::YIELD_REDEMPTION_PRICE_TYPE)
2772    }
2773
2774
2775
2776
2777    /// Sets `YieldType`, Tag 235.
2778    pub fn set_yield_type(&mut self, v: String) {
2779        self.message.body.set_field(tag::YIELD_TYPE, FIXString::from(v));
2780    }
2781
2782    /// Gets `YieldType`, Tag 235.
2783    pub fn get_yield_type(&self) -> Result<String, MessageRejectErrorEnum> {
2784        let mut fld = field::YieldTypeField::new(String::new());
2785        self.message.body.get_field(tag::YIELD_TYPE, &mut fld.0)?;
2786        Ok(fld.value().to_string())
2787    }
2788
2789
2790    /// Returns true if `YieldType` is present, Tag 235.
2791    pub fn has_yield_type(&self) -> bool {
2792        self.message.body.has(tag::YIELD_TYPE)
2793    }
2794
2795
2796}
2797
2798/// `RouteOut` is the callback type for routing `AllocationReport` messages.
2799pub type RouteOut = fn(msg: AllocationReport, session_id: SessionID) -> Result<(), MessageRejectErrorEnum>;
2800
2801/// Route type returned by the `route` function.
2802pub type Route = (&'static str, &'static str, Box<dyn Fn(&Message, SessionID) -> Result<(), MessageRejectErrorEnum> + Send>);
2803
2804/// Returns the begin string, message type, and route function for `AllocationReport`.
2805pub fn route(router: RouteOut) -> Route {
2806    let r = move |msg: &Message, session_id: SessionID| -> Result<(), MessageRejectErrorEnum> {
2807        router(AllocationReport::from_message(msg.clone()), session_id)
2808    };
2809    ("FIX.4.4", "AS", Box::new(r))
2810}