|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjavax.microedition.xml.rpc.Type
javax.microedition.xml.rpc.Element
public class Element
The JAX-RPC subset runtime SPI (Service Provider Interface) is used
by generated stubs to execute RPC calls. The SPI is defined by the
Type,
Element,
ComplexType, and
Operation classes.
The Element class is used to describe additional
properties of a Type. The properties mirror those that
can be defined in XML Schema, and referenced in the WSDL
description of an element. They are
type -
type specifies a simple type (see Type) or
a complex type (see ComplexType);
name -
the name of the element. It must be a qualified name
(see QName);
minOccurs -
minOccurs specifies the minimum number of times this
element might appear. This element is optional if minOccurs
is set to 0, and is required if it is set to a value bigger
than 1. The default value is 1.
maxOccurs -
maxOccurs specifies the maximum number of times this
element might appear. The value UNBOUNDED indicates
no maximum number of occurrences. The default value is 1;
nillable -
nillable represents unknown information, or inapplicable
information. Example (XML Schema Part 0: Primer Second Edition,
Section 2.9):
<xd:element name="shipDate" type="xsd:date" nillable="true"/>.
And to explicitly represent that shipDate has a nil
value in the instance document, one sets the nil attribute
to true, e.g.,
<shipDate xsi:nil="true"></shipDate>.
See Type,
ComplexType,
Operation.
| Field Summary | ||
|---|---|---|
static int |
UNBOUNDED
A number representing unbounded for
maxOccurs. |
|
Type |
contentType
The Type of the content of this Element. |
|
boolean |
isArray
A boolean flag indicating if this Element is an array. |
|
boolean |
isNillable
A boolean flag indicating whether this Element is nillable. |
|
boolean |
isOptional
A boolean flag indicating whether this Element
is optional. |
|
int |
maxOccurs
The maxOccurs attribute of this Element. |
|
int |
minOccurs
The minOccurs attribute of this Element. |
|
QName |
name
The qualified name of this Element. |
|
int |
value
The integer value of this ComplexType object. |
|
| Fields inherited from class javax.microedition.xml.rpc.Type |
|---|
BOOLEAN, BYTE, DOUBLE, FLOAT, INT, LONG, SHORT, STRING |
| Constructor Summary | ||
|---|---|---|
Element(QName qname,
Type type)
Constructs an Element with the default properties. |
||
Element(QName qname,
Type type,
int minOccurs,
int maxOccurs,
boolean nillable)
Constructs an Element with the given properties. |
||
| Method Summary |
|---|
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int UNBOUNDED
unbounded for
maxOccurs.
public final int value
ComplexType object.
public final Type contentType
Type of the content of this Element.
public final QName name
Element.
public final int minOccurs
minOccurs attribute of this Element.
public final boolean isOptional
Element
is optional. It is set to true if
minOccurs=0; false otherwise.
public final int maxOccurs
maxOccurs attribute of this Element.
public final boolean isNillable
Element is nillable.
It is set to true if this Element is
nillable; false otherwise.
public final boolean isArray
Element is an array.
It is set to true if this Element has the
the attribute maxOccurs assigned to a value bigger than
1 or to UNBOUNDED; false otherwise.
| Constructor Detail |
|---|
public Element(QName qname,
Type type,
int minOccurs,
int maxOccurs,
boolean nillable)
throws IllegalArgumentException
Element with the given properties.
qname - the qualified name of this Element.type - the Type of the content of this
Element.minOccurs - the minimum number of occurrence(s) this
Element might appear.maxOccurs - the maximum number of occurrence(s) this
Element might appear.
IllegalArgumentException - if
qname=null, or
type=null, or
type is an instance of Element, or
minOccurs<0, or
maxOccurs<0 and maxOccurs != UNBOUNDED
minOccurs>maxOccurs and maxOccurs != UNBOUNDED.
public Element(QName qname,
Type type)
throws IllegalArgumentException
Element with the default properties.
qname - the qualified name of this Element.type - the Type of the content of this
Element.
IllegalArgumentException - if
qname=null, or
type=null, or
type is an instance of Element.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
Copyright 1999-2011 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Java is a trademark of Oracle America Inc. in the US and other countries.
Legal