refactor: rename process java

上级 df11494a
......@@ -50,7 +50,7 @@ func GetJavaTestFiles(codeDir string) []string {
return GetFilesWithFilter(codeDir, JavaTestFileFilter)
}
func ProcessFile(path string) *JavaParser {
func ProcessJavaFile(path string) *JavaParser {
is, _ := antlr.NewFileStream(path)
lexer := NewJavaLexer(is)
stream := antlr.NewCommonTokenStream(lexer, 0)
......@@ -58,7 +58,7 @@ func ProcessFile(path string) *JavaParser {
return parser
}
func ProcessString(code string) *JavaParser {
func ProcessJavaString(code string) *JavaParser {
is := antlr.NewInputStream(code)
lexer := NewJavaLexer(is)
stream := antlr.NewCommonTokenStream(lexer, 0)
......
......@@ -9,7 +9,7 @@ import (
func TestJavaCallApp_ProcessStringWorks(t *testing.T) {
g := NewGomegaWithT(t)
parser := ProcessString(`
parser := ProcessJavaString(`
package com.phodal.coca.analysis.identifier.model;
public class DataClass {
......
......@@ -33,7 +33,7 @@ func (j *JavaFullApp) AnalysisFiles(identNodes []domain.JIdentifier, files []str
displayName := filepath.Base(file)
fmt.Println("Refactoring parse java call: " + displayName)
parser := cocafile.ProcessFile(file)
parser := cocafile.ProcessJavaFile(file)
context := parser.CompilationUnit()
listener := full.NewJavaFullListener(identMap, file)
......
......@@ -24,7 +24,7 @@ func (j *JavaIdentifierApp) AnalysisFiles(files []string) []domain.JIdentifier {
var nodeInfos []domain.JIdentifier = nil
for _, file := range files {
parser := cocafile.ProcessFile(file)
parser := cocafile.ProcessJavaFile(file)
context := parser.CompilationUnit()
listener := identifier.NewJavaIdentifierListener()
......
......@@ -23,7 +23,7 @@ func (j *JavaApiApp) AnalysisPath(codeDir string, parsedDeps []domain.JClassNode
displayName := filepath.Base(file)
fmt.Println("Refactoring parse java call: " + displayName)
parser := cocafile.ProcessFile(file)
parser := cocafile.ProcessJavaFile(file)
context := parser.CompilationUnit()
listener := api.NewJavaApiListener(identifiersMap, diMap)
......
......@@ -28,7 +28,7 @@ func (j *BadSmellApp) AnalysisPath(codeDir string) *[]bs_domain.BsJClass {
displayName := filepath.Base(file)
fmt.Println("Refactoring parse java call: " + displayName)
parser := cocafile.ProcessFile(file)
parser := cocafile.ProcessJavaFile(file)
context := parser.CompilationUnit()
listener := bs.NewBadSmellListener()
......
......@@ -40,7 +40,7 @@ func (j *MoveClassApp) Analysis() []models2.JMoveStruct {
currentFile, _ = filepath.Abs(file)
parser := cocafile.ProcessFile(file)
parser := cocafile.ProcessJavaFile(file)
context := parser.CompilationUnit()
node := models2.NewJFullIdentifier()
......
......@@ -35,7 +35,7 @@ func (j *RemoveUnusedImportApp) Analysis() []models2.JFullIdentifier {
displayName := filepath.Base(file)
fmt.Println("Refactoring parse java call: " + displayName)
parser := cocafile.ProcessFile(file)
parser := cocafile.ProcessJavaFile(file)
context := parser.CompilationUnit()
node := models2.NewJFullIdentifier()
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册