single()
Computes the quantifier for a type V when it is replaced by V[1] according to the following table:
Methods inherited from class java.lang.Enum |
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, valueOf |
Methods inherited from class java.lang.Object |
getClass, notify, notifyAll, wait, wait, wait |
NONE
public static final SmQuantifier NONE
EMPTY
public static final SmQuantifier EMPTY
EXACTLY_ONE
public static final SmQuantifier EXACTLY_ONE
OPTIONAL
public static final SmQuantifier OPTIONAL
ONE_OR_MORE
public static final SmQuantifier ONE_OR_MORE
ZERO_OR_MORE
public static final SmQuantifier ZERO_OR_MORE
values
public static SmQuantifier[] values()
- Returns an array containing the constants of this enum type, in
the order they are declared. This method may be used to iterate
over the constants as follows:
for (SmQuantifier c : SmQuantifier.values())
System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in
the order they are declared
valueOf
public static SmQuantifier valueOf(java.lang.String name)
- Returns the enum constant of this type with the specified name.
The string must match exactly an identifier used to declare an
enum constant in this type. (Extraneous whitespace characters are
not permitted.)
- Parameters:
name - the name of the enum constant to be returned.
- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException - if this enum type has no constant
with the specified name
java.lang.NullPointerException - if the argument is null
contains
public boolean contains(SmQuantifier other)
in
public boolean in(SmQuantifier... others)
- Determines whether this quantifier is contained in the specified set of quantifiers.
sum
public SmQuantifier sum(SmQuantifier other)
choice
public SmQuantifier choice(SmQuantifier other)
product
public SmQuantifier product(SmQuantifier other)
isNone
public boolean isNone()
isEmpty
public boolean isEmpty()
isOptional
public boolean isOptional()
isExactlyOne
public boolean isExactlyOne()
single
public SmQuantifier single()
- Computes the quantifier for a type V when it is replaced by V[1] according to the following table:
this |
aggregate |
? |
? |
* |
? |
1 |
1 |
+ |
1 |
none |
none |
empty |
empty |
toString
public java.lang.String toString()
- Overrides:
toString in class java.lang.Enum<SmQuantifier>
approximate
public static SmQuantifier approximate(int minOccurs,
int maxOccurs)
- Approximates the schema minOccurs and maxOccurs with the
SmQuantifier .
- Parameters:
minOccurs - The min-occurs value.maxOccurs - The max-occurs value.
- Returns:
- The
SmQuantifier approximation.
Copyright © 2009 TIBCO Software Inc. All Rights Reserved.
|