Skip to main content

cimstructs/
ExcSK.rs

1/// Slovakian excitation system. UEL and secondary voltage control are included in this model. When this model is used, there cannot be a separate underexcitation limiter or VAr controller model.
2#[derive(Debug, Default, Clone, serde::Serialize, serde::Deserialize)]
3pub struct ExcSK {
4    #[serde(flatten)]
5    pub base: super::ExcitationSystemDynamics,
6    /// Field voltage clipping upper level limit (Efdmax) (> ExcSK.efdmin).
7    #[serde(skip_serializing_if = "Option::is_none")]
8    pub efdmax: Option<f64>,
9    /// Field voltage clipping lower level limit (Efdmin) (< ExcSK.efdmax).
10    #[serde(skip_serializing_if = "Option::is_none")]
11    pub efdmin: Option<f64>,
12    /// Maximum field voltage output (Emax) (> ExcSK.emin). Typical value = 20.
13    #[serde(skip_serializing_if = "Option::is_none")]
14    pub emax: Option<f64>,
15    /// Minimum field voltage output (Emin) (< ExcSK.emax). Typical value = -20.
16    #[serde(skip_serializing_if = "Option::is_none")]
17    pub emin: Option<f64>,
18    /// Gain (K). Typical value = 1.
19    #[serde(skip_serializing_if = "Option::is_none")]
20    pub k: Option<f64>,
21    /// Parameter of underexcitation limit (K1). Typical value = 0,1364.
22    #[serde(skip_serializing_if = "Option::is_none")]
23    pub k1: Option<f64>,
24    /// Parameter of underexcitation limit (K2). Typical value = -0,3861.
25    #[serde(skip_serializing_if = "Option::is_none")]
26    pub k2: Option<f64>,
27    /// PI controller gain (Kc). Typical value = 70.
28    #[serde(skip_serializing_if = "Option::is_none")]
29    pub kc: Option<f64>,
30    /// Rectifier regulation factor (Kce). Typical value = 0.
31    #[serde(skip_serializing_if = "Option::is_none")]
32    pub kce: Option<f64>,
33    /// Exciter internal reactance (Kd). Typical value = 0.
34    #[serde(skip_serializing_if = "Option::is_none")]
35    pub kd: Option<f64>,
36    /// P controller gain (Kgob). Typical value = 10.
37    #[serde(skip_serializing_if = "Option::is_none")]
38    pub kgob: Option<f64>,
39    /// PI controller gain (Kp). Typical value = 1.
40    #[serde(skip_serializing_if = "Option::is_none")]
41    pub kp: Option<f64>,
42    /// PI controller gain of integral component (Kqi). Typical value = 0.
43    #[serde(skip_serializing_if = "Option::is_none")]
44    pub kqi: Option<f64>,
45    /// Rate of rise of the reactive power (Kqob).
46    #[serde(skip_serializing_if = "Option::is_none")]
47    pub kqob: Option<f64>,
48    /// PI controller gain (Kqp). Typical value = 0.
49    #[serde(skip_serializing_if = "Option::is_none")]
50    pub kqp: Option<f64>,
51    /// Deadband of reactive power (nq). Determines the range of sensitivity. Typical value = 0,001.
52    #[serde(skip_serializing_if = "Option::is_none")]
53    pub nq: Option<f64>,
54    /// Secondary voltage control state (Qc_on_off). true = secondary voltage control is on false = secondary voltage control is off. Typical value = false.
55    #[serde(skip_serializing_if = "Option::is_none")]
56    pub qconoff: Option<bool>,
57    /// Desired value (setpoint) of reactive power, manual setting (Qz).
58    #[serde(skip_serializing_if = "Option::is_none")]
59    pub qz: Option<f64>,
60    /// Selector to apply automatic calculation in secondary controller model (remote). true = automatic calculation is activated false = manual set is active; the use of desired value of reactive power (Qz) is required. Typical value = true.
61    #[serde(skip_serializing_if = "Option::is_none")]
62    pub remote: Option<bool>,
63    /// Apparent power of the unit (Sbase) (> 0). Unit = MVA. Typical value = 259.
64    #[serde(skip_serializing_if = "Option::is_none")]
65    pub sbase: Option<f64>,
66    /// PI controller phase lead time constant (Tc) (>= 0). Typical value = 8.
67    #[serde(skip_serializing_if = "Option::is_none")]
68    pub tc: Option<f64>,
69    /// Time constant of gain block (Te) (>= 0). Typical value = 0,1.
70    #[serde(skip_serializing_if = "Option::is_none")]
71    pub te: Option<f64>,
72    /// PI controller phase lead time constant (Ti) (>= 0). Typical value = 2.
73    #[serde(skip_serializing_if = "Option::is_none")]
74    pub ti: Option<f64>,
75    /// Time constant (Tp) (>= 0). Typical value = 0,1.
76    #[serde(skip_serializing_if = "Option::is_none")]
77    pub tp: Option<f64>,
78    /// Voltage transducer time constant (Tr) (>= 0). Typical value = 0,01.
79    #[serde(skip_serializing_if = "Option::is_none")]
80    pub tr: Option<f64>,
81    /// Maximum error (UImax) (> ExcSK.uimin). Typical value = 10.
82    #[serde(skip_serializing_if = "Option::is_none")]
83    pub uimax: Option<f64>,
84    /// Minimum error (UImin) (< ExcSK.uimax). Typical value = -10.
85    #[serde(skip_serializing_if = "Option::is_none")]
86    pub uimin: Option<f64>,
87    /// Maximum controller output (URmax) (> ExcSK.urmin). Typical value = 10.
88    #[serde(skip_serializing_if = "Option::is_none")]
89    pub urmax: Option<f64>,
90    /// Minimum controller output (URmin) (< ExcSK.urmax). Typical value = -10.
91    #[serde(skip_serializing_if = "Option::is_none")]
92    pub urmin: Option<f64>,
93    /// Maximum terminal voltage input (Vtmax) (> ExcSK.vtmin). Determines the range of voltage deadband. Typical value = 1,05.
94    #[serde(skip_serializing_if = "Option::is_none")]
95    pub vtmax: Option<f64>,
96    /// Minimum terminal voltage input (Vtmin) (< ExcSK.vtmax). Determines the range of voltage deadband. Typical value = 0,95.
97    #[serde(skip_serializing_if = "Option::is_none")]
98    pub vtmin: Option<f64>,
99    /// Maximum output (Yp). Typical value = 1.
100    #[serde(skip_serializing_if = "Option::is_none")]
101    pub yp: Option<f64>,
102}
103impl crate::base::CimElement for ExcSK {
104    fn mrid(&self) -> &str { &self.base.base.base.id }
105    fn type_name(&self) -> &'static str { "ExcSK" }
106    fn as_any(&self) -> &dyn std::any::Any { self }
107    fn to_json_value(&self) -> serde_json::Value {
108        serde_json::to_value(self).unwrap_or(serde_json::Value::Null)
109    }
110    fn to_block(&self) -> crate::base::RdfBlock {
111        let mut block = self.base.to_block();
112        block.type_name = "ExcSK".to_string();
113        if let Some(v) = self.efdmax {
114            block.fields.insert("ExcSK.efdmax".into(), crate::base::FieldValue::Text(v.to_string()));
115        }
116        if let Some(v) = self.efdmin {
117            block.fields.insert("ExcSK.efdmin".into(), crate::base::FieldValue::Text(v.to_string()));
118        }
119        if let Some(v) = self.emax {
120            block.fields.insert("ExcSK.emax".into(), crate::base::FieldValue::Text(v.to_string()));
121        }
122        if let Some(v) = self.emin {
123            block.fields.insert("ExcSK.emin".into(), crate::base::FieldValue::Text(v.to_string()));
124        }
125        if let Some(v) = self.k {
126            block.fields.insert("ExcSK.k".into(), crate::base::FieldValue::Text(v.to_string()));
127        }
128        if let Some(v) = self.k1 {
129            block.fields.insert("ExcSK.k1".into(), crate::base::FieldValue::Text(v.to_string()));
130        }
131        if let Some(v) = self.k2 {
132            block.fields.insert("ExcSK.k2".into(), crate::base::FieldValue::Text(v.to_string()));
133        }
134        if let Some(v) = self.kc {
135            block.fields.insert("ExcSK.kc".into(), crate::base::FieldValue::Text(v.to_string()));
136        }
137        if let Some(v) = self.kce {
138            block.fields.insert("ExcSK.kce".into(), crate::base::FieldValue::Text(v.to_string()));
139        }
140        if let Some(v) = self.kd {
141            block.fields.insert("ExcSK.kd".into(), crate::base::FieldValue::Text(v.to_string()));
142        }
143        if let Some(v) = self.kgob {
144            block.fields.insert("ExcSK.kgob".into(), crate::base::FieldValue::Text(v.to_string()));
145        }
146        if let Some(v) = self.kp {
147            block.fields.insert("ExcSK.kp".into(), crate::base::FieldValue::Text(v.to_string()));
148        }
149        if let Some(v) = self.kqi {
150            block.fields.insert("ExcSK.kqi".into(), crate::base::FieldValue::Text(v.to_string()));
151        }
152        if let Some(v) = self.kqob {
153            block.fields.insert("ExcSK.kqob".into(), crate::base::FieldValue::Text(v.to_string()));
154        }
155        if let Some(v) = self.kqp {
156            block.fields.insert("ExcSK.kqp".into(), crate::base::FieldValue::Text(v.to_string()));
157        }
158        if let Some(v) = self.nq {
159            block.fields.insert("ExcSK.nq".into(), crate::base::FieldValue::Text(v.to_string()));
160        }
161        if let Some(v) = self.qconoff {
162            block.fields.insert("ExcSK.qconoff".into(), crate::base::FieldValue::Text(v.to_string()));
163        }
164        if let Some(v) = self.qz {
165            block.fields.insert("ExcSK.qz".into(), crate::base::FieldValue::Text(v.to_string()));
166        }
167        if let Some(v) = self.remote {
168            block.fields.insert("ExcSK.remote".into(), crate::base::FieldValue::Text(v.to_string()));
169        }
170        if let Some(v) = self.sbase {
171            block.fields.insert("ExcSK.sbase".into(), crate::base::FieldValue::Text(v.to_string()));
172        }
173        if let Some(v) = self.tc {
174            block.fields.insert("ExcSK.tc".into(), crate::base::FieldValue::Text(v.to_string()));
175        }
176        if let Some(v) = self.te {
177            block.fields.insert("ExcSK.te".into(), crate::base::FieldValue::Text(v.to_string()));
178        }
179        if let Some(v) = self.ti {
180            block.fields.insert("ExcSK.ti".into(), crate::base::FieldValue::Text(v.to_string()));
181        }
182        if let Some(v) = self.tp {
183            block.fields.insert("ExcSK.tp".into(), crate::base::FieldValue::Text(v.to_string()));
184        }
185        if let Some(v) = self.tr {
186            block.fields.insert("ExcSK.tr".into(), crate::base::FieldValue::Text(v.to_string()));
187        }
188        if let Some(v) = self.uimax {
189            block.fields.insert("ExcSK.uimax".into(), crate::base::FieldValue::Text(v.to_string()));
190        }
191        if let Some(v) = self.uimin {
192            block.fields.insert("ExcSK.uimin".into(), crate::base::FieldValue::Text(v.to_string()));
193        }
194        if let Some(v) = self.urmax {
195            block.fields.insert("ExcSK.urmax".into(), crate::base::FieldValue::Text(v.to_string()));
196        }
197        if let Some(v) = self.urmin {
198            block.fields.insert("ExcSK.urmin".into(), crate::base::FieldValue::Text(v.to_string()));
199        }
200        if let Some(v) = self.vtmax {
201            block.fields.insert("ExcSK.vtmax".into(), crate::base::FieldValue::Text(v.to_string()));
202        }
203        if let Some(v) = self.vtmin {
204            block.fields.insert("ExcSK.vtmin".into(), crate::base::FieldValue::Text(v.to_string()));
205        }
206        if let Some(v) = self.yp {
207            block.fields.insert("ExcSK.yp".into(), crate::base::FieldValue::Text(v.to_string()));
208        }
209        block
210    }
211}
212
213impl ExcSK {
214    pub fn from_block(b: &crate::base::RdfBlock) -> Self {
215        let mut obj = Self::default();
216        obj.base.base.base.id.clone_from(&b.mrid);
217        for (key, val) in &b.fields {
218            match key.as_str() {
219                "ExcSK.efdmax" => {
220                    match val {
221                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.efdmax = Some(v); } }
222                        crate::base::FieldValue::TextList(svs) => {
223                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.efdmax = Some(v); } }
224                        }
225                        _ => {}
226                    }
227                }
228                "ExcSK.efdmin" => {
229                    match val {
230                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.efdmin = Some(v); } }
231                        crate::base::FieldValue::TextList(svs) => {
232                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.efdmin = Some(v); } }
233                        }
234                        _ => {}
235                    }
236                }
237                "ExcSK.emax" => {
238                    match val {
239                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.emax = Some(v); } }
240                        crate::base::FieldValue::TextList(svs) => {
241                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.emax = Some(v); } }
242                        }
243                        _ => {}
244                    }
245                }
246                "ExcSK.emin" => {
247                    match val {
248                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.emin = Some(v); } }
249                        crate::base::FieldValue::TextList(svs) => {
250                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.emin = Some(v); } }
251                        }
252                        _ => {}
253                    }
254                }
255                "ExcSK.k" => {
256                    match val {
257                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.k = Some(v); } }
258                        crate::base::FieldValue::TextList(svs) => {
259                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.k = Some(v); } }
260                        }
261                        _ => {}
262                    }
263                }
264                "ExcSK.k1" => {
265                    match val {
266                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.k1 = Some(v); } }
267                        crate::base::FieldValue::TextList(svs) => {
268                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.k1 = Some(v); } }
269                        }
270                        _ => {}
271                    }
272                }
273                "ExcSK.k2" => {
274                    match val {
275                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.k2 = Some(v); } }
276                        crate::base::FieldValue::TextList(svs) => {
277                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.k2 = Some(v); } }
278                        }
279                        _ => {}
280                    }
281                }
282                "ExcSK.kc" => {
283                    match val {
284                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.kc = Some(v); } }
285                        crate::base::FieldValue::TextList(svs) => {
286                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.kc = Some(v); } }
287                        }
288                        _ => {}
289                    }
290                }
291                "ExcSK.kce" => {
292                    match val {
293                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.kce = Some(v); } }
294                        crate::base::FieldValue::TextList(svs) => {
295                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.kce = Some(v); } }
296                        }
297                        _ => {}
298                    }
299                }
300                "ExcSK.kd" => {
301                    match val {
302                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.kd = Some(v); } }
303                        crate::base::FieldValue::TextList(svs) => {
304                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.kd = Some(v); } }
305                        }
306                        _ => {}
307                    }
308                }
309                "ExcSK.kgob" => {
310                    match val {
311                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.kgob = Some(v); } }
312                        crate::base::FieldValue::TextList(svs) => {
313                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.kgob = Some(v); } }
314                        }
315                        _ => {}
316                    }
317                }
318                "ExcSK.kp" => {
319                    match val {
320                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.kp = Some(v); } }
321                        crate::base::FieldValue::TextList(svs) => {
322                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.kp = Some(v); } }
323                        }
324                        _ => {}
325                    }
326                }
327                "ExcSK.kqi" => {
328                    match val {
329                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.kqi = Some(v); } }
330                        crate::base::FieldValue::TextList(svs) => {
331                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.kqi = Some(v); } }
332                        }
333                        _ => {}
334                    }
335                }
336                "ExcSK.kqob" => {
337                    match val {
338                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.kqob = Some(v); } }
339                        crate::base::FieldValue::TextList(svs) => {
340                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.kqob = Some(v); } }
341                        }
342                        _ => {}
343                    }
344                }
345                "ExcSK.kqp" => {
346                    match val {
347                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.kqp = Some(v); } }
348                        crate::base::FieldValue::TextList(svs) => {
349                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.kqp = Some(v); } }
350                        }
351                        _ => {}
352                    }
353                }
354                "ExcSK.nq" => {
355                    match val {
356                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.nq = Some(v); } }
357                        crate::base::FieldValue::TextList(svs) => {
358                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.nq = Some(v); } }
359                        }
360                        _ => {}
361                    }
362                }
363                "ExcSK.qconoff" => {
364                    match val {
365                        crate::base::FieldValue::Text(sv) => { obj.qconoff = Some(sv.trim() == "true"); }
366                        crate::base::FieldValue::TextList(svs) => {
367                            if let Some(sv) = svs.last() { obj.qconoff = Some(sv.trim() == "true"); }
368                        }
369                        _ => {}
370                    }
371                }
372                "ExcSK.qz" => {
373                    match val {
374                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.qz = Some(v); } }
375                        crate::base::FieldValue::TextList(svs) => {
376                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.qz = Some(v); } }
377                        }
378                        _ => {}
379                    }
380                }
381                "ExcSK.remote" => {
382                    match val {
383                        crate::base::FieldValue::Text(sv) => { obj.remote = Some(sv.trim() == "true"); }
384                        crate::base::FieldValue::TextList(svs) => {
385                            if let Some(sv) = svs.last() { obj.remote = Some(sv.trim() == "true"); }
386                        }
387                        _ => {}
388                    }
389                }
390                "ExcSK.sbase" => {
391                    match val {
392                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.sbase = Some(v); } }
393                        crate::base::FieldValue::TextList(svs) => {
394                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.sbase = Some(v); } }
395                        }
396                        _ => {}
397                    }
398                }
399                "ExcSK.tc" => {
400                    match val {
401                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.tc = Some(v); } }
402                        crate::base::FieldValue::TextList(svs) => {
403                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.tc = Some(v); } }
404                        }
405                        _ => {}
406                    }
407                }
408                "ExcSK.te" => {
409                    match val {
410                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.te = Some(v); } }
411                        crate::base::FieldValue::TextList(svs) => {
412                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.te = Some(v); } }
413                        }
414                        _ => {}
415                    }
416                }
417                "ExcSK.ti" => {
418                    match val {
419                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.ti = Some(v); } }
420                        crate::base::FieldValue::TextList(svs) => {
421                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.ti = Some(v); } }
422                        }
423                        _ => {}
424                    }
425                }
426                "ExcSK.tp" => {
427                    match val {
428                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.tp = Some(v); } }
429                        crate::base::FieldValue::TextList(svs) => {
430                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.tp = Some(v); } }
431                        }
432                        _ => {}
433                    }
434                }
435                "ExcSK.tr" => {
436                    match val {
437                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.tr = Some(v); } }
438                        crate::base::FieldValue::TextList(svs) => {
439                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.tr = Some(v); } }
440                        }
441                        _ => {}
442                    }
443                }
444                "ExcSK.uimax" => {
445                    match val {
446                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.uimax = Some(v); } }
447                        crate::base::FieldValue::TextList(svs) => {
448                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.uimax = Some(v); } }
449                        }
450                        _ => {}
451                    }
452                }
453                "ExcSK.uimin" => {
454                    match val {
455                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.uimin = Some(v); } }
456                        crate::base::FieldValue::TextList(svs) => {
457                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.uimin = Some(v); } }
458                        }
459                        _ => {}
460                    }
461                }
462                "ExcSK.urmax" => {
463                    match val {
464                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.urmax = Some(v); } }
465                        crate::base::FieldValue::TextList(svs) => {
466                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.urmax = Some(v); } }
467                        }
468                        _ => {}
469                    }
470                }
471                "ExcSK.urmin" => {
472                    match val {
473                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.urmin = Some(v); } }
474                        crate::base::FieldValue::TextList(svs) => {
475                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.urmin = Some(v); } }
476                        }
477                        _ => {}
478                    }
479                }
480                "ExcSK.vtmax" => {
481                    match val {
482                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.vtmax = Some(v); } }
483                        crate::base::FieldValue::TextList(svs) => {
484                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.vtmax = Some(v); } }
485                        }
486                        _ => {}
487                    }
488                }
489                "ExcSK.vtmin" => {
490                    match val {
491                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.vtmin = Some(v); } }
492                        crate::base::FieldValue::TextList(svs) => {
493                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.vtmin = Some(v); } }
494                        }
495                        _ => {}
496                    }
497                }
498                "ExcSK.yp" => {
499                    match val {
500                        crate::base::FieldValue::Text(sv) => { if let Ok(v) = sv.trim().parse() { obj.yp = Some(v); } }
501                        crate::base::FieldValue::TextList(svs) => {
502                            if let Some(sv) = svs.last() { if let Ok(v) = sv.trim().parse() { obj.yp = Some(v); } }
503                        }
504                        _ => {}
505                    }
506                }
507                "ExcitationSystemDynamics.SynchronousMachineDynamics" => {
508                    if let crate::base::FieldValue::Resource(sv) = val {
509                        obj.base.synchronous_machine_dynamics = Some(crate::base::MridRef { mrid: sv.clone() });
510                    }
511                }
512                "DynamicsFunctionBlock.enabled" => {
513                    match val {
514                        crate::base::FieldValue::Text(sv) => { obj.base.base.enabled = Some(sv.trim() == "true"); }
515                        crate::base::FieldValue::TextList(svs) => {
516                            if let Some(sv) = svs.last() { obj.base.base.enabled = Some(sv.trim() == "true"); }
517                        }
518                        _ => {}
519                    }
520                }
521                "IdentifiedObject.description" => {
522                    match val {
523                        crate::base::FieldValue::Text(sv) => { obj.base.base.base.description = sv.clone(); }
524                        crate::base::FieldValue::TextList(svs) => {
525                            if let Some(sv) = svs.last() { obj.base.base.base.description = sv.clone(); }
526                        }
527                        _ => {}
528                    }
529                }
530                "IdentifiedObject.energyIdentCodeEic" => {
531                    match val {
532                        crate::base::FieldValue::Text(sv) => { obj.base.base.base.energy_ident_code_eic = sv.clone(); }
533                        crate::base::FieldValue::TextList(svs) => {
534                            if let Some(sv) = svs.last() { obj.base.base.base.energy_ident_code_eic = sv.clone(); }
535                        }
536                        _ => {}
537                    }
538                }
539                "IdentifiedObject.mRID" => {
540                    match val {
541                        crate::base::FieldValue::Text(sv) => { obj.base.base.base.m_rid = sv.clone(); }
542                        crate::base::FieldValue::TextList(svs) => {
543                            if let Some(sv) = svs.last() { obj.base.base.base.m_rid = sv.clone(); }
544                        }
545                        _ => {}
546                    }
547                }
548                "IdentifiedObject.name" => {
549                    match val {
550                        crate::base::FieldValue::Text(sv) => { obj.base.base.base.name = sv.clone(); }
551                        crate::base::FieldValue::TextList(svs) => {
552                            if let Some(sv) = svs.last() { obj.base.base.base.name = sv.clone(); }
553                        }
554                        _ => {}
555                    }
556                }
557                "IdentifiedObject.shortName" => {
558                    match val {
559                        crate::base::FieldValue::Text(sv) => { obj.base.base.base.short_name = sv.clone(); }
560                        crate::base::FieldValue::TextList(svs) => {
561                            if let Some(sv) = svs.last() { obj.base.base.base.short_name = sv.clone(); }
562                        }
563                        _ => {}
564                    }
565                }
566                _ => {}
567            }
568        }
569        obj
570    }
571}