//////////////////////////////////////////////////////////////////////////////
//
//  Copyright 2025 by Autodesk, Inc.  All rights reserved.
//
// This computer source code and related instructions and comments 
// are the unpublished confidential and proprietary information of 
// Autodesk, Inc. and are protected under applicable copyright and 
// trade secret law.  They may not be disclosed to, copied or used 
// by any third party without the prior written consent of Autodesk, Inc.
//
//////////////////////////////////////////////////////////////////////////////
#ifndef __STDBSI_H
#define __STDBSI_H
#ifndef __STDISO_H
#error include 'stdISO.h' before including this file
#endif
class AcmSurfTextStdBSI;

///<summary>This is class AcmStandardBSI.</summary>
class STDIMP_DLLSHARE AcmStandardBSI : public AcmStandard
{
public:
  ACRX_DECLARE_MEMBERS(AcmStandardBSI);
  AcmStandardBSI();
  virtual ~AcmStandardBSI();
  ///<summary>Gets the original name of the standard.</summary>
  virtual LPCTSTR originalName() const;    
  ///<summary>This function initializes the internal structure of the standard.</summary>
  virtual Adesk::Boolean acmInit();             
  ///<summary>Returns a list of all supported text heights that conform to the standard setting.</summary>
  virtual void getTextHeightList(AcGeDoubleArray& txtArr) const;
  ///<summary>This function is used to initialize the standard.</summary>
  virtual Adesk::Boolean setFactoryDefaults();
  virtual Adesk::Boolean setDimDefaults();

protected:
  ///<summary>Constructs arrow services objects.</summary>
  virtual void initArrowServices();
  virtual Adesk::Boolean createDefaultStyle();
};                      

class STDIMP_DLLSHARE AcmSurfTextStdBSI : public AcmSurfTextStd
{
public:
  ACRX_DECLARE_MEMBERS(AcmSurfTextStdBSI);
  AcmSurfTextStdBSI();
  virtual ~AcmSurfTextStdBSI();
  ///<summary>Gets the information about the standard name and revision.</summary>
  Acm::ErrorStatus getRevision(CString& rev, Adesk::UInt16& year) const override;
  ///<summary>Provides the basic interface for the AcmStandardManager and hence determines whether 
  ///AcmSymbolSTD can be used for a particular standard.</summary>
  Adesk::Boolean   isCompatibleTo(const AcmStandard* pStd) const override;
  void initToEditOriginal() const override;
  void initToEdit() const override;
  ///<summary>Sets the factory default values.</summary>
  Adesk::Boolean setFactoryDefaults() override;
  ///<summary>Gets a direction of lay symbol descriptor.</summary>
  Adesk::Boolean getLaySymbolList(AcmCObjArray<AcmSymbolDesc4CL>& list,
                                          const AcmCSurfText* pSubSym =NULL) const override;
  ///<summary>Sets the visibility status for all values in the surface texture sub-symbol.</summary>
  Acm::ErrorStatus checkVisibility(AcmCSurfText* pData) const override;
  ///<summary>Sets the initial status of variables.</summary>
  Acm::ErrorStatus initFields(AcmCSurfText* pData) const override;
  ///<summary>Sets the suggested values for any value in the sub-symbol.</summary>
  Acm::ErrorStatus setSuggested(AcmCSurfText* pData) const override;

  ///<summary>Returns an array of graphical sub-entities representative of "Production Method" field variables 
  ///in the given Surface Texture symbol.</summary>
  ///<param name="pSubSym">Surface Texture symbol of interest.</param>
  ///<param name="subents">Array of graphical sub-entities.</param>
  ///<param name="fullExtent">Geometrical extents of the array of sub-entities.</param>
  ///<param name="txtHeight">Text height to be applied to the sub-entities.</param>
  ///<param name="commonWidth">Horizontal displacement of the sub-entities from the reference point.</param>
  ///<param name="refPoint">Reference position used to position the array of graphical sub-entities.</param>
  ///<returns>true if the array is populated successfully, false if the array fails to be populated.</returns>
  bool getSubEntsProd1(const AcmCSurfText* pSubSym,
                               AcmCAuxEntArray& subents,
                               AcDbExtents& fullExtent,
                               double txtHeight,
                               double& commonWidth,
                               AcGePoint3d& refPoint) const override;

