org.mmbase.util.magicfile
Class XmlDetector
java.lang.Object
org.mmbase.util.magicfile.AbstractDetector
org.mmbase.util.magicfile.XmlDetector
- All Implemented Interfaces:
- Detector
public class XmlDetector
- extends AbstractDetector
A detector which can match on XML namespaces, publicId.
- Since:
- MMBase-1.9.3
- Version:
- $Id: XmlDetector.java 41760 2010-04-03 15:18:20Z michiel $
- Author:
- Michiel Meeuwissen
| Methods inherited from class org.mmbase.util.magicfile.AbstractDetector |
addChild, getDesignation, getExtension, getExtensions, getMimeType, setDesignation, setExtension, setMimeType, setValid, toString, valid |
namespace
protected String namespace
publicId
protected Pattern publicId
XmlDetector
public XmlDetector()
setXmlns
public void setXmlns(String xmlns)
setPublicId
public void setPublicId(String dt)
test
public boolean test(byte[] lithmus)
- Returns:
- Whether detector matches the prefix/lithmus of the file
configure
public void configure(Element el)
- Specified by:
configure in interface Detector- Overrides:
configure in class AbstractDetector
MMBase 2.0-SNAPSHOT - null