/////////////////////////////////////////////////////////////////////////////// // Copyright (C) 2002-2025, Open Design Alliance (the "Alliance"). // All rights reserved. // // This software and its documentation and related materials are owned by // the Alliance. The software may only be incorporated into application // programs owned by members of the Alliance, subject to a signed // Membership Agreement and Supplemental Software License Agreement with the // Alliance. The structure and organization of this software are the valuable // trade secrets of the Alliance and its suppliers. The software is also // protected by copyright law and international treaty provisions. Application // programs incorporating this software must include the following statement // with their copyright notices: // // This application incorporates Open Design Alliance software pursuant to a license // agreement with Open Design Alliance. // Open Design Alliance Copyright (C) 2002-2025 by Open Design Alliance. // All rights reserved. // // By use of this software, its documentation or related materials, you // acknowledge and accept the above terms. /////////////////////////////////////////////////////////////////////////////// #ifndef IFC_PSDQTO_VALIDATION_TASK #define IFC_PSDQTO_VALIDATION_TASK #pragma once #include "OdaCommon.h" #include "daiExtentValidationTask.h" #include "IfcValidationExport.h" #include "IfcPsdQto.h" #include "daiValidationCommon.h" namespace OdIfc { class IFC_VALIDATION_EXPORT IfcPSDQTOValidationTask : public OdDAI::ExtentValidationTask { ODRX_VALIDATION_DECLARE_MEMBERS(IfcPSDQTOValidationTask); typedef std::map PropertySetMap; typedef std::map::const_iterator PropertySetMapIterator; public: /** \details Creates a new validation task object with default parameters. */ IfcPSDQTOValidationTask(); /** \details Initializes the validation task. This method is called by the validator object before the validation starts. Virtual function which is called by Validator before validation process starts. \param invalidParams [out] A shared pointer to an True if the validation initialization is successful (default return value). * Unknown in other cases. */ virtual OdDAI::Logical initializeValidation(OdDAI::ValidationContext* validationContext, OdDAIHostAppServicesBase* pServices, OdSharedPtr& invalidParams) override; /** \details Checks constraints for a specified entity instance and forms a list of violated constraints. \param pInstanceCtx [in] A raw pointer to the <InvalidValidationParamsBase object. After method execution, it contains a list of constraints that are violated. \returns * False if any constraint is violated. * ANSI string that contains the description of the validation task. */ virtual OdAnsiString description() const override; private: /** \details Checks instance property sets for a specified property set entity instance and forms a list of violated constraints. \param pPropertySetDef [in] A pointer to the <InvalidValidationParamsBase object. After method execution, it contains a list of constraints that are violated. \returns * Returns False if an internal validation error occurred, True otherwise. */ bool validatePropertySet(OdDAI::ApplicationInstance* pPropertySetDef, PropertySetMap* pIfcProperties, InvalidRxArrayValidationParams* pInvalidIds); /** \details Checks instance quantity sets for a specified quantity set entity instance and forms a list of violated constraints. \param pQtoSetDef [in] A pointer to the <InvalidValidationParamsBase object. After method execution, it contains a list of constraints that are violated. \returns * Returns False if an internal validation error occurred, True otherwise. */ bool validateQtoSet(OdDAI::ApplicationInstance* pQtoSetDef, PropertySetMap* pProperties, InvalidRxArrayValidationParams* pInvalidIds); PSDQTO m_psdqto; OdDAI::ApplicationInstance* m_instance; }; } #endif // !IFC_PSDQTO_VALIDATION_TASK