net.sf.mmm.util.value.impl.ValueConverterToNumber Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of mmm-util-value Show documentation
Show all versions of mmm-util-value Show documentation
This project provides common utitlities to for converting values.
The newest version!
/* Copyright (c) The m-m-m Team, Licensed under the Apache License, Version 2.0
* http://www.apache.org/licenses/LICENSE-2.0 */
package net.sf.mmm.util.value.impl;
import java.util.Calendar;
import java.util.Date;
import javax.inject.Inject;
import javax.inject.Named;
import javax.inject.Singleton;
import net.sf.mmm.util.math.api.MathUtil;
import net.sf.mmm.util.math.api.NumberType;
import net.sf.mmm.util.math.base.MathUtilImpl;
import net.sf.mmm.util.value.base.AbstractSimpleValueConverter;
/**
* This is an implementation of the {@link net.sf.mmm.util.value.api.ValueConverter} interface that converts an
* {@link Object} to a {@link Number}. It supports objects given as {@link CharSequence} (e.g. {@link String}) or
* {@link Number}.
*
* @author Joerg Hohwiller (hohwille at users.sourceforge.net)
* @since 1.0.1
*/
@Singleton
@Named
public class ValueConverterToNumber extends AbstractSimpleValueConverter
© 2015 - 2024 Weber Informatics LLC | Privacy Policy