  ///<summary>Returns an array of graphical sub-entities representative of "Sampling Length" field variable in 
  ///the given Surface Texture symbol.</summary>
  ///<param name="pSubSym">Surface Texture symbol of interest.</param>
  ///<param name="subents">Array of graphical sub-entities.</param>
  ///<param name="fullExtent">Geometrical extents of the array of sub-entities.</param>
  ///<param name="txtHeight">Text height to be applied to the sub-entities.</param>
  ///<param name="commonWidth">Horizontal displacement of the sub-entities from the reference point.</param>
  ///<param name="refPoint">Reference position used to position the array of graphical sub-entities.</param>
  ///<returns>true if the array is populated successfully, false if the array fails to be populated.</returns>
  bool getSubEntsSampLen(const AcmCSurfText* pSubSym,
                                 AcmCAuxEntArray& subents,
                                 AcDbExtents& fullExtent,
                                 double txtHeight,
                                 double& commonWidth,
                                 AcGePoint3d& refPoint) const override;

  ///<summary>Returns an array of graphical sub-entities representative of "Roughness average (Max)" field variable
  ///in the given Surface Texture symbol.</summary>
  ///<param name="pSubSym">Surface Texture symbol of interest.</param>
  ///<param name="subents">Array of graphical sub-entities.</param>
  ///<param name="fullExtent">Geometrical extents of the array of sub-entities.</param>
  ///<param name="txtHeight">Text height to be applied to the sub-entities.</param>
  ///<param name="commonWidth">Horizontal displacement of the sub-entities from the reference point.</param>
  ///<param name="refPoint">Reference position used to position the array of graphical sub-entities.</param>
  ///<returns>true if the array is populated successfully, false if the array fails to be populated.</returns>
  bool getSubEntsRaMax(const AcmCSurfText* pSubSym,
                       const AcmCSubSymbolsList* pSubSymbolsList,
                        AcmCAuxEntArray& subents,
                        AcDbExtents& fullExtent,
                        double txtHeight,
                        double& commonWidth,
                        AcGePoint3d& refPoint,
                        Adesk::Boolean isOnlyRaValue) const override;

  ///<summary>Returns an array of graphical sub-entities representative of "Roughness average (Min)" field variable 
  ///in the given Surface Texture symbol.</summary>
  ///<param name="pSubSym">Surface Texture symbol of interest.</param>
  ///<param name="subents">Array of graphical sub-entities.</param>
  ///<param name="fullExtent">Geometrical extents of the array of sub-entities.</param>
  ///<param name="txtHeight">Text height to be applied to the sub-entities.</param>
  ///<param name="commonWidth">Horizontal displacement of the sub-entities from the reference point.</param>
  ///<param name="refPoint">Reference position used to position the array of graphical sub-entities.</param>
  ///<returns>true if the array is populated successfully, false if the array fails to be populated.</returns>
  bool getSubEntsRaMin(const AcmCSurfText* pSubSym,
                       const AcmCSubSymbolsList* pSubSymbolsList,
                        AcmCAuxEntArray& subents,
                        AcDbExtents& fullExtent,
                        double txtHeight,
                        double& commonWidth,
                        AcGePoint3d& refPoint,
                        Adesk::Boolean isOnlyRaValue) const override;

  ///<summary>Returns the variable of the Surface Texture symbol standard that will hold the input value at the positional
  ///index (as shown in the diagram below).</summary>
  ///<param name="dlgIndex">Positional index (See diagram). DO_IMAGE images/surface_texture_requirement.png</param>
  ///<param name="var">Variable in Surface Texture symbol standard.</param>
  ///<returns>Acad::eOk = If the variable is valid in the Surface Texture symbol standard. Acad::eInvalidInput = If the 
  ///index is not valid in the Surface Texture symbol standard.</returns>
  Acad::ErrorStatus getVarFromDlgIndex(Adesk::UInt8 dlgIndex, Acm::Variable& var) const override;

  ///<summary>Returns the editability and other information of the drop-down list (Combo box) in Surface Texture symbol
  ///standard dialog.</summary>
  ///<param name="var">Variable in Surface Texture symbol standard.</param>
  ///<param name="varDlgInfo">Information of the drop-down list.</param>
  AcmSurfTextStd::ConfigListState checkConfigListState(Acm::Variable var, CVarDlgInfo& varDlgInfo) const override;

protected:
  ///<summary>Gets the height of the symbol.</summary>
  ///<param name="pSymb">Surface texture symbol of interest.</param>
  ///<param name="H1">Reference height 1.</param>
  ///<param name="H2">Reference height 2.</param>
  void getHeights(const AcmCSurfText* pSymb,
                          double& H1,
                          double& H2) const override;
};                      

