Class ObjectDetailsDatabaseBuilder

    • Constructor Detail

      • ObjectDetailsDatabaseBuilder

        public ObjectDetailsDatabaseBuilder()
    • Method Detail

      • storeInventory

        public ObjectDetailsDatabaseBuilder storeInventory​(boolean storeInventory)
        If serialized inventories should be stored in the database. Default: true.
        Parameters:
        storeInventory - true if serialized inventories should be stored in the database.
        Returns:
        builder
      • waitTime

        public ObjectDetailsDatabaseBuilder waitTime​(long waitTime,
                                                     TimeUnit timeUnit)
        Used to override the amount of time the client will wait to obtain a lock. Default: 10 seconds.
        Parameters:
        waitTime - wait time (MariaDB uses seconds, while PostgreSQL and H2 use milliseconds)
        timeUnit - unit of time
        Returns:
        builder
      • dataSource

        public ObjectDetailsDatabaseBuilder dataSource​(DataSource dataSource)
        Sets the DataSource to use for the object details table. This is a required field.
        Parameters:
        dataSource - the DataSource
        Returns:
        builder
      • tableName

        public ObjectDetailsDatabaseBuilder tableName​(String tableName)
        Sets the name of the table to use to store object details. Default: ocfl_object_details
        Parameters:
        tableName - the table name to use
        Returns:
        builder
      • build

        public ObjectDetailsDatabase build()
        Constructs a new ObjectDetailsDatabase instance using the given dataSource. If the database does not already contain an object details table, it attempts to create one.
        Returns:
        ObjectDetailsDatabase