Class OdfFileEntry
- java.lang.Object
-
- org.odftoolkit.odfdom.pkg.manifest.OdfFileEntry
-
public class OdfFileEntry extends Object
-
-
Constructor Summary
Constructors Constructor Description OdfFileEntry(FileEntryElement fileEntryElement)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description OdfFileEntry
getCopy()
EncryptionDataElement
getEncryptionData()
String
getMediaTypeString()
static String
getMediaTypeString(String fileRef)
Get the media type from the given file referenceFileEntryElement
getOdfElement()
Gets the OdfElement of this OdfFileEntry.String
getPath()
Integer
getSize()
Get the size.void
setEncryptionData(EncryptionDataElement encryptionData)
void
setMediaTypeString(String mediaType)
void
setPath(String path)
void
setSize(Integer size)
-
-
-
Constructor Detail
-
OdfFileEntry
public OdfFileEntry(FileEntryElement fileEntryElement)
- Parameters:
fileEntryElement
- the OdfElement of the
-
-
Method Detail
-
getCopy
public OdfFileEntry getCopy()
-
setPath
public void setPath(String path)
-
getPath
public String getPath()
-
setMediaTypeString
public void setMediaTypeString(String mediaType)
- Parameters:
mediaType
- of the file. Usenull
or an empty string to unset the mediaType to an empty string.
-
getMediaTypeString
public String getMediaTypeString()
- Returns:
- the mediatype of the mandatory <manifest:file-entry> attribute. If no mediatype exists an empty string is returned
-
getMediaTypeString
public static String getMediaTypeString(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(Integer size)
-
getSize
public Integer getSize()
Get the size.
-
setEncryptionData
public void setEncryptionData(EncryptionDataElement encryptionData)
-
getEncryptionData
public EncryptionDataElement getEncryptionData()
- Returns:
- null if no encryption data had been set
-
getOdfElement
public FileEntryElement getOdfElement()
Gets the OdfElement of this OdfFileEntry.- Returns:
- the OdfElement of this OdfFileEntry.
-
-