public class GetImportPrimitive extends AbstractReadPrimitive<java.lang.String[]>
changesClassHierarchy, classContent, clazz, modifiedClasses
Constructor and Description |
---|
GetImportPrimitive(ClassContent classContent) |
Modifier and Type | Method and Description |
---|---|
protected void |
executePrimitive()
Adds the specified import to the source code file of the class
|
boolean |
isSafe()
Returns if the primitive is safe or not.
|
protected void |
undoPrimitive()
Method that each primitive have to override to revert its own changes
over the ClassContent.
|
getReadValue, setReadValue
changeVersion, execute, getSuperClass, getTargetClass, undo, undoUpdateVersion, updateVersion, updateVersion
public GetImportPrimitive(ClassContent classContent)
protected void executePrimitive() throws StructuralIntercessionException
executePrimitive
in class AbstractPrimitive
StructuralIntercessionException
- If there are any errorpublic boolean isSafe()
AbstractPrimitive
isSafe
in interface Primitive
isSafe
in class AbstractPrimitive
protected void undoPrimitive() throws StructuralIntercessionException
AbstractPrimitive
undoPrimitive
in class AbstractPrimitive
StructuralIntercessionException
- If there are any error