HVAC ORTHO Business Rule - List of HVAC Spools (CAAAITACHVACSpoolCustomerData1)

An opening ID is an entry point used to customize business logic. The HVAC ORTHO business rule - list of HVAC spools in the interactive panel opening ID is used to list the HVAC spools in the interactive panel.

Note: For more information about customization by business rules, see Installation and Setup: Customize: Behavior: Data Setup: Customization by Business Rules.

This page discusses:

General Information

This opening ID is invoked when using the HVAC Orthogonal Spool Drawings command.

In the interactive panel, the app displays up to five user defined properties. They can be properties of the Spool Reference or Instance.

  • Properties of instances such as: Block and Section.
  • Properties of references such as: Inside Conservation, Outside Conservation, and Installation Stage.

Input Objects

Input objects must be of the following types:

  • ThisObject: FactType ProductOccurrence (=spool occurrence)
  • Parameters corresponds to the context object.

Sample

The following sample describes how to retrieve the HVAC Spool data to be displayed in the launch panels. Use the sample to define the business rule in the resource set. As input to the BR will be provided: VPMOccurrence of the Spool.

/*------------------------------------------------------------------------------*/
/* Rule name: CAAAITACHVACSpoolCustomerData1                                    */ 
/*                                                                              */
/* Sample rule for retrieving the customer HVAC Spool data to be displayed     */
/* in the launch panels. For pure information and Designer use only.            */
/* Any properties can be returned as seemed to be fit. The same order should be */
/* returned for each spool though...                                            */
/*                                                                              */
/* Input Arguments                                                              */
/*    ThisObject  = FactType ProductOccurrence   (=spool occurrence)            */
/*                                                                              */
/* Output Parameters                                                            */
/*    PropertyName1      = string, name of  1st property. E.g. Section          */
/*    PropertyValue1     = string, value of 1st property. E.g. 0412              */
/*    PropertyName2      = string, name of  2nd property. E.g. Block            */
/*    PropertyValue2     = string, value of 2nd property. E.g. 04               */
/*    PropertyName3      = string, name of  3rd property. E.g. Outfitting Stage */
/*    PropertyValue3     = string, value of 3rd property. E.g. Section          */
/*    PropertyName4      = string, name of  4th property. E.g. Conservation     */
/*    PropertyValue4     = string, value of 4th property. E.g. Painted          */
/*    PropertyName5      = string, name of  5th property. E.g. Material         */
/*    PropertyValue5     = string, value of 5th property. E.g. Carbon Steel      */
/*                                                                              */
/*                                                                              */
/*    Data may be read from attributes on the spool reference or instance or    */
/*    dynamically retrieved from ENOVIA, or computed using                       */
/*    SpoolOcc->QuerySpaces(NULL,1,....)                                        */
/*    or properties read from the ducts/duct parts inside the spool.            */
/*------------------------------------------------------------------------------*/

Let SpoolOcc(ProductOccurrence)
Let SpoolRef(VPMReference)
Let SpoolIns(VPMInstance)

/* spool data */
Let strSection(String)
Let strBlock(String)
Let strOutfitStage(String)
Let strConservation(String)
Let strMaterial(String)

/* initialize */
SpoolOcc=NULL
SpoolRef=NULL
SpoolIns=NULL
strSection=""
strBlock  =""
strOutfitStage=""
strConservation=""
strMaterial=""


/* ThisObject information */
Trace(1,"ThisObject : " + ThisObject.Name)

/* Get the Spool occurrence */
Set SpoolOcc = ThisObject
Trace(1,"Spool Occurrence : " + SpoolOcc.Name)

/* Get the Spool instance */
Set SpoolIns = SpoolOcc
Trace(1,"Spool Instance : " + SpoolIns.Name)

/* Get the Spool reference */
Set SpoolRef = SpoolIns.Reference
Trace(1,"Spool Reference: " + SpoolRef.Name)

/* Read the attributes from the Spool (sample, customer dependent) */
strSection=SpoolIns.GetAttributeString("AITDesignUnit")
strBlock  =SpoolIns.GetAttributeString("AITBlock")

strConservation=SpoolRef.GetAttributeString("AITOutside_Conservation")


// Output the result back to the calling code
Parameters -> SetAttributeString("PropertyName1" , "Section")
Parameters -> SetAttributeString("PropertyName2" , "Block")
Parameters -> SetAttributeString("PropertyName3" , "Conservation")
Parameters -> SetAttributeString("PropertyName4" , "Stage")
Parameters -> SetAttributeString("PropertyName5" , "Material")

Parameters -> SetAttributeString("PropertyValue1" , strSection)
Parameters -> SetAttributeString("PropertyValue2" , strBlock)
Parameters -> SetAttributeString("PropertyValue3" , strConservation)
Parameters -> SetAttributeString("PropertyValue4" , strOutfitStage)
Parameters -> SetAttributeString("PropertyValue5" , strMaterial)

/* end   */