Tabnine Logo
SearchHandlerManager.getFieldIds
Code IndexAdd Tabnine to your IDE (free)

How to use
getFieldIds
method
in
com.atlassian.jira.issue.search.managers.SearchHandlerManager

Best Java code snippets using com.atlassian.jira.issue.search.managers.SearchHandlerManager.getFieldIds (Showing top 8 results out of 315)

origin: com.atlassian.jira/jira-core

public boolean isAliasForField(final ApplicationUser user, final String jqlName)
{
  final SearchHandlerManager searchHandlerManager = ComponentAccessor.getComponentOfType(SearchHandlerManager.class);
  final Collection<String> fieldIds = searchHandlerManager.getFieldIds(user, jqlName);
  return fieldIds.contains(navigableField.getId());
}
origin: com.atlassian.jira/jira-core

/**
 * @param overrideSecurity false if only fields which the user can see should be resolved
 * @param searcher the user performing the search
 * @param clauseName the clause name used
 * @return the set of {@link com.atlassian.jira.issue.fields.CustomField}s which map to the clause name and are also
 * of the type {@link com.atlassian.jira.issue.customfields.impl.CascadingSelectCFType}; never null.
 */
private Set<CustomField> resolveField(final boolean overrideSecurity, final ApplicationUser searcher, final String clauseName)
{
  final Set<CustomField> fields = new HashSet<CustomField>();
  final Collection<String> fieldIds = overrideSecurity ? searchHandlerManager.getFieldIds(clauseName) : searchHandlerManager.getFieldIds(searcher, clauseName);
  for (String fieldId : fieldIds)
  {
    final CustomField field = customFieldManager.getCustomFieldObject(fieldId);
    if (field != null && field.getCustomFieldType() instanceof CascadingSelectCFType)
    {
      fields.add(field);
    }
    else
    {
      log.info(String.format("jql clause name %s does not resolve to a cascading select field", clauseName));
    }
  }
  return fields;
}
origin: com.atlassian.jira.plugin.labels/jira-labels-plugin

final Collection<String> fieldIds = searchHandlerManager.getFieldIds(searcher, jqlClauseName);
if (!fieldIds.isEmpty())
origin: com.atlassian.jira/jira-core

public Results getPossibleValues(final ApplicationUser user, final String jqlClauseName, final String valuePrefix, final int maxNumResults)
{
  final ApplicationUser searcher = user;
  final Set<String> suggestions = new TreeSet<String>();
  final Collection<String> fieldIds = getSearchHandlerManager().getFieldIds(searcher, jqlClauseName);
  for (String fieldId : fieldIds)
  {
    if(fieldId.equals(SystemSearchConstants.forLabels().getFieldId()))
    {
      suggestions.addAll(labelManager.getSuggestedLabels(searcher, null, valuePrefix));
    }
    else
    {
      suggestions.addAll(labelManager.getSuggestedLabels(searcher, null, CustomFieldUtils.getCustomFieldId(fieldId), valuePrefix));
    }
  }
  final List<Result> results = Lists.newArrayListWithCapacity(suggestions.size());
  for (String suggestion : suggestions)
  {
    if(results.size() == maxNumResults)
    {
      break;
    }
    results.add(new Result(suggestion));
  }
  return new Results(results);
}
origin: com.atlassian.jira/jira-core

final List<String> fieldIds = new ArrayList<String>(searchHandlerManager.getFieldIds(searcher, sortClauseName));
origin: com.atlassian.jira/jira-core

final Collection<String> fieldIds = searchHandlerManager.getFieldIds(searcher, jqlClauseName);
if (!fieldIds.isEmpty())
origin: com.atlassian.jira/jira-core

final List<String> fieldIds = new ArrayList<String>(searchHandlerManager.getFieldIds(searcher, searchSort.getField()));
origin: com.atlassian.jira/jira-core

final Collection<String> fieldIds = searchHandlerManager.getFieldIds(searcher, clauseName);
com.atlassian.jira.issue.search.managersSearchHandlerManagergetFieldIds

Javadoc

Gets the field ids that are associated with the provided jqlClauseName. The reason this returns a collection is that custom fields can have the same JQL clause name and therefore resolve to multiple field ids. This will only return the fields associated with clause handlers that the user has permission to see as specified by the com.atlassian.jira.jql.permission.ClausePermissionHandler#hasPermissionToUseClause(com.atlassian.crowd.embedded.api.User)method.

Popular methods of SearchHandlerManager

  • getJqlClauseNames
    Get the com.atlassian.jira.issue.search.ClauseNames associated with the provided field name. A colle
  • getClauseHandler
    Return a collection of com.atlassian.jira.jql.ClauseHandlers registered against the passed JQL claus
  • getSearcher
    Get a searcher by the searchers name.
  • getAllSearchers
    Return all the active searchers in JIRA. It will not return the searchers unless they are associated
  • getSearcherGroups
    Get all searcher groups with the IssueSearcher that are applicable for the context. * com.atlassian.
  • getSearchers
    Get searchers that are applicable for a given context. This is found through the * com.atlassian.jir
  • getSearchersByClauseName
    Return a collection of com.atlassian.jira.issue.search.searchers.IssueSearchers registered against t
  • getVisibleClauseHandlers
    Get all the available clause handlers that the searcher can see.
  • refresh
    Refreshes the com.atlassian.jira.issue.search.managers.SearchHandlerManager.

Popular in Java

  • Updating database using SQL prepared statement
  • scheduleAtFixedRate (ScheduledExecutorService)
  • getApplicationContext (Context)
  • findViewById (Activity)
  • KeyStore (java.security)
    KeyStore is responsible for maintaining cryptographic keys and their owners. The type of the syste
  • List (java.util)
    An ordered collection (also known as a sequence). The user of this interface has precise control ove
  • UUID (java.util)
    UUID is an immutable representation of a 128-bit universally unique identifier (UUID). There are mul
  • JFileChooser (javax.swing)
  • Table (org.hibernate.mapping)
    A relational table
  • Logger (org.slf4j)
    The org.slf4j.Logger interface is the main user entry point of SLF4J API. It is expected that loggin
  • Top Sublime Text plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now