Class StorageClientFactory

  • All Implemented Interfaces:
    VitamClientFactoryInterface<StorageClient>

    public class StorageClientFactory
    extends VitamClientFactory<StorageClient>

    StorageClient factory

    Use to get a storage client in function of its type. Example :

     {
         @code
         // Retrieve default storage client
         StorageClient client = StorageClientFactory.getInstance().getStorageClient();
    
         // Exists
         client.exists(tenantId, strategyId);
     }
     
    You can change the type of the client to get. The types are define into the enum StorageClient. Use the changeDefaultClientType method to change the client type.
    • Field Detail

      • RESOURCE_PATH

        public static final java.lang.String RESOURCE_PATH
        Default path
        See Also:
        Constant Field Values
    • Method Detail

      • getInstance

        public static StorageClientFactory getInstance()
        Get the StorageClientFactory instance
        Returns:
        the instance
      • getClient

        public StorageClient getClient()
        Get the default storage client
        Returns:
        the default storage client