01: /*
02: * JOnAS: Java(TM) Open Application Server
03: * Copyright (C) 2005 Bull S.A.
04: * Contact: jonas-team@objectweb.org
05: *
06: * This library is free software; you can redistribute it and/or
07: * modify it under the terms of the GNU Lesser General Public
08: * License as published by the Free Software Foundation; either
09: * version 2.1 of the License, or any later version.
10: *
11: * This library is distributed in the hope that it will be useful,
12: * but WITHOUT ANY WARRANTY; without even the implied warranty of
13: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14: * Lesser General Public License for more details.
15: *
16: * You should have received a copy of the GNU Lesser General Public
17: * License along with this library; if not, write to the Free Software
18: * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
19: * USA
20: *
21: * --------------------------------------------------------------------------
22: * $Id$
23: * --------------------------------------------------------------------------
24: */
25: package mfb.converters;
26:
27: import javax.emb.MediaConverter;
28: import javax.emb.MediaException;
29:
30: import org.objectweb.jonas.emb.mfb.converter.image.ImageConverter;
31: import org.objectweb.jonas.emb.mfb.converter.image.ImageFormatConverterSpec;
32: import org.objectweb.jonas.emb.mfb.formats.image.JpegFormat;
33:
34: /**
35: * Converter avaiable to pass the TCK : convert a BMP to JPEG
36: * <p>
37: * TODO : check the source format to be compliant with TCK (but not spec)
38: *
39: * @author Brice Ruzand
40: */
41: public class BmpToJpegConverterSpec extends ImageFormatConverterSpec {
42:
43: /**
44: * serialVersionUID
45: */
46: private static final long serialVersionUID = -3894499792502442548L;
47:
48: /**
49: * Default constructor
50: */
51: public BmpToJpegConverterSpec() {
52: super (new JpegFormat());
53: }
54:
55: /**
56: * @see org.objectweb.jonas.emb.mfb.converter.image.ImageAbstractConverterSpec#getConverter()
57: * @inheritDoc
58: */
59: public MediaConverter getConverter() throws MediaException {
60: return new ImageConverter(this , new String[] { "bmp" });
61: }
62:
63: }
|