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

Remove unuse method parser(Inputstream in)

This commit is contained in:
Alain Magloire 2003-09-24 15:02:32 +00:00
parent 56ca1ac8d7
commit b91a9b0446

View file

@ -5,8 +5,6 @@ package org.eclipse.cdt.internal.core.model;
* All Rights Reserved.
*/
import java.io.InputStream;
import java.io.StringBufferInputStream;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.Iterator;
@ -205,18 +203,6 @@ public class TranslationUnit extends Openable implements ITranslationUnit {
return sourceManipulationInfo;
}
protected Map parse(InputStream in) {
try {
removeChildren();
CModelBuilder modelBuilder = new CModelBuilder(this);
return modelBuilder.parse();
} catch (Exception e) {
System.out.println(e);
return null;
}
}
protected CElementInfo createElementInfo () {
return new TranslationUnitInfo(this);
}
@ -476,16 +462,13 @@ public class TranslationUnit extends Openable implements ITranslationUnit {
* Parse the buffer contents of this element.
*/
public Map parse(){
try{
String buf =this.getBuffer().getContents();
if (buf != null) {
StringBufferInputStream in = new StringBufferInputStream (buf);
return (parse (in));
}
return null;
} catch (CModelException e){
// error getting the buffer
try {
removeChildren();
CModelBuilder modelBuilder = new CModelBuilder(this);
return modelBuilder.parse();
} catch (Exception e) {
// FIXME: use the debug log for this exception.
//System.out.println(e);
return null;
}
}