Class OAuth1AuthorizationFlowImpl.Builder

    • Field Detail

      • requestTokenUri

        private java.lang.String requestTokenUri
      • accessTokenUri

        private java.lang.String accessTokenUri
      • authorizationUri

        private java.lang.String authorizationUri
      • client

        private javax.ws.rs.client.Client client
      • callbackUri

        private java.lang.String callbackUri
      • enableLogging

        private boolean enableLogging
    • Constructor Detail

      • Builder

        public Builder​(OAuth1Parameters params,
                       OAuth1Secrets secrets,
                       java.lang.String requestTokenUri,
                       java.lang.String accessTokenUri,
                       java.lang.String authorizationUri)
        Create a new builder.
        Parameters:
        params - Pre-configured oauth parameters.
        secrets - Pre-configured oauth secrets.
        requestTokenUri - Request token uri.
        accessTokenUri - Access token uri.
        authorizationUri - Authorization uri.
    • Method Detail

      • callbackUri

        public OAuth1Builder.FlowBuilder callbackUri​(java.lang.String callbackUri)
        Description copied from interface: OAuth1Builder.FlowBuilder
        Set the callback URI to which the user (resource owner) should be redirected after he/she grants access to this application. In most cases, the URI is under control of this application and request done on this URI will be used to extract query parameter verifier that will be used in OAuth1AuthorizationFlow.finish(String) method.

        If URI is not defined by this method, the default value oob will be used in the Authorization Flow which should cause that verifier will be passed to application in other way than request redirection (for example shown to the user using html page).

        Specified by:
        callbackUri in interface OAuth1Builder.FlowBuilder
        Parameters:
        callbackUri - URI that should receive authorization response from the Service Provider.
        Returns:
        this builder.
      • client

        public OAuth1Builder.FlowBuilder client​(javax.ws.rs.client.Client client)
        Description copied from interface: OAuth1Builder.FlowBuilder
        Set the client that should be used internally by the OAuth1AuthorizationFlow to make requests to Authorization Server. If this method is not called, it is up to the implementation to create or get any private client instance to perform these requests. This method could be used mainly for performance reasons to avoid creation of new client instances and have control about created client instances used in the application.
        Specified by:
        client in interface OAuth1Builder.FlowBuilder
        Parameters:
        client - Client instance.
        Returns:
        this builder.