public interface Speedment
Platform
class acts as a generic holder of different system
Components. Using its pluggable architecture, one can
replace existing default implementations of existing Components or plug in
custom made implementation of any type.
Pluggable components must have a default constructor.
Modifier and Type | Method and Description |
---|---|
<ENTITY> ManagerConfigurator<ENTITY> |
configure(Class<? extends Manager<ENTITY>> manager)
Creates and Returns a manager configurator that can be used to configure
an existing manager.
|
<T> Optional<T> |
get(Class<T> type)
Returns the specified component from the platform, or if it does not
exist, an empty
Optional . |
<T> T |
getOrThrow(Class<T> type)
Returns the specified component from the platform, or if it does not
exist, throws a
SpeedmentException . |
void |
stop()
Stops the Speedment instance and deallocates any allocated resources.
|
<T> Optional<T> get(Class<T> type)
Optional
.T
- the type to search fortype
- the interface type<T> T getOrThrow(Class<T> type) throws SpeedmentException
SpeedmentException
.T
- the component interface typetype
- the component interface classSpeedmentException
- if it was not installed<ENTITY> ManagerConfigurator<ENTITY> configure(Class<? extends Manager<ENTITY>> manager)
ENTITY
- the entity typemanager
- to configurevoid stop()
Copyright © 2017 Speedment, Inc.. All rights reserved.