This class represents an item that has been, or will be published to a pubsub node. An
Item has several properties that are dependent on the configuration of the node to which it has been or will be published.
An Item received from a node (via {@link LeafNode#getItems()} or {@link LeafNode#addItemEventListener(org.jivesoftware.smackx.pubsub.listener.ItemEventListener)}
Will always have an id (either user or server generated) unless node configuration has both {@link ConfigureForm#isPersistItems()} and {@link ConfigureForm#isDeliverPayloads()}set to false. Will have a payload if the node configuration has {@link ConfigureForm#isDeliverPayloads()} set to true, otherwise it will be null. An Item created to send to a node (via {@link LeafNode#send()} or {@link LeafNode#publish()}
The id is optional, since the server will generate one if necessary, but should be used if it is meaningful in the context of the node. This value must be unique within the node that it is sent to, since resending an item with the same id will overwrite the one that already exists if the items are persisted. Will require payload if the node configuration has {@link ConfigureForm#isDeliverPayloads()} setto true. To customise the payload object being returned from the {@link #getPayload()} method, you canadd a custom parser as explained in {@link ItemProvider}.
@author Robin Collier