use of com.intellij.struts2.dom.struts.strutspackage.GlobalResults in project intellij-plugins by JetBrains.
the class ExceptionMappingResultResolveConverter method getVariants.
@NotNull
public Collection<? extends HasResultType> getVariants(final ConvertContext context) {
final DomElement invocationElement = context.getInvocationElement();
final Action action = invocationElement.getParentOfType(Action.class, true);
if (action == null) {
return Collections.emptySet();
}
final List<HasResultType> variants = new ArrayList<>();
// Action-local first
variants.addAll(action.getResults());
final StrutsPackage strutsPackage = action.getStrutsPackage();
final GlobalResults globalResults = strutsPackage.getGlobalResults();
variants.addAll(globalResults.getResults());
return variants;
}
Aggregations