Class SchemaManager<T>
- java.lang.Object
-
- no.skatteetaten.fastsetting.formueinntekt.felles.documentsql.management.SchemaManager<T>
-
public class SchemaManager<T> extends Object
-
-
Field Summary
Fields Modifier and Type Field Description static StringCHANGE_LOG
-
Constructor Summary
Constructors Constructor Description SchemaManager(DataSource dataSource, Function<String,Optional<SchemaContext<T>>> schemas, JdbcDispatcherFactory factory)SchemaManager(DataSource dataSource, Map<String,SchemaContext<T>> schemas, JdbcDispatcherFactory factory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description JdbcDispatcher<T>create(String name)JdbcDispatcher<T>create(String name, boolean force)JdbcDispatcher<T>create(String name, boolean force, Consumer<String> onForce)booleandrop(String name)SchemaManager<T>withLength(int length)SchemaManager<T>withResolvers(Function<Class<?>,Map<PathElement,PathContext>> pathResolver, BiFunction<Class<?>,String,List<List<PathElement>>> rootResolver)SchemaManager<T>withUsers(Collection<String> users)
-
-
-
Field Detail
-
CHANGE_LOG
public static final String CHANGE_LOG
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
SchemaManager
public SchemaManager(DataSource dataSource, Map<String,SchemaContext<T>> schemas, JdbcDispatcherFactory factory)
-
SchemaManager
public SchemaManager(DataSource dataSource, Function<String,Optional<SchemaContext<T>>> schemas, JdbcDispatcherFactory factory)
-
-
Method Detail
-
withResolvers
public SchemaManager<T> withResolvers(Function<Class<?>,Map<PathElement,PathContext>> pathResolver, BiFunction<Class<?>,String,List<List<PathElement>>> rootResolver)
-
withLength
public SchemaManager<T> withLength(int length)
-
withUsers
public SchemaManager<T> withUsers(Collection<String> users)
-
create
public JdbcDispatcher<T> create(String name) throws SQLException
- Throws:
SQLException
-
create
public JdbcDispatcher<T> create(String name, boolean force) throws SQLException
- Throws:
SQLException
-
create
public JdbcDispatcher<T> create(String name, boolean force, Consumer<String> onForce) throws SQLException
- Throws:
SQLException
-
drop
public boolean drop(String name) throws SQLException
- Throws:
SQLException
-
-