Adds the given extension to this Bayeux object.
@param extension the extension to add @see #removeExtension(Extension) The parameter names must NOT contain the "openid.
For example: the following code will create a filter that filters out all files except those that end in ".jpg" and ".tif":
DefaultFileFilter filter = new DefaultFileFilter(); filter.addExtension("jpg"); filter.addExtension("tif");Note that "." or "*." before the extension is not needed and will be removed.
It is important that this is the first and last time the element contained in PacketExtension is added to another Packet. Otherwise, a runtime error will be thrown when trying to add the PacketExtension's element to the Packet's element. Future modifications to the PacketExtension will be reflected in this Packet.
Note: packet extensions on IQ packets are only for use in specialized situations. In most cases, you should only need to set the child element of the IQ. @param extension the PacketExtension whose element will be added to this Packet's element.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|