Class ModelConverterContextImpl

    • Constructor Detail

      • ModelConverterContextImpl

        public ModelConverterContextImpl​(List<ModelConverter> converters)
      • ModelConverterContextImpl

        public ModelConverterContextImpl​(ModelConverter converter)
    • Method Detail

      • defineModel

        public void defineModel​(String name,
                                Model model)
        Description copied from interface: ModelConverterContext
        needs to be called whenever a Model is defined which can be referenced from another Model or Property
        Specified by:
        defineModel in interface ModelConverterContext
        Parameters:
        name - the name of the model
        model - the Model
      • defineModel

        public void defineModel​(String name,
                                Model model,
                                Type type,
                                String prevName)
        Description copied from interface: ModelConverterContext
        needs to be called whenever a Model is defined which can be referenced from another Model or Property
        Specified by:
        defineModel in interface ModelConverterContext
        Parameters:
        name - the name of the model
        model - the Model
        type - the Type
        prevName - the (optional) previous name
      • resolveProperty

        public Property resolveProperty​(Type type,
                                        Annotation[] annotations)
        Specified by:
        resolveProperty in interface ModelConverterContext
        Parameters:
        type - the property Class
        Returns:
        a property representation of the Class. Any referenced models will be defined already.
      • resolve

        public Model resolve​(Type type)
        Specified by:
        resolve in interface ModelConverterContext
        Parameters:
        type - The Model Class
        Returns:
        a Model representation of the Class. Any referenced models will be defined already.
      • getJsonView

        public com.fasterxml.jackson.annotation.JsonView getJsonView()
        Specified by:
        getJsonView in interface ModelConverterContext
        Returns:
        A nullable JsonView annotation.
      • setJsonView

        public void setJsonView​(com.fasterxml.jackson.annotation.JsonView jsonView)
        Specified by:
        setJsonView in interface ModelConverterContext
        Parameters:
        jsonView - A nullable JsonView annotation, which is normally added to the annotated method to filter the response.