|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sf.jmimemagic.MagicMatch
This class represents a single match test
Constructor Summary | |
MagicMatch()
constructor |
Method Summary | |
void |
addSubMatch(MagicMatch m)
add a submatch to this magic match |
protected java.lang.Object |
clone()
DOCUMENT ME! |
boolean |
descriptionMatches(java.lang.String desc)
determine if this match or any submatches has the description |
long |
getBitmask()
get the bitmask that will be applied for this magic match |
char |
getComparator()
get the comparator for this magic match |
java.lang.String |
getDescription()
get the description for this magic match |
java.lang.String |
getExtension()
get the extension for this magic match |
int |
getLength()
get the length we are restricting the comparison to for this magic match |
java.lang.String |
getMimeType()
get the magic match for this magic match |
int |
getOffset()
get the offset in the stream we are comparing to the test value for this magic match |
java.util.Map |
getProperties()
get the properties for this magic match |
java.util.Collection |
getSubMatches()
get all submatches for this magic match |
java.nio.ByteBuffer |
getTest()
get the test value for this magic match |
java.lang.String |
getType()
get the type of match for this magic match |
boolean |
mimeTypeMatches(java.lang.String desc)
determine if this match or any submatches has the description |
java.lang.String |
print()
print information about this match |
void |
setBitmask(java.lang.String value)
set the bitmask that will be applied for this magic match |
void |
setComparator(java.lang.String value)
set the comparator for this magic match |
void |
setDescription(java.lang.String value)
set the description for this magic match |
void |
setExtension(java.lang.String value)
set the extension for this magic match |
void |
setLength(int value)
set the length we are restricting the comparison to for this magic match |
void |
setMimeType(java.lang.String value)
set the mime type for this magic match |
void |
setOffset(int value)
set the offset in the stream we are comparing to the test value for this magic match |
void |
setProperties(java.util.Map properties)
set the properties for this magic match |
void |
setSubMatches(java.util.Collection a)
set all submatches |
void |
setTest(java.nio.ByteBuffer value)
set the test value for thie magic match |
void |
setType(java.lang.String value)
set the type of match to perform for this magic match |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public MagicMatch()
Method Detail |
public java.lang.String print()
public void setMimeType(java.lang.String value)
value
- DOCUMENT ME!public java.lang.String getMimeType()
public void setExtension(java.lang.String value)
value
- DOCUMENT ME!public java.lang.String getExtension()
public void setDescription(java.lang.String value)
value
- DOCUMENT ME!public java.lang.String getDescription()
public void setTest(java.nio.ByteBuffer value)
value
- DOCUMENT ME!public java.nio.ByteBuffer getTest()
public void setOffset(int value)
value
- DOCUMENT ME!public int getOffset()
public void setLength(int value)
value
- DOCUMENT ME!public int getLength()
public void setType(java.lang.String value)
value
- DOCUMENT ME!public java.lang.String getType()
public void setBitmask(java.lang.String value)
value
- DOCUMENT ME!public long getBitmask()
public void setComparator(java.lang.String value)
value
- DOCUMENT ME!public char getComparator()
public void setProperties(java.util.Map properties)
properties
- DOCUMENT ME!public java.util.Map getProperties()
public void addSubMatch(MagicMatch m)
m
- a magic matchpublic void setSubMatches(java.util.Collection a)
a
- a collection of submatchespublic java.util.Collection getSubMatches()
public boolean descriptionMatches(java.lang.String desc)
desc
- DOCUMENT ME!
public boolean mimeTypeMatches(java.lang.String desc)
desc
- DOCUMENT ME!
protected java.lang.Object clone() throws java.lang.CloneNotSupportedException
java.lang.CloneNotSupportedException
- DOCUMENT ME!
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |