mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-06-05 08:46:02 +02:00
Added the abstract prototypes for some generic methods.
This commit is contained in:
parent
fd62bdd86c
commit
60b8ef73ba
7 changed files with 59 additions and 9 deletions
|
@ -1,3 +1,12 @@
|
||||||
|
2004-08-05 Mikhail Khodjaiants
|
||||||
|
Added the abstract prototypes for some generic methods.
|
||||||
|
* AbstractCValue.java
|
||||||
|
* AbstractCVariable.java
|
||||||
|
* CArrayPartition.java
|
||||||
|
* CArrayPartitionValue.java
|
||||||
|
* CValue.java
|
||||||
|
* CVariable.java
|
||||||
|
|
||||||
2004-08-04 Mikhail Khodjaiants
|
2004-08-04 Mikhail Khodjaiants
|
||||||
New implementation of the variable types.
|
New implementation of the variable types.
|
||||||
* CDIDebugModel.java
|
* CDIDebugModel.java
|
||||||
|
|
|
@ -24,5 +24,9 @@ public abstract class AbstractCValue extends CDebugElement implements ICValue {
|
||||||
super( target );
|
super( target );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
abstract protected void setChanged( boolean changed );
|
||||||
|
|
||||||
abstract public void dispose();
|
abstract public void dispose();
|
||||||
|
|
||||||
|
abstract protected void reset();
|
||||||
}
|
}
|
||||||
|
|
|
@ -34,4 +34,8 @@ public abstract class AbstractCVariable extends CDebugElement implements ICVaria
|
||||||
public abstract String getExpressionString() throws DebugException;
|
public abstract String getExpressionString() throws DebugException;
|
||||||
|
|
||||||
public abstract void dispose();
|
public abstract void dispose();
|
||||||
|
|
||||||
|
protected abstract void resetValue();
|
||||||
|
|
||||||
|
protected abstract void setChanged( boolean changed );
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,6 +19,7 @@ import org.eclipse.cdt.debug.core.cdi.model.ICDIVariableObject;
|
||||||
import org.eclipse.cdt.debug.core.cdi.model.type.ICDIArrayValue;
|
import org.eclipse.cdt.debug.core.cdi.model.type.ICDIArrayValue;
|
||||||
import org.eclipse.cdt.debug.core.model.CVariableFormat;
|
import org.eclipse.cdt.debug.core.model.CVariableFormat;
|
||||||
import org.eclipse.cdt.debug.core.model.ICType;
|
import org.eclipse.cdt.debug.core.model.ICType;
|
||||||
|
import org.eclipse.debug.core.DebugEvent;
|
||||||
import org.eclipse.debug.core.DebugException;
|
import org.eclipse.debug.core.DebugException;
|
||||||
import org.eclipse.debug.core.model.IValue;
|
import org.eclipse.debug.core.model.IValue;
|
||||||
|
|
||||||
|
@ -319,4 +320,23 @@ public class CArrayPartition extends AbstractCVariable {
|
||||||
fArrayPartitionValue = null;
|
fArrayPartitionValue = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* (non-Javadoc)
|
||||||
|
* @see org.eclipse.cdt.debug.internal.core.model.AbstractCVariable#resetValue()
|
||||||
|
*/
|
||||||
|
protected void resetValue() {
|
||||||
|
if ( fArrayPartitionValue != null ) {
|
||||||
|
fArrayPartitionValue.reset();
|
||||||
|
fireChangeEvent( DebugEvent.STATE );
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* (non-Javadoc)
|
||||||
|
* @see org.eclipse.cdt.debug.internal.core.model.AbstractCVariable#setChanged(boolean)
|
||||||
|
*/
|
||||||
|
protected void setChanged( boolean changed ) {
|
||||||
|
if ( fArrayPartitionValue != null ) {
|
||||||
|
fArrayPartitionValue.setChanged( changed );
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -116,10 +116,13 @@ public class CArrayPartitionValue extends AbstractCValue {
|
||||||
return fEnd;
|
return fEnd;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setChanged( boolean changed ) throws DebugException {
|
/* (non-Javadoc)
|
||||||
|
* @see org.eclipse.cdt.debug.internal.core.model.AbstractCValue#setChanged(boolean)
|
||||||
|
*/
|
||||||
|
protected void setChanged( boolean changed ) {
|
||||||
Iterator it = fVariables.iterator();
|
Iterator it = fVariables.iterator();
|
||||||
while( it.hasNext() ) {
|
while( it.hasNext() ) {
|
||||||
((CVariable)it.next()).setChanged( changed );
|
((AbstractCVariable)it.next()).setChanged( changed );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -157,4 +160,14 @@ public class CArrayPartitionValue extends AbstractCValue {
|
||||||
((AbstractCVariable)it.next()).dispose();
|
((AbstractCVariable)it.next()).dispose();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* (non-Javadoc)
|
||||||
|
* @see org.eclipse.cdt.debug.internal.core.model.AbstractCValue#reset()
|
||||||
|
*/
|
||||||
|
protected void reset() {
|
||||||
|
Iterator it = fVariables.iterator();
|
||||||
|
while( it.hasNext() ) {
|
||||||
|
((AbstractCVariable)it.next()).resetValue();
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
|
@ -175,14 +175,14 @@ public class CValue extends AbstractCValue {
|
||||||
return Arrays.asList( vars );
|
return Arrays.asList( vars );
|
||||||
}
|
}
|
||||||
|
|
||||||
public synchronized void setChanged( boolean changed ) /*throws DebugException*/ {
|
protected synchronized void setChanged( boolean changed ) {
|
||||||
if ( changed ) {
|
if ( changed ) {
|
||||||
fValueString = null;
|
fValueString = null;
|
||||||
resetStatus();
|
resetStatus();
|
||||||
}
|
}
|
||||||
Iterator it = fVariables.iterator();
|
Iterator it = fVariables.iterator();
|
||||||
while( it.hasNext() ) {
|
while( it.hasNext() ) {
|
||||||
((CVariable)it.next()).setChanged( changed );
|
((AbstractCVariable)it.next()).setChanged( changed );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -448,7 +448,7 @@ public class CValue extends AbstractCValue {
|
||||||
fValueString = null;
|
fValueString = null;
|
||||||
Iterator it = fVariables.iterator();
|
Iterator it = fVariables.iterator();
|
||||||
while( it.hasNext() ) {
|
while( it.hasNext() ) {
|
||||||
((CVariable)it.next()).resetValue();
|
((AbstractCVariable)it.next()).resetValue();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -264,8 +264,8 @@ public class CVariable extends AbstractCVariable implements ICDIEventListener {
|
||||||
if ( changed ) {
|
if ( changed ) {
|
||||||
invalidateValue();
|
invalidateValue();
|
||||||
}
|
}
|
||||||
if ( fValue instanceof CValue ) {
|
if ( fValue instanceof AbstractCValue ) {
|
||||||
((CValue)fValue).setChanged( changed );
|
((AbstractCValue)fValue).setChanged( changed );
|
||||||
}
|
}
|
||||||
fChanged = changed;
|
fChanged = changed;
|
||||||
}
|
}
|
||||||
|
@ -279,8 +279,8 @@ public class CVariable extends AbstractCVariable implements ICDIEventListener {
|
||||||
}
|
}
|
||||||
|
|
||||||
void resetValue() {
|
void resetValue() {
|
||||||
if ( fValue instanceof CValue ) {
|
if ( fValue instanceof AbstractCValue ) {
|
||||||
((CValue)fValue).reset();
|
((AbstractCValue)fValue).reset();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue