@Override public RecoveredElement add(ImportReference pkgRef1, int bracketBalance1) { this.pkgRef = new RecoveredImport(pkgRef1, this, bracketBalance1); return this; } public RecoveredElement add(ModuleReference target, int bracketBalance1) {
@Override public String toString(int tab) { return tabString(tab) + "Recovered import: " + this.importReference.toString(); //$NON-NLS-1$ } public ImportReference updatedImportReference(){
@Override public void updateParseTree(){ updatedImportReference(); } /*
public String toString(int tab) { StringBuffer result = new StringBuffer(tabString(tab)); result.append("Recovered unit: [\n"); //$NON-NLS-1$ this.unitDeclaration.print(tab + 1, result); result.append(tabString(tab + 1)); result.append("]"); //$NON-NLS-1$ if (this.imports != null) { for (int i = 0; i < this.importCount; i++) { result.append("\n"); //$NON-NLS-1$ result.append(this.imports[i].toString(tab + 1)); } } if (this.types != null) { for (int i = 0; i < this.typeCount; i++) { result.append("\n"); //$NON-NLS-1$ result.append(this.types[i].toString(tab + 1)); } } return result.toString(); } public CompilationUnitDeclaration updatedCompilationUnitDeclaration(){
public String toString(int tab) { StringBuffer result = new StringBuffer(tabString(tab)); result.append("Recovered unit: [\n"); //$NON-NLS-1$ this.unitDeclaration.print(tab + 1, result); result.append(tabString(tab + 1)); result.append("]"); //$NON-NLS-1$ if (this.imports != null) { for (int i = 0; i < this.importCount; i++) { result.append("\n"); //$NON-NLS-1$ result.append(this.imports[i].toString(tab + 1)); } } if (this.types != null) { for (int i = 0; i < this.typeCount; i++) { result.append("\n"); //$NON-NLS-1$ result.append(this.types[i].toString(tab + 1)); } } return result.toString(); } public CompilationUnitDeclaration updatedCompilationUnitDeclaration(){
public void updateParseTree(){ updatedImportReference(); } /*
public RecoveredElement add(ImportReference pkgRef1, int bracketBalance1) { this.pkgRef = new RecoveredImport(pkgRef1, this, bracketBalance1); return this; } public RecoveredElement add(ModuleReference target, int bracketBalance1) {
public String toString(int tab) { return tabString(tab) + "Recovered import: " + this.importReference.toString(); //$NON-NLS-1$ } public ImportReference updatedImportReference(){
public String toString(int tab) { StringBuffer result = new StringBuffer(tabString(tab)); result.append("Recovered unit: [\n"); //$NON-NLS-1$ this.unitDeclaration.print(tab + 1, result); result.append(tabString(tab + 1)); result.append("]"); //$NON-NLS-1$ if (this.imports != null) { for (int i = 0; i < this.importCount; i++) { result.append("\n"); //$NON-NLS-1$ result.append(this.imports[i].toString(tab + 1)); } } if (this.types != null) { for (int i = 0; i < this.typeCount; i++) { result.append("\n"); //$NON-NLS-1$ result.append(this.types[i].toString(tab + 1)); } } return result.toString(); } public CompilationUnitDeclaration updatedCompilationUnitDeclaration(){
public void updateParseTree(){ updatedImportReference(); } /*
public RecoveredElement add(ImportReference importReference, int bracketBalanceValue) { resetPendingModifiers(); if (this.imports == null) { this.imports = new RecoveredImport[5]; this.importCount = 0; } else { if (this.importCount == this.imports.length) { System.arraycopy( this.imports, 0, (this.imports = new RecoveredImport[2 * this.importCount]), 0, this.importCount); } } RecoveredImport element = new RecoveredImport(importReference, this, bracketBalanceValue); this.imports[this.importCount++] = element; /* if import not finished, then import becomes current */ if (importReference.declarationSourceEnd == 0) return element; return this; } public RecoveredElement add(TypeDeclaration typeDeclaration, int bracketBalanceValue) {
public String toString(int tab) { return tabString(tab) + "Recovered import: " + this.importReference.toString(); //$NON-NLS-1$ } public ImportReference updatedImportReference(){
public String toString(int tab) { StringBuffer result = new StringBuffer(tabString(tab)); result.append("Recovered unit: [\n"); //$NON-NLS-1$ this.unitDeclaration.print(tab + 1, result); result.append(tabString(tab + 1)); result.append("]"); //$NON-NLS-1$ if (this.imports != null) { for (int i = 0; i < this.importCount; i++) { result.append("\n"); //$NON-NLS-1$ result.append(this.imports[i].toString(tab + 1)); } } if (this.types != null) { for (int i = 0; i < this.typeCount; i++) { result.append("\n"); //$NON-NLS-1$ result.append(this.types[i].toString(tab + 1)); } } return result.toString(); } public CompilationUnitDeclaration updatedCompilationUnitDeclaration(){
public void updateParseTree(){ updatedImportReference(); } /*
public RecoveredElement add(ImportReference importReference, int bracketBalanceValue) { resetPendingModifiers(); if (this.imports == null) { this.imports = new RecoveredImport[5]; this.importCount = 0; } else { if (this.importCount == this.imports.length) { System.arraycopy( this.imports, 0, (this.imports = new RecoveredImport[2 * this.importCount]), 0, this.importCount); } } RecoveredImport element = new RecoveredImport(importReference, this, bracketBalanceValue); this.imports[this.importCount++] = element; /* if import not finished, then import becomes current */ if (importReference.declarationSourceEnd == 0) return element; return this; } public RecoveredElement add(TypeDeclaration typeDeclaration, int bracketBalanceValue) {
public String toString(int tab) { return tabString(tab) + "Recovered import: " + this.importReference.toString(); //$NON-NLS-1$ } public ImportReference updatedImportReference(){
public String toString(int tab) { StringBuffer result = new StringBuffer(tabString(tab)); result.append("Recovered unit: [\n"); //$NON-NLS-1$ this.unitDeclaration.print(tab + 1, result); result.append(tabString(tab + 1)); result.append("]"); //$NON-NLS-1$ if (this.imports != null) { for (int i = 0; i < this.importCount; i++) { result.append("\n"); //$NON-NLS-1$ result.append(this.imports[i].toString(tab + 1)); } } if (this.types != null) { for (int i = 0; i < this.typeCount; i++) { result.append("\n"); //$NON-NLS-1$ result.append(this.types[i].toString(tab + 1)); } } return result.toString(); } public CompilationUnitDeclaration updatedCompilationUnitDeclaration(){
public void updateParseTree(){ updatedImportReference(); } /*
public RecoveredElement add(ImportReference importReference, int bracketBalanceValue) { resetPendingModifiers(); if (this.imports == null) { this.imports = new RecoveredImport[5]; this.importCount = 0; } else { if (this.importCount == this.imports.length) { System.arraycopy( this.imports, 0, (this.imports = new RecoveredImport[2 * this.importCount]), 0, this.importCount); } } RecoveredImport element = new RecoveredImport(importReference, this, bracketBalanceValue); this.imports[this.importCount++] = element; /* if import not finished, then import becomes current */ if (importReference.declarationSourceEnd == 0) return element; return this; } public RecoveredElement add(TypeDeclaration typeDeclaration, int bracketBalanceValue) {
public String toString(int tab) { return tabString(tab) + "Recovered import: " + this.importReference.toString(); //$NON-NLS-1$ } public ImportReference updatedImportReference(){