All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.leopard.web.editor.LeopardWebBindingInitializer Maven / Gradle / Ivy

There is a newer version: 0.9.12
Show newest version
package io.leopard.web.editor;

import org.springframework.web.bind.WebDataBinder;
import org.springframework.web.bind.support.ConfigurableWebBindingInitializer;
import org.springframework.web.context.request.WebRequest;

public class LeopardWebBindingInitializer extends ConfigurableWebBindingInitializer {

	// private static boolean convert = true;
	//
	// public static void setConvert(boolean convert) {
	// LeopardWebBindingInitializer.convert = convert;
	// }

	@Override
	public void initBinder(WebDataBinder binder, WebRequest request) {
		super.initBinder(binder, request);

		// new CustomBooleanEditor(true)//

		// binder.registerCustomEditor(Date.class, new DefaultDateEditor());
		// binder.registerCustomEditor(boolean.class, new BooleanEditor());
		// binder.registerCustomEditor(int.class, new IntegerEditor());
		// binder.registerCustomEditor(long.class, new LongEditor());

		// if (convert) {
		// binder.registerCustomEditor(Boolean.class, new BooleanEditor());
		// binder.registerCustomEditor(Integer.class, new IntegerEditor());
		// binder.registerCustomEditor(Long.class, new LongEditor());
		// }

	}

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy