org.jabber.jabberbeans.serverside
Class XDB12Builder

java.lang.Object
  |
  +--org.jabber.jabberbeans.PacketBuilder
        |
        +--org.jabber.jabberbeans.serverside.XDB12Builder
All Implemented Interfaces:
java.io.Serializable

public class XDB12Builder
extends PacketBuilder
implements java.io.Serializable

XDB12Builder is the class that expands upon PacketBuilder to allow building of XDB objects (packets). The builder is a required object in the creation of said packet, as the number of fields is too numerous to make direct creation feasable and non-error prone.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.jabber.jabberbeans.PacketBuilder
error, extensions, fromAddress, identifier, toAddress, type
 
Constructor Summary
XDB12Builder()
          Creates a new InfoQueryBuilder instance.
 
Method Summary
 Packet build()
          build returns a packet, specifically an InfoQuery packet.
 void reset()
          reset all parameters (including those in the parent class) to default values
 void setErrorCode(java.lang.String code)
          set the error type number
 void setErrorType(java.lang.String code)
           
 
Methods inherited from class org.jabber.jabberbeans.PacketBuilder
addExtension, delExtension, getError, getErrorCode, getErrorText, getExtensionVector, getFromAddress, getIdentifier, getToAddress, getType, resetBase, setError, setErrorText, setFromAddress, setIdentifier, setToAddress, setType
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XDB12Builder

public XDB12Builder()
Creates a new InfoQueryBuilder instance.

Method Detail

reset

public void reset()
reset all parameters (including those in the parent class) to default values

Specified by:
reset in class PacketBuilder

setErrorCode

public void setErrorCode(java.lang.String code)
Description copied from class: PacketBuilder
set the error type number

Overrides:
setErrorCode in class PacketBuilder

setErrorType

public void setErrorType(java.lang.String code)

build

public Packet build()
             throws java.lang.InstantiationException
build returns a packet, specifically an InfoQuery packet. It will fail if the parameters specified in the builder were not sufficient to create a valid packet.

Specified by:
build in class PacketBuilder
Returns:
a valid Packet
Throws:
java.lang.InstantiationException - if there was not sufficient information to create a valid InfoQuery packet