
package com.beem.project.beem.smack.caps;

import org.xmlpull.v1.XmlPullParser;
import org.jivesoftware.smack.provider.PacketExtensionProvider;
import org.jivesoftware.smack.packet.PacketExtension;

public class CapsProvider implements PacketExtensionProvider {

    @Override
    public PacketExtension parseExtension(XmlPullParser parser) {
	String ver = parser.getAttributeValue("", "ver");
	String hash = parser.getAttributeValue("", "hash");
	String node = parser.getAttributeValue("", "node");
	String ext = parser.getAttributeValue("", "ext");
	CapsExtension e = new CapsExtension(hash, node, ver);
	e.setExt(ext);
	return e;
    }

}
