Integrated generic resource: Fundamentals of product description and support | ISO 10303-41:2021(E) © ISO |
Each implementation of an AP that uses this schema and that encodes entity names shall use the encoding specified in Annex A. Each reference to this schema in an open system shall use the identifier encoding specified in Annex B. This schema is illustrated in Annex D using the EXPRESS-G notation.
EXPRESS specification:
*)
SCHEMA contract_schema;
REFERENCE FROM
support_resource_schema
--
ISO 10303-41
(bag_to_set,
identifier,
label,
text);
(*
NOTE 1 The schemas referenced above are specified in the following parts:
support_resource_schema ISO 10303-41
NOTE 2 See Annex D for a graphical representation of this schema.
NOTE Contracts may be enforceable by law.
EXPRESS specification:
*)
ENTITY contract;
name : label;
purpose : text;
kind : contract_type;
END_ENTITY;
(*
Attribute definitions:
name: the label by which the contract is known.
purpose: an informal description of the reason for the contract.
kind: the contract's type.
NOTE 1 The role of contract_relationship can be defined in the annotated EXPRESS schemas that use or specialize this entity, or by default, in an agreement of common understanding between the partners sharing this information.
NOTE 2 Relationships represented using this entity may be parent child relationship. Annotated EXPRESS schemas that use or specialize this entity specify whether or not the relationship is directed.
NOTE 3 This entity, together with the contract entity, is based on the relationship template that is described in annex E.3.
EXPRESS specification:
*)
ENTITY contract_relationship;
id : identifier;
name : label;
description :
OPTIONAL
text;
relating_contract : contract;
related_contract : contract;
END_ENTITY;
(*
Attribute definitions:
id: the identifier that distinguishes the contract_relationship.
NOTE 4 The context in which id is used as a discriminating characteristic can be identified in an annotated Express schema that uses or specializes this entity, or by default, in an agreement of common understanding between partners sharing this information.
name: the label by which the contract_relationship is known.
description: the text that characterizes the contract_relationship. The value of the attribute need not be specified.
relating_contract: one of the instances of contract that is a part of the relationship.
NOTE 5 The meaning of this attribute can be defined in the annotated EXPRESS schemas that use or specialize this entity, or in an agreement of common understanding between the partners sharing this information.
related_contract: the other instance of contract that is a part of the relationship. If one element of the relationship is dependent upon the other, this attribute shall be the dependent one.
NOTE 6 The meaning of this attribute can be defined in the annotated EXPRESS schemas that use or specialize this entity, or in an agreement of common understanding between the partners sharing this information.
EXAMPLE A contract for an organization that is supplying goods to another organization could be 'fixed' or 'cost plus'.
EXPRESS specification:
*)
ENTITY contract_type;
description : label;
END_ENTITY;
(*
Attribute definitions:
description: the text that characterizes the contract_type. The value of the attribute need not be specified.
NOTE The meaning of this attribute can be defined in the annotated EXPRESS schemas that use or specialize this entity, or in an agreement of common understanding between the partners sharing this information.
The function returns TRUE if no cycle has been detected. Otherwise it returns FALSE.
NOTE 1 The algorithm of the function is explained in annex E.2.
NOTE 2 This function is not used in this schema. It is defined here because other ISO 10303 integrated resources and application protocols that use the contract_relationship entity include rules that use this function.
EXPRESS specification:
*)
FUNCTION acyclic_contract_relationship (relation : contract_relationship; relatives : SET[1:?] OF contract; specific_relation : STRING) : BOOLEAN;
LOCAL x : SET OF contract_relationship; END_LOCAL; IF relation.relating_contract IN relatives THEN RETURN (FALSE); END_IF; x := QUERY(cont <* bag_to_set(USEDIN(relation.relating_contract, 'CONTRACT_SCHEMA.' + 'CONTRACT_RELATIONSHIP.' + 'RELATED_CONTRACT')) | specific_relation IN TYPEOF(cont)); REPEAT i := 1 TO HIINDEX(x); IF NOT acyclic_contract_relationship(x[i], relatives + relation.relating_contract, specific_relation) THEN RETURN (FALSE); END_IF; END_REPEAT; RETURN (TRUE);
END_FUNCTION;
(*
Argument definitions:
relation: (input) the candidate contract_relationship to be checked.
relatives: (input) the set of instances of the entity data type contract for which the function is searching in the relating_contract parameter of the relation argument.
specific_relation: (input) the fully qualified entity name of a type of contract_relationship entity.
*)
END_SCHEMA; -- contract_schema
(*
© ISO 2021 — All rights reserved