scan(visitor, targetFile);
}
private void setGoToItems(Set<String> viewPath, FILE_TYPE fileType, boolean isAll) {
FileObject targetDirectory = getDirectory(fileType);
GoToItemFactory itemFactory = GoToItemFactory.getInstance();
for (String path : viewPath) {
if (StringUtils.isEmpty(path)) {
continue;
}
// check moodule
String[] moduleSplite = FuelUtils.moduleSplit(path);
FileObject moduleDirectory = null;
if (moduleSplite != null && moduleSplite.length == 2) {
String moduleName = moduleSplite[0];
path = moduleSplite[1];
FuelPhpModule fuelModule = FuelPhpModule.forPhpModule(getPhpModule());
moduleDirectory = fuelModule.getDirectory(DIR_TYPE.MODULES, fileType, moduleName);
}
// get file
FileObject view;
if (moduleDirectory != null) {
view = moduleDirectory.getFileObject(path.concat(".php")); // NOI18N
} else {
view = targetDirectory.getFileObject(path.concat(".php")); // NOI18N
}
if (view == null) {
continue;
}
// add to items
GoToItem item = itemFactory.create(view, DEFAULT_OFFSET, ""); // NOI18N
if (item == null) {
continue;
}
switch (fileType) {
case VIEW: