#ifndef  TYPE_SDAIOBSERVED_CONTEXT_H
#define  TYPE_SDAIOBSERVED_CONTEXT_H

// This file was generated by exp2cxx,
// 0.8.1.
// You probably don't want to edit it since your modifications
// will be lost if exp2cxx is used to regenerate it.


//////////  SELECT TYPE SdaiObserved_context
class SC_SCHEMA_EXPORT SdaiObserved_context  :  public SDAI_Select {
  protected:
    //  types in SELECT 
    //   ACTIVITY    --  sdaiINSTANCE
    //   ACTIVITY_METHOD    --  sdaiINSTANCE
    //   APPLIED_ACTIVITY_ASSIGNMENT    --  sdaiINSTANCE
    //   ATTACHMENT_SLOT    --  sdaiINSTANCE
    //   ATTACHMENT_SLOT_DEFINITION    --  sdaiINSTANCE
    //   ATTACHMENT_SLOT_VERSION    --  sdaiINSTANCE
    //   BREAKDOWN    --  sdaiINSTANCE
    //   BREAKDOWN_ELEMENT    --  sdaiINSTANCE
    //   BREAKDOWN_ELEMENT_DEFINITION    --  sdaiINSTANCE
    //   BREAKDOWN_VERSION    --  sdaiINSTANCE
    //   INTERFACE_CONNECTOR_OCCURRENCE    --  sdaiINSTANCE
    //   PRODUCT    --  sdaiINSTANCE
    //   PRODUCT_GROUP    --  sdaiINSTANCE
    //   PRODUCT_VERSION    --  sdaiINSTANCE
    //   PRODUCT_VIEW_DEFINITION    --  sdaiINSTANCE
    //   REQUIRED_RESOURCE    --  sdaiINSTANCE
    //   RESOURCE_AS_REALIZED    --  sdaiINSTANCE
    //   RESOURCE_ITEM    --  sdaiINSTANCE
    //   SCHEME    --  sdaiINSTANCE
    //   SCHEME_ENTRY    --  sdaiINSTANCE
    //   SCHEME_VERSION    --  sdaiINSTANCE
    //   TASK_ELEMENT    --  sdaiINSTANCE
    //   TASK_METHOD    --  sdaiINSTANCE
    //   TASK_METHOD_VERSION    --  sdaiINSTANCE
    //   VIEW_DEFINITION_RELATIONSHIP    --  sdaiINSTANCE
    //   WORK_ORDER    --  sdaiINSTANCE
    //   WORK_OUTPUT    --  sdaiINSTANCE
    //   WORK_REQUEST    --  sdaiINSTANCE
       SDAI_Application_instance_ptr _app_inst;

  public:
    virtual const TypeDescriptor * AssignEntity (SDAI_Application_instance * se);
    virtual SDAI_Select * NewSelect ();

