Class SimpleNitriteMapper

    • Constructor Detail

      • SimpleNitriteMapper

        public SimpleNitriteMapper​(Class<?>... valueTypes)
        Instantiates a new SimpleNitriteMapper.
        Parameters:
        valueTypes - the value types
    • Method Detail

      • tryConvert

        public <Source,​Target> Object tryConvert​(Source source,
                                                       Class<Target> type)
        Description copied from interface: NitriteMapper
        Tries to convert an object of type Source to an object of type Target. If the conversion is not possible, it will return the source object.
        Specified by:
        tryConvert in interface NitriteMapper
        Type Parameters:
        Source - the type parameter
        Target - the type parameter
        Parameters:
        source - the source
        type - the type
        Returns:
        the target
      • registerEntityConverter

        public void registerEntityConverter​(EntityConverter<?> entityConverter)
        Registers an EntityConverter.
        Parameters:
        entityConverter - the entity converter
      • initialize

        public void initialize​(NitriteConfig nitriteConfig)
        Description copied from interface: NitritePlugin
        Initializes the plugin instance.
        Specified by:
        initialize in interface NitritePlugin
        Parameters:
        nitriteConfig - the nitrite config