How does select type extension behave?

Phil Spiby Phil.Spiby at eurostep.com
Wed May 15 11:05:43 EDT 2002


Pascal,

My understanding is as follows:
context: Schema_1
attachment_method (nail, screw)

context: Schema_2
attachment_method (nail, screw, glue, weld)
permanent_attachment (nail, screw, glue, weld)

So in the context of schema_1, wall_mounting_1 cannot use glue, in the
context of schema_2, wall_mounting_1 can use glue.
So you are correct!

There is no real difference in the above results if the use is changed to
reference.

Phil
  -----Original Message-----
  From: owner-wg11 at steptools.com [mailto:owner-wg11 at steptools.com]On Behalf
Of Pascal Huau
  Sent: Wednesday, May 15, 2002 2:26 PM
  To: Module exploder; WG11
  Subject: How does select type extension behave?


  Dear all,


  a sudden doubt invades me: what is the consequence of a select type
extension in a multiple schemas context?

  Let's take a slightly modified example of the DAM of P11.

  SCHEMA schema_1;

  TYPE attachment_method = EXTENSIBLE SELECT(nail, screw);

  END_TYPE;

  ENTITY nail;

  END_ENTITY;

  ENTITY screw;

  END_ENTITY;

  ENTITY wall_mounting_1;

  mounting : product;

  on : wall;

  using_method : attachment_method;

  END_ENTITY;

  END_SCHEMA;



  SCHEMA Schema_2;

  USE FROM Schema_1(wall_mounting_1);

  TYPE permanent_attachment = SELECT BASED ON attachment_method WITH (glue,
weld);

  END_TYPE;

  ENTITY glue;

  END_ENTITY;

  ENTITY weld;

  END_ENTITY;

  ENTITY wall_mounting_2;

  mounting : product;

  on : wall;

  using_method : permanent_attachment_method;

  END_ENTITY;

  END_SCHEMA;



  Initial remark: according to the DAM, if there was only one schema,  the
attribute using_method of a valid instance of wall_mounting_1 could refer to
an instance of glue

  Question:

  - in the 2-schemas case,  can the attribute using_method of a valid
instance of wall_mounting_1 refer to an instance of glue?


  My present interpretation is the following:
  - there are in fact two kinds of wall_mounting_1 instances: those that are
created from the definition of wall_mounting_1 in schema_1 and those that
are created from the copy of wall_mounting_1 in schema_2
  - for the first category of instances, the answer to my question is NO.
For the 2nd, the answer is Yes.


  Will this interpretation be correct with the FDAM of Express2?


  NB: I suggest to provide such a 2-schemas example of select type extension
in the FDAM as it corresponds to common cases of select type extension in
the modules.


  Last (for fun):
  - Is this interpretation valid if we replace USE FROM by REFERENCE FROM?


  Regards,
  Pascal Huau
  Association GOSET
  107,111 avenue Clemenceau
  92000 Nanterre
  France
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.steptools.com/pipermail/wg11/attachments/20020515/c890256e/attachment.htm


More information about the wg11 mailing list