|
org.netbeans.modules.refactoring.api 1.0 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface TreeElementFactoryImplementation
Register your own TreeElementFactoryImplementation into META-INF/services if you want to build your own RefactoringPreview tree. For instance Java Refactoring understand Java - specific objects e.g. Projects, Groups, Methods etc.
public TreeElement getTreeElement(Object o) {
.
.
if (o instanceof SourceGroup) {
return new SourceGroupTreeElement((SourceGroup)o);
} else if (o instanceof SomethingFromJava) {
return new SomethingFromJavaTreeElement((SomethingFromJava) o);
}
Important note. It is expected from mathematical point of view, that this method
is function, or even better bijection.
| Method Summary | |
|---|---|
void |
cleanUp()
clears internal structures |
TreeElement |
getTreeElement(Object o)
returns TreeElement for given object if possible. |
| Method Detail |
|---|
TreeElement getTreeElement(Object o)
o -
void cleanUp()
|
org.netbeans.modules.refactoring.api 1.0 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||