Class CustomFieldOptionResolver

java.lang.Object
com.atlassian.jira.jql.resolver.CustomFieldOptionResolver
All Implemented Interfaces:
NameResolver<Option>

public class CustomFieldOptionResolver extends Object implements NameResolver<Option>
Looks up custom field option objects from the database.
Since:
v5.1
  • Constructor Details

    • CustomFieldOptionResolver

      public CustomFieldOptionResolver(OptionsManager optionsManager)
  • Method Details

    • getIdsFromName

      public List<String> getIdsFromName(String name)
      Returns the list of ids of Option objects that have the given name. The name is case-insensitive.
      Specified by:
      getIdsFromName in interface NameResolver<Option>
      Parameters:
      name - the name of the option.
      Returns:
      all IDs of objects matching the name
    • nameExists

      public boolean nameExists(String name)
      Description copied from interface: NameResolver
      Returns true if the name would resolve to a domain object.
      Specified by:
      nameExists in interface NameResolver<Option>
      Parameters:
      name - the addressable name.
      Returns:
      true only if the name resolves to a domain object in the database.
    • idExists

      public boolean idExists(Long id)
      Description copied from interface: NameResolver
      Returns true if the id would resolve to a domain object.
      Specified by:
      idExists in interface NameResolver<Option>
      Parameters:
      id - the primary key.
      Returns:
      true only if the id resolves to a domain object in the database.
    • get

      public Option get(Long id)
      Description copied from interface: NameResolver
      Get by id.
      Specified by:
      get in interface NameResolver<Option>
      Parameters:
      id - the id.
      Returns:
      the domain object or null on lookup failure.
    • getAll

      @Nonnull public Collection<Option> getAll()
      Description copied from interface: NameResolver
      Gets all domain objects of this type in the underlying database. Note that calling this may not be a good idea for some domain object types.
      Specified by:
      getAll in interface NameResolver<Option>
      Returns:
      all objects of the configured type in the database (possibly empty, never null).