This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 78609 - Custom column combination in different debugger types
Summary: Custom column combination in different debugger types
Status: CLOSED DUPLICATE of bug 61319
Alias: None
Product: debugger
Classification: Unclassified
Component: Code (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Martin Entlicher
URL:
Keywords:
Depends on:
Blocks: 63083
  Show dependency tree
 
Reported: 2006-06-20 16:34 UTC by Martin Entlicher
Modified: 2008-04-15 18:46 UTC (History)
1 user (show)

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Entlicher 2006-06-20 16:34:36 UTC
When a new debugger implementation adds it's own column to existing views, the
existing debugger implementations can not provide values for these columns,
which results in UnknownTypeException being thrown.
Also, not all columns might have sense for all debuggers, therefore individual
debugger implementation need to have a possibility to hide columns they do not
want to support.
Comment 1 Martin Entlicher 2006-06-20 16:35:51 UTC
Scheduling for "Dev" for now...
Comment 2 ivan 2006-06-20 22:06:50 UTC
I'm not sure hiding column would work because you might have two different
sesions, say a jpda and a CND native debugger and you want the column to be
present for the sake of the CND debugger.
My original suggestion was to have the concept of "N/A" (Not Applicable)
instead of UnknownTypeExceptions. The cell could either render "N/A",
or stay blank or show a "shrug" glyph :-)

I'm working around the problem as follows.
It should work regardless of who gets to be the original model and who
gets to be the filter.

    private Object fallbackGetValueAt(TableModel original,
                                      Object node,
                                      String columnID)
                                  throws UnknownTypeException {
        try {
            return original.getValueAt(node, columnID);
        } catch (UnknownTypeException x) {
            if (isOurProperty(columnID))
                return "";
            else
                throw x;
        }
    }

    // interface TableModelFilter
    public Object getValueAt(TableModel original, Object node, String columnID)
        throws UnknownTypeException {

        if (! (node instanceof Session))
            return fallbackGetValueAt(original, node, columnID);

        NativeSession ds = NativeSession.map((Session) node);
        if (ds != null) {
            if (columnID == X) {
                return X
            } else if (columnID == Y ) {
                return Y
            } else {
                return original.getValueAt(node, columnID);
            }
        } else {
            return fallbackGetValueAt(original, node, columnID);
        }
    }
Comment 3 Martin Entlicher 2006-11-03 16:47:09 UTC
IMHO this will be solved by the fix of issue #61319, this is a duplicale of that
in my point of view.
I'll set this as a duplicate after we have a fix of issue #61319.
Comment 4 Martin Entlicher 2006-11-18 21:35:05 UTC
This should be resolved by the fix of issue #61319. Therefore resolving as a
duplicate.

*** This issue has been marked as a duplicate of 61319 ***
Comment 5 Antonin Nebuzelsky 2006-12-01 13:14:09 UTC
Removing MARS keyword. The already fixed issue 61319 will be considered for
porting to 5.5.1.
Comment 6 Petr Cyhelsky 2008-04-15 18:45:55 UTC
verified duplicate of much more active issue