Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoreutarass2010-04-30 16:24:03 -0400
committereutarass2010-04-30 16:24:03 -0400
commitb6a48dc562c3844a3dfab0c362c8bd103c2d2fee (patch)
treeb858a17c8a1022fa2b9ab2f333a74914c66ba54a /plugins/org.eclipse.tm.tcf.core
parent5a277bfafe0da72d9a962bd0dbc54c0d72429511 (diff)
downloadorg.eclipse.tcf-b6a48dc562c3844a3dfab0c362c8bd103c2d2fee.tar.gz
org.eclipse.tcf-b6a48dc562c3844a3dfab0c362c8bd103c2d2fee.tar.xz
org.eclipse.tcf-b6a48dc562c3844a3dfab0c362c8bd103c2d2fee.zip
TCF Agent: in order to improve debug API abstraction:
1. removed "pid_t pid" and "pid_t mem" fields from "struct Context": usage of pid_t is not 100% portable, some contexts might not have a PID. 2. added "char id[]" field in "struct Context". The field contains TCF ID of the context. 3. added "Context * mem" field in "struct Context". The field points to memory space object of the context. 4. added "Context * creator" field in "struct Context".
Diffstat (limited to 'plugins/org.eclipse.tm.tcf.core')
-rw-r--r--plugins/org.eclipse.tm.tcf.core/src/org/eclipse/tm/internal/tcf/services/remote/RunControlProxy.java8
-rw-r--r--plugins/org.eclipse.tm.tcf.core/src/org/eclipse/tm/tcf/services/IRunControl.java40
2 files changed, 44 insertions, 4 deletions
diff --git a/plugins/org.eclipse.tm.tcf.core/src/org/eclipse/tm/internal/tcf/services/remote/RunControlProxy.java b/plugins/org.eclipse.tm.tcf.core/src/org/eclipse/tm/internal/tcf/services/remote/RunControlProxy.java
index c1147e5a3..bed999776 100644
--- a/plugins/org.eclipse.tm.tcf.core/src/org/eclipse/tm/internal/tcf/services/remote/RunControlProxy.java
+++ b/plugins/org.eclipse.tm.tcf.core/src/org/eclipse/tm/internal/tcf/services/remote/RunControlProxy.java
@@ -48,6 +48,14 @@ public class RunControlProxy implements IRunControl {
return (String)props.get(PROP_PARENT_ID);
}
+ public String getProcessID() {
+ return (String)props.get(PROP_PROCESS_ID);
+ }
+
+ public String getCreatorID() {
+ return (String)props.get(PROP_CREATOR_ID);
+ }
+
public boolean isContainer() {
Boolean b = (Boolean)props.get(PROP_IS_CONTAINER);
return b != null && b.booleanValue();
diff --git a/plugins/org.eclipse.tm.tcf.core/src/org/eclipse/tm/tcf/services/IRunControl.java b/plugins/org.eclipse.tm.tcf.core/src/org/eclipse/tm/tcf/services/IRunControl.java
index e13786406..f0179c93b 100644
--- a/plugins/org.eclipse.tm.tcf.core/src/org/eclipse/tm/tcf/services/IRunControl.java
+++ b/plugins/org.eclipse.tm.tcf.core/src/org/eclipse/tm/tcf/services/IRunControl.java
@@ -24,14 +24,34 @@ public interface IRunControl extends IService {
* Context property names.
*/
static final String
+ /** Run control context ID */
PROP_ID = "ID",
+
+ /** Context parent (owner) ID, for a thread it is same as process ID */
PROP_PARENT_ID = "ParentID",
+
+ /** Context process (memory space) ID */
PROP_PROCESS_ID = "ProcessID",
+
+ /** ID of a context that created this context */
+ PROP_CREATOR_ID = "CreatorID",
+
+ /** true if the context is a container. Container can propagate run control commands to his children */
PROP_IS_CONTAINER = "IsContainer",
+
+ /** true if context has execution state - can be suspended/resumed */
PROP_HAS_STATE = "HasState",
+
+ /** Bit-set of RM_ values that are supported by the context */
PROP_CAN_RESUME = "CanResume",
+
+ /** Bit-set of RM_ values that can be used with count > 1 */
PROP_CAN_COUNT = "CanCount",
+
+ /** true if suspend command is supported by the context */
PROP_CAN_SUSPEND = "CanSuspend",
+
+ /** true if terminate command is supported by the context */
PROP_CAN_TERMINATE = "CanTerminate";
/**
@@ -211,6 +231,13 @@ public interface IRunControl extends IService {
interface RunControlContext {
/**
+ * Get context properties. See PROP_* definitions for property names.
+ * Context properties are read only, clients should not try to modify them.
+ * @return Map of context properties.
+ */
+ Map<String,Object> getProperties();
+
+ /**
* Retrieve context ID.
* Same as getProperties().get(“ID”)
*/
@@ -223,11 +250,16 @@ public interface IRunControl extends IService {
String getParentID();
/**
- * Get context properties. See PROP_* definitions for property names.
- * Context properties are read only, clients should not try to modify them.
- * @return Map of context properties.
+ * Retrieve context process ID.
+ * Same as getProperties().get(“ProcessID”)
*/
- Map<String,Object> getProperties();
+ String getProcessID();
+
+ /**
+ * Retrieve context creator ID.
+ * Same as getProperties().get(“CreatorID”)
+ */
+ String getCreatorID();
/**
* Utility method to read context property PROP_IS_CONTAINER.

Back to the top