Change visibility to private for net.sourceforge.phpeclipse.xdebug.php.model.XDebugEl...
[phpeclipse.git] / net.sourceforge.phpeclipse.xdebug.core / src / net / sourceforge / phpeclipse / xdebug / php / model / XDebugVariable.java
index 8a563cf..f8c54bd 100644 (file)
@@ -10,11 +10,11 @@ import net.sourceforge.phpeclipse.xdebug.core.PHPDebugUtils;
 
 //import org.eclipse.core.runtime.CoreException;
 import org.eclipse.debug.core.DebugException;
-import org.eclipse.debug.core.DebugEvent;
+//import org.eclipse.debug.core.DebugEvent;
 import org.eclipse.debug.core.model.IValue;
 import org.eclipse.debug.core.model.IVariable;
 import org.w3c.dom.Node;
-import org.eclipse.debug.core.model.IWatchExpressionDelegate;
+//import org.eclipse.debug.core.model.IWatchExpressionDelegate;
 /**
  * @author Axel
  *
@@ -22,7 +22,7 @@ import org.eclipse.debug.core.model.IWatchExpressionDelegate;
  * Window - Preferences - Java - Code Style - Code Templates
  */
 public class XDebugVariable  extends XDebugElement implements IVariable/*, IWatchExpressionFactoryAdapter*/ {
-       public static final int VARTYPE_UNKNOWN = -1;
+       /*public static final int VARTYPE_UNKNOWN = -1;
        public static final int VARTYPE_UNINITIALIZED = 0;
        public static final int VARTYPE_STRING = 1;
        public static final int VARTYPE_INT = 2;
@@ -30,7 +30,7 @@ public class XDebugVariable  extends XDebugElement implements IVariable/*, IWatc
        public static final int VARTYPE_ARRAY = 8;
        public static final int VARTYPE_HASH = 9;
        public static final int VARTYPE_OBJECT = 10;
-       public static final int VARTYPE_RESOURCE = 11;
+       public static final int VARTYPE_RESOURCE = 11;*/
        
        private int fNumChildren;
        private String fName;
@@ -88,6 +88,8 @@ public class XDebugVariable  extends XDebugElement implements IVariable/*, IWatc
                        fValue= new XDebugArrayValue(this,property,typeName);
                else if (typeName.equals("object") )
                        fValue= new XDebugArrayValue(this,property,typeName);
+               else if (typeName.equals("resource") )
+                       fValue= new XDebugResourceValue(this, property, typeName);
                else
                        fValue= new XDebugValue(this,property,typeName);
        }
@@ -128,8 +130,10 @@ public class XDebugVariable  extends XDebugElement implements IVariable/*, IWatc
         * @see org.eclipse.debug.core.model.IValueModification#setValue(java.lang.String)
         */
        public void setValue(String expression) throws DebugException {
-               if(fValue.setValue(expression))
-                       fireEvent(new DebugEvent(this, DebugEvent.CHANGE, DebugEvent.CONTENT));
+               if(fValue.setValue(expression)) {
+                       
+               }
+                       //fireEvent(new DebugEvent(this, DebugEvent.CHANGE, DebugEvent.CONTENT));
                //fValue.setValueA(expression);
        }
        
@@ -170,11 +174,6 @@ public class XDebugVariable  extends XDebugElement implements IVariable/*, IWatc
                return fFrame;
        }
        
-       public void setStackFrame(XDebugStackFrame frame) {
-               fFrame = frame;
-               super.setDebugTarget((XDebugTarget) frame.getDebugTarget());
-       }
-
 //     public int getType() {
 //             return fType;
 //     }
@@ -191,10 +190,6 @@ public class XDebugVariable  extends XDebugElement implements IVariable/*, IWatc
                return (fNumChildren > 0);
        }
 
-       public boolean isArray() {
-               return (fValue.isArray());
-       }
-
        public String getEncoding() {
                return fEncoding;
        }
@@ -208,7 +203,7 @@ public class XDebugVariable  extends XDebugElement implements IVariable/*, IWatc
        }
        
        public String toString() {
-               return fValue.toString();
+               return null;
        }
 
        public String getFullName() {
@@ -219,10 +214,6 @@ public class XDebugVariable  extends XDebugElement implements IVariable/*, IWatc
                return fNumChildren;
        }
 
-       public void setNumChildren(int numChildren) {
-               fNumChildren = numChildren;
-       }
-       
        public void setChange(IVariable oldVariable)  throws DebugException {
                XDebugAbstractValue oldValue = null;
                IVariable[] newVariable = null;