1 package com.thaiopensource.validate; 2 3 import com.thaiopensource.util.PropertyId; 4 5 public interface Option { 6 PropertyId getPropertyId(); 7 Object valueOf(String arg) throws OptionArgumentException; 8 /** 9 * Combines multiple values of an option into a single value. A property 10 * whose value is logically a sequence may be represented by multiple options 11 * each representing a single member of the sequence. 12 * 13 * @param values an array of values to be combined 14 * @return an Object representing the combination, or <code>null</code> 15 * if they cannot be combined 16 */ 17 Object combine(Object[] values); 18 } 19