|
soap tutorial | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectadriani.jws.template.wrappers.Wrapper
adriani.jws.template.wrappers.WrapperIn
adriani.jws.template.wrappers.WrapperDateIn
public class WrapperDateIn
The class wrapping the ADBBean
elements containing the input SOAP request for the
formatDate()
method.
Field Summary | |
---|---|
protected java.util.Date |
the_date
Wrapped input value, used to store the SOAP input request value after validation. |
protected int |
the_id
Wrapped input value, used to store the SOAP input request value after validation. |
protected java.lang.StringBuffer |
the_pattern
Wrapped input value, used to store the SOAP input request value after validation. |
Fields inherited from class adriani.jws.template.wrappers.WrapperIn |
---|
BLANK, DOT, element, EMPTY, leadingName, NO_NUMBER, NOT_A_NUMBER, NOT_AVAILABLE |
Fields inherited from class adriani.jws.template.wrappers.Wrapper |
---|
logger, NOT_BIG_INTEGER, UNDEFINED |
Constructor Summary | |
---|---|
WrapperDateIn()
Constructor used by the SimpleClient to test the service (empty). |
|
WrapperDateIn(DateIn dateIn)
Constructor used by the actual web service logic, used to set the wrapper's class fields reading the values from the ADBBean element of the input SOAP request. |
Method Summary | |
---|---|
java.lang.String |
arrayToString()
Serialize all the data contained by this wrapper as a String object. |
java.util.Date |
getDate()
Accessor method. |
int |
getId()
Accessor method. |
java.lang.StringBuffer |
getPattern()
Accessor method. |
boolean |
hasValidID()
Helper method, used just to improve performance by reducing multiple checks (only for frequent calls). |
void |
setCalendar(java.lang.StringBuffer value)
This method is used only when the SOAP request is produced running the simple client, using hardcoded values or reading data from shell or property file. |
void |
setDate(java.util.Date value)
Mutator method. |
void |
setDate(java.sql.Date value)
Mutator method (overloaded). |
void |
setDate(java.lang.StringBuffer value)
Mutator method (overloaded). |
void |
setDefaults()
Usually input wrappers don't need to set default data in the input SOAP requests, since if some data is missing we can not assume any default behavior. |
void |
setId(int value)
Mutator method. |
void |
setId(java.lang.String value)
Mutator method (overloaded). |
void |
setId(java.lang.StringBuffer value)
Mutator method (overloaded). |
void |
setPattern(java.lang.StringBuffer value)
Mutator method. |
java.lang.StringBuffer[] |
toArray(boolean complete)
Produce a StringBuffer[] array containing all data contained by this wrapper. |
java.lang.String |
toString()
Serialize all the data contained by this wrapper as a String object, dot separated. |
boolean |
validate()
This method should be called after that all the wrapper's fields have been properly set, in order to adjust any string requiring a particular format. |
Methods inherited from class adriani.jws.template.wrappers.Wrapper |
---|
compareSB, getElement |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected java.util.Date the_date
protected java.lang.StringBuffer the_pattern
protected int the_id
Constructor Detail |
---|
public WrapperDateIn()
SimpleClient
to test the service (empty).
public WrapperDateIn(DateIn dateIn)
ADBBean
element of the input SOAP request. For this reason
implementation of this constructor is strongly coupled to the WSDL definition.
dateIn
- the ADBBean
object as received by the service skeleton classMethod Detail |
---|
public boolean validate()
ADBBean
Java classes
should NOT be used within this method.
validate
in class Wrapper
true
if all the mandatory ADBBean
objects were set correctlypublic void setDefaults()
ADBBean
is not SOAP nillable, we don't have a criterion allowing
to acknowledge if the id was set or not. For this reason, by default we set the
value NOT_A_NUMBER
on the ID wrapper's field.
setDefaults
in class Wrapper
Wrapper.Wrapper()
,
WrapperOut
public java.util.Date getDate()
public java.lang.StringBuffer getPattern()
public int getId()
public void setDate(java.util.Date value)
public void setDate(java.sql.Date value)
public void setDate(java.lang.StringBuffer value)
public void setCalendar(java.lang.StringBuffer value)
Utilities
class will
convert the input date (in string format) into a local Calendar
object, and set
this object in the proper class field.
value
- the input date in string value, e.g. "2010-02-26T15:40:00+01:00"public void setPattern(java.lang.StringBuffer value)
public void setId(int value)
public void setId(java.lang.StringBuffer value)
public void setId(java.lang.String value)
public boolean hasValidID()
public java.lang.String toString()
String
object, dot separated.
toString
in class java.lang.Object
public java.lang.String arrayToString()
String
object.
This is the "old plain version" of the toString()
method, which can be
used only if ALL input data (contained the SOAP request) are mandatory!
public java.lang.StringBuffer[] toArray(boolean complete)
StringBuffer[]
array containing all data contained by this wrapper.
If this method must be used in a test environment (where dummy input data should be complete),
the input flag complete
allows to add some hard-coded values if the creation
of the array fails.
complete
- if true
some hard-coded data will be created if creation of the array fails
StringBuffer[]
array with the data contained by this wrapper
|
Build 18/09/2012 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |