Package org.bson.codecs
Interface Parameterizable
Deprecated.
An interface indicating that a Codec is for a type that can be parameterized by generic types.
- Since:
- 4.8
-
Method Summary
Modifier and TypeMethodDescriptionCodec<?>
parameterize
(CodecRegistry codecRegistry, List<Type> types) Deprecated.Recursively parameterize the codec with the given registry and generic type arguments.
-
Method Details
-
parameterize
Deprecated.Recursively parameterize the codec with the given registry and generic type arguments.- Parameters:
codecRegistry
- the code registry to use to resolve codecs for the generic type argumentstypes
- the types that are parameterizing the containing type. The size of the list should be equal to the number of type parameters of the class whose codec is being parameterized, e.g. for aCollection
the size of the list would be one sinceCollection
has a single type parameter. Additionally, the size will never be 0 since there is no purpose in parameterizing a codec for a type that has no type parameters.- Returns:
- the Codec parameterized with the given types
-
Parameterizable
for a customCodec
, users should implementCodecProvider.get(Class, List, CodecRegistry)
for a customCodecProvider
.