///<summary>The AcmSurfTextStdBSI2002 class is a derived class of the AcmSurfTextStdBSI class. The usage of 
///AcmSurfTextStdBSI2002 class is the same as that of AcmSurfTextStd class.</summary>
class STDIMP_DLLSHARE AcmSurfTextStdBSI2002 : public AcmSurfTextStdBSI
{
public:
  ACRX_DECLARE_MEMBERS(AcmSurfTextStdBSI2002);
  AcmSurfTextStdBSI2002();
  virtual ~AcmSurfTextStdBSI2002();
  ///<summary>Sets the factory default values.</summary>
  Adesk::Boolean setFactoryDefaults() override;
  ///<summary>Gets a direction of lay symbol descriptor.</summary>
  Adesk::Boolean getLaySymbolList(AcmCObjArray<AcmSymbolDesc4CL>& list,
                                          const AcmCSurfText* pSubSym =NULL) const override;
  ///<summary>Gets the information about the standard name and revision.</summary>
  Acm::ErrorStatus getRevision(CString& rev, Adesk::UInt16& year) const override;
  void initToEditOriginal() const override;
  void initToEdit() const override;

  ///<summary>Returns the variable of the Surface Texture symbol standard that will hold the input value at the positional 
  ///index (as shown in the diagram below).</summary>
  ///<param name="dlgIndex ">Positional index (See diagram). DO_IMAGE images/surface_texture_requirement.png</param>
  ///<param name="var">Variable in Surface Texture symbol standard.</param>
  ///<returns>Acad::eOk = If the variable is valid in the Surface Texture symbol standard. Acad::eInvalidInput = If the
  ///index is not valid in the Surface Texture symbol standard.</returns>
  Acad::ErrorStatus getVarFromDlgIndex(Adesk::UInt8 dlgIndex, Acm::Variable& var) const override;

  ///<summary>Returns the editability and other information of the drop-down list (Combo box) in Surface Texture symbol 
  ///standard dialog.</summary>
  ///<param name="var">Variable in Surface Texture symbol standard.</param>
  ///<param name="varDlgInfo">Information of the drop-down list.</param>
  AcmSurfTextStd::ConfigListState checkConfigListState(Acm::Variable var, CVarDlgInfo& varDlgInfo) const override;

  ///<summary>Sets the visibility status for all values in the surface texture sub-symbol.</summary>
  Acm::ErrorStatus checkVisibility(AcmCSurfText* pData) const override;
  ///<summary>Sets the initial status of variables.</summary>
  Acm::ErrorStatus initFields(AcmCSurfText* pData) const override;
  ///<summary>Sets the suggested values for any value in the sub-symbol.</summary>
  Acm::ErrorStatus setSuggested(AcmCSurfText* pData) const override;
  ///<summary>Restore the drop down lists for all variables of surface texture symbol standard to the default preset lists.</summary>
  void restoreAllSuggestedList() override;
  ///<param name="symArray">Array indicating state of selection of direction of lay symbols.</param>
  void getDefaultLaySymbols(AcDbIntArray& symArray) const override;
  void getDefaultVarSuggestList(Acm::Variable var, CStringList& list) const override;

  ///<summary>Returns an array of graphical sub-entities representative of "Production Method" field variables in 
  ///the given Surface Texture symbol.</summary>
  ///<param name="pSubSym">Surface Texture symbol of interest.</param>
  ///<param name="subents">Array of graphical sub-entities.</param>
  ///<param name="fullExtent">Geometrical extents of the array of sub-entities.</param>
  ///<param name="txtHeight">Text height to be applied to the sub-entities.</param>
  ///<param name="commonWidth">Horizontal displacement of the sub-entities from the reference point.</param>
  ///<param name="refPoint">Reference position used to position the array of graphical sub-entities.</param>
  ///<returns>true if the array is populated successfully, false if the array fails to be populated.</returns>
  bool getSubEntsProd1(const AcmCSurfText* pSubSym,
                               AcmCAuxEntArray& subents,
                               AcDbExtents& fullExtent,
                               double txtHeight,
                               double& commonWidth,
                               AcGePoint3d& refPoint) const override;

  ///<summary>Returns true if this symbol standard supports surface indication leader. 
  ///Otherwise, returns false.</summary>
  Adesk::Boolean isSurfIndLeaderSupported() const override;

protected:
  ///<summary>Gets the height of the symbol.</summary>
  ///<param name="pSymb">Surface texture symbol of interest.</param>
  ///<param name="H1">Reference height 1.</param>
  ///<param name="H2">Reference height 2.</param>
  void getHeights(const AcmCSurfText* pSymb,
                          double& H1,
                          double& H2) const override;
};                      

