Template:— representing_product_relationship (repr_prod_rel)
Capability:representing_parts
Date: 2011/08/01 12:03:38
Revision: 1.5
Template: representing_product_relationship

XML references to the Template

These can be cut and pasted into the XML as required.

representing_product_relationship

Set up a hyperlink to the template definition.
<template_ref name="representing_product_relationship" capability="representing_parts"/>

Set up a table of the template parameters.
<template_table figure_id="?" instance="" name="representing_product_relationship" capability="representing_parts">
  <param name="relating">
    <param_value></param_value>
    <description></description>
  </param>
  <param name="related">
    <param_value></param_value>
    <description></description>
  </param>
  <param name="rel_type_name">
    <param_value></param_value>
    <description></description>
  </param>
  <param name="rel_type_ecl_id">
    <param_value>urn:plcs:rdl:std</param_value>
    <description></description>
  </param>
</template_table>

Setup a template_example:
<template_example name="representing_product_relationship">
  <param_in name="relating" value=""/>
  <param_in name="related" value=""/>
  <param_in name="rel_type_name" value=""/>
  <param_in name="rel_type_ecl_id" value="urn:plcs:rdl:std"/>
</template_example>

representing_product_relationship
/representing_product_relationship(relating='', related='', rel_type_name='', rel_type_ecl_id='urn:plcs:rdl:std')/

Path

Product_relationship
%^prod_rel = Product_relationship%
Product_relationship.relation_type = '/IGNORE'
Product_relationship.description = '/IGNORE'
Product_relationship.relating_product -> @relating
Product_relationship.related_product -> @related

-- provide the type of relationship
/assigning_reference_data(
    items=^prod_rel,
    class_name=@rel_type_name,
    ecl_id=@rel_type_ecl_id)/
The following entities are instantiated with attributes as specified:
Entity in path Value Inherited from
Product_relationship.relation_type '/IGNORE'
Product_relationship.description '/IGNORE'

XML representation of path

<refpath
   template="representing_product_relationship">
   <instantiate
      entity="Product_relationship"
      context="">
      
   </instantiate>
   <bind
      parameter="prod_rel">
      <express_entity
         entity="Product_relationship"
         context="">
         
      </express_entity>
   </bind>
   <assign
      assignment_type="equals"
      context="">
      <target>
         <express_attribute
            entity="Product_relationship"
            attribute="relation_type"
            context="">
            
         </express_attribute>
      </target>
      <source>
         <string
            value=" '/IGNORE' ">
            
         </string>
      </source>
   </assign>
   <assign
      assignment_type="equals"
      context="">
      <target>
         <express_attribute
            entity="Product_relationship"
            attribute="description"
            context="">
            
         </express_attribute>
      </target>
      <source>
         <string
            value=" '/IGNORE' ">
            
         </string>
      </source>
   </assign>
   <assign
      assignment_type="points-to">
      <target>
         <express_attribute
            entity="Product_relationship"
            attribute="relating_product"
            context="">
            
         </express_attribute>
      </target>
      <source>
         <param_in_ref
            name="relating">
            
         </param_in_ref>
      </source>
   </assign>
   <assign
      assignment_type="points-to">
      <target>
         <express_attribute
            entity="Product_relationship"
            attribute="related_product"
            context="">
            
         </express_attribute>
      </target>
      <source>
         <param_in_ref
            name="related">
            
         </param_in_ref>
      </source>
   </assign>
   <comment>
      provide the type of relationship
   </comment>
   <call_template
      name="assigning_reference_data"
      business_context="">
      <param_in
         name="items"
         value="^prod_rel">
         
      </param_in>
      <param_in
         name="class_name"
         value="@rel_type_name">
         
      </param_in>
      <param_in
         name="ecl_id"
         value="@rel_type_ecl_id">
         
      </param_in>
   </call_template>
</refpath>

© OASIS 2010 — All rights reserved