    virtual BASE_TYPE ValueType() const;


// STEP Part 21
    virtual void STEPwrite_content (ostream& out =std::cout,
                    const char *currSch =0) const;
    virtual void STEPwrite_verbose (ostream& out =std::cout,
                    const char *currSch =0) const;
    virtual Severity STEPread_content (istream& in =cin,
        InstMgrBase * instances =0, const char *utype =0,
        int addFileId =0, const char *currSch =0);
    virtual Severity StrToVal_content (const char *,
        InstMgrBase * instances =0);

// STEP Part 22:  SDAI

// constructors
    SdaiObserved_context( const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    //  part 1
    SdaiObserved_context( const SdaiActivity_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiActivity_method_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiApplied_activity_assignment_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiAttachment_slot_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiAttachment_slot_definition_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiAttachment_slot_version_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiBreakdown_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiBreakdown_element_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiBreakdown_element_definition_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiBreakdown_version_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiInterface_connector_occurrence_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiProduct_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiProduct_group_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiProduct_version_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiProduct_view_definition_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiRequired_resource_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiResource_as_realized_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiResource_item_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiScheme_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiScheme_entry_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiScheme_version_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiTask_element_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiTask_method_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiTask_method_version_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiView_definition_relationship_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiWork_order_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiWork_output_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    SdaiObserved_context( const SdaiWork_request_ptr&,
                          const SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    virtual ~SdaiObserved_context();

    //  part 2
    operator SdaiActivity_ptr();
    operator SdaiActivity_method_ptr();
    operator SdaiApplied_activity_assignment_ptr();
    operator SdaiAttachment_slot_ptr();
    operator SdaiAttachment_slot_definition_ptr();
    operator SdaiAttachment_slot_version_ptr();
    operator SdaiBreakdown_ptr();
    operator SdaiBreakdown_element_ptr();
    operator SdaiBreakdown_element_definition_ptr();
    operator SdaiBreakdown_version_ptr();
    operator SdaiInterface_connector_occurrence_ptr();
    operator SdaiProduct_ptr();
    operator SdaiProduct_group_ptr();
    operator SdaiProduct_version_ptr();
    operator SdaiProduct_view_definition_ptr();
    operator SdaiRequired_resource_ptr();
    operator SdaiResource_as_realized_ptr();
    operator SdaiResource_item_ptr();
    operator SdaiScheme_ptr();
    operator SdaiScheme_entry_ptr();
    operator SdaiScheme_version_ptr();
    operator SdaiTask_element_ptr();
    operator SdaiTask_method_ptr();
    operator SdaiTask_method_version_ptr();
    operator SdaiView_definition_relationship_ptr();
    operator SdaiWork_order_ptr();
    operator SdaiWork_output_ptr();
    operator SdaiWork_request_ptr();

    //  part 3
  const SDAI_String   version_id_() const;
        SDAI_String   version_id_();
        void version_id_( const SDAI_String x );

  const SDAI_String   request_id_() const;
        SDAI_String   request_id_();
        void request_id_( const SDAI_String x );

        SdaiWork_output_item_ptr_c output_item_() const;
        SdaiWork_output_item_ptr   output_item_();
        void output_item_( const SdaiWork_output_item_ptr x );

        EntityAggregate_ptr_c in_response_to_() const;
        EntityAggregate_ptr   in_response_to_();
        void in_response_to_( const EntityAggregate_ptr x );

        SdaiProduct_view_definition_ptr_c related_view_() const;
        SdaiProduct_view_definition_ptr   related_view_();
        void related_view_( const SdaiProduct_view_definition_ptr x );

        SdaiProduct_view_definition_ptr_c relating_view_() const;
        SdaiProduct_view_definition_ptr   relating_view_();
        void relating_view_( const SdaiProduct_view_definition_ptr x );

  const SDAI_String   relation_type_() const;
        SDAI_String   relation_type_();
        void relation_type_( const SDAI_String x );

        SdaiTask_method_ptr_c of_task_method_() const;
        SdaiTask_method_ptr   of_task_method_();
        void of_task_method_( const SdaiTask_method_ptr x );

        SdaiTask_element_ptr_c content_() const;
        SdaiTask_element_ptr   content_();
        void content_( const SdaiTask_element_ptr x );

        EntityAggregate_ptr_c objective_() const;
        EntityAggregate_ptr   objective_();
        void objective_( const EntityAggregate_ptr x );

        EntityAggregate_ptr_c notes_() const;
        EntityAggregate_ptr   notes_();
        void notes_( const EntityAggregate_ptr x );

        SdaiScheme_ptr_c of_scheme_() const;
        SdaiScheme_ptr   of_scheme_();
        void of_scheme_( const SdaiScheme_ptr x );

        SdaiScheme_version_ptr_c scheme_() const;
        SdaiScheme_version_ptr   scheme_();
        void scheme_( const SdaiScheme_version_ptr x );

        SdaiResource_item_select_agg_ptr_c resource_items_() const;
        SdaiResource_item_select_agg_ptr   resource_items_();
        void resource_items_( const SdaiResource_item_select_agg_ptr x );

        SdaiValue_with_unit_ptr_c quantity_() const;
        SdaiValue_with_unit_ptr   quantity_();
        void quantity_( const SdaiValue_with_unit_ptr x );

        SdaiValue_with_unit_ptr_c required_quantity_() const;
        SdaiValue_with_unit_ptr   required_quantity_();
        void required_quantity_( const SdaiValue_with_unit_ptr x );

  const SDAI_String   product_group_context_() const;
        SDAI_String   product_group_context_();
        void product_group_context_( const SDAI_String x );

  const SDAI_String   membership_rule_() const;
        SDAI_String   membership_rule_();
        void membership_rule_( const SDAI_String x );

        SdaiConnector_on_item_ptr_c connector_on_() const;
        SdaiConnector_on_item_ptr   connector_on_();
        void connector_on_( const SdaiConnector_on_item_ptr x );

        SdaiInterface_connector_definition_ptr_c occurrence_of_() const;
        SdaiInterface_connector_definition_ptr   occurrence_of_();
        void occurrence_of_( const SdaiInterface_connector_definition_ptr x );

        EntityAggregate_ptr_c breakdown_of_() const;
        EntityAggregate_ptr   breakdown_of_();
        void breakdown_of_( const EntityAggregate_ptr x );

        SdaiAttachment_slot_ptr_c product_version_of_product_() const;
        SdaiAttachment_slot_ptr   product_version_of_product_();
        void product_version_of_product_( const SdaiAttachment_slot_ptr x );

        SdaiProduct_ptr_c of_product_() const;
        SdaiProduct_ptr   of_product_();
        void of_product_( const SdaiProduct_ptr x );

        SdaiAttachment_slot_version_ptr_c product_view_definition_defined_version_() const;
        SdaiAttachment_slot_version_ptr   product_view_definition_defined_version_();
        void product_view_definition_defined_version_( const SdaiAttachment_slot_version_ptr x );

        SdaiProduct_version_ptr_c defined_version_() const;
        SdaiProduct_version_ptr   defined_version_();
        void defined_version_( const SdaiProduct_version_ptr x );

        EntityAggregate_ptr_c additional_contexts_() const;
        EntityAggregate_ptr   additional_contexts_();
        void additional_contexts_( const EntityAggregate_ptr x );

        SdaiView_definition_context_ptr_c initial_context_() const;
        SdaiView_definition_context_ptr   initial_context_();
        void initial_context_( const SdaiView_definition_context_ptr x );

  const SDAI_String   additional_characterization_() const;
        SDAI_String   additional_characterization_();
        void additional_characterization_( const SDAI_String x );

  const SDAI_String   role_() const;
        SDAI_String   role_();
        void role_( const SDAI_String x );

        SdaiActivity_item_agg_ptr_c items_() const;
        SdaiActivity_item_agg_ptr   items_();
        void items_( const SdaiActivity_item_agg_ptr x );

        SdaiActivity_ptr_c assigned_activity_() const;
        SdaiActivity_ptr   assigned_activity_();
        void assigned_activity_( const SdaiActivity_ptr x );

  const SDAI_String   purpose_() const;
        SDAI_String   purpose_();
        void purpose_( const SDAI_String x );

  const SDAI_String   consequence_() const;
        SDAI_String   consequence_();
        void consequence_( const SDAI_String x );

        SdaiActivity_method_ptr_c chosen_method_() const;
        SdaiActivity_method_ptr   chosen_method_();
        void chosen_method_( const SdaiActivity_method_ptr x );

  const SDAI_String   description_() const;
        SDAI_String   description_();
        void description_( const SDAI_String x );

  const SDAI_String   name_() const;
        SDAI_String   name_();
        void name_( const SDAI_String x );

  const SDAI_String   id_() const;
        SDAI_String   id_();
        void id_( const SDAI_String x );


    //  part 4
    SdaiObserved_context& operator =( const SdaiActivity_ptr& );
    SdaiObserved_context& operator =( const SdaiActivity_method_ptr& );
    SdaiObserved_context& operator =( const SdaiApplied_activity_assignment_ptr& );
    SdaiObserved_context& operator =( const SdaiAttachment_slot_ptr& );
    SdaiObserved_context& operator =( const SdaiAttachment_slot_definition_ptr& );
    SdaiObserved_context& operator =( const SdaiAttachment_slot_version_ptr& );
    SdaiObserved_context& operator =( const SdaiBreakdown_ptr& );
    SdaiObserved_context& operator =( const SdaiBreakdown_element_ptr& );
    SdaiObserved_context& operator =( const SdaiBreakdown_element_definition_ptr& );
    SdaiObserved_context& operator =( const SdaiBreakdown_version_ptr& );
    SdaiObserved_context& operator =( const SdaiInterface_connector_occurrence_ptr& );
    SdaiObserved_context& operator =( const SdaiProduct_ptr& );
    SdaiObserved_context& operator =( const SdaiProduct_group_ptr& );
    SdaiObserved_context& operator =( const SdaiProduct_version_ptr& );
    SdaiObserved_context& operator =( const SdaiProduct_view_definition_ptr& );
    SdaiObserved_context& operator =( const SdaiRequired_resource_ptr& );
    SdaiObserved_context& operator =( const SdaiResource_as_realized_ptr& );
    SdaiObserved_context& operator =( const SdaiResource_item_ptr& );
    SdaiObserved_context& operator =( const SdaiScheme_ptr& );
    SdaiObserved_context& operator =( const SdaiScheme_entry_ptr& );
    SdaiObserved_context& operator =( const SdaiScheme_version_ptr& );
    SdaiObserved_context& operator =( const SdaiTask_element_ptr& );
    SdaiObserved_context& operator =( const SdaiTask_method_ptr& );
    SdaiObserved_context& operator =( const SdaiTask_method_version_ptr& );
    SdaiObserved_context& operator =( const SdaiView_definition_relationship_ptr& );
    SdaiObserved_context& operator =( const SdaiWork_order_ptr& );
    SdaiObserved_context& operator =( const SdaiWork_output_ptr& );
    SdaiObserved_context& operator =( const SdaiWork_request_ptr& );
    // not in SDAI
    SdaiObserved_context& ShallowCopy ( const SdaiObserved_context& );

#ifdef COMPILER_DEFINES_OPERATOR_EQ
#else
    SdaiObserved_context& operator =( SdaiObserved_context * const & );
    SDAI_Select& operator =( const SDAI_Select& );
#endif

    //  part 5
    Logical IsActivity() const;
    Logical IsActivity_method() const;
    Logical IsApplied_activity_assignment() const;
    Logical IsAttachment_slot() const;
    Logical IsAttachment_slot_definition() const;
    Logical IsAttachment_slot_version() const;
    Logical IsBreakdown() const;
    Logical IsBreakdown_element() const;
    Logical IsBreakdown_element_definition() const;
    Logical IsBreakdown_version() const;
    Logical IsInterface_connector_occurrence() const;
    Logical IsProduct() const;
    Logical IsProduct_group() const;
    Logical IsProduct_version() const;
    Logical IsProduct_view_definition() const;
    Logical IsRequired_resource() const;
    Logical IsResource_as_realized() const;
    Logical IsResource_item() const;
    Logical IsScheme() const;
    Logical IsScheme_entry() const;
    Logical IsScheme_version() const;
    Logical IsTask_element() const;
    Logical IsTask_method() const;
    Logical IsTask_method_version() const;
    Logical IsView_definition_relationship() const;
    Logical IsWork_order() const;
    Logical IsWork_output() const;
    Logical IsWork_request() const;

    //  part 6 ... UnderlyingTypeName () implemented in SDAI_Select class ...

    //  part 7 ... NONE    only for complex selects...
};

inline SDAI_Select * create_SdaiObserved_context () { return new SdaiObserved_context; }
typedef SdaiObserved_context * SdaiObserved_contextH;
typedef SdaiObserved_context_ptr SdaiObserved_context_var;


class SdaiObserved_context_agg : public SelectAggregate {
  protected:
    SelectTypeDescriptor *sel_type;

  public:
    SdaiObserved_context_agg( SelectTypeDescriptor * =ap239_product_life_cycle_support_arm_lf::t_observed_context );
    ~SdaiObserved_context_agg();
    virtual SingleLinkNode * NewNode()
     { return new SelectNode (new SdaiObserved_context( sel_type )); }
};
inline STEPaggregate * create_SdaiObserved_context_agg () { return new SdaiObserved_context_agg; }
typedef SdaiObserved_context_agg_ptr SdaiObserved_context_agg_var;

/////  END SELECT TYPE observed_context

void init_SdaiObserved_context(Registry& reg);

#endif
