Tabnine Logo
ApplicationKey
Code IndexAdd Tabnine to your IDE (free)

How to use
ApplicationKey
in
com.atlassian.application.api

Best Java code snippets using com.atlassian.application.api.ApplicationKey (Showing top 20 results out of 315)

origin: com.atlassian.jira/jira-tests

@Override
public String getDefaultGroup()
{
  return key.value() + "-group";
}
origin: com.atlassian.jira/jira-tests

public MockApplicationRole key(String id)
{
  this.key = ApplicationKey.valueOf(id);
  return this;
}
origin: com.atlassian.jira/jira-tests

@Override
public boolean equals(final Object o)
{
  if (this == o) { return true; }
  if (o == null || getClass() != o.getClass()) { return false; }
  final MockPluginApplicationMetaData that = (MockPluginApplicationMetaData) o;
  return key.equals(that.key);
}
origin: com.atlassian.jira/jira-core

if (!ApplicationKey.isValid(applicationKeyStr))
final ApplicationKey applicationKey = ApplicationKey.valueOf(m.group(1));
if (!isApplicationActivated(applicationKey, licenseProperties))
origin: com.atlassian.jira/jira-tests

  @Override
  public int hashCode()
  {
    return key.hashCode();
  }
}
origin: com.atlassian.jira/jira-tests

public MockApplicationRole(ApplicationKey key)
{
  this();
  this.key = key;
  this.name = key.toString();
}
origin: com.atlassian.jira/jira-core

  public boolean isApplicationKeyCorrupted(String key)
  {
    return !ApplicationKey.isValid(key);
  }
}
origin: com.atlassian.jira/jira-rest-plugin

/**
 * Gets an ApplicationRole from the provided key
 *
 * @param key the key of the ApplicationRole to retrieve
 * @return an ApplicationRole or a ResponseBuilder containing an error response
 */
private Either<Response.ResponseBuilder, ApplicationRole> getApplicationRole(String key)
{
  if (!ApplicationKey.isValid(key))
  {
    return Either.left(forError(helper.getText("application.role.rest.bad.key", key)));
  }
  final ServiceOutcome<ApplicationRole> outcome = service.getRole(ApplicationKey.valueOf(key));
  if (!outcome.isValid())
  {
    return Either.left(forCollection(outcome.getErrorCollection()));
  }
  return Either.right(outcome.get());
}
origin: com.atlassian.application/atlassian-application-host

  @Override
  public int hashCode()
  {
    return key.hashCode();
  }
}
origin: com.atlassian.jira/jira-core

private void createAuditingRecord(ApplicationKey applicationKey)
{
  log.debug("Creating audit entry for {}. The application will be marked as a default.", applicationKey);
  final List<ChangedValue> changedValues = ImmutableList.of(new ChangedValueImpl(
          applicationKey.toString(), "", applicationKey + " (default)")
  );
  migrationLogDao.store(new AuditEntry(this.getClass(),
      "Setting the application defaults", "Applications were marked as default, based on the product license."
      + " New users will be created with respect to the default applications selection.",
      AssociatedItem.Type.APPLICATION_ROLE,
      applicationKey.toString(), EVENT_SHOWS_IN_CLOUD_LOG,
      changedValues, AuditEntrySeverity.INFO));
}
origin: com.atlassian.application/atlassian-application-api

private ApplicationKey(final String key)
{
  if (!isValid(key))
  {
    throw new IllegalArgumentException("'key' must match the regular expression '" + ALLOWED_KEYS + "'.");
  }
  this.key = key;
}
origin: com.atlassian.application/atlassian-application-api

@Override
public String toString()
{
  return value();
}
origin: com.atlassian.jira/jira-core

@Override
public boolean equals(final Object o)
{
  if (this == o) { return true; }
  if (o == null || getClass() != o.getClass()) { return false; }
  final LoaderKey loaderKey = (LoaderKey) o;
  if (locale != null ? !locale.equals(loaderKey.locale) : loaderKey.locale != null) { return false; }
  return !(applicationKey != null ? !applicationKey.equals(loaderKey.applicationKey) : loaderKey.applicationKey != null);
}
origin: com.atlassian.jira/jira-tests

public ApplicationRoleDataMatcher key(String key)
{
  this.key = ApplicationKey.valueOf(key);
  return this;
}
origin: com.atlassian.application/atlassian-application-host

  @Override
  public final int hashCode()
  {
    return key.hashCode();
  }
}
origin: com.atlassian.jira/jira-core

private Set<ApplicationKey> configureApplicationForLicense(final LicenseDetails licenseDetails,
    Optional<ApplicationUser> optionalUser)
{
  notNull("licenseDetails", licenseDetails);
  if (!userManager.hasGroupWritableDirectory())
  {
    log.warn("There are no writable directories to create the default group for the new license.");
    return Collections.emptySet();
  }
  final Set<ApplicationKey> configuredApps = Sets.newHashSet();
  for (final ApplicationKey key : licenseDetails.getLicensedApplications().getKeys())
  {
    if (!doesApplicationHaveActiveDefaultGroupConfigured(key))
    {
      if (configureApplicationWithDefaultGroup(key, optionalUser))
      {
        configuredApps.add(key);
      }
      else
      {
        log.info("Unable to perform application configuration for {}.", key.toString());
      }
    }
    else
    {
      log.info("Application already configured for {}.", key.toString());
    }
  }
  return configuredApps;
}
origin: com.atlassian.jira/jira-core

public String getKey()
{
  return key.value();
}
origin: com.atlassian.jira/jira-tests

@Override
public boolean equals(@Nullable final Object o)
{
  if (this == o) { return true; }
  if (o == null || getClass() != o.getClass()) { return false; }
  final MockApplicationRole that = (MockApplicationRole) o;
  //It is intentional that we only look at id.
  return key != null ? key.equals(that.key) : that.key == null;
}
origin: com.atlassian.jira/jira-tests

public MockApplicationRoleDefinition(String key, String name)
{
  this.key = ApplicationKey.valueOf(key);
  this.name = name;
}
origin: com.atlassian.jira/jira-tests

@Override
public int hashCode()
{
  //It is intentional that we only look at id.
  return key != null ? key.hashCode() : 0;
}
com.atlassian.application.apiApplicationKey

Javadoc

Represents the identifier to an Application. An ApplicationKey must match the the regular expression [a-zA-Z.]+. It is case-preserving but not case-sensitive. For example, ApplicationKey.valueOf("ABC").equals(ApplicationKey.valueOf("aBc")) evaluates to true.

Most used methods

  • value
    Return the String key used to create the ApplicationKey.
  • valueOf
    Create a new com.atlassian.application.api.ApplicationKey. The passed key must match the regex [a-zA
  • equals
  • hashCode
  • isValid
    Indicate if the passed key is valid.
  • toString
  • <init>
  • getComparableKey

Popular in Java

  • Making http post requests using okhttp
  • putExtra (Intent)
  • getSupportFragmentManager (FragmentActivity)
  • getSystemService (Context)
  • String (java.lang)
  • Date (java.util)
    A specific moment in time, with millisecond precision. Values typically come from System#currentTime
  • Properties (java.util)
    A Properties object is a Hashtable where the keys and values must be Strings. Each property can have
  • JButton (javax.swing)
  • JCheckBox (javax.swing)
  • Location (org.springframework.beans.factory.parsing)
    Class that models an arbitrary location in a Resource.Typically used to track the location of proble
  • Top PhpStorm 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