1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-29 19:45:01 +02:00

Cleanup: removed unused and internal methods from ICValue.

This commit is contained in:
Mikhail Khodjaiants 2003-06-11 22:58:44 +00:00
parent f4829f4428
commit 038b3552b2
6 changed files with 14 additions and 70 deletions

View file

@ -1,3 +1,13 @@
2003-06-11 Mikhail Khodjaiants
The unused 'getUnderlyingValueString' method has been removed from ICValue and CValue.
The methods 'setChanged' and 'getUnderlyingValue' are only for internal usage and
have been removed from ICValue.
* ICValue.java
* CArrayPartitionValue.java
* CValueFactory.java
* CValue.java
* CVariable.java
2003-06-10 Mikhail Khodjaiants
Refactoring: moved the type and value related methods from ICVariable to ICType and ICValue.
* ICType.java: new

View file

@ -6,8 +6,6 @@
package org.eclipse.cdt.debug.core.model;
import org.eclipse.cdt.debug.core.cdi.model.ICDIValue;
import org.eclipse.debug.core.DebugException;
import org.eclipse.debug.core.model.IValue;
/**
@ -18,20 +16,8 @@ import org.eclipse.debug.core.model.IValue;
*/
public interface ICValue extends IValue
{
/**
* Returns the underlying CDI value for this value.
*/
ICDIValue getUnderlyingValue();
/**
* Returns the string representation of the underlying CDI value for this value.
*/
String getUnderlyingValueString();
String evaluateAsExpression();
void setChanged( boolean changed ) throws DebugException;
boolean isNaN();
boolean isPositiveInfinity();

View file

@ -11,7 +11,6 @@ import java.util.Collections;
import java.util.Iterator;
import java.util.List;
import org.eclipse.cdt.debug.core.cdi.model.ICDIValue;
import org.eclipse.cdt.debug.core.cdi.model.ICDIVariable;
import org.eclipse.cdt.debug.core.model.ICValue;
import org.eclipse.debug.core.DebugException;
@ -57,22 +56,6 @@ public class CArrayPartitionValue extends CDebugElement implements ICValue
fEnd = end;
}
/* (non-Javadoc)
* @see org.eclipse.cdt.debug.core.ICValue#getType()
*/
public int getType()
{
return 0;
}
/* (non-Javadoc)
* @see org.eclipse.cdt.debug.core.ICValue#getUnderlyingValue()
*/
public ICDIValue getUnderlyingValue()
{
return null;
}
/* (non-Javadoc)
* @see org.eclipse.debug.core.model.IValue#getReferenceTypeName()
*/
@ -131,9 +114,6 @@ public class CArrayPartitionValue extends CDebugElement implements ICValue
return fEnd;
}
/* (non-Javadoc)
* @see org.eclipse.cdt.debug.core.model.ICValue#setChanged(boolean)
*/
public void setChanged( boolean changed ) throws DebugException
{
Iterator it = fVariables.iterator();
@ -143,14 +123,6 @@ public class CArrayPartitionValue extends CDebugElement implements ICValue
}
}
/* (non-Javadoc)
* @see org.eclipse.cdt.debug.core.model.ICValue#getUnderlyingValueString()
*/
public String getUnderlyingValueString()
{
return null;
}
/* (non-Javadoc)
* @see org.eclipse.cdt.debug.core.model.ICValue#computeDetail()
*/

View file

@ -168,9 +168,6 @@ public class CValue extends CDebugElement implements ICValue
return false;
}
/* (non-Javadoc)
* @see org.eclipse.cdt.debug.core.ICValue#getUnderlyingValue()
*/
public ICDIValue getUnderlyingValue()
{
return fCDIValue;
@ -516,26 +513,6 @@ public class CValue extends CDebugElement implements ICValue
return result;
}
/* (non-Javadoc)
* @see org.eclipse.cdt.debug.core.model.ICValue#getUnderlyingValueString()
*/
public String getUnderlyingValueString()
{
String valueString = null;
if ( getUnderlyingValue() != null )
{
try
{
valueString = getUnderlyingValue().getValueString();
}
catch( CDIException e )
{
valueString = e.getMessage();
}
}
return valueString;
}
/* (non-Javadoc)
* @see org.eclipse.cdt.debug.core.model.ICValue#evaluateAsExpression()
*/

View file

@ -7,7 +7,6 @@
package org.eclipse.cdt.debug.internal.core.model;
import org.eclipse.cdt.debug.core.cdi.model.ICDIValue;
import org.eclipse.cdt.debug.core.model.ICValue;
import org.eclipse.debug.core.DebugException;
/**
@ -18,12 +17,12 @@ import org.eclipse.debug.core.DebugException;
*/
public class CValueFactory
{
static public ICValue createValue( CVariable parent, ICDIValue cdiValue ) throws DebugException
static public CValue createValue( CVariable parent, ICDIValue cdiValue ) throws DebugException
{
return new CValue( parent, cdiValue );
}
static public ICValue createGlobalValue( CVariable parent, ICDIValue cdiValue ) throws DebugException
static public CValue createGlobalValue( CVariable parent, ICDIValue cdiValue ) throws DebugException
{
return new CGlobalValue( parent, cdiValue );
}

View file

@ -60,7 +60,7 @@ public abstract class CVariable extends CDebugElement
/**
* Cache of current value - see #getValue().
*/
protected ICValue fValue;
protected CValue fValue;
/**
* The name of this variable.
@ -270,7 +270,7 @@ public abstract class CVariable extends CDebugElement
if ( getValue() != null && getValue() instanceof ICValue )
{
fChanged = changed;
((ICValue)getValue()).setChanged( changed );
((CValue)getValue()).setChanged( changed );
}
}