Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
RE: [cdt-dev] DSF (GDB only?) question: Can an IExpressionDMC be aparent of another IExpressionDMC

>I there something like a parent-child relationship on the view model side? 
>I started looking at the IVMContext, but couldn't find something. It must 
>be somewhere, otherwise the views wouldn't show trees, right?

The parent-child relationship is queried from the service.  The view model uses this to build the tree structure.  See service method IExpressions. getSubExpressions(IExpressionDMContext,...) which returns the children of the given expression. 
So with the current DSF-GDB implemention, as far as I understand, you can ask for the children of an expression, but not for the parent of an expression.  As Marc pointed out, you can get the parent through the expression sting (i.e. f.a, f.b).  

I think you do have a valid point about specifying IExpressionDMContext as parent element of other IExpressionDMContexts.  However, I don't think there are any limitations with the current implementation. 

- Navid

-----Original Message-----
From: cdt-dev-bounces@xxxxxxxxxxx [mailto:cdt-dev-bounces@xxxxxxxxxxx] On Behalf Of Elmenthaler, Jens
Sent: Monday, April 12, 2010 9:49 AM
To: CDT General developers list.
Subject: RE: [cdt-dev] DSF (GDB only?) question: Can an IExpressionDMC be aparent of another IExpressionDMC

> -----Original Message-----
> From: cdt-dev-bounces@xxxxxxxxxxx [mailto:cdt-dev-bounces@xxxxxxxxxxx] On
> Behalf Of Marc Khouzam
> Sent: Montag, 12. April 2010 14:56
> To: 'CDT General developers list.'
> Subject: RE: [cdt-dev] DSF (GDB only?) question: Can an IExpressionDMC be
> aparent of another IExpressionDMC
> 
> As you point out above, you can't have IExpressionDMContext be
> a child of another IExpressionDMContext, at least not with
> DSF-GDB.  Each expression is independent if its parent.
> For example for
> f
>  a
>  b
> 
> The expressions are
> f
> f.a
> f.b
> 
> where f.a and f.b don't know they are children of f, except
> from their expression string.
Yes, I can understand this.

I there something like a parent-child relationship on the view model side? I started looking at the IVMContext, but couldn't find something. It must be somewhere, otherwise the views wouldn't show trees, right?

The reason why I ask is I'm trying to implement IVMNode.buildDelta in GDBVariableNode for an event that requests more children for a variable/expression provided by a pretty printer.

Jens.
_______________________________________________
cdt-dev mailing list
cdt-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/cdt-dev


Back to the top