18 package org.turro.elephant.impl.abstracts;
20 import java.sql.Timestamp;
21 import java.util.Date;
22 import org.turro.string.ObjectString;
23 import org.turro.elephant.context.IAction;
24 import org.turro.elephant.context.IConstructor;
47 public abstract int execute() throws Exception;
72 if(value ==
null)
return "";
85 Integer i = (Integer) ObjectString.parseNativeString(
getParameter(param), Integer.class,
false);
95 Double d = (Double) ObjectString.parseNativeString(
getParameter(param), Double.class,
false);
100 return d.doubleValue();
105 Date d = (Date) ObjectString.parseString(
getParameter(param), ObjectString.COMPRESSED_DATE_PATTERN, Date.class,
false);
115 return ObjectString.formatObject(date, ObjectString.COMPRESSED_DATE_PATTERN,
false);
123 if(value !=
null && value.indexOf(
":") > -1) {
124 String parts[] = value.split(
"\\:");
125 if(key ==
null || key.equals(parts[0])) {
String getParameter(String param, boolean encode)
static String getValuePortion(String key, String value)
boolean getBooleanParameter(String param)
double getDoubleParameter(String param, double defaultValue)
void setConstructor(IConstructor constructor)
IConstructor getConstructor()
String getStringParameter(String param)
String getParameter(String param)
int getIntParameter(String param, int defaultValue)
String getContextParameter()
Date getDateParameter(String param, Date defaultValue)
static String makeDateParameter(Timestamp date)
String getIdelParameter()
String getValueParameter(String param)
String getActionParameter()
static String makeDateParameter(Date date)
String getContextParameter()
String getParameter(String param)
String getActionParameter()
String getIdelParameter()