Example usage for org.springframework.data.rest.core.config RepositoryRestConfiguration setReturnBodyOnUpdate

List of usage examples for org.springframework.data.rest.core.config RepositoryRestConfiguration setReturnBodyOnUpdate

Introduction

In this page you can find the example usage for org.springframework.data.rest.core.config RepositoryRestConfiguration setReturnBodyOnUpdate.

Prototype

public RepositoryRestConfiguration setReturnBodyOnUpdate(Boolean returnBodyOnUpdate) 

Source Link

Document

Set whether to return a response body after updating an entity.

Usage

From source file:org.agatom.springatom.boot.init.rest.SARepositoryRestMvcConfiguration.java

@Override
protected void configureRepositoryRestConfiguration(final RepositoryRestConfiguration configuration) {
    configuration.setReturnBodyOnCreate(
            Boolean.parseBoolean(this.properties.getProperty("rest.returnBodyOnCreate")));
    configuration.setReturnBodyOnUpdate(
            Boolean.parseBoolean(this.properties.getProperty("rest.returnBodyOnUpdate")));
    configuration.setMaxPageSize(Integer.parseInt(this.properties.getProperty("rest.maxPageSize")));
    configuration.setLimitParamName(this.properties.getProperty("rest.limitParamName"));
    configuration.setPageParamName(this.properties.getProperty("rest.pageParamName"));
    configuration.setSortParamName(this.properties.getProperty("rest.sortParamName"));
    configuration.setDefaultPageSize(Integer.parseInt(this.properties.getProperty("rest.defaultPageSize")));
}

From source file:org.lightadmin.core.config.context.LightAdminRepositoryRestMvcConfiguration.java

@Override
protected void configureRepositoryRestConfiguration(RepositoryRestConfiguration config) {
    config.setDefaultPageSize(10);//  w  ww  . j  a v  a2 s.  c o m
    config.setBaseUri(lightAdminConfiguration().getApplicationRestBaseUrl());
    config.exposeIdsFor(globalAdministrationConfiguration().getAllDomainTypesAsArray());
    config.setReturnBodyOnCreate(true);
    config.setReturnBodyOnUpdate(true);
}