public String getType() { if (!watch.isEnabled()) { return ""; } if (!evaluated) { evaluate(); } return variable == null ? "" : variable.getType(); }
public static Variable getVarStringValueAsVar(JPDADebugger debugger, ObjectVariable ov) { List<JPDAClassType> supportClasses = debugger.getClassesByName(DEBUGGER_SUPPORT_CLASS); if (supportClasses.isEmpty()) { return ov; } JPDAClassType supportClass = supportClasses.get(0); Variable[] args = new Variable[1]; try { args[0] = ov; Variable strVar = supportClass.invokeMethod(METHOD_VALUE_AS_STRING, SIGNAT_VALUE_AS_STRING, args); // This method returns quoted value. :-( if (String.class.getName().equals(strVar.getType())) { return adjustQuotes(debugger, (ObjectVariable) strVar); } else { return strVar; } } catch (NoSuchMethodException | InvalidExpressionException ex) { Exceptions.printStackTrace(ex); return ov; } }
String type = attributeValue.getType (); String stringValue = attributeValue.getValue(); if (attributeValue instanceof ObjectVariable) {
/** * Returns true if node is leaf. You should not throw UnknownTypeException * directly from this method! * * @param original the original tree model * @throws UnknownTypeException this exception can be thrown from * <code>original.isLeaf (...)</code> method call only! * @return true if node is leaf */ public boolean isLeaf(TreeModel original, Object node) throws UnknownTypeException { boolean il; if (node instanceof ImplicitLocals) il = false; else if (node instanceof AttributeMap) il = false; else if (node instanceof AttributeMap.Attribute) { Variable attributeValue = ((AttributeMap.Attribute)node).getValue(); if (isLeafType(attributeValue.getType())) il = true; else il = original.isLeaf(attributeValue); } else il = original.isLeaf(node); return il; }
v = d.evaluate (expression); String type = v.getType (); if (v instanceof ObjectVariable) try {
return ; // Something went wrong... String type = v.getType (); if (v instanceof ObjectVariable) { tooltipVariable = (ObjectVariable) v;
return ; // Something went wrong... String type = v.getType (); if (v instanceof ObjectVariable) { tooltipVariable = (ObjectVariable) v;