public final class DefaultQueryXml
extends java.lang.Object
TaxiiXml
provides.
This class is slightly different in that Schematron conformance is not supported
(as of this writing there were no Schematron rules for queries). This class
also contains a DefaultQueryInfo
field that contains the query object
to be operated on whereas in TaxiiXml
the
JAXB object is kept separate.Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CM_CORE
Capability Module ID for Core
|
static java.util.List<java.lang.String> |
CM_IDS
Tuple of all capability modules defined in TAXII Default Query 1.0
|
static java.lang.String |
CM_REGEX
Capability Module ID for Regex
|
static java.lang.String |
CM_TIMESTAMP
Capability Module ID for Timestamp
|
static java.lang.String |
FID_TAXII_DEFAULT_QUERY_10
Format ID for this version of TAXII Default Query
|
static java.lang.String |
OP_AND
Operator AND
|
static java.lang.String |
OP_OR
Operator OR
|
static java.util.List<java.lang.String> |
OP_TYPES
Tuple of all operators
|
static java.lang.String |
ST_UNSUPPORTED_CAPABILITY_MODULE
Status Type indicating an unsupported capability module
|
static java.lang.String |
ST_UNSUPPORTED_TARGETING_EXPRESSION
Status Type indicating an unsupported targeting expression
|
static java.lang.String |
ST_UNSUPPORTED_TARGETING_EXPRESSION_ID
Status Type indicating an unsupported targeting expression id
|
Modifier and Type | Method and Description |
---|---|
javax.xml.bind.Marshaller |
createMarshaller(boolean prettyPrint)
Returns a marshaller for the TAXII Default Query binding.
|
DefaultQueryInfo |
getDefaultQueryInfo() |
static DefaultQueryXml |
newInstance() |
void |
setDefaultQueryInfo(DefaultQueryInfo dqi) |
org.w3c.dom.Element |
toElement()
Marshals the DefaultQueryInfo to a DOM Element.
|
java.lang.String |
toString()
Marshals the DefaultQueryInfo to an XML String.
|
Validation |
validateAll()
Validates the given message, returning all accumulated errors and warnings.
|
Validation |
validateFast()
Validates the given message, throwing a SAXException on the first
validation error encountered.
|
public static final java.lang.String FID_TAXII_DEFAULT_QUERY_10
public static final java.lang.String CM_CORE
public static final java.lang.String CM_REGEX
public static final java.lang.String CM_TIMESTAMP
public static final java.util.List<java.lang.String> CM_IDS
public static final java.lang.String OP_OR
public static final java.lang.String OP_AND
public static final java.util.List<java.lang.String> OP_TYPES
public static final java.lang.String ST_UNSUPPORTED_CAPABILITY_MODULE
public static final java.lang.String ST_UNSUPPORTED_TARGETING_EXPRESSION
public static final java.lang.String ST_UNSUPPORTED_TARGETING_EXPRESSION_ID
public static DefaultQueryXml newInstance()
public void setDefaultQueryInfo(DefaultQueryInfo dqi)
public DefaultQueryInfo getDefaultQueryInfo()
public javax.xml.bind.Marshaller createMarshaller(boolean prettyPrint) throws javax.xml.bind.JAXBException
prettyPrint
- Returns a marshaller that indents the output if true.javax.xml.bind.JAXBException
- if an error was encountered while creating the Marshallerpublic java.lang.String toString()
toString
in class java.lang.Object
public org.w3c.dom.Element toElement()
public Validation validateAll() throws javax.xml.bind.JAXBException, org.xml.sax.SAXException, java.io.IOException
javax.xml.bind.JAXBException
- If the message couldn't be validated because of an underlying JAXB errorjava.io.IOException
- If the underlying XMLReader
throws an
IOException
.org.xml.sax.SAXException
- on any fatal validation errorpublic Validation validateFast() throws javax.xml.bind.JAXBException, org.xml.sax.SAXException, java.io.IOException
javax.xml.bind.JAXBException
- If the message couldn't be validated because of an underlying JAXB errorjava.io.IOException
- If the underlying XMLReader
throws an
IOException
.org.xml.sax.SAXException
- On the first validation error