Quantcast
Channel: OpenPlant | AutoPLANT
Viewing all articles
Browse latest Browse all 16985

Wiki Page: OPPID - Tag Expression and results

$
0
0

Tag number parsing and the results. These are defined in the OpenPlant_Supplemental_Tagging schema.

Class

ANNOTATION_COMPONENTS

ECExpression

this.GetRelatedInstance("PLANT_AREA_HAS_NAMED_ITEM:1:PLANT_AREA, NAME:?").NAME & "-" & this.DEVICE_TYPE_CODE & "-" & this.NUMBER

ParserRegularExpression

^[?\w]*-(?<DEVICE_TYPE_CODE>[?\w]*)-(?<NUMBER>.*)|(?<NUMBER>.*)

Result

A1-SP-0001

 

Class

EQUIPMENT

ECExpression

this.DEVICE_TYPE_CODE & "-" & this.NUMBER

ParserRegularExpression

^(?<DEVICE_TYPE_CODE>.*)-(?<NUMBER>.*)|(?<NUMBER>.*)

Result

PMP-0001

 

Class

FLUID_REGULATOR

ECExpression

this.DEVICE_TYPE_CODE & "-" & this.NUMBER

ParserRegularExpression

^(?<DEVICE_TYPE_CODE>.*)-(?<NUMBER>.*)|(?<NUMBER>.*)

Result

HV-0001

 

Class

INSTRUMENT

ECExpression

this.GetRelatedInstance("PLANT_AREA_HAS_NAMED_ITEM:1:PLANT_AREA, NAME:?").NAME & "-" & this.DEVICE_TYPE_CODE & "-" & this.NUMBER

ParserRegularExpression

^[?\w]*-(?<DEVICE_TYPE_CODE>[?\w]*)-(?<NUMBER>.*)|(?<NUMBER>.*)

Result

A1-FT-0001

 

Class

INSTRUMENT_LOOP/LOOP

ECExpression

this.GetRelatedInstance("PLANT_AREA_HAS_NAMED_ITEM:1:PLANT_AREA, NAME:?").NAME & "-" & this.DEVICE_TYPE_CODE & "-" & this.NUMBER

ParserRegularExpression

^[?\w]*-(?<DEVICE_TYPE_CODE>[?\w]*)-(?<NUMBER>.*)|(?<NUMBER>.*)

Result

A1-L-0001

 

Class

NOZZLE

ECExpression

this.GetRelatedInstance("EQUIPMENT_HAS_NOZZLE:1:EQUIPMENT, DEVICE_TYPE_CODE:?").DEVICE_TYPE_CODE & "-" & this.GetRelatedInstance("EQUIPMENT_HAS_NOZZLE:1:EQUIPMENT, NUMBER:?").NUMBER & "-" & this.DEVICE_TYPE_CODE & this.NUMBER

ParserRegularExpression

^[?\w]*-[?\w]*-(?<DEVICE_TYPE_CODE>.)(?<NUMBER>.*)|(?<NUMBER>.*)

Result

PMP-0001-N-1

 

Class

PIPING_NETWORK_SYSTEM

ECExpression

this.UNIT_NAME & "-" & this.SERVICE_NAME & "-" & this.NUMBER & "-" &  this.SPECIFICATION

ParserRegularExpression

^[?\w]*-[?\w]*-(?<NUMBER>[?\w]*)-(?<SPECIFICATION>.*)|(?<NUMBER>.*)

Result

U1-Oil-0001-Ductile

Copy and paste table below to add new table.

Class

Any class

 Comment

 This simple example checks to see if it's an email address, there are many ways to do it.  This is a simple example looking for any characters, and seperated by an "@" symbol

ECExpression

this.AccountName&"-"&this.Company

ParserRegularExpression

^(?<AccountName>[A-Z0-9._%+-]*)@(?<Company>[\w]*).

Result

Bentley_Software1234@bentley_systems.com

 

Class

Any property example

 Comment

this will look for digits and then parse out the " inches character.  Example Size=12" would parse to Size=12 (had this request for annotation purposes, and they didn't want inches shown.  Note: the value must be followed by a " inches character.

ECExpression

this.Size

ParserRegularExpression

^(?<SIZE>[\d]{1,3})"

Result

1 or 12 or 123

 

ClassPIPING_NETWORK_SYSTEM
CommentThis allows for a Pipeline tag of Area-Service-Design Size-Specification-Number where the Design Size has the "inch" mark on the size value. In the parser expression note the /" (Forward Slash and Inch mark in the section for DESIGN_SIZE
ECExpressionthis.AREA_NAME & "-" & this.SERVICE_NAME & "-" & this.DESIGN_SIZE & "-" & this.SPECIFICATION & "-" & this.NUMBER
Parser Regular Expression

^(?<AREA_NAME>[?\w]*)-(?<SERVICE_NAME>[?\w]*)-(?<DESIGN_SIZE>[?\w/"]*)-(?<SPECIFICATION>.*)-(?<NUMBER>[?\w]*)

Result10-STM-4"-CS150-2222

 

 

 

 

 

 

ClassPIPING_NETWORK_SYSTEM
CommentA tag format where the first value is SERVICE and SERVICE has spaces in the value. The SERVICE property is an Associated Item so it must be stripped out.
ECExpressionthis.SERVICE & "-" & this.NUMBER & "-" & this.SUFFIX
Parser Regular Expression

^[?\w\s]*-(?<NUMBER>.*)-(?<SUFFIX>.*)

ResultCM F-1234-1

 


Viewing all articles
Browse latest Browse all 16985

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>