Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » XML Schema Definition (XSD) » Help with generic setting of sf values
Help with generic setting of sf values [message #31502] Tue, 07 October 2003 18:24 Go to next message
Lance Phillips is currently offline Lance PhillipsFriend
Messages: 210
Registered: July 2009
Senior Member
All,
I'm running into a problem when trying to handle XSD entities in a
generic manner. For example, when processing an
XSDModelGroupDefinitionImpl, I try to set the
XSDResolvedModelGroupDefinition reference by getting the appropriate
structural feature and performing an eSet on the ModelGroupDefinition. Why
can't I do this??? It is failing in the eDynamicSet at EObject due to the
fact that the dynamicFeature ID is -4. What am I missing?

thanks,

lp
Re: Help with generic setting of sf values [message #31572 is a reply to message #31502] Tue, 07 October 2003 19:33 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: merks.ca.ibm.com

--------------9CCF2D61C307E098E97BA3AF
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Lance,

Are you saying that it goes in here but doesn't hit the
XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_DEFINITION case:

public void eSet(EStructuralFeature eFeature, Object newValue)
{
switch (eDerivedStructuralFeatureID(eFeature))
{
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ELEMENT:
setElement((Element)newValue);
return;
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__DIAGNOSTICS:
getDiagnostics().clear();
getDiagnostics().addAll((Collection)newValue);
return;
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__NAME:
setName((String)newValue);
return;
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__TARGET_NAMESPACE:
setTargetNamespace((String)newValue);
return;
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ANNOTATION:
setAnnotation((XSDAnnotation)newValue);
return;
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__MODEL_GROUP:
setModelGroup((XSDModelGroup)newValue);
return;
case
XSDPackage.XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_ DEFINITION:


setResolvedModelGroupDefinition((XSDModelGroupDefinition)new Value);
return;
}
eDynamicSet(eFeature, newValue);
}

Lance Phillips wrote:

> All,
> I'm running into a problem when trying to handle XSD entities in a
> generic manner. For example, when processing an
> XSDModelGroupDefinitionImpl, I try to set the
> XSDResolvedModelGroupDefinition reference by getting the appropriate
> structural feature and performing an eSet on the ModelGroupDefinition. Why
> can't I do this??? It is failing in the eDynamicSet at EObject due to the
> fact that the dynamicFeature ID is -4. What am I missing?
>
> thanks,
>
> lp

--------------9CCF2D61C307E098E97BA3AF
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit

<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
Lance,
<p>Are you saying that it goes in here but doesn't hit the <tt>XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_DEFINITION </tt>
case:
<blockquote><tt>&nbsp; public void eSet(EStructuralFeature eFeature, Object
newValue)</tt>
<br><tt>&nbsp; {</tt>
<br><tt>&nbsp;&nbsp;&nbsp; switch (eDerivedStructuralFeatureID(eFeature))</tt>
<br><tt>&nbsp;&nbsp;&nbsp; {</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ELEMENT:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setElement((Element)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__DIAGNOSTICS:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; getDiagnostics().clear();</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; getDiagnostics().addAll((Collection)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__NAME:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setName((String)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__TARGET_NAMESPACE:</tt >
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setTargetNamespace((String)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ANNOTATION:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setAnnotation((XSDAnnotation)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__MODEL_GROUP:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setModelGroup((XSDModelGroup)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_ DEFINITION: </tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setResolvedModelGroupDefinition((XSDModelGroupDefinition)new Value); </tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp; }</tt>
<br><tt>&nbsp;&nbsp;&nbsp; eDynamicSet(eFeature, newValue);</tt>
<br><tt>&nbsp; }</tt></blockquote>

<p><br>Lance Phillips wrote:
<blockquote TYPE=CITE>All,
<br>&nbsp;&nbsp;&nbsp; I'm running into a problem when trying to handle
XSD entities in a
<br>generic manner.&nbsp; For example, when processing an
<br>XSDModelGroupDefinitionImpl, I try to set the
<br>XSDResolvedModelGroupDefinition reference by getting the appropriate
<br>structural feature and performing an eSet on the ModelGroupDefinition.&nbsp;
Why
<br>can't I do this???&nbsp; It is failing in the eDynamicSet at EObject
due to the
<br>fact that the dynamicFeature ID is -4.&nbsp; What am I missing?
<p>thanks,
<p>lp</blockquote>
</html>

--------------9CCF2D61C307E098E97BA3AF--
Re: Help with generic setting of sf values [message #31607 is a reply to message #31572] Tue, 07 October 2003 19:35 Go to previous messageGo to next message
Lance Phillips is currently offline Lance PhillipsFriend
Messages: 210
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.

------=_NextPart_000_0014_01C38CE0.4210B520
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

I guess so.... I end up in eDynamicSet so that must be the case.

Let me try setting a break point in this code and see why it doesn't =
stop.

lp
"Ed Merks" <merks@ca.ibm.com> wrote in message =
news:3F8314EE.6EC4EA4@ca.ibm.com...
Lance,=20
Are you saying that it goes in here but doesn't hit the =
XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_DEFINITION case:=20

public void eSet(EStructuralFeature eFeature, Object newValue)=20
{=20
switch (eDerivedStructuralFeatureID(eFeature))=20
{=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ELEMENT:=20
setElement((Element)newValue);=20
return;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__DIAGNOSTICS:=20
getDiagnostics().clear();=20
getDiagnostics().addAll((Collection)newValue);=20
return;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__NAME:=20
setName((String)newValue);=20
return;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__TARGET_NAMESPACE:=20
setTargetNamespace((String)newValue);=20
return;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ANNOTATION:=20
setAnnotation((XSDAnnotation)newValue);=20
return;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__MODEL_GROUP:=20
setModelGroup((XSDModelGroup)newValue);=20
return;=20
case =
XSDPackage.XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_ DEFINITION:=20
=
setResolvedModelGroupDefinition((XSDModelGroupDefinition)new Value);=20
return;=20
}=20
eDynamicSet(eFeature, newValue);=20
}

Lance Phillips wrote:=20

All,=20
I'm running into a problem when trying to handle XSD entities in =
a=20
generic manner. For example, when processing an=20
XSDModelGroupDefinitionImpl, I try to set the=20
XSDResolvedModelGroupDefinition reference by getting the appropriate =

structural feature and performing an eSet on the =
ModelGroupDefinition. Why=20
can't I do this??? It is failing in the eDynamicSet at EObject due =
to the=20
fact that the dynamicFeature ID is -4. What am I missing?=20
thanks,=20

lp

------=_NextPart_000_0014_01C38CE0.4210B520
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1226" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>I guess so.... I end up in eDynamicSet =
so that must=20
be the case.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Let me try setting a break point in =
this code and=20
see why it doesn't stop.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>lp</FONT></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Ed Merks" &lt;<A =
href=3D"mailto:merks@ca.ibm.com">merks@ca.ibm.com</A>&gt;=20
wrote in message <A=20
=
href=3D"news:3F8314EE.6EC4EA4@ca.ibm.com">news:3F8314EE.6EC4EA4@ca.ibm.co=
m</A>...</DIV>Lance,=20

<P>Are you saying that it goes in here but doesn't hit the=20
<TT>XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_DEFINITION </TT> =
case:=20
<BLOCKQUOTE><TT>&nbsp; public void eSet(EStructuralFeature eFeature, =
Object=20
newValue)</TT> <BR><TT>&nbsp; {</TT> <BR><TT>&nbsp;&nbsp;&nbsp; =
switch=20
(eDerivedStructuralFeatureID(eFeature))</TT> =
<BR><TT>&nbsp;&nbsp;&nbsp;=20
{</TT> <BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__ELEMENT:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setElement((Element)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__DIAGNOSTICS:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
getDiagnostics().clear();</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
getDiagnostics().addAll((Collection)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__NAME:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setName((String)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__TARGET_NAMESPACE:</TT >=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setTargetNamespace((String)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__ANNOTATION:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setAnnotation((XSDAnnotation)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__MODEL_GROUP:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setModelGroup((XSDModelGroup)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
=
XSDPackage.XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_ DEFINITION: </=
TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
=
setResolvedModelGroupDefinition((XSDModelGroupDefinition)new Value); </TT> =

<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp; }</TT> <BR><TT>&nbsp;&nbsp;&nbsp;=20
eDynamicSet(eFeature, newValue);</TT> <BR><TT>&nbsp; =
}</TT></BLOCKQUOTE>
<P><BR>Lance Phillips wrote:=20
<BLOCKQUOTE TYPE=3D"CITE">All, <BR>&nbsp;&nbsp;&nbsp; I'm running into =
a=20
problem when trying to handle XSD entities in a <BR>generic =
manner.&nbsp;=20
For example, when processing an <BR>XSDModelGroupDefinitionImpl, I =
try to=20
set the <BR>XSDResolvedModelGroupDefinition reference by getting the =

appropriate <BR>structural feature and performing an eSet on the=20
ModelGroupDefinition.&nbsp; Why <BR>can't I do this???&nbsp; It is =
failing=20
in the eDynamicSet at EObject due to the <BR>fact that the =
dynamicFeature ID=20
is -4.&nbsp; What am I missing?=20
<P>thanks,=20
<P>lp</P></BLOCKQUOTE></BLOCKQUOTE></BODY></HTML>

------=_NextPart_000_0014_01C38CE0.4210B520--
Re: Help with generic setting of sf values [message #31642 is a reply to message #31607] Tue, 07 October 2003 19:49 Go to previous messageGo to next message
Lance Phillips is currently offline Lance PhillipsFriend
Messages: 210
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.

------=_NextPart_000_0022_01C38CE2.348254C0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Nope.... problem was on my end (but I bet you knew that already!). I =
was grabbing the wrong sf. All is well now.

thanks,

lp
"Lance Phillips" <lphillips@metamatrix.com> wrote in message =
news:blv4j1$28o$1@eclipse.org...
I guess so.... I end up in eDynamicSet so that must be the case.

Let me try setting a break point in this code and see why it doesn't =
stop.

lp
"Ed Merks" <merks@ca.ibm.com> wrote in message =
news:3F8314EE.6EC4EA4@ca.ibm.com...
Lance,=20
Are you saying that it goes in here but doesn't hit the =
XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_DEFINITION case:=20

public void eSet(EStructuralFeature eFeature, Object newValue)=20
{=20
switch (eDerivedStructuralFeatureID(eFeature))=20
{=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ELEMENT:=20
setElement((Element)newValue);=20
return;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__DIAGNOSTICS:=20
getDiagnostics().clear();=20
getDiagnostics().addAll((Collection)newValue);=20
return;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__NAME:=20
setName((String)newValue);=20
return;=20
case =
XSDPackage.XSD_MODEL_GROUP_DEFINITION__TARGET_NAMESPACE:=20
setTargetNamespace((String)newValue);=20
return;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ANNOTATION:=20
setAnnotation((XSDAnnotation)newValue);=20
return;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__MODEL_GROUP:=20
setModelGroup((XSDModelGroup)newValue);=20
return;=20
case =
XSDPackage.XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_ DEFINITION:=20
=
setResolvedModelGroupDefinition((XSDModelGroupDefinition)new Value);=20
return;=20
}=20
eDynamicSet(eFeature, newValue);=20
}

Lance Phillips wrote:=20

All,=20
I'm running into a problem when trying to handle XSD entities =
in a=20
generic manner. For example, when processing an=20
XSDModelGroupDefinitionImpl, I try to set the=20
XSDResolvedModelGroupDefinition reference by getting the =
appropriate=20
structural feature and performing an eSet on the =
ModelGroupDefinition. Why=20
can't I do this??? It is failing in the eDynamicSet at EObject =
due to the=20
fact that the dynamicFeature ID is -4. What am I missing?=20
thanks,=20

lp

------=_NextPart_000_0022_01C38CE2.348254C0
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1226" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>Nope.... problem was on my end (but I =
bet you knew=20
that already!).&nbsp; I was grabbing the wrong sf.&nbsp; All is well=20
now.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>thanks,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>lp</FONT></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Lance Phillips" &lt;<A=20
=
href=3D"mailto:lphillips@metamatrix.com">lphillips@metamatrix.com</A>&gt;=
wrote=20
in message <A=20
=
href=3D"news:blv4j1$28o$1@eclipse.org">news:blv4j1$28o$1@eclipse.org</A>.=
...</DIV>
<DIV><FONT face=3DArial size=3D2>I guess so.... I end up in =
eDynamicSet so that=20
must be the case.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Let me try setting a break point in =
this code and=20
see why it doesn't stop.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>lp</FONT></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Ed Merks" &lt;<A=20
href=3D"mailto:merks@ca.ibm.com">merks@ca.ibm.com</A>&gt; wrote in =
message <A=20
=
href=3D"news:3F8314EE.6EC4EA4@ca.ibm.com">news:3F8314EE.6EC4EA4@ca.ibm.co=
m</A>...</DIV>Lance,=20

<P>Are you saying that it goes in here but doesn't hit the=20
<TT>XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_DEFINITION </TT> =
case:=20
<BLOCKQUOTE><TT>&nbsp; public void eSet(EStructuralFeature eFeature, =

Object newValue)</TT> <BR><TT>&nbsp; {</TT> =
<BR><TT>&nbsp;&nbsp;&nbsp;=20
switch (eDerivedStructuralFeatureID(eFeature))</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp; {</TT> =
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ELEMENT:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setElement((Element)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__DIAGNOSTICS:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
getDiagnostics().clear();</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
getDiagnostics().addAll((Collection)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__NAME:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setName((String)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__TARGET_NAMESPACE:</TT >=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setTargetNamespace((String)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__ANNOTATION:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setAnnotation((XSDAnnotation)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__MODEL_GROUP:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setModelGroup((XSDModelGroup)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
=
XSDPackage.XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_ DEFINITION: </=
TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
=
setResolvedModelGroupDefinition((XSDModelGroupDefinition)new Value); </TT> =

<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp; }</TT> <BR><TT>&nbsp;&nbsp;&nbsp;=20
eDynamicSet(eFeature, newValue);</TT> <BR><TT>&nbsp; =
}</TT></BLOCKQUOTE>
<P><BR>Lance Phillips wrote:=20
<BLOCKQUOTE TYPE=3D"CITE">All, <BR>&nbsp;&nbsp;&nbsp; I'm running =
into a=20
problem when trying to handle XSD entities in a <BR>generic =
manner.&nbsp;=20
For example, when processing an <BR>XSDModelGroupDefinitionImpl, I =
try to=20
set the <BR>XSDResolvedModelGroupDefinition reference by getting =
the=20
appropriate <BR>structural feature and performing an eSet on the=20
ModelGroupDefinition.&nbsp; Why <BR>can't I do this???&nbsp; It is =
failing=20
in the eDynamicSet at EObject due to the <BR>fact that the =
dynamicFeature=20
ID is -4.&nbsp; What am I missing?=20
<P>thanks,=20
<P>lp</P></BLOCKQUOTE></BLOCKQUOTE></BLOCKQUOTE></BODY ></HTML>

------=_NextPart_000_0022_01C38CE2.348254C0--
Re: Help with generic setting of sf values [message #31677 is a reply to message #31642] Tue, 07 October 2003 20:01 Go to previous message
Eclipse UserFriend
Originally posted by: merks.ca.ibm.com

--------------01C36149B2C4A8548EC7299A
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Lance,

Thanks for letting me know. (That was my working assumption. ;-)

Lance Phillips wrote:

> Nope.... problem was on my end (but I bet you knew that already!). I
> was grabbing the wrong sf. All is well now. thanks, lp
>
> "Lance Phillips" <lphillips@metamatrix.com> wrote in message
> news:blv4j1$28o$1@eclipse.org...I guess so.... I end up in
> eDynamicSet so that must be the case. Let me try setting a
> break point in this code and see why it doesn't stop. lp
>
> "Ed Merks" <merks@ca.ibm.com> wrote in message
> news:3F8314EE.6EC4EA4@ca.ibm.com...Lance,
>
> Are you saying that it goes in here but doesn't
> hit the
> XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_DEFINITION
> case:
>
> public void eSet(EStructuralFeature
> eFeature, Object newValue)
> {
> switch
> (eDerivedStructuralFeatureID(eFeature))
> {
> case
> XSDPackage.XSD_MODEL_GROUP_DEFINITION__ELEMENT:
>
> setElement((Element)newValue);
> return;
> case
> XSDPackage.XSD_MODEL_GROUP_DEFINITION__DIAGNOSTICS:
>
> getDiagnostics().clear();
>
> getDiagnostics().addAll((Collection)newValue);
>
> return;
> case
> XSDPackage.XSD_MODEL_GROUP_DEFINITION__NAME:
>
> setName((String)newValue);
> return;
> case
> XSDPackage.XSD_MODEL_GROUP_DEFINITION__TARGET_NAMESPACE:
>
>
> setTargetNamespace((String)newValue);
> return;
> case
> XSDPackage.XSD_MODEL_GROUP_DEFINITION__ANNOTATION:
>
>
> setAnnotation((XSDAnnotation)newValue);
> return;
> case
> XSDPackage.XSD_MODEL_GROUP_DEFINITION__MODEL_GROUP:
>
>
> setModelGroup((XSDModelGroup)newValue);
> return;
> case
> XSDPackage.XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_ DEFINITION:
>
>
> setResolvedModelGroupDefinition((XSDModelGroupDefinition)new Value);
>
> return;
> }
> eDynamicSet(eFeature, newValue);
> }
>
>
> Lance Phillips wrote:
>
> > All,
> > I'm running into a problem when trying to
> > handle XSD entities in a
> > generic manner. For example, when processing an
> >
> > XSDModelGroupDefinitionImpl, I try to set the
> > XSDResolvedModelGroupDefinition reference by
> > getting the appropriate
> > structural feature and performing an eSet on the
> > ModelGroupDefinition. Why
> > can't I do this??? It is failing in the
> > eDynamicSet at EObject due to the
> > fact that the dynamicFeature ID is -4. What am
> > I missing?
> >
> > thanks,
> >
> > lp
>

--------------01C36149B2C4A8548EC7299A
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit

<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
<body bgcolor="#FFFFFF">
Lance,
<p>Thanks for letting me know.&nbsp; (That was my working assumption. ;-)
<p>Lance Phillips wrote:
<blockquote TYPE=CITE><style></style>
<font face="Arial"><font size=-1>Nope....
problem was on my end (but I bet you knew that already!).&nbsp; I was grabbing
the wrong sf.&nbsp; All is well now.</font></font>&nbsp;<font face="Arial"><font size=-1>thanks,</font></font>&nbsp;<font face="Arial"><font size=-1>lp</font></font>
<blockquote dir=ltr
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">"Lance
Phillips" &lt;<a href="mailto:lphillips@metamatrix.com">lphillips@metamatrix.com</a>>
wrote in message <a href="news:blv4j1$28o$1@eclipse.org">news:blv4j1$28o$1@eclipse.org</a>...<font face="Arial"><font size=-1>I
guess so.... I end up in eDynamicSet so that must be the case.</font></font>&nbsp;<font face="Arial"><font size=-1>Let
me try setting a break point in this code and see why it doesn't stop.</font></font>&nbsp;<font face="Arial"><font size=-1>lp</font></font>
<blockquote dir=ltr
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">"Ed
Merks" &lt;<a href="mailto:merks@ca.ibm.com">merks@ca.ibm.com</a>> wrote
in message <a href="news:3F8314EE.6EC4EA4@ca.ibm.com">news:3F8314EE.6EC4EA4@ca.ibm.com</a>...Lance,
<p>Are you saying that it goes in here but doesn't hit the <tt>XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_DEFINITION </tt>
case:
<blockquote><tt>&nbsp; public void eSet(EStructuralFeature eFeature, Object
newValue)</tt>
<br><tt>&nbsp; {</tt>
<br><tt>&nbsp;&nbsp;&nbsp; switch (eDerivedStructuralFeatureID(eFeature))</tt>
<br><tt>&nbsp;&nbsp;&nbsp; {</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ELEMENT:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setElement((Element)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__DIAGNOSTICS:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; getDiagnostics().clear();</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; getDiagnostics().addAll((Collection)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__NAME:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setName((String)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__TARGET_NAMESPACE:</tt >
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setTargetNamespace((String)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ANNOTATION:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setAnnotation((XSDAnnotation)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__MODEL_GROUP:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setModelGroup((XSDModelGroup)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_ DEFINITION: </tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setResolvedModelGroupDefinition((XSDModelGroupDefinition)new Value); </tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp; }</tt>
<br><tt>&nbsp;&nbsp;&nbsp; eDynamicSet(eFeature, newValue);</tt>
<br><tt>&nbsp; }</tt></blockquote>

<p><br>Lance Phillips wrote:
<blockquote TYPE="CITE">All,
<br>&nbsp;&nbsp;&nbsp; I'm running into a problem when trying to handle
XSD entities in a
<br>generic manner.&nbsp; For example, when processing an
<br>XSDModelGroupDefinitionImpl, I try to set the
<br>XSDResolvedModelGroupDefinition reference by getting the appropriate
<br>structural feature and performing an eSet on the ModelGroupDefinition.&nbsp;
Why
<br>can't I do this???&nbsp; It is failing in the eDynamicSet at EObject
due to the
<br>fact that the dynamicFeature ID is -4.&nbsp; What am I missing?
<p>thanks,
<p>lp</blockquote>
</blockquote>
</blockquote>
</blockquote>

</body>
</html>

--------------01C36149B2C4A8548EC7299A--
Re: Help with generic setting of sf values [message #579674 is a reply to message #31502] Tue, 07 October 2003 19:33 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 33137
Registered: July 2009
Senior Member
--------------9CCF2D61C307E098E97BA3AF
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Lance,

Are you saying that it goes in here but doesn't hit the
XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_DEFINITION case:

public void eSet(EStructuralFeature eFeature, Object newValue)
{
switch (eDerivedStructuralFeatureID(eFeature))
{
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ELEMENT:
setElement((Element)newValue);
return;
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__DIAGNOSTICS:
getDiagnostics().clear();
getDiagnostics().addAll((Collection)newValue);
return;
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__NAME:
setName((String)newValue);
return;
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__TARGET_NAMESPACE:
setTargetNamespace((String)newValue);
return;
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ANNOTATION:
setAnnotation((XSDAnnotation)newValue);
return;
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__MODEL_GROUP:
setModelGroup((XSDModelGroup)newValue);
return;
case
XSDPackage.XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_ DEFINITION:


setResolvedModelGroupDefinition((XSDModelGroupDefinition)new Value);
return;
}
eDynamicSet(eFeature, newValue);
}

Lance Phillips wrote:

> All,
> I'm running into a problem when trying to handle XSD entities in a
> generic manner. For example, when processing an
> XSDModelGroupDefinitionImpl, I try to set the
> XSDResolvedModelGroupDefinition reference by getting the appropriate
> structural feature and performing an eSet on the ModelGroupDefinition. Why
> can't I do this??? It is failing in the eDynamicSet at EObject due to the
> fact that the dynamicFeature ID is -4. What am I missing?
>
> thanks,
>
> lp

--------------9CCF2D61C307E098E97BA3AF
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit

<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
Lance,
<p>Are you saying that it goes in here but doesn't hit the <tt>XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_DEFINITION </tt>
case:
<blockquote><tt>&nbsp; public void eSet(EStructuralFeature eFeature, Object
newValue)</tt>
<br><tt>&nbsp; {</tt>
<br><tt>&nbsp;&nbsp;&nbsp; switch (eDerivedStructuralFeatureID(eFeature))</tt>
<br><tt>&nbsp;&nbsp;&nbsp; {</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ELEMENT:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setElement((Element)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__DIAGNOSTICS:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; getDiagnostics().clear();</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; getDiagnostics().addAll((Collection)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__NAME:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setName((String)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__TARGET_NAMESPACE:</tt >
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setTargetNamespace((String)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ANNOTATION:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setAnnotation((XSDAnnotation)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__MODEL_GROUP:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setModelGroup((XSDModelGroup)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_ DEFINITION: </tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setResolvedModelGroupDefinition((XSDModelGroupDefinition)new Value); </tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp; }</tt>
<br><tt>&nbsp;&nbsp;&nbsp; eDynamicSet(eFeature, newValue);</tt>
<br><tt>&nbsp; }</tt></blockquote>

<p><br>Lance Phillips wrote:
<blockquote TYPE=CITE>All,
<br>&nbsp;&nbsp;&nbsp; I'm running into a problem when trying to handle
XSD entities in a
<br>generic manner.&nbsp; For example, when processing an
<br>XSDModelGroupDefinitionImpl, I try to set the
<br>XSDResolvedModelGroupDefinition reference by getting the appropriate
<br>structural feature and performing an eSet on the ModelGroupDefinition.&nbsp;
Why
<br>can't I do this???&nbsp; It is failing in the eDynamicSet at EObject
due to the
<br>fact that the dynamicFeature ID is -4.&nbsp; What am I missing?
<p>thanks,
<p>lp</blockquote>
</html>

--------------9CCF2D61C307E098E97BA3AF--


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Help with generic setting of sf values [message #579697 is a reply to message #31572] Tue, 07 October 2003 19:35 Go to previous message
Lance Phillips is currently offline Lance PhillipsFriend
Messages: 210
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.

------=_NextPart_000_0014_01C38CE0.4210B520
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

I guess so.... I end up in eDynamicSet so that must be the case.

Let me try setting a break point in this code and see why it doesn't =
stop.

lp
"Ed Merks" <merks@ca.ibm.com> wrote in message =
news:3F8314EE.6EC4EA4@ca.ibm.com...
Lance,=20
Are you saying that it goes in here but doesn't hit the =
XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_DEFINITION case:=20

public void eSet(EStructuralFeature eFeature, Object newValue)=20
{=20
switch (eDerivedStructuralFeatureID(eFeature))=20
{=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ELEMENT:=20
setElement((Element)newValue);=20
return;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__DIAGNOSTICS:=20
getDiagnostics().clear();=20
getDiagnostics().addAll((Collection)newValue);=20
return;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__NAME:=20
setName((String)newValue);=20
return;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__TARGET_NAMESPACE:=20
setTargetNamespace((String)newValue);=20
return;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ANNOTATION:=20
setAnnotation((XSDAnnotation)newValue);=20
return;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__MODEL_GROUP:=20
setModelGroup((XSDModelGroup)newValue);=20
return;=20
case =
XSDPackage.XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_ DEFINITION:=20
=
setResolvedModelGroupDefinition((XSDModelGroupDefinition)new Value);=20
return;=20
}=20
eDynamicSet(eFeature, newValue);=20
}

Lance Phillips wrote:=20

All,=20
I'm running into a problem when trying to handle XSD entities in =
a=20
generic manner. For example, when processing an=20
XSDModelGroupDefinitionImpl, I try to set the=20
XSDResolvedModelGroupDefinition reference by getting the appropriate =

structural feature and performing an eSet on the =
ModelGroupDefinition. Why=20
can't I do this??? It is failing in the eDynamicSet at EObject due =
to the=20
fact that the dynamicFeature ID is -4. What am I missing?=20
thanks,=20

lp

------=_NextPart_000_0014_01C38CE0.4210B520
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1226" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>I guess so.... I end up in eDynamicSet =
so that must=20
be the case.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Let me try setting a break point in =
this code and=20
see why it doesn't stop.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>lp</FONT></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Ed Merks" &lt;<A =
href=3D"mailto:merks@ca.ibm.com">merks@ca.ibm.com</A>&gt;=20
wrote in message <A=20
=
href=3D"news:3F8314EE.6EC4EA4@ca.ibm.com">news:3F8314EE.6EC4EA4@ca.ibm.co=
m</A>...</DIV>Lance,=20

<P>Are you saying that it goes in here but doesn't hit the=20
<TT>XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_DEFINITION </TT> =
case:=20
<BLOCKQUOTE><TT>&nbsp; public void eSet(EStructuralFeature eFeature, =
Object=20
newValue)</TT> <BR><TT>&nbsp; {</TT> <BR><TT>&nbsp;&nbsp;&nbsp; =
switch=20
(eDerivedStructuralFeatureID(eFeature))</TT> =
<BR><TT>&nbsp;&nbsp;&nbsp;=20
{</TT> <BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__ELEMENT:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setElement((Element)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__DIAGNOSTICS:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
getDiagnostics().clear();</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
getDiagnostics().addAll((Collection)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__NAME:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setName((String)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__TARGET_NAMESPACE:</TT >=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setTargetNamespace((String)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__ANNOTATION:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setAnnotation((XSDAnnotation)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__MODEL_GROUP:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setModelGroup((XSDModelGroup)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
=
XSDPackage.XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_ DEFINITION: </=
TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
=
setResolvedModelGroupDefinition((XSDModelGroupDefinition)new Value); </TT> =

<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp; }</TT> <BR><TT>&nbsp;&nbsp;&nbsp;=20
eDynamicSet(eFeature, newValue);</TT> <BR><TT>&nbsp; =
}</TT></BLOCKQUOTE>
<P><BR>Lance Phillips wrote:=20
<BLOCKQUOTE TYPE=3D"CITE">All, <BR>&nbsp;&nbsp;&nbsp; I'm running into =
a=20
problem when trying to handle XSD entities in a <BR>generic =
manner.&nbsp;=20
For example, when processing an <BR>XSDModelGroupDefinitionImpl, I =
try to=20
set the <BR>XSDResolvedModelGroupDefinition reference by getting the =

appropriate <BR>structural feature and performing an eSet on the=20
ModelGroupDefinition.&nbsp; Why <BR>can't I do this???&nbsp; It is =
failing=20
in the eDynamicSet at EObject due to the <BR>fact that the =
dynamicFeature ID=20
is -4.&nbsp; What am I missing?=20
<P>thanks,=20
<P>lp</P></BLOCKQUOTE></BLOCKQUOTE></BODY></HTML>

------=_NextPart_000_0014_01C38CE0.4210B520--
Re: Help with generic setting of sf values [message #579715 is a reply to message #31607] Tue, 07 October 2003 19:49 Go to previous message
Lance Phillips is currently offline Lance PhillipsFriend
Messages: 210
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.

------=_NextPart_000_0022_01C38CE2.348254C0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Nope.... problem was on my end (but I bet you knew that already!). I =
was grabbing the wrong sf. All is well now.

thanks,

lp
"Lance Phillips" <lphillips@metamatrix.com> wrote in message =
news:blv4j1$28o$1@eclipse.org...
I guess so.... I end up in eDynamicSet so that must be the case.

Let me try setting a break point in this code and see why it doesn't =
stop.

lp
"Ed Merks" <merks@ca.ibm.com> wrote in message =
news:3F8314EE.6EC4EA4@ca.ibm.com...
Lance,=20
Are you saying that it goes in here but doesn't hit the =
XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_DEFINITION case:=20

public void eSet(EStructuralFeature eFeature, Object newValue)=20
{=20
switch (eDerivedStructuralFeatureID(eFeature))=20
{=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ELEMENT:=20
setElement((Element)newValue);=20
return;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__DIAGNOSTICS:=20
getDiagnostics().clear();=20
getDiagnostics().addAll((Collection)newValue);=20
return;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__NAME:=20
setName((String)newValue);=20
return;=20
case =
XSDPackage.XSD_MODEL_GROUP_DEFINITION__TARGET_NAMESPACE:=20
setTargetNamespace((String)newValue);=20
return;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ANNOTATION:=20
setAnnotation((XSDAnnotation)newValue);=20
return;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__MODEL_GROUP:=20
setModelGroup((XSDModelGroup)newValue);=20
return;=20
case =
XSDPackage.XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_ DEFINITION:=20
=
setResolvedModelGroupDefinition((XSDModelGroupDefinition)new Value);=20
return;=20
}=20
eDynamicSet(eFeature, newValue);=20
}

Lance Phillips wrote:=20

All,=20
I'm running into a problem when trying to handle XSD entities =
in a=20
generic manner. For example, when processing an=20
XSDModelGroupDefinitionImpl, I try to set the=20
XSDResolvedModelGroupDefinition reference by getting the =
appropriate=20
structural feature and performing an eSet on the =
ModelGroupDefinition. Why=20
can't I do this??? It is failing in the eDynamicSet at EObject =
due to the=20
fact that the dynamicFeature ID is -4. What am I missing?=20
thanks,=20

lp

------=_NextPart_000_0022_01C38CE2.348254C0
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1226" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>Nope.... problem was on my end (but I =
bet you knew=20
that already!).&nbsp; I was grabbing the wrong sf.&nbsp; All is well=20
now.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>thanks,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>lp</FONT></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Lance Phillips" &lt;<A=20
=
href=3D"mailto:lphillips@metamatrix.com">lphillips@metamatrix.com</A>&gt;=
wrote=20
in message <A=20
=
href=3D"news:blv4j1$28o$1@eclipse.org">news:blv4j1$28o$1@eclipse.org</A>.=
...</DIV>
<DIV><FONT face=3DArial size=3D2>I guess so.... I end up in =
eDynamicSet so that=20
must be the case.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Let me try setting a break point in =
this code and=20
see why it doesn't stop.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>lp</FONT></DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Ed Merks" &lt;<A=20
href=3D"mailto:merks@ca.ibm.com">merks@ca.ibm.com</A>&gt; wrote in =
message <A=20
=
href=3D"news:3F8314EE.6EC4EA4@ca.ibm.com">news:3F8314EE.6EC4EA4@ca.ibm.co=
m</A>...</DIV>Lance,=20

<P>Are you saying that it goes in here but doesn't hit the=20
<TT>XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_DEFINITION </TT> =
case:=20
<BLOCKQUOTE><TT>&nbsp; public void eSet(EStructuralFeature eFeature, =

Object newValue)</TT> <BR><TT>&nbsp; {</TT> =
<BR><TT>&nbsp;&nbsp;&nbsp;=20
switch (eDerivedStructuralFeatureID(eFeature))</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp; {</TT> =
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ELEMENT:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setElement((Element)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__DIAGNOSTICS:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
getDiagnostics().clear();</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
getDiagnostics().addAll((Collection)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__NAME:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setName((String)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__TARGET_NAMESPACE:</TT >=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setTargetNamespace((String)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__ANNOTATION:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setAnnotation((XSDAnnotation)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
XSDPackage.XSD_MODEL_GROUP_DEFINITION__MODEL_GROUP:</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
setModelGroup((XSDModelGroup)newValue);</TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case=20
=
XSDPackage.XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_ DEFINITION: </=
TT>=20
<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
=
setResolvedModelGroupDefinition((XSDModelGroupDefinition)new Value); </TT> =

<BR><TT> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</TT>=20
<BR><TT>&nbsp;&nbsp;&nbsp; }</TT> <BR><TT>&nbsp;&nbsp;&nbsp;=20
eDynamicSet(eFeature, newValue);</TT> <BR><TT>&nbsp; =
}</TT></BLOCKQUOTE>
<P><BR>Lance Phillips wrote:=20
<BLOCKQUOTE TYPE=3D"CITE">All, <BR>&nbsp;&nbsp;&nbsp; I'm running =
into a=20
problem when trying to handle XSD entities in a <BR>generic =
manner.&nbsp;=20
For example, when processing an <BR>XSDModelGroupDefinitionImpl, I =
try to=20
set the <BR>XSDResolvedModelGroupDefinition reference by getting =
the=20
appropriate <BR>structural feature and performing an eSet on the=20
ModelGroupDefinition.&nbsp; Why <BR>can't I do this???&nbsp; It is =
failing=20
in the eDynamicSet at EObject due to the <BR>fact that the =
dynamicFeature=20
ID is -4.&nbsp; What am I missing?=20
<P>thanks,=20
<P>lp</P></BLOCKQUOTE></BLOCKQUOTE></BLOCKQUOTE></BODY ></HTML>

------=_NextPart_000_0022_01C38CE2.348254C0--
Re: Help with generic setting of sf values [message #579736 is a reply to message #31642] Tue, 07 October 2003 20:01 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 33137
Registered: July 2009
Senior Member
--------------01C36149B2C4A8548EC7299A
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Lance,

Thanks for letting me know. (That was my working assumption. ;-)

Lance Phillips wrote:

> Nope.... problem was on my end (but I bet you knew that already!). I
> was grabbing the wrong sf. All is well now. thanks, lp
>
> "Lance Phillips" <lphillips@metamatrix.com> wrote in message
> news:blv4j1$28o$1@eclipse.org...I guess so.... I end up in
> eDynamicSet so that must be the case. Let me try setting a
> break point in this code and see why it doesn't stop. lp
>
> "Ed Merks" <merks@ca.ibm.com> wrote in message
> news:3F8314EE.6EC4EA4@ca.ibm.com...Lance,
>
> Are you saying that it goes in here but doesn't
> hit the
> XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_DEFINITION
> case:
>
> public void eSet(EStructuralFeature
> eFeature, Object newValue)
> {
> switch
> (eDerivedStructuralFeatureID(eFeature))
> {
> case
> XSDPackage.XSD_MODEL_GROUP_DEFINITION__ELEMENT:
>
> setElement((Element)newValue);
> return;
> case
> XSDPackage.XSD_MODEL_GROUP_DEFINITION__DIAGNOSTICS:
>
> getDiagnostics().clear();
>
> getDiagnostics().addAll((Collection)newValue);
>
> return;
> case
> XSDPackage.XSD_MODEL_GROUP_DEFINITION__NAME:
>
> setName((String)newValue);
> return;
> case
> XSDPackage.XSD_MODEL_GROUP_DEFINITION__TARGET_NAMESPACE:
>
>
> setTargetNamespace((String)newValue);
> return;
> case
> XSDPackage.XSD_MODEL_GROUP_DEFINITION__ANNOTATION:
>
>
> setAnnotation((XSDAnnotation)newValue);
> return;
> case
> XSDPackage.XSD_MODEL_GROUP_DEFINITION__MODEL_GROUP:
>
>
> setModelGroup((XSDModelGroup)newValue);
> return;
> case
> XSDPackage.XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_ DEFINITION:
>
>
> setResolvedModelGroupDefinition((XSDModelGroupDefinition)new Value);
>
> return;
> }
> eDynamicSet(eFeature, newValue);
> }
>
>
> Lance Phillips wrote:
>
> > All,
> > I'm running into a problem when trying to
> > handle XSD entities in a
> > generic manner. For example, when processing an
> >
> > XSDModelGroupDefinitionImpl, I try to set the
> > XSDResolvedModelGroupDefinition reference by
> > getting the appropriate
> > structural feature and performing an eSet on the
> > ModelGroupDefinition. Why
> > can't I do this??? It is failing in the
> > eDynamicSet at EObject due to the
> > fact that the dynamicFeature ID is -4. What am
> > I missing?
> >
> > thanks,
> >
> > lp
>

--------------01C36149B2C4A8548EC7299A
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit

<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
<body bgcolor="#FFFFFF">
Lance,
<p>Thanks for letting me know.&nbsp; (That was my working assumption. ;-)
<p>Lance Phillips wrote:
<blockquote TYPE=CITE><style></style>
<font face="Arial"><font size=-1>Nope....
problem was on my end (but I bet you knew that already!).&nbsp; I was grabbing
the wrong sf.&nbsp; All is well now.</font></font>&nbsp;<font face="Arial"><font size=-1>thanks,</font></font>&nbsp;<font face="Arial"><font size=-1>lp</font></font>
<blockquote dir=ltr
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">"Lance
Phillips" &lt;<a href="mailto:lphillips@metamatrix.com">lphillips@metamatrix.com</a>>
wrote in message <a href="news:blv4j1$28o$1@eclipse.org">news:blv4j1$28o$1@eclipse.org</a>...<font face="Arial"><font size=-1>I
guess so.... I end up in eDynamicSet so that must be the case.</font></font>&nbsp;<font face="Arial"><font size=-1>Let
me try setting a break point in this code and see why it doesn't stop.</font></font>&nbsp;<font face="Arial"><font size=-1>lp</font></font>
<blockquote dir=ltr
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">"Ed
Merks" &lt;<a href="mailto:merks@ca.ibm.com">merks@ca.ibm.com</a>> wrote
in message <a href="news:3F8314EE.6EC4EA4@ca.ibm.com">news:3F8314EE.6EC4EA4@ca.ibm.com</a>...Lance,
<p>Are you saying that it goes in here but doesn't hit the <tt>XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_DEFINITION </tt>
case:
<blockquote><tt>&nbsp; public void eSet(EStructuralFeature eFeature, Object
newValue)</tt>
<br><tt>&nbsp; {</tt>
<br><tt>&nbsp;&nbsp;&nbsp; switch (eDerivedStructuralFeatureID(eFeature))</tt>
<br><tt>&nbsp;&nbsp;&nbsp; {</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ELEMENT:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setElement((Element)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__DIAGNOSTICS:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; getDiagnostics().clear();</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; getDiagnostics().addAll((Collection)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__NAME:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setName((String)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__TARGET_NAMESPACE:</tt >
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setTargetNamespace((String)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__ANNOTATION:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setAnnotation((XSDAnnotation)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__MODEL_GROUP:</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setModelGroup((XSDModelGroup)newValue);</tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; case XSDPackage.XSD_MODEL_GROUP_DEFINITION__RESOLVED_MODEL_GROUP_ DEFINITION: </tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; setResolvedModelGroupDefinition((XSDModelGroupDefinition)new Value); </tt>
<br><tt> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; return;</tt>
<br><tt>&nbsp;&nbsp;&nbsp; }</tt>
<br><tt>&nbsp;&nbsp;&nbsp; eDynamicSet(eFeature, newValue);</tt>
<br><tt>&nbsp; }</tt></blockquote>

<p><br>Lance Phillips wrote:
<blockquote TYPE="CITE">All,
<br>&nbsp;&nbsp;&nbsp; I'm running into a problem when trying to handle
XSD entities in a
<br>generic manner.&nbsp; For example, when processing an
<br>XSDModelGroupDefinitionImpl, I try to set the
<br>XSDResolvedModelGroupDefinition reference by getting the appropriate
<br>structural feature and performing an eSet on the ModelGroupDefinition.&nbsp;
Why
<br>can't I do this???&nbsp; It is failing in the eDynamicSet at EObject
due to the
<br>fact that the dynamicFeature ID is -4.&nbsp; What am I missing?
<p>thanks,
<p>lp</blockquote>
</blockquote>
</blockquote>
</blockquote>

</body>
</html>

--------------01C36149B2C4A8548EC7299A--


Ed Merks
Professional Support: https://www.macromodeling.com/
Previous Topic:The XS package in Xerces vs XSD
Next Topic:Sharing a common schema instance across many schemas
Goto Forum:
  


Current Time: Fri Apr 19 14:18:06 GMT 2024

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

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

Back to the top