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

How to use
AuthorizationsDeclaration
in
org.restlet.ext.platform.internal.conversion.swagger.v1_2.model

Best Java code snippets using org.restlet.ext.platform.internal.conversion.swagger.v1_2.model.AuthorizationsDeclaration (Showing top 12 results out of 315)

origin: org.restlet.jse/org.restlet.ext.platform

private static void fillEndpointAuthorization(AuthorizationsDeclaration authorizations, Endpoint endpoint) {
  if (authorizations != null) {
    if (authorizations.getBasicAuth() != null) {
      endpoint.setAuthenticationProtocol(ChallengeScheme.HTTP_BASIC
          .getName());
    } else if (authorizations.getOauth2() != null) {
      endpoint.setAuthenticationProtocol(ChallengeScheme.HTTP_OAUTH
          .getName());
    } else if (authorizations.getApiKey() != null) {
      endpoint.setAuthenticationProtocol(ChallengeScheme.CUSTOM
          .getName());
    }
  }
}
origin: org.restlet.jee/org.restlet.ext.platform

AuthorizationsDeclaration authorizations = new AuthorizationsDeclaration();
if (ChallengeScheme.HTTP_BASIC.getName().equals(
    (endpoint.getAuthenticationProtocol()))) {
  authorizations.setBasicAuth(new BasicAuthorizationDeclaration());
  apiDeclaration.setAuthorizations(authorizations);
} else if (ChallengeScheme.HTTP_OAUTH.getName().equals(
    || ChallengeScheme.HTTP_OAUTH_MAC.getName().equals(
        (endpoint.getAuthenticationProtocol()))) {
  authorizations.setOauth2(new OAuth2AuthorizationDeclaration());
origin: org.restlet.osgi/org.restlet.ext.platform

AuthorizationsDeclaration authorizations = new AuthorizationsDeclaration();
if (ChallengeScheme.HTTP_BASIC.getName().equals(
    (endpoint.getAuthenticationProtocol()))) {
  authorizations.setBasicAuth(new BasicAuthorizationDeclaration());
  apiDeclaration.setAuthorizations(authorizations);
} else if (ChallengeScheme.HTTP_OAUTH.getName().equals(
    || ChallengeScheme.HTTP_OAUTH_MAC.getName().equals(
        (endpoint.getAuthenticationProtocol()))) {
  authorizations.setOauth2(new OAuth2AuthorizationDeclaration());
origin: org.restlet.jse/org.restlet.ext.platform

AuthorizationsDeclaration authorizations = new AuthorizationsDeclaration();
if (ChallengeScheme.HTTP_BASIC.getName().equals(
    (endpoint.getAuthenticationProtocol()))) {
  authorizations.setBasicAuth(new BasicAuthorizationDeclaration());
  apiDeclaration.setAuthorizations(authorizations);
} else if (ChallengeScheme.HTTP_OAUTH.getName().equals(
    || ChallengeScheme.HTTP_OAUTH_MAC.getName().equals(
        (endpoint.getAuthenticationProtocol()))) {
  authorizations.setOauth2(new OAuth2AuthorizationDeclaration());
origin: org.restlet.jee/org.restlet.ext.platform

private static void fillEndpointAuthorization(AuthorizationsDeclaration authorizations, Endpoint endpoint) {
  if (authorizations != null) {
    if (authorizations.getBasicAuth() != null) {
      endpoint.setAuthenticationProtocol(ChallengeScheme.HTTP_BASIC
          .getName());
    } else if (authorizations.getOauth2() != null) {
      endpoint.setAuthenticationProtocol(ChallengeScheme.HTTP_OAUTH
          .getName());
    } else if (authorizations.getApiKey() != null) {
      endpoint.setAuthenticationProtocol(ChallengeScheme.CUSTOM
          .getName());
    }
  }
}
origin: org.restlet.gae/org.restlet.ext.platform

AuthorizationsDeclaration authorizations = new AuthorizationsDeclaration();
if (ChallengeScheme.HTTP_BASIC.getName().equals(
    (endpoint.getAuthenticationProtocol()))) {
  authorizations.setBasicAuth(new BasicAuthorizationDeclaration());
  apiDeclaration.setAuthorizations(authorizations);
} else if (ChallengeScheme.HTTP_OAUTH.getName().equals(
    || ChallengeScheme.HTTP_OAUTH_MAC.getName().equals(
        (endpoint.getAuthenticationProtocol()))) {
  authorizations.setOauth2(new OAuth2AuthorizationDeclaration());
origin: org.restlet.gae/org.restlet.ext.platform

private static void fillEndpointAuthorization(AuthorizationsDeclaration authorizations, Endpoint endpoint) {
  if (authorizations != null) {
    if (authorizations.getBasicAuth() != null) {
      endpoint.setAuthenticationProtocol(ChallengeScheme.HTTP_BASIC
          .getName());
    } else if (authorizations.getOauth2() != null) {
      endpoint.setAuthenticationProtocol(ChallengeScheme.HTTP_OAUTH
          .getName());
    } else if (authorizations.getApiKey() != null) {
      endpoint.setAuthenticationProtocol(ChallengeScheme.CUSTOM
          .getName());
    }
  }
}
origin: org.restlet.jee/org.restlet.ext.platform

    .getAuthenticationProtocol();
if (authenticationProtocol != null) {
  AuthorizationsDeclaration authorizations = new AuthorizationsDeclaration();
        .setBasicAuth(new BasicAuthorizationDeclaration());
    listing.setAuthorizations(authorizations);
  } else if (ChallengeScheme.HTTP_OAUTH.getName().equals(
          authenticationProtocol)) {
    authorizations
        .setOauth2(new OAuth2AuthorizationDeclaration());
origin: org.restlet.osgi/org.restlet.ext.platform

private static void fillEndpointAuthorization(AuthorizationsDeclaration authorizations, Endpoint endpoint) {
  if (authorizations != null) {
    if (authorizations.getBasicAuth() != null) {
      endpoint.setAuthenticationProtocol(ChallengeScheme.HTTP_BASIC
          .getName());
    } else if (authorizations.getOauth2() != null) {
      endpoint.setAuthenticationProtocol(ChallengeScheme.HTTP_OAUTH
          .getName());
    } else if (authorizations.getApiKey() != null) {
      endpoint.setAuthenticationProtocol(ChallengeScheme.CUSTOM
          .getName());
    }
  }
}
origin: org.restlet.gae/org.restlet.ext.platform

    .getAuthenticationProtocol();
if (authenticationProtocol != null) {
  AuthorizationsDeclaration authorizations = new AuthorizationsDeclaration();
        .setBasicAuth(new BasicAuthorizationDeclaration());
    listing.setAuthorizations(authorizations);
  } else if (ChallengeScheme.HTTP_OAUTH.getName().equals(
          authenticationProtocol)) {
    authorizations
        .setOauth2(new OAuth2AuthorizationDeclaration());
origin: org.restlet.osgi/org.restlet.ext.platform

    .getAuthenticationProtocol();
if (authenticationProtocol != null) {
  AuthorizationsDeclaration authorizations = new AuthorizationsDeclaration();
        .setBasicAuth(new BasicAuthorizationDeclaration());
    listing.setAuthorizations(authorizations);
  } else if (ChallengeScheme.HTTP_OAUTH.getName().equals(
          authenticationProtocol)) {
    authorizations
        .setOauth2(new OAuth2AuthorizationDeclaration());
origin: org.restlet.jse/org.restlet.ext.platform

    .getAuthenticationProtocol();
if (authenticationProtocol != null) {
  AuthorizationsDeclaration authorizations = new AuthorizationsDeclaration();
        .setBasicAuth(new BasicAuthorizationDeclaration());
    listing.setAuthorizations(authorizations);
  } else if (ChallengeScheme.HTTP_OAUTH.getName().equals(
          authenticationProtocol)) {
    authorizations
        .setOauth2(new OAuth2AuthorizationDeclaration());
org.restlet.ext.platform.internal.conversion.swagger.v1_2.modelAuthorizationsDeclaration

Most used methods

  • <init>
  • getApiKey
  • getBasicAuth
  • getOauth2
  • setBasicAuth
  • setOauth2

Popular in Java

  • Finding current android device location
  • getApplicationContext (Context)
  • compareTo (BigDecimal)
  • setRequestProperty (URLConnection)
  • FileOutputStream (java.io)
    An output stream that writes bytes to a file. If the output file exists, it can be replaced or appen
  • SecureRandom (java.security)
    This class generates cryptographically secure pseudo-random numbers. It is best to invoke SecureRand
  • Date (java.util)
    A specific moment in time, with millisecond precision. Values typically come from System#currentTime
  • HashSet (java.util)
    HashSet is an implementation of a Set. All optional operations (adding and removing) are supported.
  • LinkedList (java.util)
    Doubly-linked list implementation of the List and Dequeinterfaces. Implements all optional list oper
  • Timer (java.util)
    Timers schedule one-shot or recurring TimerTask for execution. Prefer java.util.concurrent.Scheduled
  • Top plugins for WebStorm
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