/////////////////////////////////////////////////////////////////////////////// // 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 _PRCFILESTRUCTUREGLOBALS_INCLUDED_ #define _PRCFILESTRUCTUREGLOBALS_INCLUDED_ #include "PrcBase.h" #include "PrcMarkupSerializationHelper.h" #include "PrcRgbColor.h" #include "PrcPicture.h" #include "PrcRepresentationItem.h" #include "PrcCategory1LineStyle.h" #include "PrcLinePattern.h" #include "PrcMaterial.h" #include "PrcTextureDefinition.h" #include "PrcFillPattern.h" #include "PrcUserData.h" #include "PrcUniqueId.h" #include "PrcObjectId.h" #define STL_USING_ALL #include "OdaSTL.h" class OdPrcFile; SMARTPTR(OdPrcFileStructureGlobals); /** \details Class stores global data of a file structure. Global data contains coordinate systems, colors, linestyles, and references to other file structures for each entity in the file structure. */ class PRC_TOOLKIT OdPrcFileStructureGlobals : public OdPrcBase { public: //DOM-IGNORE-BEGIN ODPRC_DECLARE_MEMBERS_PRCBASE(OdPrcFileStructureGlobals) //DOM-IGNORE-END /** \details Requests the current user-defined data from the global data of the file structure. \returns An object that contains the user-defined data. \remarks User data is returned as a reference to an object, and therefore it can be used to set new user data. To restrict modifications of the user data outside the object, call another method that returns a constant reference. */ OdPrcUserData &userData(); /** \details Requests the current user-defined data from the global data of the file structure. \returns An object that contains the user-defined data. */ const OdPrcUserData &userData() const; /** \details Requests the current picture array from the global data of the file structure. \returns An array of smart pointers to objects. \remarks The is returned via a reference, and therefore it can be used to set a new array of pictures outside the object. To restrict modifications of the picture array outside the object, call another method that returns a constant reference. */ OdPrcPicturePtrArray &pictures(); /** \details Requests the current picture array from the global data of the file structure. \returns An array of smart pointers to objects. */ const OdPrcPicturePtrArray &pictures() const; /** \details Requests the current from the global data of the file structure. \returns An array of smart pointers to objects. \remarks The is returned via a reference, and therefore it can be used to set a new array of color definitions outside the object. To restrict modifications of the color definition array outside the object, call another method that returns a constant reference. */ OdPrcRgbColorArray &colors(); /** \details Requests the current from the global data of the file structure. \returns An array of smart pointers to objects. */ const OdPrcRgbColorArray &colors() const; /** \details Requests the current object from the global data of the file structure. \returns The current object. \remarks The current object is returned via a reference, and therefore it can be used to set a new serialization helper for markups outside the object. To restrict modifications of the object outside the object, call another method that returns a constant reference. */ OdPrcMarkupSerializationHelper &markupSerializationHelper(); /** \details Requests the current object from the file structure global data. \returns The current object. */ const OdPrcMarkupSerializationHelper &markupSerializationHelper() const; /** \details Sets a new value of the tessellation angle degree for the global data of the file structure. \param tessellation_angle_degree [in] A new value of the tessellation angle degree. */ void setTessellationAngleDegree(double tessellation_angle_degree); /** \details Requests the current value of the tessellation angle degree from the global data of the file structure. \returns A double value that contains the current tessellation angle degree. */ double tessellationAngleDegree() const; /** \details Sets a new value of the tessellation chord height for the global data of the file structure. \param tessellation_chord_height_ratio [in] A new tessellation chord height to be set. */ void setTessellationChordHeightRatio(double tessellation_chord_height_ratio); /** \details Requests the current tessellation chord height from the global data of the file structure. \returns A double value that contains the current tessellation chord height. */ double tessellationChordHeightRatio() const; /** \details Requests the current array of category 1 linestyles from the global data of the file structure. \returns An array of that refer to the category 1 linestyles. */ const OdPrcObjectIdArray& category1LineStyles(void) const; /** \details Requests the current array of category 1 linestyles from the global data of the file structure. \returns An array of that refer to the category 1 linestyles. \remarks The array of is returned via a reference, and therefore it can be used to set a new array of category 1 linestyles outside the object. To restrict modifications of the array of outside the object, call another method that returns a constant reference. */ OdPrcObjectIdArray& category1LineStyles(void); /** \details Requests the current array of line patterns from the global data of the file structure. \returns An array of that refer to the line patterns. */ const OdPrcObjectIdArray& linePatterns(void) const; /** \details Requests the current array of line patterns from the global data of the file structure. \returns An array of that refer to the line patterns. \remarks The array of is returned via a reference, and therefore it can be used to set a new array of line patterns outside the object. To restrict modifications of the array of outside the object, call another method that returns a constant reference. */ OdPrcObjectIdArray& linePatterns(void); /** \details Requests the current array of materials from the global data of the file structure. \returns An array of that refer to the materials. */ const OdPrcObjectIdArray& materials(void) const; /** \details Requests the current array of materials from the global data of the file structure. \returns An array of that refer to the materials. \remarks The array of is returned via a reference, and therefore it can be used to set a new array of materials outside the object. To restrict modifications of the array of outside the object, call another method that returns a constant reference. */ OdPrcObjectIdArray& materials(void); /** \details Requests the current array of texture definitions from the global data of the file structure. \returns An array of that refer to the texture definitions. */ const OdPrcObjectIdArray& textureDefinitions(void) const; /** \details Requests the current array of texture definitions from the global data of the file structure. \returns An array of that refer to the texture definitions. \remarks The array of is returned via a reference, and therefore it can be used to set a new array of texture definitions outside the object. To restrict modifications of the array of outside the object, call another method that returns a constant reference. */ OdPrcObjectIdArray& textureDefinitions(void); /** \details Requests the current array of fill patterns from the global data of the file structure. \returns An array of that refer to the fill patterns. */ const OdPrcObjectIdArray& fillPatterns(void) const; /** \details Requests the current array of fill patterns from the global data of the file structure. \returns An array of that refer to the fill patterns. \remarks The array of is returned via a reference, and therefore it can be used to set a new array of fill patterns outside the object. To restrict modifications of the array of outside the object, call another method that returns a constant reference. */ OdPrcObjectIdArray& fillPatterns(void); /** \details Requests the current array of coordinate systems from the global data of the file structure. \returns An array of that refer to the coordinate systems. */ const OdPrcObjectIdArray& coordinateSystem(void) const; /** \details Requests the current array of coordinate systems from the global data of the file structure. \returns An array of that refer to the coordinate systems. \remarks The array of is returned via a reference, and therefore it can be used to set a new array of coordinate systems outside the object. To restrict modifications of the array of outside the object, call another method that returns a constant reference. */ OdPrcObjectIdArray& coordinateSystem(void); /** \details Requests the current array of referenced file structures from the global data of the file structure. \returns An array of that refer to the referenced file structures. */ const OdPrcObjectIdArray& referencedFileStructuresID() const; }; #endif // _PRCFILESTRUCTUREGLOBALS_INCLUDED_