Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » Missing Model Object in the Example EMF Model Creation Wizard
Missing Model Object in the Example EMF Model Creation Wizard [message #408960] Wed, 02 May 2007 17:58 Go to next message
Matthew Rawlings is currently offline Matthew RawlingsFriend
Messages: 39
Registered: July 2009
Member
1. I imported my XSD schema to an eCore and genmodel file.
<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified" attributeFormDefault="unqualified">
<xs:element name="FpML">
<xs:complexType>
<xs:simpleContent>
<xs:extension base="xs:string">
<xs:attributeGroup ref="StandardAttributes.atts"/>
</xs:extension>
</xs:simpleContent>
</xs:complexType>
</xs:element>
<xs:attributeGroup name="StandardAttributes.atts">
<xs:attribute name="version" use="required">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="4-0"/>
<xs:enumeration value="4-1"/>
<xs:enumeration value="4-2"/>
<xs:enumeration value="4-3"/>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
<xs:attribute name="expectedBuild" type="xs:positiveInteger"/>
<xs:attribute name="actualBuild" type="xs:positiveInteger" fixed="3"/>
</xs:attributeGroup>
</xs:schema>

2. I generated the model code, edit code, and editor code for the genmodel.

3. I ran the editor project as an Eclipse application. I selected the model
under Example EMF Model Creation Wizards. I selected the file name.

4. I got to the Dialog that said "Select a model object to create". There
were no model objects present in the Model Object drop down box to select.

My expected result was that I could select "FpML" in the drop-down box. I
would then have created a file that would have contained the following:
<?xml version="1.0" encoding="UTF-8"?>
<FpML version="4-3" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="fpmlTest3.xsd" expectedBuild="1234"
actualBuild="3">
</FpML>


What prevents "FpML" being listed as a Model Object in the wizard's drop
down selector? How should I work around this?
Re: Missing Model Object in the Example EMF Model Creation Wizard [message #408962 is a reply to message #408960] Wed, 02 May 2007 20:20 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33140
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.
--------------000802060406070003040209
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

Matthew,

I just tried it and could create this:

<?xml version="1.0" encoding="UTF-8"?>
<FpML actualBuild="4" expectedBuild="5" version="4-3">10</FpML>

The dialog should provide choices based on all your global elements.
Does your model wizard have a method that looks like this:

protected Collection<String> getInitialObjectNames()
{
if (initialObjectNames == null)
{
initialObjectNames = new ArrayList<String>();
for (EStructuralFeature eStructuralFeature :
ExtendedMetaData.INSTANCE.getAllElements(ExtendedMetaData.IN STANCE.getDocumentRoot(fpmlPackage)))
{
EClassifier eClassifier = eStructuralFeature.getEType();
if (eClassifier instanceof EClass)
{
EClass eClass = (EClass)eClassifier;
if (!eClass.isAbstract())
{
initialObjectNames.add(eStructuralFeature.getName());
}
}
}
Collections.sort(initialObjectNames,
java.text.Collator.getInstance());
}
return initialObjectNames;
}

Which version of EMF are you trying this with?


Matthew Rawlings wrote:
> 1. I imported my XSD schema to an eCore and genmodel file.
> <?xml version="1.0" encoding="UTF-8"?>
> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
> elementFormDefault="qualified" attributeFormDefault="unqualified">
> <xs:element name="FpML">
> <xs:complexType>
> <xs:simpleContent>
> <xs:extension base="xs:string">
> <xs:attributeGroup ref="StandardAttributes.atts"/>
> </xs:extension>
> </xs:simpleContent>
> </xs:complexType>
> </xs:element>
> <xs:attributeGroup name="StandardAttributes.atts">
> <xs:attribute name="version" use="required">
> <xs:simpleType>
> <xs:restriction base="xs:token">
> <xs:enumeration value="4-0"/>
> <xs:enumeration value="4-1"/>
> <xs:enumeration value="4-2"/>
> <xs:enumeration value="4-3"/>
> </xs:restriction>
> </xs:simpleType>
> </xs:attribute>
> <xs:attribute name="expectedBuild" type="xs:positiveInteger"/>
> <xs:attribute name="actualBuild" type="xs:positiveInteger" fixed="3"/>
> </xs:attributeGroup>
> </xs:schema>
>
> 2. I generated the model code, edit code, and editor code for the genmodel.
>
> 3. I ran the editor project as an Eclipse application. I selected the model
> under Example EMF Model Creation Wizards. I selected the file name.
>
> 4. I got to the Dialog that said "Select a model object to create". There
> were no model objects present in the Model Object drop down box to select.
>
> My expected result was that I could select "FpML" in the drop-down box. I
> would then have created a file that would have contained the following:
> <?xml version="1.0" encoding="UTF-8"?>
> <FpML version="4-3" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:noNamespaceSchemaLocation="fpmlTest3.xsd" expectedBuild="1234"
> actualBuild="3">
> </FpML>
>
>
> What prevents "FpML" being listed as a Model Object in the wizard's drop
> down selector? How should I work around this?
>
>
>


--------------000802060406070003040209
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Matthew,<br>
<br>
I just tried it and could create this:<br>
<blockquote>&lt;?xml version="1.0" encoding="UTF-8"?&gt;<br>
&lt;FpML actualBuild="4" expectedBuild="5"
version="4-3"&gt;10&lt;/FpML&gt;<br>
</blockquote>
The dialog should provide choices based on all your global elements.&nbsp;
Does your model wizard have a method that looks like this:<br>
<blockquote><small>&nbsp; protected Collection&lt;String&gt;
getInitialObjectNames()</small><br>
<small>&nbsp; {</small><br>
<small>&nbsp;&nbsp;&nbsp; if (initialObjectNames == null)</small><br>
<small>&nbsp;&nbsp;&nbsp; {</small><br>
<small>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; initialObjectNames = new ArrayList&lt;String&gt;();</small><br>
<small>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; for (EStructuralFeature eStructuralFeature :
ExtendedMetaData.INSTANCE.getAllElements(ExtendedMetaData.IN STANCE.getDocumentRoot(fpmlPackage))) </small><br>
<small>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {</small><br>
<small> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; EClassifier eClassifier =
eStructuralFeature.getEType();</small><br>
<small> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; if (eClassifier instanceof EClass)</small><br>
<small> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; {</small><br>
<small> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; EClass eClass = (EClass)eClassifier;</small><br>
<small> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; if (!eClass.isAbstract())</small><br>
<small> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; {</small><br>
<small> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
initialObjectNames.add(eStructuralFeature.getName());</small ><br>
<small> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; }</small><br>
<small> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; }</small><br>
<small>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }</small><br>
<small>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Collections.sort(initialObjectNames,
java.text.Collator.getInstance());</small><br>
<small>&nbsp;&nbsp;&nbsp; }</small><br>
<small>&nbsp;&nbsp;&nbsp; return initialObjectNames;</small><br>
<small>&nbsp; }</small><br>
</blockquote>
Which version of EMF are you trying this with?<br>
<br>
<br>
Matthew Rawlings wrote:
<blockquote cite="midf1ajgp$i1i$1@build.eclipse.org" type="cite">
<pre wrap="">1. I imported my XSD schema to an eCore and genmodel file.
&lt;?xml version="1.0" encoding="UTF-8"?&gt;
&lt;xs:schema xmlns:xs=<a class="moz-txt-link-rfc2396E" href="http://www.w3.org/2001/XMLSchema">"http://www.w3.org/2001/XMLSchema"</a>
elementFormDefault="qualified" attributeFormDefault="unqualified"&gt;
&lt;xs:element name="FpML"&gt;
&lt;xs:complexType&gt;
&lt;xs:simpleContent&gt;
&lt;xs:extension base="xs:string"&gt;
&lt;xs:attributeGroup ref="StandardAttributes.atts"/&gt;
&lt;/xs:extension&gt;
&lt;/xs:simpleContent&gt;
&lt;/xs:complexType&gt;
&lt;/xs:element&gt;
&lt;xs:attributeGroup name="StandardAttributes.atts"&gt;
&lt;xs:attribute name="version" use="required"&gt;
&lt;xs:simpleType&gt;
&lt;xs:restriction base="xs:token"&gt;
&lt;xs:enumeration value="4-0"/&gt;
&lt;xs:enumeration value="4-1"/&gt;
&lt;xs:enumeration value="4-2"/&gt;
&lt;xs:enumeration value="4-3"/&gt;
&lt;/xs:restriction&gt;
&lt;/xs:simpleType&gt;
&lt;/xs:attribute&gt;
&lt;xs:attribute name="expectedBuild" type="xs:positiveInteger"/&gt;
&lt;xs:attribute name="actualBuild" type="xs:positiveInteger" fixed="3"/&gt;
&lt;/xs:attributeGroup&gt;
&lt;/xs:schema&gt;

2. I generated the model code, edit code, and editor code for the genmodel.

3. I ran the editor project as an Eclipse application. I selected the model
under Example EMF Model Creation Wizards. I selected the file name.

4. I got to the Dialog that said "Select a model object to create". There
were no model objects present in the Model Object drop down box to select.

My expected result was that I could select "FpML" in the drop-down box. I
would then have created a file that would have contained the following:
&lt;?xml version="1.0" encoding="UTF-8"?&gt;
&lt;FpML version="4-3" xmlns:xsi=<a class="moz-txt-link-rfc2396E" href="http://www.w3.org/2001/XMLSchema-instance">"http://www.w3.org/2001/XMLSchema-instance"</a>
xsi:noNamespaceSchemaLocation="fpmlTest3.xsd" expectedBuild="1234"
actualBuild="3"&gt;
&lt;/FpML&gt;


What prevents "FpML" being listed as a Model Object in the wizard's drop
down selector? How should I work around this?


</pre>
</blockquote>
<br>
</body>
</html>

--------------000802060406070003040209--


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Missing Model Object in the Example EMF Model Creation Wizard [message #408966 is a reply to message #408962] Wed, 02 May 2007 21:29 Go to previous messageGo to next message
Matthew Rawlings is currently offline Matthew RawlingsFriend
Messages: 39
Registered: July 2009
Member
Hi Ed,

I am running EMF 2.2.0.v200702131851 on Eclipse 3.2.2.

This problem is resolved. It was my configuration error in retesting a
problem before posting. I can produce this fine now.

The remaining problem is that the name of the Model Object is changed to "Fp
ML Type". Why is there a space inserted between "Fp" and "ML"?

Example from file: FpMLTypeImpl.java

package FpmlTest4.impl;

import FpmlTest4.FpMLType;
import FpmlTest4.FpmlTest4Package;
import FpmlTest4.VersionType;

import java.math.BigInteger;

import org.eclipse.emf.common.notify.Notification;

import org.eclipse.emf.ecore.EClass;

import org.eclipse.emf.ecore.impl.ENotificationImpl;
import org.eclipse.emf.ecore.impl.EObjectImpl;

/**
* <!-- begin-user-doc -->
* An implementation of the model object '<em><b>Fp ML Type</b></em>'.
* <!-- end-user-doc -->


Why is a space inserted in the model object name, the one that appears in
the user-doc? This appears consistently throughout the code wherever the
model object name is used.

- Matthew
Re: Missing Model Object in the Example EMF Model Creation Wizard [message #408967 is a reply to message #408962] Wed, 02 May 2007 21:36 Go to previous messageGo to next message
Matthew Rawlings is currently offline Matthew RawlingsFriend
Messages: 39
Registered: July 2009
Member
This is the correct schema to reproduce the problem. Apologies for
publishing the incorrect schema before.

When I use this schema I get an empty drop down box when selecting a Model
Object in the creation wizard.

<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified" attributeFormDefault="unqualified">
<xs:element name="FpML" type="Document">
<xs:annotation>
<xs:documentation xml:lang="en">The FpML element forms the root for any
conforming FpML instance document. The actual structure of the document is
determined by setting the 'type' attribute to an appropriate derived subtype
of the complex type Document.</xs:documentation>
</xs:annotation>
</xs:element>
<xs:complexType name="Document" abstract="true">
<xs:annotation>
<xs:documentation xml:lang="en">The abstract base type from which all
FpML compliant messages and documents must be derived.</xs:documentation>
</xs:annotation>
<xs:attributeGroup ref="StandardAttributes.atts"/>
</xs:complexType>
<xs:attributeGroup name="StandardAttributes.atts">
<xs:attribute name="version" use="required">
<xs:annotation>
<xs:documentation xml:lang="en">Indicate which version of the FpML
Schema an FpML message adheres to.</xs:documentation>
</xs:annotation>
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="4-0"/>
<xs:enumeration value="4-1"/>
<xs:enumeration value="4-2"/>
<xs:enumeration value="4-3"/>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
<xs:attribute name="expectedBuild" type="xs:positiveInteger">
<xs:annotation>
<xs:documentation xml:lang="en">The message creator can send the build
number of the schema on which they built the messages against.
</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="actualBuild" type="xs:positiveInteger" fixed="3">
<xs:annotation>
<xs:documentation xml:lang="en">Taken from the schemas that the
recipient validated against. Every time there is a change on the schema,
validation rules, or examples within a version the actual build number is
incremented. If no changes have been made between releases within a version
(i.e. from Trial Recommendation to Recommendation) the actual build number
stays the same.</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:attributeGroup>
<xs:complexType name="DataDocument">
<xs:annotation>
<xs:documentation xml:lang="en">A type defining a content model that is
backwards compatible with older FpML releases and which can be used to
contain sets of data without expressing any processing
intention.</xs:documentation>
</xs:annotation>
<xs:complexContent>
<xs:extension base="Document">
<xs:sequence>
<xs:group ref="Validation.model"/>
<xs:element name="party" type="xs:string" minOccurs="0"
maxOccurs="unbounded">
<xs:annotation>
<xs:documentation xml:lang="en">A legal entity or a subdivision of a
legal entity.</xs:documentation>
<xs:documentation xml:lang="en">Parties can perform multiple roles in
a trade lifecycle. For example, the principal parties obligated to make
payments from time to time during the term of the trade, but may include
other parties involved in, or incidental to, the trade, such as parties
acting in the role of novation transferor/transferee, broker, calculation
agent, etc. In FpML roles are defined in multiple places within a
document.</xs:documentation>
</xs:annotation>
</xs:element>
</xs:sequence>
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:group name="Validation.model">
<xs:sequence>
<xs:element name="validation" type="xs:string" minOccurs="0"
maxOccurs="unbounded"/>
</xs:sequence>
</xs:group>
</xs:schema>
Re: Missing Model Object in the Example EMF Model Creation Wizard [message #408969 is a reply to message #408967] Wed, 02 May 2007 21:56 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33140
Registered: July 2009
Senior Member
Matthew,

Since Document is abstract the generated code I showed in the previous
post won't and can't create an instance of it and it's not smart enough
to look for derived classes that could substitute. It's a very odd
design for a schema to define a model for which an xsi:type is needed
for the root element. I've never seen one like that before...


Matthew Rawlings wrote:
> This is the correct schema to reproduce the problem. Apologies for
> publishing the incorrect schema before.
>
> When I use this schema I get an empty drop down box when selecting a Model
> Object in the creation wizard.
>
> <?xml version="1.0" encoding="UTF-8"?>
> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
> elementFormDefault="qualified" attributeFormDefault="unqualified">
> <xs:element name="FpML" type="Document">
> <xs:annotation>
> <xs:documentation xml:lang="en">The FpML element forms the root for any
> conforming FpML instance document. The actual structure of the document is
> determined by setting the 'type' attribute to an appropriate derived subtype
> of the complex type Document.</xs:documentation>
> </xs:annotation>
> </xs:element>
> <xs:complexType name="Document" abstract="true">
> <xs:annotation>
> <xs:documentation xml:lang="en">The abstract base type from which all
> FpML compliant messages and documents must be derived.</xs:documentation>
> </xs:annotation>
> <xs:attributeGroup ref="StandardAttributes.atts"/>
> </xs:complexType>
> <xs:attributeGroup name="StandardAttributes.atts">
> <xs:attribute name="version" use="required">
> <xs:annotation>
> <xs:documentation xml:lang="en">Indicate which version of the FpML
> Schema an FpML message adheres to.</xs:documentation>
> </xs:annotation>
> <xs:simpleType>
> <xs:restriction base="xs:token">
> <xs:enumeration value="4-0"/>
> <xs:enumeration value="4-1"/>
> <xs:enumeration value="4-2"/>
> <xs:enumeration value="4-3"/>
> </xs:restriction>
> </xs:simpleType>
> </xs:attribute>
> <xs:attribute name="expectedBuild" type="xs:positiveInteger">
> <xs:annotation>
> <xs:documentation xml:lang="en">The message creator can send the build
> number of the schema on which they built the messages against.
> </xs:documentation>
> </xs:annotation>
> </xs:attribute>
> <xs:attribute name="actualBuild" type="xs:positiveInteger" fixed="3">
> <xs:annotation>
> <xs:documentation xml:lang="en">Taken from the schemas that the
> recipient validated against. Every time there is a change on the schema,
> validation rules, or examples within a version the actual build number is
> incremented. If no changes have been made between releases within a version
> (i.e. from Trial Recommendation to Recommendation) the actual build number
> stays the same.</xs:documentation>
> </xs:annotation>
> </xs:attribute>
> </xs:attributeGroup>
> <xs:complexType name="DataDocument">
> <xs:annotation>
> <xs:documentation xml:lang="en">A type defining a content model that is
> backwards compatible with older FpML releases and which can be used to
> contain sets of data without expressing any processing
> intention.</xs:documentation>
> </xs:annotation>
> <xs:complexContent>
> <xs:extension base="Document">
> <xs:sequence>
> <xs:group ref="Validation.model"/>
> <xs:element name="party" type="xs:string" minOccurs="0"
> maxOccurs="unbounded">
> <xs:annotation>
> <xs:documentation xml:lang="en">A legal entity or a subdivision of a
> legal entity.</xs:documentation>
> <xs:documentation xml:lang="en">Parties can perform multiple roles in
> a trade lifecycle. For example, the principal parties obligated to make
> payments from time to time during the term of the trade, but may include
> other parties involved in, or incidental to, the trade, such as parties
> acting in the role of novation transferor/transferee, broker, calculation
> agent, etc. In FpML roles are defined in multiple places within a
> document.</xs:documentation>
> </xs:annotation>
> </xs:element>
> </xs:sequence>
> </xs:extension>
> </xs:complexContent>
> </xs:complexType>
> <xs:group name="Validation.model">
> <xs:sequence>
> <xs:element name="validation" type="xs:string" minOccurs="0"
> maxOccurs="unbounded"/>
> </xs:sequence>
> </xs:group>
> </xs:schema>
>
>
>


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Missing Model Object in the Example EMF Model Creation Wizard [message #408972 is a reply to message #408969] Thu, 03 May 2007 10:03 Go to previous messageGo to next message
Matthew Rawlings is currently offline Matthew RawlingsFriend
Messages: 39
Registered: July 2009
Member
Ed,

The example is from the FpML schema http://www.fpml.org/ which is a
Standard for financial products used by Banks, Securities Houses,
Brokerages, Insurers, Hedge Funds, and Exchanges. It is very widely
adopted in the financial services industry.

As this is legal XML Schema shall I raise an unplanned enhancement for EMF
to look for valid alternative types?
Re: Missing Model Object in the Example EMF Model Creation Wizard [message #408974 is a reply to message #408972] Thu, 03 May 2007 11:12 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33140
Registered: July 2009
Senior Member
Matthew,

It being a standard doesn't mean it's a good design. ;-) In general,
hand modifying the wizard to provide only the useful/sensible choices
would seem like a reasonable way to deal with corner cases. So while a
feature request is reasonable, our limited development resource likely
needs to focus on more common issues, so without a contribution, it's
not a given that this will be addressed in the current release cycle.


Matthew Rawlings wrote:
> Ed,
>
> The example is from the FpML schema http://www.fpml.org/ which is a
> Standard for financial products used by Banks, Securities Houses,
> Brokerages, Insurers, Hedge Funds, and Exchanges. It is very widely
> adopted in the financial services industry.
>
> As this is legal XML Schema shall I raise an unplanned enhancement for
> EMF to look for valid alternative types?
>
>


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Missing Model Object in the Example EMF Model Creation Wizard [message #409006 is a reply to message #408966] Thu, 03 May 2007 14:37 Go to previous messageGo to next message
Matthew Rawlings is currently offline Matthew RawlingsFriend
Messages: 39
Registered: July 2009
Member
Any comment on why "FpML" turns into "Fp ML"? Is this expected behaviour?
Re: Missing Model Object in the Example EMF Model Creation Wizard [message #409010 is a reply to message #409006] Thu, 03 May 2007 15:00 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33140
Registered: July 2009
Senior Member
Matthew,

Yes. Any switch in case from lower to upper is assumed to be a camel
case change that ends one word and starts the next. E.g., AbcXyz
becomes Abc Xyz and AbcXML will become Abc XML. Of course you can edit
the .properties file to fix that, but this don't help with the generated
Javadoc or with constants like DOCUMENT_ROOT__FP_ML.


Matthew Rawlings wrote:
> Any comment on why "FpML" turns into "Fp ML"? Is this expected behaviour?
>


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Missing Model Object in the Example EMF Model Creation Wizard [message #409377 is a reply to message #408974] Fri, 18 May 2007 03:41 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: treilly.prolifics.com

My 2 cents: I wouldn't categorize this as a corner case.
e.g.:
http://maven.apache.org/maven-v4_0_0.xsd

I would say separating types and elements is a best practice and allows for
better extensibility (even at the root element.)
Definitely strikes the "bug" note for me.

"Ed Merks" <merks@ca.ibm.com> wrote in message
news:f1cg32$hq0$1@build.eclipse.org...
> Matthew,
>
> It being a standard doesn't mean it's a good design. ;-) In general,
> hand modifying the wizard to provide only the useful/sensible choices
> would seem like a reasonable way to deal with corner cases. So while a
> feature request is reasonable, our limited development resource likely
> needs to focus on more common issues, so without a contribution, it's not
> a given that this will be addressed in the current release cycle.
>
>
> Matthew Rawlings wrote:
>> Ed,
>>
>> The example is from the FpML schema http://www.fpml.org/ which is a
>> Standard for financial products used by Banks, Securities Houses,
>> Brokerages, Insurers, Hedge Funds, and Exchanges. It is very widely
>> adopted in the financial services industry.
>>
>> As this is legal XML Schema shall I raise an unplanned enhancement for
>> EMF to look for valid alternative types?
>>
>>
Re: Missing Model Object in the Example EMF Model Creation Wizard [message #409379 is a reply to message #409377] Fri, 18 May 2007 05:23 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33140
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.
--------------030302020407050404040808
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

Tim,

I think you've misunderstood because the example you point at has a root
element for which the type is a non-abstract complex type, so it's
definitely not an example of a corner case schema in which there is not
even a single root element that can be used without also requiring an
xsi:type. So I'll continue to assert that such a situation is very odd
(I've only seen it once it all my years of looking at schemas) and it
doesn't strike me as a good thing.


Tim Reilly wrote:
> My 2 cents: I wouldn't categorize this as a corner case.
> e.g.:
> http://maven.apache.org/maven-v4_0_0.xsd
>
> I would say separating types and elements is a best practice and allows for
> better extensibility (even at the root element.)
> Definitely strikes the "bug" note for me.
>
> "Ed Merks" <merks@ca.ibm.com> wrote in message
> news:f1cg32$hq0$1@build.eclipse.org...
>
>> Matthew,
>>
>> It being a standard doesn't mean it's a good design. ;-) In general,
>> hand modifying the wizard to provide only the useful/sensible choices
>> would seem like a reasonable way to deal with corner cases. So while a
>> feature request is reasonable, our limited development resource likely
>> needs to focus on more common issues, so without a contribution, it's not
>> a given that this will be addressed in the current release cycle.
>>
>>
>> Matthew Rawlings wrote:
>>
>>> Ed,
>>>
>>> The example is from the FpML schema http://www.fpml.org/ which is a
>>> Standard for financial products used by Banks, Securities Houses,
>>> Brokerages, Insurers, Hedge Funds, and Exchanges. It is very widely
>>> adopted in the financial services industry.
>>>
>>> As this is legal XML Schema shall I raise an unplanned enhancement for
>>> EMF to look for valid alternative types?
>>>
>>>
>>>
>
>
>


--------------030302020407050404040808
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Tim,<br>
<br>
I think you've misunderstood because the example you point at has a
root element for which the type is a non-abstract complex type, so it's
definitely not an example of a corner case schema in which there is not
even a single root element that can be used without also requiring an
xsi:type.&nbsp; So I'll continue to assert that such a situation is very odd
(I've only seen it once it all my years of looking at schemas) and it
doesn't strike me as a good thing.<br>
<br>
<br>
Tim Reilly wrote:
<blockquote cite="midf2j78p$pk6$1@build.eclipse.org" type="cite">
<pre wrap="">My 2 cents: I wouldn't categorize this as a corner case.
e.g.:
<a class="moz-txt-link-freetext" href="http://maven.apache.org/maven-v4_0_0.xsd">http://maven.apache.org/maven-v4_0_0.xsd</a>

I would say separating types and elements is a best practice and allows for
better extensibility (even at the root element.)
Definitely strikes the "bug" note for me.

"Ed Merks" <a class="moz-txt-link-rfc2396E" href="mailto:merks@ca.ibm.com">&lt;merks@ca.ibm.com&gt;</a> wrote in message
<a class="moz-txt-link-freetext" href="news:f1cg32$hq0$1@build.eclipse.org">news:f1cg32$hq0$1@build.eclipse.org</a>...
</pre>
<blockquote type="cite">
<pre wrap="">Matthew,

It being a standard doesn't mean it's a good design. ;-) In general,
hand modifying the wizard to provide only the useful/sensible choices
would seem like a reasonable way to deal with corner cases. So while a
feature request is reasonable, our limited development resource likely
needs to focus on more common issues, so without a contribution, it's not
a given that this will be addressed in the current release cycle.


Matthew Rawlings wrote:
</pre>
<blockquote type="cite">
<pre wrap="">Ed,

The example is from the FpML schema <a class="moz-txt-link-freetext" href="http://www.fpml.org/">http://www.fpml.org/</a> which is a
Standard for financial products used by Banks, Securities Houses,
Brokerages, Insurers, Hedge Funds, and Exchanges. It is very widely
adopted in the financial services industry.

As this is legal XML Schema shall I raise an unplanned enhancement for
EMF to look for valid alternative types?


</pre>
</blockquote>
</blockquote>
<pre wrap=""><!---->

</pre>
</blockquote>
<br>
</body>
</html>

--------------030302020407050404040808--


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Missing Model Object in the Example EMF Model Creation Wizard [message #409425 is a reply to message #409379] Tue, 22 May 2007 03:05 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: treilly.prolifics.com

Hi Ed,

Poor mistake on my part! You are correct..

I thought this was the same reason I do not get an EObject for the project
element in the maven xsd from codegen.
BUG 185357, Re: Missing Model Object in the Example EMF Model Creation Wizard [message #427143 is a reply to message #409379] Tue, 03 February 2009 21:02 Go to previous messageGo to next message
Philipp Kutter is currently offline Philipp KutterFriend
Messages: 306
Registered: July 2009
Senior Member
Dear Ed.
This was reported as Bug
https://bugs.eclipse.org/bugs/show_bug.cgi?id=185357
back in 2007.

We moved now forward 2 years, and I think that we should reconsider
things, that where corner-cases back then.

As well, consider that while what you say about XML Schema design may
be true, the problem could as well be looked at from the MOF/ECore
perspective:
Is having a main package, which has abstract classes, and then different
packages which implement the concrete classes such a corner case?

And how would we generate an editor for this case?

Please remember, that a very related problem, generating "create new"
actions in the editor for inheriting classes (not know in the package of
the class which has the corresponding feature) has been fixed by your team!

Please give me a little sign that you might reconsider your opinion, and
I'll put efforts in providing examples and in documenting variants of
this problem in the bug.

Best Regards, Philipp

Ed Merks wrote:
> Tim,
>
> I think you've misunderstood because the example you point at has a root
> element for which the type is a non-abstract complex type, so it's
> definitely not an example of a corner case schema in which there is not
> even a single root element that can be used without also requiring an
> xsi:type. So I'll continue to assert that such a situation is very odd
> (I've only seen it once it all my years of looking at schemas) and it
> doesn't strike me as a good thing.
>
>
> Tim Reilly wrote:
>> My 2 cents: I wouldn't categorize this as a corner case.
>> e.g.:
>> http://maven.apache.org/maven-v4_0_0.xsd
>>
>> I would say separating types and elements is a best practice and allows for
>> better extensibility (even at the root element.)
>> Definitely strikes the "bug" note for me.
>>
>> "Ed Merks" <merks@ca.ibm.com> wrote in message
>> news:f1cg32$hq0$1@build.eclipse.org...
>>
>>> Matthew,
>>>
>>> It being a standard doesn't mean it's a good design. ;-) In general,
>>> hand modifying the wizard to provide only the useful/sensible choices
>>> would seem like a reasonable way to deal with corner cases. So while a
>>> feature request is reasonable, our limited development resource likely
>>> needs to focus on more common issues, so without a contribution, it's not
>>> a given that this will be addressed in the current release cycle.
>>>
>>>
>>> Matthew Rawlings wrote:
>>>
>>>> Ed,
>>>>
>>>> The example is from the FpML schema http://www.fpml.org/ which is a
>>>> Standard for financial products used by Banks, Securities Houses,
>>>> Brokerages, Insurers, Hedge Funds, and Exchanges. It is very widely
>>>> adopted in the financial services industry.
>>>>
>>>> As this is legal XML Schema shall I raise an unplanned enhancement for
>>>> EMF to look for valid alternative types?
>>>>
>>>>
>>>>
>>
>>
>>
>
Re: BUG 185357, Re: Missing Model Object in the Example EMF Model Creation Wizard [message #427148 is a reply to message #427143] Wed, 04 February 2009 12:14 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33140
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.
--------------040309060800060709080203
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

Philipp,

Comments below.

Philipp Kutter wrote:
> Dear Ed.
> This was reported as Bug
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=185357
> back in 2007.
>
> We moved now forward 2 years, and I think that we should reconsider
> things, that where corner-cases back then.
I've got a list of 100 bugzillas all of which are worth (re)considering:

https://bugs.eclipse.org/bugs/buglist.cgi?product=EMF&co mponent=Core&component=Doc&component=Edit&compon ent=Mapping&component=Tools&component=XML/XMI&bu g_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED &bug_status=RESOLVED&resolution=FIXED&resolution =---&order=bugs.bug_status,bugs.target_milestone,bugs.bu g_id&query_format=advanced
< https://bugs.eclipse.org/bugs/buglist.cgi?product=EMF&co mponent=Core&component=Doc&component=Edit&compon ent=Mapping&component=Tools&component=XML/XMI&bu g_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED &bug_status=RESOLVED&resolution=FIXED&resolution =---&order=bugs.bug_status,bugs.target_milestone,bugs.bu g_id&query_format=advanced>

The vast majority of these have no associated patches and are
effectively waiting for me to do the work.
>
> As well, consider that while what you say about XML Schema design may
> be true, the problem could as well be looked at from the MOF/ECore
> perspective:
> Is having a main package, which has abstract classes, and then
> different packages which implement the concrete classes such a
> corner case?
Yes, I think so.
>
> And how would we generate an editor for this case?
Given that you only have abstract classes, there's really nothing to
create so while we can have an editor, and we support extensible child
creation, we can't really generate a wizard that creates anything since
as you've described, there is nothing to create.
>
> Please remember, that a very related problem, generating "create new"
> actions in the editor for inheriting classes (not know in the package
> of the class which has the corresponding feature) has been fixed by
> your team!
There are few things I forget. :-P
>
> Please give me a little sign that you might reconsider your opinion, and
> I'll put efforts in providing examples and in documenting variants of
> this problem in the bug.
It's just not a high priority for me. Given that I have 100 things to
do, I will need to spend my time on the things that personally feel are
likely to have the most value for the most people. This problem just
isn't high on that list. What's at the top of my list right now is
access listeners https://bugs.eclipse.org/bugs/show_bug.cgi?id=247130
and even finding time for that is far too challenging.
>
> Best Regards, Philipp
>
> Ed Merks wrote:
>> Tim,
>>
>> I think you've misunderstood because the example you point at has a
>> root element for which the type is a non-abstract complex type, so
>> it's definitely not an example of a corner case schema in which there
>> is not even a single root element that can be used without also
>> requiring an xsi:type. So I'll continue to assert that such a
>> situation is very odd (I've only seen it once it all my years of
>> looking at schemas) and it doesn't strike me as a good thing.
>>
>>
>> Tim Reilly wrote:
>>> My 2 cents: I wouldn't categorize this as a corner case.
>>> e.g.:
>>> http://maven.apache.org/maven-v4_0_0.xsd
>>>
>>> I would say separating types and elements is a best practice and
>>> allows for better extensibility (even at the root element.)
>>> Definitely strikes the "bug" note for me.
>>>
>>> "Ed Merks" <merks@ca.ibm.com> wrote in message
>>> news:f1cg32$hq0$1@build.eclipse.org...
>>>
>>>> Matthew,
>>>>
>>>> It being a standard doesn't mean it's a good design. ;-) In
>>>> general, hand modifying the wizard to provide only the
>>>> useful/sensible choices would seem like a reasonable way to deal
>>>> with corner cases. So while a feature request is reasonable, our
>>>> limited development resource likely needs to focus on more common
>>>> issues, so without a contribution, it's not a given that this will
>>>> be addressed in the current release cycle.
>>>>
>>>>
>>>> Matthew Rawlings wrote:
>>>>
>>>>> Ed,
>>>>>
>>>>> The example is from the FpML schema http://www.fpml.org/ which is
>>>>> a Standard for financial products used by Banks, Securities
>>>>> Houses, Brokerages, Insurers, Hedge Funds, and Exchanges. It is
>>>>> very widely adopted in the financial services industry.
>>>>>
>>>>> As this is legal XML Schema shall I raise an unplanned enhancement
>>>>> for EMF to look for valid alternative types?
>>>>>
>>>>>
>>>>>
>>>
>>>
>>>
>>

--------------040309060800060709080203
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Philipp,<br>
<br>
Comments below.<br>
<br>
Philipp Kutter wrote:
<blockquote cite="mid:4988B0E6.6000800@montages.com" type="cite">Dear
Ed.
<br>
This was reported as Bug
<a class="moz-txt-link-freetext" href="https://bugs.eclipse.org/bugs/show_bug.cgi?id=185357">https://bugs.eclipse.org/bugs/show_bug.cgi?id=185357</a>
<br>
back in 2007.
<br>
<br>
We moved now forward 2 years, and I think that we should reconsider
things, that where corner-cases back then.
<br>
</blockquote>
I've got a list of 100 bugzillas all of which are worth (re)considering:<br>
<blockquote><a
href=" https://bugs.eclipse.org/bugs/buglist.cgi?product=EMF&am p ;component=Core&amp;component=Doc&amp;component=Edit &amp;component=Mapping&amp;component=Tools&amp;c omponent=XML/XMI&amp;bug_status=NEW&amp;bug_status=A SSIGNED&amp;bug_status=REOPENED&amp;bug_status=RESOL VED&amp;resolution=FIXED&amp;resolution=---&amp; order=bugs.bug_status,bugs.target_milestone,bugs.bug_id& amp;query_format=advanced "> https://bugs.eclipse.org/bugs/buglist.cgi?product=EMF&am p ;component=Core&amp;component=Doc&amp;component=Edit &amp;component=Mapping&amp;component=Tools&amp;c omponent=XML/XMI&amp;bug_status=NEW&amp;bug_status=A SSIGNED&amp;bug_status=REOPENED&amp;bug_status=RESOL VED&amp;resolution=FIXED&amp;resolution=---&amp; order=bugs.bug_status,bugs.target_milestone,bugs.bug_id& amp;query_format=advanced </a><br>
</blockquote>
The vast majority of these have no associated patches and are
effectively waiting for me to do the work.<br>
<blockquote cite="mid:4988B0E6.6000800@montages.com" type="cite"><br>
As well, consider that while what you say about XML Schema design may
<br>
be true, the problem could as well be looked at from the MOF/ECore
perspective:
<br>
Is having a main package, which has abstract classes, and then
different &nbsp;&nbsp; packages which implement the concrete classes such a
corner case?
<br>
</blockquote>
Yes, I think so.<br>
<blockquote cite="mid:4988B0E6.6000800@montages.com" type="cite"><br>
And how would we generate an editor for this case?
<br>
</blockquote>
Given that you only have abstract classes, there's really nothing to
create so while we can have an editor, and we support extensible child
creation, we can't really generate a wizard that creates anything since
as you've described, there is nothing to create.<br>
<blockquote cite="mid:4988B0E6.6000800@montages.com" type="cite"><br>
Please remember, that a very related problem, generating "create new"
actions in the editor for inheriting classes (not know in the package
of the class which has the corresponding feature) has been fixed by
your team!
<br>
</blockquote>
There are few things I forget. :-P<br>
<blockquote cite="mid:4988B0E6.6000800@montages.com" type="cite"><br>
Please give me a little sign that you might reconsider your opinion,
and
<br>
I'll put efforts in providing examples and in documenting variants of
this problem in the bug.
<br>
</blockquote>
It's just not a high priority for me.&nbsp; Given that I have 100 things to
do, I will need to spend my time on the things that personally feel are
likely to have the most value for the most people.&nbsp; This problem just
isn't high on that list.&nbsp; What's at the top of my list right now is
access listeners <a
href="https://bugs.eclipse.org/bugs/show_bug.cgi?id=247130">https://bugs.eclipse.org/bugs/show_bug.cgi?id=247130</a>
and even finding time for that is far too challenging.<br>
<blockquote cite="mid:4988B0E6.6000800@montages.com" type="cite"><br>
Best Regards, Philipp
<br>
<br>
Ed Merks wrote:
<br>
<blockquote type="cite">Tim,
<br>
<br>
I think you've misunderstood because the example you point at has a
root element for which the type is a non-abstract complex type, so it's
definitely not an example of a corner case schema in which there is not
even a single root element that can be used without also requiring an
xsi:type.&nbsp; So I'll continue to assert that such a situation is very odd
(I've only seen it once it all my years of looking at schemas) and it
doesn't strike me as a good thing.
<br>
<br>
<br>
Tim Reilly wrote:
<br>
<blockquote type="cite">My 2 cents: I wouldn't categorize this as a
corner case.
<br>
e.g.:
<br>
<a class="moz-txt-link-freetext" href="http://maven.apache.org/maven-v4_0_0.xsd">http://maven.apache.org/maven-v4_0_0.xsd</a>
<br>
<br>
I would say separating types and elements is a best practice and allows
for better extensibility (even at the root element.)
<br>
Definitely strikes the "bug" note for me.
<br>
<br>
"Ed Merks" <a class="moz-txt-link-rfc2396E" href="mailto:merks@ca.ibm.com">&lt;merks@ca.ibm.com&gt;</a> wrote in message
<a class="moz-txt-link-freetext" href="news:f1cg32$hq0$1@build.eclipse.org">news:f1cg32$hq0$1@build.eclipse.org</a>...
<br>
&nbsp;
<blockquote type="cite">Matthew,
<br>
<br>
It being a standard doesn't mean it's a good design.&nbsp; ;-)&nbsp; In general,
hand modifying the wizard to provide only the useful/sensible choices
would seem like a reasonable way to deal with corner cases.&nbsp; So while a
feature request is reasonable, our limited development resource likely
needs to focus on more common issues, so without a contribution, it's
not a given that this will be addressed in the current release cycle.
<br>
<br>
<br>
Matthew Rawlings wrote:
<br>
&nbsp;&nbsp;&nbsp;
<blockquote type="cite">Ed,
<br>
<br>
The example is from the FpML schema <a class="moz-txt-link-freetext" href="http://www.fpml.org/">http://www.fpml.org/</a> which is a
Standard for financial products used by Banks, Securities Houses,
Brokerages, Insurers, Hedge Funds, and Exchanges. It is very widely
adopted in the financial services industry.
<br>
<br>
As this is legal XML Schema shall I raise an unplanned enhancement for
EMF to look for valid alternative types?
<br>
<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </blockquote>
</blockquote>
<br>
<br>
&nbsp; </blockquote>
<br>
</blockquote>
</blockquote>
</body>
</html>

--------------040309060800060709080203--


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: BUG 185357, Re: Missing Model Object in the Example EMF Model Creation Wizard [message #427221 is a reply to message #427148] Fri, 06 February 2009 15:31 Go to previous messageGo to next message
Philipp Kutter is currently offline Philipp KutterFriend
Messages: 306
Registered: July 2009
Senior Member
Hi, Ed.
I understand. What we'll do is creating some proposal and associated
patches what to do, which relate to both the Editor root element and
extensible child creation.

What I have in mind is an extension point, where other ECore models can
be entered, which will be used when the classes for "extensible child
creation" or the "root elements" are proposed.

Are there other proposals or ideas in bugzillas I have to coordinate
with for this?

Best Regards,
Philipp

PS: In our OCL usage, we will correspondingly add OCL expressions to
constraint and construct the proposed classes both for extensible child
creation (OCL constraints added to the corresponding containment
feature) and editor root elements (OCL constraints added to the package
which is used as basis for the editor.

Marc: can you please create a corresponding feature request in our
internal bugzilla which includes contribution to Bug 185357

Ed Merks wrote:
> Philipp,
>
> Comments below.
>
> Philipp Kutter wrote:
>> Dear Ed.
>> This was reported as Bug
>> https://bugs.eclipse.org/bugs/show_bug.cgi?id=185357
>> back in 2007.
>>
>> We moved now forward 2 years, and I think that we should reconsider
>> things, that where corner-cases back then.
> I've got a list of 100 bugzillas all of which are worth (re)considering:
>
> https://bugs.eclipse.org/bugs/buglist.cgi?product=EMF&co mponent=Core&component=Doc&component=Edit&compon ent=Mapping&component=Tools&component=XML/XMI&bu g_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED &bug_status=RESOLVED&resolution=FIXED&resolution =---&order=bugs.bug_status,bugs.target_milestone,bugs.bu g_id&query_format=advanced
> < https://bugs.eclipse.org/bugs/buglist.cgi?product=EMF&co mponent=Core&component=Doc&component=Edit&compon ent=Mapping&component=Tools&component=XML/XMI&bu g_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED &bug_status=RESOLVED&resolution=FIXED&resolution =---&order=bugs.bug_status,bugs.target_milestone,bugs.bu g_id&query_format=advanced>
>
> The vast majority of these have no associated patches and are
> effectively waiting for me to do the work.
>>
>> As well, consider that while what you say about XML Schema design may
>> be true, the problem could as well be looked at from the MOF/ECore
>> perspective:
>> Is having a main package, which has abstract classes, and then
>> different packages which implement the concrete classes such a
>> corner case?
> Yes, I think so.
>>
>> And how would we generate an editor for this case?
> Given that you only have abstract classes, there's really nothing to
> create so while we can have an editor, and we support extensible child
> creation, we can't really generate a wizard that creates anything since
> as you've described, there is nothing to create.
>>
>> Please remember, that a very related problem, generating "create new"
>> actions in the editor for inheriting classes (not know in the package
>> of the class which has the corresponding feature) has been fixed by
>> your team!
> There are few things I forget. :-P
>>
>> Please give me a little sign that you might reconsider your opinion, and
>> I'll put efforts in providing examples and in documenting variants of
>> this problem in the bug.
> It's just not a high priority for me. Given that I have 100 things to
> do, I will need to spend my time on the things that personally feel are
> likely to have the most value for the most people. This problem just
> isn't high on that list. What's at the top of my list right now is
> access listeners https://bugs.eclipse.org/bugs/show_bug.cgi?id=247130
> and even finding time for that is far too challenging.
>>
>> Best Regards, Philipp
>>
>> Ed Merks wrote:
>>> Tim,
>>>
>>> I think you've misunderstood because the example you point at has a
>>> root element for which the type is a non-abstract complex type, so
>>> it's definitely not an example of a corner case schema in which there
>>> is not even a single root element that can be used without also
>>> requiring an xsi:type. So I'll continue to assert that such a
>>> situation is very odd (I've only seen it once it all my years of
>>> looking at schemas) and it doesn't strike me as a good thing.
>>>
>>>
>>> Tim Reilly wrote:
>>>> My 2 cents: I wouldn't categorize this as a corner case.
>>>> e.g.:
>>>> http://maven.apache.org/maven-v4_0_0.xsd
>>>>
>>>> I would say separating types and elements is a best practice and
>>>> allows for better extensibility (even at the root element.)
>>>> Definitely strikes the "bug" note for me.
>>>>
>>>> "Ed Merks" <merks@ca.ibm.com> wrote in message
>>>> news:f1cg32$hq0$1@build.eclipse.org...
>>>>
>>>>> Matthew,
>>>>>
>>>>> It being a standard doesn't mean it's a good design. ;-) In
>>>>> general, hand modifying the wizard to provide only the
>>>>> useful/sensible choices would seem like a reasonable way to deal
>>>>> with corner cases. So while a feature request is reasonable, our
>>>>> limited development resource likely needs to focus on more common
>>>>> issues, so without a contribution, it's not a given that this will
>>>>> be addressed in the current release cycle.
>>>>>
>>>>>
>>>>> Matthew Rawlings wrote:
>>>>>
>>>>>> Ed,
>>>>>>
>>>>>> The example is from the FpML schema http://www.fpml.org/ which is
>>>>>> a Standard for financial products used by Banks, Securities
>>>>>> Houses, Brokerages, Insurers, Hedge Funds, and Exchanges. It is
>>>>>> very widely adopted in the financial services industry.
>>>>>>
>>>>>> As this is legal XML Schema shall I raise an unplanned enhancement
>>>>>> for EMF to look for valid alternative types?
>>>>>>
>>>>>>
>>>>>>
>>>>
>>>>
>>>>
>>>
Re: BUG 185357, Re: Missing Model Object in the Example EMF Model Creation Wizard [message #427224 is a reply to message #427221] Fri, 06 February 2009 18:09 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 33140
Registered: July 2009
Senior Member
Philipp,

Certainly bugzillas with patches move up in my priority queue. Helping
those who help themselves tends to pay off better and demonstrates that
the problem truly is important enough to invest the time. Discussions
in the bugzilla are a good place to make progress.


Philipp Kutter wrote:
> Hi, Ed.
> I understand. What we'll do is creating some proposal and associated
> patches what to do, which relate to both the Editor root element and
> extensible child creation.
>
> What I have in mind is an extension point, where other ECore models
> can be entered, which will be used when the classes for "extensible
> child creation" or the "root elements" are proposed.
>
> Are there other proposals or ideas in bugzillas I have to coordinate
> with for this?
>
> Best Regards,
> Philipp
>
> PS: In our OCL usage, we will correspondingly add OCL expressions to
> constraint and construct the proposed classes both for extensible
> child creation (OCL constraints added to the corresponding containment
> feature) and editor root elements (OCL constraints added to the
> package which is used as basis for the editor.
>
> Marc: can you please create a corresponding feature request in our
> internal bugzilla which includes contribution to Bug 185357
>
> Ed Merks wrote:
>> Philipp,
>>
>> Comments below.
>>
>> Philipp Kutter wrote:
>>> Dear Ed.
>>> This was reported as Bug
>>> https://bugs.eclipse.org/bugs/show_bug.cgi?id=185357
>>> back in 2007.
>>>
>>> We moved now forward 2 years, and I think that we should reconsider
>>> things, that where corner-cases back then.
>> I've got a list of 100 bugzillas all of which are worth (re)considering:
>>
>>
>> https://bugs.eclipse.org/bugs/buglist.cgi?product=EMF&co mponent=Core&component=Doc&component=Edit&compon ent=Mapping&component=Tools&component=XML/XMI&bu g_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED &bug_status=RESOLVED&resolution=FIXED&resolution =---&order=bugs.bug_status,bugs.target_milestone,bugs.bu g_id&query_format=advanced
>>
>>
>> < https://bugs.eclipse.org/bugs/buglist.cgi?product=EMF&co mponent=Core&component=Doc&component=Edit&compon ent=Mapping&component=Tools&component=XML/XMI&bu g_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED &bug_status=RESOLVED&resolution=FIXED&resolution =---&order=bugs.bug_status,bugs.target_milestone,bugs.bu g_id&query_format=advanced>
>>
>>
>> The vast majority of these have no associated patches and are
>> effectively waiting for me to do the work.
>>>
>>> As well, consider that while what you say about XML Schema design may
>>> be true, the problem could as well be looked at from the MOF/ECore
>>> perspective:
>>> Is having a main package, which has abstract classes, and then
>>> different packages which implement the concrete classes such a
>>> corner case?
>> Yes, I think so.
>>>
>>> And how would we generate an editor for this case?
>> Given that you only have abstract classes, there's really nothing to
>> create so while we can have an editor, and we support extensible
>> child creation, we can't really generate a wizard that creates
>> anything since as you've described, there is nothing to create.
>>>
>>> Please remember, that a very related problem, generating "create
>>> new" actions in the editor for inheriting classes (not know in the
>>> package of the class which has the corresponding feature) has been
>>> fixed by your team!
>> There are few things I forget. :-P
>>>
>>> Please give me a little sign that you might reconsider your opinion,
>>> and
>>> I'll put efforts in providing examples and in documenting variants
>>> of this problem in the bug.
>> It's just not a high priority for me. Given that I have 100 things
>> to do, I will need to spend my time on the things that personally
>> feel are likely to have the most value for the most people. This
>> problem just isn't high on that list. What's at the top of my list
>> right now is access listeners
>> https://bugs.eclipse.org/bugs/show_bug.cgi?id=247130 and even finding
>> time for that is far too challenging.
>>>
>>> Best Regards, Philipp
>>>
>>> Ed Merks wrote:
>>>> Tim,
>>>>
>>>> I think you've misunderstood because the example you point at has a
>>>> root element for which the type is a non-abstract complex type, so
>>>> it's definitely not an example of a corner case schema in which
>>>> there is not even a single root element that can be used without
>>>> also requiring an xsi:type. So I'll continue to assert that such a
>>>> situation is very odd (I've only seen it once it all my years of
>>>> looking at schemas) and it doesn't strike me as a good thing.
>>>>
>>>>
>>>> Tim Reilly wrote:
>>>>> My 2 cents: I wouldn't categorize this as a corner case.
>>>>> e.g.:
>>>>> http://maven.apache.org/maven-v4_0_0.xsd
>>>>>
>>>>> I would say separating types and elements is a best practice and
>>>>> allows for better extensibility (even at the root element.)
>>>>> Definitely strikes the "bug" note for me.
>>>>>
>>>>> "Ed Merks" <merks@ca.ibm.com> wrote in message
>>>>> news:f1cg32$hq0$1@build.eclipse.org...
>>>>>
>>>>>> Matthew,
>>>>>>
>>>>>> It being a standard doesn't mean it's a good design. ;-) In
>>>>>> general, hand modifying the wizard to provide only the
>>>>>> useful/sensible choices would seem like a reasonable way to deal
>>>>>> with corner cases. So while a feature request is reasonable, our
>>>>>> limited development resource likely needs to focus on more common
>>>>>> issues, so without a contribution, it's not a given that this
>>>>>> will be addressed in the current release cycle.
>>>>>>
>>>>>>
>>>>>> Matthew Rawlings wrote:
>>>>>>
>>>>>>> Ed,
>>>>>>>
>>>>>>> The example is from the FpML schema http://www.fpml.org/ which
>>>>>>> is a Standard for financial products used by Banks, Securities
>>>>>>> Houses, Brokerages, Insurers, Hedge Funds, and Exchanges. It is
>>>>>>> very widely adopted in the financial services industry.
>>>>>>>
>>>>>>> As this is legal XML Schema shall I raise an unplanned
>>>>>>> enhancement for EMF to look for valid alternative types?
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>
>>>>>
>>>>>
>>>>


Ed Merks
Professional Support: https://www.macromodeling.com/
Previous Topic:[CDO] referencing element from other ecore model
Next Topic:Finding Parent-Cross-Referencer A.K.A Non-Containing-Parents
Goto Forum:
  


Current Time: Thu Apr 25 04:27:20 GMT 2024

Powered by FUDForum. Page generated in 0.04149 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top