Package com._1c.g5.v8.dt.qw.ui.utils
Class QueryWizardLabelProvidersUtil
- java.lang.Object
-
- com._1c.g5.v8.dt.qw.ui.utils.QueryWizardLabelProvidersUtil
-
public class QueryWizardLabelProvidersUtil extends Object
Util class containing useful methods for query wizard label providers.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description List<org.eclipse.xtext.validation.Issue>
getAssociatedIssues(Object element, QueryWizardSource source)
Returns issues associated with given element.List<org.eclipse.xtext.validation.Issue>
getAssociatedIssues(org.eclipse.emf.ecore.EObject eObject, QueryWizardSource source)
Searches and returns issues associated with given eobject in query issues.org.eclipse.xtext.diagnostics.Severity
getGreatestSeverity(Collection<org.eclipse.xtext.validation.Issue> issues)
Returns greatest severity from given issues.org.eclipse.swt.graphics.Image
getGreatestSeverityImage(List<org.eclipse.xtext.validation.Issue> issues)
Returns image for issue with greatest severity.static QueryWizardLabelProvidersUtil
getInstance()
Returns instance of this class.org.eclipse.jface.resource.ImageDescriptor
getSeverityIcon(org.eclipse.xtext.diagnostics.Severity severity)
Returns icon for given severity.
-
-
-
Method Detail
-
getInstance
public static QueryWizardLabelProvidersUtil getInstance()
Returns instance of this class.- Returns:
- instance of this class. Cannot return
null
.
-
getAssociatedIssues
public List<org.eclipse.xtext.validation.Issue> getAssociatedIssues(Object element, QueryWizardSource source)
Returns issues associated with given element.- Parameters:
element
- - element to look for issue. Cannot benull
.source
- - query wizard source containing issues. Cannot benull
.- Returns:
- issues associated with given element. Can return
null
.
-
getAssociatedIssues
public List<org.eclipse.xtext.validation.Issue> getAssociatedIssues(org.eclipse.emf.ecore.EObject eObject, QueryWizardSource source)
Searches and returns issues associated with given eobject in query issues.- Parameters:
eObject
- - object to search issue for. Cannot benull
.source
- - source to look for issues. Cannot benull
.- Returns:
- issues associated with given object. Can return
null
.
-
getGreatestSeverity
public org.eclipse.xtext.diagnostics.Severity getGreatestSeverity(Collection<org.eclipse.xtext.validation.Issue> issues)
Returns greatest severity from given issues.- Parameters:
issues
- - issues to get greatest severity. Cannot benull
.- Returns:
- greatest severity from given issues. Returns
null
if given issues is empty.
-
getGreatestSeverityImage
public org.eclipse.swt.graphics.Image getGreatestSeverityImage(List<org.eclipse.xtext.validation.Issue> issues)
Returns image for issue with greatest severity.- Parameters:
issues
- - issues to look for severity. Cannot benull
.- Returns:
- image for issue with greatest severity. Returns
null
if given issues is empty.
-
getSeverityIcon
public org.eclipse.jface.resource.ImageDescriptor getSeverityIcon(org.eclipse.xtext.diagnostics.Severity severity)
Returns icon for given severity.- Parameters:
severity
- - severity to get icon for. Cannot benull
.- Returns:
- icon for given severity.
Returns non
null
only forSeverity.ERROR
andSeverity.WARNING
.
-
-