Simple Comment Case

This commit is contained in:
jeffcheasey88 2023-05-26 18:36:04 +02:00
parent 784a51e75c
commit bd2cf6c26a
3 changed files with 13 additions and 4 deletions

View file

@ -91,6 +91,7 @@ public class Function {
}
private void body(String content, CleanerPool cleaner) throws Exception{
System.out.println("BODY "+content);
}
public void show(int tab){

View file

@ -21,6 +21,8 @@ public class Import {
this.name = matcher.group(2);
return matcher.group(1).length();
}
// public int DoYouSeeMe(){ return false; }
public String getName(){
return this.name;

View file

@ -81,8 +81,16 @@ public class JavaParser{
String content = "";
int index;
CleanerPool cleaner = new CleanerPool(
new Cleaner("CONSTANT_STRING",'"','"'),
new Cleaner("CONSTANT_CHAR",'\'','\''));
String line;
while((line = reader.readLine()) != null) content+=line;
while((line = reader.readLine()) != null){
index = line.indexOf("//");
if(index >= 0) line = line.substring(0, index);
content+=line;
}
// content = CleanerPool.getterToDelete.clean(content);
@ -99,9 +107,7 @@ public class JavaParser{
}
this.clazz = new Class();
index = this.clazz.parse(content, new CleanerPool(
new Cleaner("CONSTANT_STRING",'"','"'),
new Cleaner("CONSTANT_CHAR",'\'','\'')));
index = this.clazz.parse(content, cleaner);
content = content.substring(index);
}