org.odftoolkit.odfdom.pkg.manifest
Class OdfFileEntry
java.lang.Object
org.odftoolkit.odfdom.pkg.manifest.OdfFileEntry
public class OdfFileEntry
- extends java.lang.Object
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
OdfFileEntry
public OdfFileEntry()
OdfFileEntry
public OdfFileEntry(java.lang.String path)
- Parameters:
path - the path of the
Use null for no mediaType
OdfFileEntry
public OdfFileEntry(java.lang.String path,
java.lang.String mediaType)
- Parameters:
path - the path of the mediaType - of the file.
Use null for no mediaType
OdfFileEntry
public OdfFileEntry(java.lang.String path,
java.lang.String mediaType,
int size)
setPath
public void setPath(java.lang.String path)
getPath
public java.lang.String getPath()
setMediaTypeString
public void setMediaTypeString(java.lang.String mediaType)
- Parameters:
mediaType - of the file.
Use null or an empty string to unset the mediaType to an empty string.
getMediaTypeString
public java.lang.String getMediaTypeString()
- Returns:
- the mediatype of the mandatory <manifest:file-entry> attribute.
If no mediatype exists an empty string is returned
getMediaTypeString
public static java.lang.String getMediaTypeString(java.lang.String fileRef)
- Get the media type from the given file reference
- Parameters:
fileRef - the reference to the file the media type is questioned
- Returns:
- the mediaType string of the given file reference
setSize
public void setSize(int size)
getSize
public int getSize()
- get the size or -1 if not set
setEncryptionData
public void setEncryptionData(EncryptionData encryptionData)
getEncryptionData
public EncryptionData getEncryptionData()
- Returns:
- null if no encryption data had been set
Copyright © 2008-2012 The Apache Software Foundation. All Rights Reserved.