org.dspace.app.mediafilter
Class JPEGFilter
java.lang.Object
org.dspace.app.mediafilter.MediaFilter
org.dspace.app.mediafilter.JPEGFilter
- All Implemented Interfaces:
- FormatFilter, SelfRegisterInputFormats
public class JPEGFilter
- extends MediaFilter
- implements SelfRegisterInputFormats
Filter image bitstreams, scaling the image to be within the bounds of
thumbnail.maxwidth, thumbnail.maxheight, the size we want our thumbnail to be
no bigger than. Creates only JPEGs.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
JPEGFilter
public JPEGFilter()
getFilteredName
public String getFilteredName(String oldFilename)
- Description copied from interface:
FormatFilter
- Get a filename for a newly created filtered bitstream
- Specified by:
getFilteredName in interface FormatFilter
- Parameters:
oldFilename - name of source bitstream
- Returns:
- filename generated by the filter - for example, document.pdf
becomes document.pdf.txt
getBundleName
public String getBundleName()
- Specified by:
getBundleName in interface FormatFilter
- Returns:
- String bundle name
getFormatString
public String getFormatString()
- Specified by:
getFormatString in interface FormatFilter
- Returns:
- String bitstreamformat
getDescription
public String getDescription()
- Specified by:
getDescription in interface FormatFilter
- Returns:
- String description
getDestinationStream
public InputStream getDestinationStream(InputStream source)
throws Exception
- Specified by:
getDestinationStream in interface FormatFilter
- Parameters:
source - source input stream
- Returns:
- InputStream the resulting input stream
- Throws:
Exception
getInputMIMETypes
public String[] getInputMIMETypes()
- Specified by:
getInputMIMETypes in interface SelfRegisterInputFormats
getInputDescriptions
public String[] getInputDescriptions()
- Specified by:
getInputDescriptions in interface SelfRegisterInputFormats
getInputExtensions
public String[] getInputExtensions()
- Specified by:
getInputExtensions in interface SelfRegisterInputFormats
Copyright © 2012 DuraSpace. All Rights Reserved.