public Element get(String username, Element data)
    {
        if (enabled)
        {
            final PEPServiceManager serviceMgr = XMPPServer.getInstance().getIQPEPHandler().getServiceManager();
            final PEPService pepService = serviceMgr.getPEPService( XMPPServer.getInstance().createJID( username, null ) );
            if ( pepService != null )
            {
                final Node node = pepService.getNode( data.getNamespaceURI() );
                if ( node != null )
                {
                    final PublishedItem item = node.getPublishedItem( "current" );
                    if ( item != null )
                    {
                        data.clearContent();
                        data = item.getPayload();
                    }
                }
            }
        }
        return data;
    }
Returns the data stored under a key corresponding to the name and namespace
of the given element. The Element must be in the form:<p>

<code>&lt;name xmlns='namespace'/&gt;</code><p>

If no data is currently stored under the given key, an empty element will be
returned.

@param data an XML document who's element name and namespace is used to
     match previously stored private data.
@param username the username of the account where private data is being stored.
@return the data stored under the given key or the data element.
xmppserver/src/main/java/org/jivesoftware/openfire/PrivateStorage.java