Mask files are written in a human-readable text format allowing their edition to comply with customers’ choices. This section describes the mask file syntax.
References the <attribute> that is visible in the current operation's view.
Rule: <attribute> must have been previously declared using the keyword ATTR.
<editable> specifies if this attribute is modifiable or not. Legal values are Y and N:
Y attribute can be modified in this operation
N not modifiable.
Note: this property is meaningful mainly for the Write operation: is the end-user allowed to modify or not the corresponding field in the properties editor?
However, this property is mandatory for any FATTR declarations under any FUNC declarations.
This property should be set to:
Y for Create, Write, Query and Ezquery
N for Read, Tree and List.
The order of the FATTR declarations in the FUNC section specifies the order in which the referenced attributes appear in the current operation's view.
FATTR PLMExternalID;Y
Rules about IP Protection (defined in metadata files)
Not all attribute combinations are authorized in a security mask: this depends on their IP Protection declaration in the .metadata file.
These rules are enforced by the VPLMPosMaskGenerator tools and any errors reported by the VPLMPosMaskCompiler tool (however, these are not fatal errors for the compilation process, only syntax errors are fatal):
ATTR
An attribute is authorized in a security mask if its Protection attribute equals ExternalRO, External, Free, or User.
<mandatory> MUST BE == Y if this attribute has Mandatory=Yes in the .metadata file.
FATTR
If Protection equals External or ExternalRO, then this attribute SHOULD NOT be visible in:
SHOULD NOT be visible in FUNC Create
SHOULD NOT be modifiable in FUNC Write
You could have either:
no corresponding FATTR command
the following: FATTR <attribute>;N.
If Protection equals Free or User and <mandatory> is Y, then this attribute MUST be visible in FUNC Create
The only valid case is: FATTR < attribute >;Y.
Summary
<Simple>
ATTR <mandatory>
FUNC Create
FUNC Create
Protection
Mandatory
V
<editable>
V
<editable>
External
Yes
Y
O
*
N
External
No
Y/N
O
*
N
Free, User
Yes
Y
X
Y
*
Y/N
Free, User
No
Y
X
Y
*
Y/N
Free, User
No
Y
X
Y
*
Y/N
V indicates the visibility:
x = visible (listed via an FATTR command)
o = not visible
* = indicates any possibilities.
Mask Concatenation
Mask concatenation mechanism is finally a mask override mechanism.
When a user logs on, only one mask is chosen (and loaded) according to the first mask found granted on (in this order):
the person
the current security context
the current security context's project
the current security context's role
the current security context's organization.
If none is found, the DEFAULT mask is applied.
Notes:
there is no search of granted mask in the hierarchy of the current context's project, role or organization. So, even if one (or several) was granted in higher levels in hierarchy, IT WILL NOT BE TAKEN INTO ACCOUNT.
if MORE THAN ONE mask is granted to the same component, the first mask found in the list of available mask commands is taken. You can know this order in using the MQL command:
list mask::*
The recommendation is to grant only ONE mask to a given P&O object to avoid such side effects.
All entities declared in the chosen mask are RESTRICTED: they are subject to access control.
When an entity is RESTRICTED by a mask, ALL its attributes must be EXPLICITLY DECLARED to be accessible. Otherwise, attributes of a restricted entity are considered as NOT ACCESSIBLE. The entities not referenced by a mask have NO RESTRICTION: no access control is applied.
PLMProductDS Sample
The examples below show the effects of security masks as far as the Product dialog boxes are concerned (Product is the alias for the customized PLMProductDS entity, in this example).
If you are using a context with no mask other than the default mask, the Product dialog boxes will look like below.
PLMProductDS Mask Definition
The mask definition of the PLMProductDS entity corresponding to these views is contained in the PLMProductDS.mask file. We show the related part of this file along with the panels. The syntax used to define the security mask is explained in this document.
The mask definition begins with the entity and its attribute definitions:
ENTITY PLMProductDS
ATTR PLM_ExternalID;Y;N;$
ATTR V_version;N;N;$
ATTR V_description;N;N;$
ATTR C_created;N;N;$
ATTR C_modified;N;N;$
ATTR V_maturity;N;N;$
ATTR LOCKUSER;N;N;$
ATTR V_discipline;N;N;$
ATTR V_usage;N;N;$
ATTR V_project;N;N;$
ATTR V_user;Y;N;$
ATTR V_organization;Y;N;$
ATTR V_IndustryCode;N;N;$
ATTR V_StdNumber;N;N;$
ATTR V_BOM;N;Y;Yes
VALUE Yes
VALUE No
ATTR V_Supplier;N;Y;TRUE
VALUE TRUE
VALUE FALSE
ATTR V_SupplierName;N;N;$
VALUE Supplier A
VALUE Supplier B
VALUE Supplier C
Next is the mask for the Create operation. Create controls the creation time attribute list:
Next are the masks for EZQuery and Query operations. Query controls the list of attributes available for queries. EZQuery is the same as Query except that the EZQuery mask is used to define the "Easy" panel (the most-used list of attributes for query) whereas the Query mask is used for the "Extended" and "Expert" panels (all queryable attributes):
You may have noticed the difference between the attribute names contained in the .mask file and the attribute names displayed in the panels which are all NLS enabled aliases. The attribute aliases are not contained in the mask definition any more like in ENOVIA V5 releases, but are contained in CATNls files (on the CATIA client in the directory:
<os>/resources/msgcatalog
that must be provided along with the metadata and mask files to complete the picture for the entities and their attributes. The aliases should conform to the following format:
Where <PLM core type> is one of the possible core types: PLMCoreReference, PLMCoreInstance, PLMCoreRepReference, PLMCoreRepInstance, PLMPort, PLMConnection.
Example: an extract from file PLMProductDS.CATNls: