net.jqhome.jwps.ea
Class BadEA
java.lang.Object
|
+--net.jqhome.jwps.ea.AbstractEA
|
+--net.jqhome.jwps.ea.ByteArrayEA
|
+--net.jqhome.jwps.ea.BadEA
- public class BadEA
- extends ByteArrayEA
A Bad EA is one that is not in standard format. Since OS/2 does absolutely no checking
before writing EAs to the disk, it is possible for an application to write some garbage
(normally they just leave off the first 4 control bytes). This EA is returned by the
factory and is made to preserve all bytes, so unless you change this somehow, saving it
write it back to the disk exactly as it was originally.
Note when you are saving EAs, these are not normally saved. You must pass a flag
to the system to explicitly tell it to overwrite BadEAs.
| Fields inherited from class net.jqhome.jwps.ea.AbstractEA |
EA_NAME_ASSOCIATION_TABLE, EA_NAME_CODEPAGE, EA_NAME_COMMENTS, EA_NAME_HISTORY, EA_NAME_ICON, EA_NAME_ICON1, EA_NAME_KEYPHRASES, EA_NAME_LONGNAME, EA_NAME_SUBJECT, EA_NAME_TYPE, EA_NAME_VERSION, XML_EA_B64_ENCODING, XML_EA_CODEPAGE_TAGNAME, XML_EA_ENCODING_TYPE_TAGNAME, XML_EA_FILE_TAGNAME, XML_EA_IS_CRITICAL_TAGNAME, XML_EA_LIST_TAGNAME, XML_EA_NAME_TAGNAME, XML_EA_TAGNAME, XML_EA_TEXT_ENCODING, XML_EA_TYPE_TAGNAME, XML_EA_VALUE_TAGNAME |
|
Constructor Summary |
BadEA()
|
BadEA(RawEA rawEA)
|
BadEA(java.lang.String name)
|
BadEA(java.lang.String name,
byte[] value)
|
BadEA(java.lang.String name,
byte[] value,
int type,
boolean isCritical)
|
BadEA(java.lang.String name,
byte[] value,
int start,
int length)
|
BadEA(java.lang.String name,
int type)
Sets a non-critical EA without value |
BadEA(java.lang.String name,
int type,
boolean isCritical)
|
|
Method Summary |
void |
fromRawEA(RawEA rawEA)
The byte stream that the C API returns is only slightly parsed before being put into a raw EA object. |
int |
getRawEASize()
This returns the size of the raw EA item. |
RawEA |
toRawEA()
This method will take the EA and turn it into a Raw EA, that is, one that is almost directly storable
in OS2. |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
BadEA
public BadEA(java.lang.String name,
int type,
boolean isCritical)
throws JWPException
BadEA
public BadEA()
throws JWPException
BadEA
public BadEA(java.lang.String name,
int type)
throws JWPException
- Sets a non-critical EA without value
BadEA
public BadEA(java.lang.String name)
throws JWPException
BadEA
public BadEA(java.lang.String name,
byte[] value,
int type,
boolean isCritical)
throws JWPException
BadEA
public BadEA(RawEA rawEA)
throws JWPException
BadEA
public BadEA(java.lang.String name,
byte[] value)
throws JWPException
BadEA
public BadEA(java.lang.String name,
byte[] value,
int start,
int length)
throws JWPException
fromRawEA
public void fromRawEA(RawEA rawEA)
throws JWPException
- Description copied from class:
AbstractEA
- The byte stream that the C API returns is only slightly parsed before being put into a raw EA object.
Java EA objects are created from these.
- Overrides:
fromRawEA in class ByteArrayEA
JWPException
getRawEASize
public int getRawEASize()
- Description copied from class:
AbstractEA
- This returns the size of the raw EA item.
- Overrides:
getRawEASize in class ByteArrayEA
toRawEA
public RawEA toRawEA()
throws JWPException
- Description copied from class:
AbstractEA
- This method will take the EA and turn it into a Raw EA, that is, one that is almost directly storable
in OS2. Since there are really only 4 formats that are used, for ascii, binary, mvmt and mvst as long as you
extend one of these you should not have to concern yourself with the vagaries of writing one of these.
- Overrides:
toRawEA in class ByteArrayEA
JWPException