Searched refs:packet (Results 76 - 100 of 1029) sorted by last modified time

1234567891011>>

/external/smack/src/org/jivesoftware/smack/filter/
H A DFromContainsFilter.java23 import org.jivesoftware.smack.packet.Packet;
37 * @param from the from field value the packet must contain.
46 public boolean accept(Packet packet) { argument
47 if (packet.getFrom() == null) {
51 return packet.getFrom().toLowerCase().indexOf(from) != -1;
H A DFromMatchesFilter.java23 import org.jivesoftware.smack.packet.Packet;
30 * if the sender of the packet matches the specified resource.
45 * specified address is a full JID then the filter will only match if the sender of the packet
48 * @param address the from field value the packet must match. Could be a full or bare JID.
58 public boolean accept(Packet packet) { argument
59 if (packet.getFrom() == null) {
63 // Check if the bare JID of the sender of the packet matches the specified JID
64 return packet.getFrom().toLowerCase().startsWith(address);
67 // Check if the full JID of the sender of the packet matches the specified JID
68 return address.equals(packet
[all...]
H A DIQTypeFilter.java22 import org.jivesoftware.smack.packet.IQ;
23 import org.jivesoftware.smack.packet.Packet;
26 * A filter for IQ packet types. Returns true only if the packet is an IQ packet
43 * @see org.jivesoftware.smack.filter.PacketFilter#accept(org.jivesoftware.smack.packet.Packet)
45 public boolean accept(Packet packet) { argument
46 return (packet instanceof IQ && ((IQ) packet).getType().equals(type));
H A DMessageTypeFilter.java23 import org.jivesoftware.smack.packet.Message;
24 import org.jivesoftware.smack.packet.Packet;
29 * @see org.jivesoftware.smack.packet.Message.Type
45 public boolean accept(Packet packet) { argument
46 if (!(packet instanceof Message)) {
50 return ((Message) packet).getType().equals(this.type);
H A DNotFilter.java23 import org.jivesoftware.smack.packet.Packet;
26 * Implements the logical NOT operation on a packet filter. In other words, packets
47 public boolean accept(Packet packet) { argument
48 return !filter.accept(packet);
H A DOrFilter.java23 import org.jivesoftware.smack.packet.Packet;
26 * Implements the logical OR operation over two or more packet filters. In
55 * @param filter1 the first packet filter.
56 * @param filter2 the second packet filter.
69 * Adds a filter to the filter list for the OR operation. A packet
91 public boolean accept(Packet packet) { argument
93 if (filters[i].accept(packet)) {
H A DPacketExtensionFilter.java23 import org.jivesoftware.smack.packet.Packet;
26 * Filters for packets with a particular type of packet extension.
36 * Creates a new packet extension filter. Packets will pass the filter if
37 * they have a packet extension that matches the specified element name
40 * @param elementName the XML element name of the packet extension.
41 * @param namespace the XML namespace of the packet extension.
49 * Creates a new packet extension filter. Packets will pass the filter if they have a packet
52 * @param namespace the XML namespace of the packet extension.
58 public boolean accept(Packet packet) { argument
[all...]
H A DPacketFilter.java23 import org.jivesoftware.smack.packet.Packet;
27 * used when constructing packet listeners or collectors -- the filter defines
29 * packet processing.<p>
32 * for more complex packet filtering by using the
39 * // Use an anonymous inner class to define a packet filter that returns
40 * // all packets that have a packet ID of "RS145".
42 * public boolean accept(Packet packet) {
43 * return "RS145".equals(packet.getPacketID());
46 * // Create a new packet collector using the filter we created.
57 * Tests whether or not the specified packet shoul
62 accept(Packet packet) argument
[all...]
H A DPacketIDFilter.java23 import org.jivesoftware.smack.packet.Packet;
26 * Filters for packets with a particular packet ID.
35 * Creates a new packet ID filter using the specified packet ID.
37 * @param packetID the packet ID to filter for.
46 public boolean accept(Packet packet) { argument
47 return packetID.equals(packet.getPacketID());
H A DPacketTypeFilter.java23 import org.jivesoftware.smack.packet.Packet;
41 * Creates a new packet type filter that will filter for packets that are the
47 // Ensure the packet type is a sub-class of Packet.
54 public boolean accept(Packet packet) { argument
55 return packetType.isInstance(packet);
H A DThreadFilter.java23 import org.jivesoftware.smack.packet.Packet;
24 import org.jivesoftware.smack.packet.Message;
47 public boolean accept(Packet packet) { argument
48 return packet instanceof Message && thread.equals(((Message) packet).getThread());
H A DToContainsFilter.java23 import org.jivesoftware.smack.packet.Packet;
38 * @param to the to field value the packet must contain.
47 public boolean accept(Packet packet) { argument
48 if (packet.getTo() == null) {
52 return packet.getTo().toLowerCase().indexOf(to) != -1;
/external/smack/src/org/jivesoftware/smack/packet/
H A DAuthentication.java21 package org.jivesoftware.smack.packet;
26 * Authentication packet, which can be used to login to a XMPP server as well
37 * Create a new authentication packet. By default, the packet will be in
40 * modes back from the server, change the type of the IQ packet to "get":
H A DBind.java21 package org.jivesoftware.smack.packet;
24 * IQ packet used by Smack to bind a resource and to obtain the jid assigned by the server.
25 * There are two ways to bind a resource. One is simply sending an empty Bind packet where the
H A DDefaultPacketExtension.java21 package org.jivesoftware.smack.packet;
28 * instances of this class will be returned when getting packet extensions.<p>
54 * Creates a new generic packet extension.
65 * Returns the XML element name of the extension sub-packet root element.
67 * @return the XML element name of the packet extension.
74 * Returns the XML namespace of the extension sub-packet root element.
76 * @return the XML namespace of the packet extension.
97 * values of the packet extension.
109 * Returns a packet extension value given a name.
122 * Sets a packet extensio
[all...]
H A DIQ.java21 package org.jivesoftware.smack.packet;
26 * The base IQ (Info/Query) packet. IQ packets are used to get and set information
28 * accounts. Each IQ packet has a specific type that indicates what type of action
33 * type of IQ packet it is. Some example IQ subpacket snippets:<ul>
55 * Returns the type of the IQ packet.
57 * @return the type of the IQ packet.
64 * Sets the type of the IQ packet.
66 * @param type the type of the IQ packet.
100 // Add the error sub-packet, if there is one.
110 * Returns the sub-element XML section of the IQ packet, o
[all...]
H A DMessage.java21 package org.jivesoftware.smack.packet;
88 * org.jivesoftware.smack.packet.Message.Type#normal}.
175 * @return the new {@link org.jivesoftware.smack.packet.Message.Subject}
294 * @return the new {@link org.jivesoftware.smack.packet.Message.Body}
467 // Add packet extensions, if any are defined.
H A DPacket.java21 package org.jivesoftware.smack.packet;
41 * Base class for XMPP packets. Every packet has a unique ID (which is automatically
60 * Constant used as packetID to indicate that a packet has no id. To indicate that a packet
61 * has no id set this constant as the packet's id. When the packet is asked for its id the
133 * Returns the unique ID of the packet. The returned value could be <tt>null</tt> when
134 * ID_NOT_AVAILABLE was set as the packet's id.
136 * @return the packet's unique ID or <tt>null</tt> if the packet'
[all...]
H A DPacketExtension.java21 package org.jivesoftware.smack.packet;
24 * Interface to represent packet extensions. A packet extension is an XML subdocument
27 * packet extensions include message events, message properties, and extra presence data.
28 * IQ packets cannot contain packet extensions.
53 * @return the packet extension as XML.
H A DPresence.java21 package org.jivesoftware.smack.packet;
26 * Represents XMPP presence packets. Every presence packet has a type, which is one of
38 * <li>{@link Presence.Type#error error} -- the presence packet contains an error message.
93 * false if the user is unavailable (offline), or if this is a presence packet
121 * Returns the type of this presence packet.
123 * @return the type of the presence packet.
130 * Sets the type of the presence packet.
132 * @param type the type of the presence packet.
260 // Add the error sub-packet, if there is one.
323 * The presence packet contain
[all...]
H A DPrivacy.java20 package org.jivesoftware.smack.packet;
317 // Add packet extensions, if any are defined.
H A DPrivacyItem.java18 package org.jivesoftware.smack.packet;
21 * A privacy item acts a rule that when matched defines if a packet should be blocked or not.
H A DRegistration.java21 package org.jivesoftware.smack.packet;
150 // Add packet extensions, if any are defined.
H A DRosterPacket.java21 package org.jivesoftware.smack.packet;
42 * Adds a roster item to the packet.
61 * Returns the number of roster items in this roster packet.
72 * Returns an unmodifiable collection for the roster items in the packet.
74 * @return an unmodifiable collection for the roster items in the packet.
H A DSession.java21 package org.jivesoftware.smack.packet;
24 * IQ packet that will be sent to the server to establish a session.<p>

Completed in 2134 milliseconds

1234567891011>>