org.acm.seguin.refactor
Interface ComplexTransform

All Known Implementing Classes:
DefaultComplexTransform, JEditComplexTransform

public interface ComplexTransform

Base class for a program that reads in an abstract syntax tree, transforms the code, and rewrites the file to disk.

Author:
Chris Seguin

Method Summary
 void add(TransformAST value)
          Adds a syntax tree transformation
 void apply(java.io.File inputFile, java.io.File outputFile)
          Given a file, applies a set of transformations to it
 void clear()
          Clears all the transforms
 void createFile(java.io.File file)
          Creates a new file
 boolean hasAnyChanges()
          Is it worth applying the transforms
 void removeFile(java.io.File file)
          Removes an old file
 void setUndoAction(UndoAction init)
           
 

Method Detail

setUndoAction

void setUndoAction(UndoAction init)

add

void add(TransformAST value)
Adds a syntax tree transformation

Parameters:
value - Description of Parameter

clear

void clear()
Clears all the transforms


hasAnyChanges

boolean hasAnyChanges()
Is it worth applying the transforms

Returns:
true if there is any

apply

void apply(java.io.File inputFile,
           java.io.File outputFile)
Given a file, applies a set of transformations to it

Parameters:
inputFile - Description of Parameter
outputFile - Description of Parameter

createFile

void createFile(java.io.File file)
Creates a new file

Parameters:
file - Description of Parameter

removeFile

void removeFile(java.io.File file)
Removes an old file

Parameters:
file - Description of Parameter