Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cdt-patch] VariableManager

Index: ChangeLog
===================================================================
RCS file: /home/tools/org.eclipse.cdt.debug.core/ChangeLog,v
retrieving revision 1.93
diff -u -r1.93 ChangeLog
--- ChangeLog	13 Jan 2003 22:25:31 -0000	1.93
+++ ChangeLog	14 Jan 2003 21:11:49 -0000
@@ -1,3 +1,9 @@
+2003-01-14 Alain Magloire
+
+	* src/org/eclipse/cdt/debug/core/cdi/ICDIVariableManager.java: New file.
+	* src/org/eclipse/cdt/debug/core/cdi/ICDIVariableObject.java: New file.
+	* src/org/eclipse/cdt/debug/core/cdi/ICDIArgumentObject.java: New file.
+	
 2003-01-13 Mikhail Khodjaiants
 	Added the 'IRunToAddress' interface to support the 'Run To Line' action in disassembly.
 	* ICDebugTarget.java: extends IRunToAddress
Index: src/org/eclipse/cdt/debug/core/cdi/ICDIArgumentObject.java
===================================================================
RCS file: src/org/eclipse/cdt/debug/core/cdi/ICDIArgumentObject.java
diff -N src/org/eclipse/cdt/debug/core/cdi/ICDIArgumentObject.java
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ src/org/eclipse/cdt/debug/core/cdi/ICDIArgumentObject.java	14 Jan 2003 21:11:49 -0000
@@ -0,0 +1,12 @@
+/*
+ *(c) Copyright QNX Software Systems Ltd. 2002.
+ * All Rights Reserved.
+ * 
+ */
+package org.eclipse.cdt.debug.core.cdi;
+
+/**
+ */
+public interface ICDIArgumentObject extends ICDIVariableObject {
+
+}
Index: src/org/eclipse/cdt/debug/core/cdi/ICDIRegisterObject.java
===================================================================
RCS file: /home/tools/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/cdi/ICDIRegisterObject.java,v
retrieving revision 1.1
diff -u -r1.1 ICDIRegisterObject.java
--- src/org/eclipse/cdt/debug/core/cdi/ICDIRegisterObject.java	28 Aug 2002 01:42:26 -0000	1.1
+++ src/org/eclipse/cdt/debug/core/cdi/ICDIRegisterObject.java	14 Jan 2003 21:11:49 -0000
@@ -11,9 +11,5 @@
  * 
  * @since Jul 9, 2002
  */
