org.keycloak.storage.openshift

## Class OpenshiftClientStorageProviderFactory

- java.lang.Object
- - org.keycloak.storage.openshift.OpenshiftClientStorageProviderFactory

- All Implemented Interfaces:
    ComponentFactory<OpenshiftClientStorageProvider,ClientStorageProvider>, ConfiguredProvider, EnvironmentDependentProviderFactory, ProviderFactory<ClientStorageProvider>, ClientStorageProviderFactory<OpenshiftClientStorageProvider>

      public class OpenshiftClientStorageProviderFactory
      extends Object
      implements ClientStorageProviderFactory<OpenshiftClientStorageProvider>, EnvironmentDependentProviderFactory

  Author:
    Pedro Igor

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static String` | `CONFIG_PROPERTY_ACCESS_TOKEN`
    `static String` | `CONFIG_PROPERTY_DEFAULT_NAMESPACE`
    `static String` | `CONFIG_PROPERTY_DISPLAY_SCOPE_CONSENT_TEXT`
    `static String` | `CONFIG_PROPERTY_OPENSHIFT_URI`
    `static String` | `CONFIG_PROPERTY_REQUIRE_USER_CONSENT`
    `static String` | `PROVIDER_ID`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `OpenshiftClientStorageProviderFactory()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `OpenshiftClientStorageProvider` | `create(KeycloakSession session, ComponentModel model)` called per Keycloak transaction.
    `List<ProviderConfigProperty>` | `getConfigProperties()`
    `String` | `getHelpText()`
    `String` | `getId()` This is the name of the provider and will be showed in the admin console as an option.
    `boolean` | `isSupported()`
    `void` | `onUpdate(KeycloakSession session, RealmModel realm, ComponentModel oldModel, ComponentModel newModel)` Called after the component is updated.
    `void` | `validateConfiguration(KeycloakSession session, RealmModel realm, ComponentModel config)` Called before a component is created or updated.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

    - ### Methods inherited from interface org.keycloak.storage.client.ClientStorageProviderFactory

      `close, getCommonProviderConfigProperties, getTypeMetadata, init, onCreate, postInit`

    - ### Methods inherited from interface org.keycloak.component.ComponentFactory

      `create, preRemove`

    - ### Methods inherited from interface org.keycloak.provider.ProviderFactory

      `order`

- - ### Field Detail

    - #### PROVIDER_ID

          public static final String PROVIDER_ID

      See Also:
        Constant Field Values

    - #### CONFIG_PROPERTY_ACCESS_TOKEN

          public static final String CONFIG_PROPERTY_ACCESS_TOKEN

      See Also:
        Constant Field Values

    - #### CONFIG_PROPERTY_OPENSHIFT_URI

          public static final String CONFIG_PROPERTY_OPENSHIFT_URI

      See Also:
        Constant Field Values

    - #### CONFIG_PROPERTY_DEFAULT_NAMESPACE

          public static final String CONFIG_PROPERTY_DEFAULT_NAMESPACE

      See Also:
        Constant Field Values

    - #### CONFIG_PROPERTY_REQUIRE_USER_CONSENT

          public static final String CONFIG_PROPERTY_REQUIRE_USER_CONSENT

      See Also:
        Constant Field Values

    - #### CONFIG_PROPERTY_DISPLAY_SCOPE_CONSENT_TEXT

          public static final String CONFIG_PROPERTY_DISPLAY_SCOPE_CONSENT_TEXT

      See Also:
        Constant Field Values

  - ### Constructor Detail

    - #### OpenshiftClientStorageProviderFactory

          public OpenshiftClientStorageProviderFactory()

  - ### Method Detail

    - #### getId

          public String getId()

      Description copied from interface: `ClientStorageProviderFactory`
      This is the name of the provider and will be showed in the admin console as an option.
      Specified by:
        `getId` in interface `ProviderFactory<ClientStorageProvider>`
      Specified by:
        `getId` in interface `ClientStorageProviderFactory<OpenshiftClientStorageProvider>`

    - #### create

          public OpenshiftClientStorageProvider create(KeycloakSession session,
                                                       ComponentModel model)

      Description copied from interface: `ClientStorageProviderFactory`
      called per Keycloak transaction.
      Specified by:
        `create` in interface `ComponentFactory<OpenshiftClientStorageProvider,ClientStorageProvider>`
      Specified by:
        `create` in interface `ClientStorageProviderFactory<OpenshiftClientStorageProvider>`

    - #### getHelpText

          public String getHelpText()

      Specified by:
        `getHelpText` in interface `ConfiguredProvider`
      Specified by:
        `getHelpText` in interface `ClientStorageProviderFactory<OpenshiftClientStorageProvider>`

    - #### getConfigProperties

          public List<ProviderConfigProperty> getConfigProperties()

      Specified by:
        `getConfigProperties` in interface `ConfiguredProvider`
      Specified by:
        `getConfigProperties` in interface `ClientStorageProviderFactory<OpenshiftClientStorageProvider>`

    - #### validateConfiguration

          public void validateConfiguration(KeycloakSession session,
                                            RealmModel realm,
                                            ComponentModel config)
                                     throws ComponentValidationException

      Description copied from interface: `ComponentFactory`
      Called before a component is created or updated. Allows you to validate the configuration
      Specified by:
        `validateConfiguration` in interface `ComponentFactory<OpenshiftClientStorageProvider,ClientStorageProvider>`
      Specified by:
        `validateConfiguration` in interface `ClientStorageProviderFactory<OpenshiftClientStorageProvider>`
      Throws:
        `ComponentValidationException`

    - #### onUpdate

          public void onUpdate(KeycloakSession session,
                               RealmModel realm,
                               ComponentModel oldModel,
                               ComponentModel newModel)

      Description copied from interface: `ComponentFactory`
      Called after the component is updated.
      Specified by:
        `onUpdate` in interface `ComponentFactory<OpenshiftClientStorageProvider,ClientStorageProvider>`
        `oldModel` - old saved model
        `newModel` - new configuration

    - #### isSupported

          public boolean isSupported()

      Specified by:
        `isSupported` in interface `EnvironmentDependentProviderFactory`
      Returns:
        `true` if the provider is supported and should be available, `false` otherwise

Copyright © 2021 JBoss by Red Hat. All rights reserved.