// Auto-generated PLCopen types from TC6 XML schema
// DO NOT EDIT - Generated by build script

use serde::{Serialize, Deserialize};

#[path = "generated_sfc.rs"]
mod sfc;
#[path = "generated_variables.rs"]
mod variables;
#[path = "generated_body.rs"]
mod body;
#[path = "generated_config.rs"]
mod config;
#[path = "generated_misc.rs"]
mod misc;
#[path = "generated_ladder.rs"]
mod ladder;
#[path = "generated_fbd.rs"]
mod fbd;
#[path = "generated_datatypes.rs"]
mod datatypes;
#[path = "generated_inline.rs"]
mod inline;
#[path = "generated_pou.rs"]
mod pou;
#[path = "generated_graphics.rs"]
mod graphics;
#[path = "generated_addons.rs"]
mod addons;
pub use self::{
    sfc::*,
    variables::*,
    body::*,
    config::*,
    misc::*,
    ladder::*,
    fbd::*,
    datatypes::*,
    inline::*,
    pou::*,
    graphics::*,
    addons::*
};

/// Placeholder for xs:any wildcard elements
/// quick-xml cannot deserialize dynamic element names, so these are skipped
#[derive(Debug, Clone, Default, PartialEq, Serialize, Deserialize)]
pub struct AnyElement;

/// elementaryTypes choice group
#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
pub enum ElementaryTypes {
    BOOL(String),
    BYTE(String),
    WORD(String),
    DWORD(String),
    LWORD(String),
    SINT(String),
    INT(String),
    DINT(String),
    LINT(String),
    USINT(String),
    UINT(String),
    UDINT(String),
    ULINT(String),
    REAL(String),
    LREAL(String),
    TIME(String),
    DATE(String),
    DT(String),
    TOD(String),
    String(ElementaryTypes_string_Inline),
    Wstring(ElementaryTypes_wstring_Inline),
    ANY(String),
    ANY_DERIVED(String),
    ANY_ELEMENTARY(String),
    ANY_MAGNITUDE(String),
    ANY_NUM(String),
    ANY_REAL(String),
    ANY_INT(String),
    ANY_BIT(String),
    ANY_STRING(String),
    ANY_DATE(String),
}

/// derivedTypes choice group
#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
pub enum DerivedTypes {
    Array(DerivedTypes_array_Inline),
    Derived(DerivedTypes_derived_Inline),
    #[serde(rename = "enum")]
    Enumeration(DerivedTypes_enum_Inline),
    #[serde(rename = "struct")]
    Structure(VarListPlain),
    SubrangeSigned(DerivedTypes_subrangeSigned_Inline),
    SubrangeUnsigned(DerivedTypes_subrangeUnsigned_Inline),
}

/// extended choice group
#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
pub enum Extended {
    Pointer(Extended_pointer_Inline),
}

/// commonObjects choice group
#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
pub enum CommonObjects {
    Comment(CommonObjects_comment_Inline),
    Error(CommonObjects_error_Inline),
    Connector(CommonObjects_connector_Inline),
    Continuation(CommonObjects_continuation_Inline),
    ActionBlock(CommonObjects_actionBlock_Inline),
    VendorElement(CommonObjects_vendorElement_Inline),
}

/// fbdObjects choice group
#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
pub enum FbdObjects {
    Block(FbdObjects_block_Inline),
    InVariable(FbdObjects_inVariable_Inline),
    OutVariable(FbdObjects_outVariable_Inline),
    InOutVariable(FbdObjects_inOutVariable_Inline),
    Label(FbdObjects_label_Inline),
    Jump(FbdObjects_jump_Inline),
    #[serde(rename = "return")]
    Return(FbdObjects_return_Inline),
}

/// ldObjects choice group
#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
pub enum LdObjects {
    LeftPowerRail(LdObjects_leftPowerRail_Inline),
    RightPowerRail(LdObjects_rightPowerRail_Inline),
    Coil(LdObjects_coil_Inline),
    Contact(LdObjects_contact_Inline),
}

/// sfcObjects choice group
#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
pub enum SfcObjects {
    Step(SfcObjects_step_Inline),
    MacroStep(SfcObjects_macroStep_Inline),
    JumpStep(SfcObjects_jumpStep_Inline),
    Transition(SfcObjects_transition_Inline),
    SelectionDivergence(SfcObjects_selectionDivergence_Inline),
    SelectionConvergence(SfcObjects_selectionConvergence_Inline),
    SimultaneousDivergence(SfcObjects_simultaneousDivergence_Inline),
    SimultaneousConvergence(SfcObjects_simultaneousConvergence_Inline),
}

