类 DefaultJobParametersConverter

  • 所有已实现的接口:
    JobParametersConverter

    public class DefaultJobParametersConverter
    extends java.lang.Object
    implements JobParametersConverter
    Converter for JobParameters instances using a simple naming convention for property keys. Key names that are prefixed with a - are considered non-identifying and will not contribute to the identity of a JobInstance. Key names ending with "(<type>)" where type is one of string, date, long are converted to the corresponding type. The default type is string. E.g.
     schedule.date(date)=2007/12/11
     department.id(long)=2345
     
    The literal values are converted to the correct type using the default Spring strategies, augmented if necessary by the custom editors provided.
    If you need to be able to parse and format local-specific dates and numbers, you can inject formatters (setDateFormat(DateFormat) and setNumberFormat(NumberFormat)).
    作者:
    Dave Syer, Michael Minella, Mahmoud Ben Hassine
    • 字段概要

      字段 
      修饰符和类型字段说明
      static java.lang.StringDATE_TYPE 
      static java.lang.StringLONG_TYPE 
      static java.lang.StringSTRING_TYPE 
    • 方法概要

      所有方法 实例方法 具体方法 
      修饰符和类型方法说明
      JobParametersgetJobParameters​(java.util.Properties props)
      Check for suffix on keys and use those to decide how to convert the value.
      java.util.PropertiesgetProperties​(JobParameters params)
      Use the same suffixes to create properties (omitting the string suffix because it is the default).
      voidsetDateFormat​(java.text.DateFormat dateFormat)
      Public setter for injecting a date format.
      voidsetNumberFormat​(java.text.NumberFormat numberFormat)
      Public setter for the NumberFormat.
      • 从类继承的方法 java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait