Class IncrementalIdStrategy.Factory
java.lang.Object
io.protostuff.runtime.IncrementalIdStrategy.Factory
- All Implemented Interfaces:
IdStrategy.Factory
- Enclosing class:
IncrementalIdStrategy
To use
IncrementalIdStrategy without registering anything, set the system property:
"-Dprotostuff.runtime.id_strategy_factory=io.protostuff.runtime.IncrementalIdStrategy$Factory"
Note that the pojos will be limited to 63 and the enums to 15.
It is best that you use the IncrementalIdStrategy.Registry to configure the strategy and set the max limits for each type.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreate()Creates a newIdStrategyinstance (impl).voidCalled after the methodIdStrategy.Factory.create()has been called.
-
Constructor Details
-
Factory
public Factory()
-
-
Method Details
-
create
Description copied from interface:IdStrategy.FactoryCreates a newIdStrategyinstance (impl).- Specified by:
createin interfaceIdStrategy.Factory
-
postCreate
public void postCreate()Description copied from interface:IdStrategy.FactoryCalled after the methodIdStrategy.Factory.create()has been called. This is used to prevent classloader issues. RuntimeEnv'sRuntimeEnv.ID_STRATEGYneed to be set first.- Specified by:
postCreatein interfaceIdStrategy.Factory
-