public class EncryptionPacketExtension extends AbstractPacketExtension
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
ELEMENT_NAME
The name of the "encryption" element.
|
static java.lang.String |
NAMESPACE
The namespace of the "encryption" element.
|
static java.lang.String |
REQUIRED_ATTR_NAME
The name of the required attribute.
|
attributes
Constructor and Description |
---|
EncryptionPacketExtension()
Creates a new instance of this EncryptionPacketExtension.
|
Modifier and Type | Method and Description |
---|---|
void |
addChildExtension(org.jivesoftware.smack.packet.PacketExtension childExtension)
Adds the specified childExtension to the list of extensions
registered with this packet.
|
void |
addCrypto(CryptoPacketExtension crypto)
Adds a new crypto element to this encryption element.
|
java.util.List<? extends org.jivesoftware.smack.packet.PacketExtension> |
getChildExtensions()
Returns a list containing all crypto sub-elements.
|
java.util.List<CryptoPacketExtension> |
getCryptoList()
Returns a reference to the list of crypto elements that
we have registered with this encryption element so far.
|
boolean |
isRequired()
Returns true if encryption is required for this session and
false otherwise.
|
void |
setRequired(boolean required)
Specifies whether encryption is required for this session or not.
|
addPacket, clone, getAttribute, getAttributeAsInt, getAttributeAsInt, getAttributeAsString, getAttributeAsURI, getAttributeNames, getChildExtensionsOfType, getElementName, getFirstChildOfType, getNamespace, getPackets, getText, removeAttribute, setAttribute, setNamespace, setText, toXML
public static final java.lang.String NAMESPACE
public static final java.lang.String ELEMENT_NAME
public static final java.lang.String REQUIRED_ATTR_NAME
public EncryptionPacketExtension()
public void addCrypto(CryptoPacketExtension crypto)
crypto
- the new crypto element to add.public java.util.List<CryptoPacketExtension> getCryptoList()
public void setRequired(boolean required)
required
- true if encryption is required for this session
and false otherwise.public boolean isRequired()
public java.util.List<? extends org.jivesoftware.smack.packet.PacketExtension> getChildExtensions()
getChildExtensions
in class AbstractPacketExtension
List
containing all our crypto sub-elements.public void addChildExtension(org.jivesoftware.smack.packet.PacketExtension childExtension)
addChildExtension
in class AbstractPacketExtension
childExtension
- the extension we'd like to add here.
Jitsi, the OpenSource Java VoIP and Instant Messaging client.
Distributable under Apache license.