///<summary>This is class AcmFCFStdBSI.</summary>
class STDIMP_DLLSHARE AcmFCFStdBSI : public AcmFCFStd
{
public:
  ACRX_DECLARE_MEMBERS(AcmFCFStdBSI);
  AcmFCFStdBSI();            
  virtual ~AcmFCFStdBSI();
  ///<summary>Gets the information about the standard name and revision.</summary>
  virtual Acm::ErrorStatus getRevision(CString& rev, Adesk::UInt16& year) const;
  ///<summary>Provides the basic interface for the AcmStandardManager and hence determines whether AcmSymbolSTD 
  ///can be used for a particular standard.</summary>
  virtual Adesk::Boolean   isCompatibleTo(const AcmStandard* pStd) const;
  ///<summary>Sets the factory default values.</summary>
  virtual Adesk::Boolean setFactoryDefaults();
  void initToEditOriginal() const override;
  void initToEdit() const override;
  ///<summary>Returns the list of available material removal characteristics.</summary>
  virtual Adesk::Boolean getMat(AcmCObjArray<AcmCGDTSymbolDesc>& list) const;
  ///<summary>Checks whether the symbol data is visible or not.</summary>
  virtual Acm::ErrorStatus checkVisibility(AcmCFCF* pData) const;
};                      

///<summary>This is class AcmFCFStdBSI2013.</summary>
class STDIMP_DLLSHARE AcmFCFStdBSI2013 : public AcmFCFStdBSI
{
public:
  ACRX_DECLARE_MEMBERS(AcmFCFStdBSI2013);
  AcmFCFStdBSI2013();            
  virtual ~AcmFCFStdBSI2013();
  ///<summary>Gets the information about the standard name and revision.</summary>
  virtual Acm::ErrorStatus getRevision(CString& rev, Adesk::UInt16& year) const;
  ///<summary>Sets the factory default values.</summary>
  virtual Adesk::Boolean setFactoryDefaults();
  ///<summary>Returns the list of available material removal characteristics.</summary>
  virtual Adesk::Boolean getMat(AcmCObjArray<AcmCGDTSymbolDesc>& list) const;
};

///<summary>This is class AcmWeldingStdBSI.</summary>
class STDIMP_DLLSHARE AcmWeldingStdBSI : public AcmWeldingStdISO
{
public:
  ACRX_DECLARE_MEMBERS(AcmWeldingStdBSI);
  AcmWeldingStdBSI();
  virtual ~AcmWeldingStdBSI();

  virtual Acm::ErrorStatus getRevision(CString& rev, Adesk::UInt16& year) const;
  virtual Adesk::Boolean   isCompatibleTo(const AcmStandard* pStd) const;
  ///<summary>This class implementation doesn't do anything and returns eNotImplemented if it is not overloaded in
  ///the child class.</summary>
  virtual Acm::ErrorStatus cInit(); 
  ///<summary>Sets the factory default values.</summary>
  virtual Adesk::Boolean setFactoryDefaults();
};                      

///<summary>This is class AcmDatumStdBSI.</summary>
class STDIMP_DLLSHARE AcmDatumStdBSI : public AcmDatumStd
{
public:
  ACRX_DECLARE_MEMBERS(AcmDatumStdBSI);
  AcmDatumStdBSI(); 
  virtual ~AcmDatumStdBSI();
  ///<summary>Gets the information about the standard name and revision.</summary>
  virtual Acm::ErrorStatus getRevision(CString& rev, Adesk::UInt16& year) const;
  ///<summary>Provides the basic interface for the AcmStandardManager and hence determines whether AcmSymbolSTD can
  ///be used for a particular standard.</summary>
  virtual Adesk::Boolean   isCompatibleTo(const AcmStandard* pStd) const;
  ///<summary>Sets the factory default values.</summary>
  virtual Adesk::Boolean setFactoryDefaults();
  ///<summary>This class implementation doesn't do anything and returns eNotImplemented if it is not overloaded in 
  ///the child class.</summary>
  virtual Acm::ErrorStatus cInit();
};                      

