Integer formatID = new Integer(myBitstream.getFormat().getID());  if (filterNames.containsKey(formatID))
MediaFilter myFilter = (MediaFilter)PluginManager.getNamedPlugin( MediaFilter.class, myBitstream.getFormat().getShortDescription()); if (myFilter != null)
    public static void filterBitstream(Context c, Item myItem,            Bitstream myBitstream) throws Exception    {        // do we have a filter for that format?        Integer formatID = new Integer(myBitstream.getFormat().getID());        if (filterNames.containsKey(formatID))        {            // now, have we instantiated the class already?            if (!filterCache.containsKey(formatID))            {                // given a class name, load the class                Class f = Class.forName((String) filterNames.get(formatID));                MediaFilter myFilter = (MediaFilter) f.newInstance();                filterCache.put(formatID, myFilter);            }            // now get the filter and use it            MediaFilter myFilter = (MediaFilter) filterCache.get(formatID);            try            {                // only update item if bitstream not skipped                if (myFilter.processBitstream(c, myItem, myBitstream))                {                    myItem.update(); // Make sure new bitstream has a sequence                                     // number                }            }            catch (Exception e)            {                System.out.println("ERROR filtering, skipping bitstream #"                        + myBitstream.getID() + " " + e);                e.printStackTrace();            }        }    }