Example usage for org.springframework.data.geo.format PointFormatter INSTANCE

List of usage examples for org.springframework.data.geo.format PointFormatter INSTANCE

Introduction

In this page you can find the example usage for org.springframework.data.geo.format PointFormatter INSTANCE.

Prototype

PointFormatter INSTANCE

To view the source code for org.springframework.data.geo.format PointFormatter INSTANCE.

Click Source Link

Usage

From source file:org.springframework.data.web.config.SpringDataWebConfiguration.java

@Override
public void addFormatters(FormatterRegistry registry) {

    registry.addFormatter(DistanceFormatter.INSTANCE);
    registry.addFormatter(PointFormatter.INSTANCE);

    if (!(registry instanceof FormattingConversionService)) {
        return;// w  ww. j  ava2 s. c  o m
    }

    FormattingConversionService conversionService = (FormattingConversionService) registry;

    DomainClassConverter<FormattingConversionService> converter = new DomainClassConverter<>(conversionService);
    converter.setApplicationContext(context);
}