-public interface ICDIRegisterObject {
-	/**
-	 * Return the name of the register.
-	 */
-	String getName();
+public interface ICDIRegisterObject extends ICDIVariableObject {
 }
Index: src/org/eclipse/cdt/debug/core/cdi/ICDIVariableManager.java
===================================================================
RCS file: src/org/eclipse/cdt/debug/core/cdi/ICDIVariableManager.java
diff -N src/org/eclipse/cdt/debug/core/cdi/ICDIVariableManager.java
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ src/org/eclipse/cdt/debug/core/cdi/ICDIVariableManager.java	14 Jan 2003 21:11:49 -0000
@@ -0,0 +1,139 @@
+/*
+ *(c) Copyright QNX Software Systems Ltd. 2002.
+ * All Rights Reserved.
+ * 
+ */
+package org.eclipse.cdt.debug.core.cdi;
+
+import org.eclipse.cdt.debug.core.cdi.model.ICDIStackFrame;
+import org.eclipse.cdt.debug.core.cdi.model.ICDIArgument;
+import org.eclipse.cdt.debug.core.cdi.model.ICDIExpression;
+import org.eclipse.cdt.debug.core.cdi.model.ICDIVariable;
+import org.eclipse.cdt.debug.core.cdi.model.ICDIRegister;
+
+/**
+ */
+public interface ICDIVariableManager extends ICDISessionObject {
+
+	/**
+	 * Method getVariableObject.
+	 * you can specify a static/global variable in a particular function or file,
+	 * filename or/and function is the context for the static ICDIVariableObject.
+	 * <pre>
+	 * hello.c:
+	 *   int bar;
+	 *   int main() {
+	 *   	static int bar;
+	 *   }
+	 * file.c:
+	 *   int foo() {
+	 *   	static int bar;
+	 *   }
+	 * getVariableObject(null, null, "bar");
+	 * getVariableObject(null, "main", "bar");
+	 * getVariableObject("file.c", "foo", "bar");
+	 * </pre>
+	 * @param filename
+	 * @param function
+	 * @param name
+	 * @return ICDIVariableObject
+	 * @throws CDIException
+	 */
+	public ICDIVariableObject getVariableObject(String filename, String function, String name) throws CDIException;
+
+	/**
+	 * Method createVariable.
+	 * Use the current stackframe to return an ICDIVariable.
+	 * A null stack means to use the current stackframe.
+	 *
+	 * @param stack
+	 * @param name
+	 * @return ICDIVariableObject
+	 * @throws CDIException
+	 */
+	public ICDIVariableObject getVariableObject(ICDIStackFrame stack, String name) throws CDIException;
+
+	/**
+	 * Method getVariableObjects.
+	 * Returns all the variable object of that context.
+	 * @param stack
+	 * @return ICDIVariableObject[]
+	 * @throws CDIException
+	 */
+	public ICDIVariableObject[] getVariableObjects(ICDIStackFrame stack) throws CDIException;
+
+	/**
+	 * Method createVariable.
+	 * Create a Variable for evaluation.  A CreatedEvent will be trigger and
+	 * ChangedEvent will also be trigger when the variable is assign a new value.
+	 * DestroyedEvent is fired when the variable is out of scope and automatically
+	 * removed from the manager list.
+	 * @param var
+	 * @return ICDIVariable
+	 * @throws CDIException
+	 */
+	public ICDIVariable createVariable(ICDIVariableObject var) throws CDIException;
+
+
+	/**
+	 * Method getArgumentObject.
+	 * Returns a argument Object that will hold the name and the context.
+	 * @param stack
+	 * @param name
+	 * @return ICDIArgumentObject
+	 * @throws CDIException
+	 */
+	public ICDIArgumentObject getArgumentObject(ICDIStackFrame stack, String name) throws CDIException;
+
+	/**
+	 * Method getArgumentObjects.
+	 * Returns all the arguments of that context.
+	 * @param stack
+	 * @return ICDIArgumentObject[]
+	 * @throws CDIException
+	 */
+	public ICDIArgumentObject[] getArgumentObjects(ICDIStackFrame stack) throws CDIException;
+
+	/**
+	 * Method createArgument.
+	 * Create a Variable for evaluation.  CreatedEvent will be trigger and
+	 * ChangedEvent will also be trigger when the variable is assign a new value.
+	 * DestroyedEvent is fired when the variable is out of scope and automatically
+	 * from th manager list.
+	 * @param var
+	 * @return ICDIArgument
+	 * @throws CDIException
+	 */
+	public ICDIArgument createArgument(ICDIArgumentObject var) throws CDIException;
+
+
+	/**
+	 * Method createExpression.
+	 * Create a Variable for evaluation.  A null stack means to use the current
+	 * stackframe. A CreatedEvent will be trigger and
+	 * ChangedEvent will also be trigger when the variable is assign a new value.
+	 * No DestroyedEvent is trigger even when the variable goes out of scope.
+	 * @param stack
+	 * @param name
+	 * @return ICDIExpression
+	 * @throws CDIException
+	 */
+	public ICDIExpression createExpression(ICDIStackFrame stack, String name) throws CDIException;
+
+	/**
+	 * Method createRegister.
+	 * @param stack
+	 * @param reg
+	 * @return ICDIRegister
+	 * @throws CDIException
+	 */
+	public ICDIRegister createRegister(ICDIStackFrame stack, ICDIRegisterObject reg) throws CDIException;
+
+	/**
+	 * Method getRegisterObjects.
+	 * @return ICDIRegisterObject[]
+	 * @throws CDIException
+	 */
+	public ICDIRegisterObject[] getRegisterObjects() throws CDIException;
+
+}
Index: src/org/eclipse/cdt/debug/core/cdi/ICDIVariableObject.java
===================================================================
RCS file: src/org/eclipse/cdt/debug/core/cdi/ICDIVariableObject.java
diff -N src/org/eclipse/cdt/debug/core/cdi/ICDIVariableObject.java
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ src/org/eclipse/cdt/debug/core/cdi/ICDIVariableObject.java	14 Jan 2003 21:11:49 -0000
@@ -0,0 +1,21 @@
+/*
+ *(c) Copyright QNX Software Systems Ltd. 2002.
+ * All Rights Reserved.
+ * 
+ */
+
+package org.eclipse.cdt.debug.core.cdi;
+
+
+/**
+ * 
+ */
+public interface ICDIVariableObject {
+
+	/**
+	 * Method getName.
+	 * @return String
+	 */
+	public String getName();
+
+}



Back to the top