///<summary>This is class AcmDatumStdBSI2013.</summary>
class STDIMP_DLLSHARE AcmDatumStdBSI2013 : public AcmDatumStdBSI
{
public:
  ACRX_DECLARE_MEMBERS(AcmDatumStdBSI2013);
  AcmDatumStdBSI2013(); 
  virtual ~AcmDatumStdBSI2013();
  ///<summary>Gets the information about the standard name and revision.</summary>
  virtual Acm::ErrorStatus getRevision(CString& rev, Adesk::UInt16& year) const;
  ///<summary>Sets the factory default values.</summary>
  virtual Adesk::Boolean setFactoryDefaults();
};                      

///<summary>This is class AcmIdStdBSI.</summary>
class STDIMP_DLLSHARE AcmIdStdBSI : public AcmIdStd
{
public:
  ACRX_DECLARE_MEMBERS(AcmIdStdBSI);
  AcmIdStdBSI();
  virtual ~AcmIdStdBSI();
  ///<summary>Gets the information about the standard name and revision.</summary>
  virtual Acm::ErrorStatus getRevision(CString& rev, Adesk::UInt16& year) const;
  ///<summary>Provides the basic interface for the AcmStandardManager and hence determines whether AcmSymbolSTD 
  ///can be used for a particular standard.</summary>
  virtual Adesk::Boolean   isCompatibleTo(const AcmStandard* pStd) const;
};

///<summary>This is class AcmIdStdBSI2013.</summary>
class STDIMP_DLLSHARE AcmIdStdBSI2013 : public AcmIdStdBSI
{
public:
  ACRX_DECLARE_MEMBERS(AcmIdStdBSI2013);
  AcmIdStdBSI2013();
  virtual ~AcmIdStdBSI2013();
  ///<summary>Gets the information about the standard name and revision.</summary>
  virtual Acm::ErrorStatus getRevision(CString& rev, Adesk::UInt16& year) const;
};

///<summary>This is class AcmCPartListStdBSI.</summary>
class STDIMP_DLLSHARE AcmCPartListStdBSI : public AcmCPartListStd
{
public:
  AcmCPartListStdBSI(AcmBOMStd *std);
  virtual ~AcmCPartListStdBSI();
  ///<summary>This member function will forward the call to the parts list standard and balloon standard objects, 
  ///if they are defined.</summary>
  virtual Adesk::Boolean setFactoryDefaults();
  ///<summary>This member function is implemented for the AcmSymbolStd interface. It is necessary to be able to
  ///properly edit the standard.</summary>
  virtual Acm::ErrorStatus getRevision(CString& rev, Adesk::UInt16& year) const;
};

///<summary>This is class AcmCBalloonStdBSI.</summary>
class STDIMP_DLLSHARE AcmCBalloonStdBSI : public AcmCBalloonStd
{
public:
  AcmCBalloonStdBSI(AcmBOMStd *std);
  virtual ~AcmCBalloonStdBSI();
  ///<summary>This member function will forward the call to the parts list standard and balloon standard objects,
  ///if they are defined.</summary>
  virtual Adesk::Boolean setFactoryDefaults();
  virtual Acm::ErrorStatus getRevision(CString& rev, Adesk::UInt16& year) const;
};


///<summary>The AcmBOMStdBSI class is a derived class of the AcmBOMStd class. The usage of AcmBOMStdBSI class is the
///same as that of AcmBOMStd class.</summary>
class STDIMP_DLLSHARE AcmBOMStdBSI : public AcmBOMStd
{
public:
  ACRX_DECLARE_MEMBERS(AcmBOMStdBSI);
  ///<summary>the construct function.</summary>
  AcmBOMStdBSI();
  ///<summary>the destruct function.</summary>
  virtual ~AcmBOMStdBSI();
  ///<summary>You may overload this method in their classes to initialize the BOM standard with their own parts list
  ///standard balloon standards.</summary>
  virtual Acm::ErrorStatus cInit();
  ///<summary>This member function will forward the call to the parts list standard and balloon standard objects, 
  ///if they are defined.</summary>
  virtual Adesk::Boolean setFactoryDefaults();
  ///<summary>This member function is implemented for the AcmSymbolStd interface. It is necessary to be able to properly 
  ///edit the standard.</summary>
  virtual Acm::ErrorStatus getRevision(CString& rev, Adesk::UInt16& year) const;
  ///<summary>Provides the basic interface for the AcmStandardManager and hence determines whether AcmSymbolSTD can be 
  ///used for a particular standard.</summary>
  virtual Adesk::Boolean   isCompatibleTo(const AcmStandard* pStd) const;
};

#endif // STDBSI
