Package com.sun.syndication.feed.module.mediarss

Examples of com.sun.syndication.feed.module.mediarss.MediaEntryModuleImpl


            int listSize = modules.size();
            Object currModule;

            for (int x = 0; x < listSize; x++) {
                currModule = modules.get(x);
                MediaEntryModuleImpl currMediaModule;

                if (currModule instanceof MediaEntryModuleImpl) {
                    //This is a Media module supported by us at the moment
                    currMediaModule = (MediaEntryModuleImpl) currModule;

                    //Since in our implementation we have a 1 to 1 mapping of module to content,
                    //we need to create a module each for every content element.
                    MediaContent[] content = currMediaModule.getMediaContents();

                    if (content.length > 0) {

                        for (int y = 0; y < content.length; y++) {
                            MediaModule mediaModule = new MediaModule();
View Full Code Here


                                           boolean inNewExpr) throws CarbonException {
        MediaModule newMediaModule = null;

        //The first argument is a string representing the URI of the media
        if (args[0] instanceof String) {
            MediaEntryModuleImpl newModule = new MediaEntryModuleImpl();
            MediaContent[] newContents = new MediaContent[1];
            MediaContent newMediaItem = null;
            try {
                newMediaItem = new MediaContent(new UrlReference((String) args[0]));
            } catch (URISyntaxException e) {
                throw new CarbonException(e.getMessage());
            }
            newContents[0] = newMediaItem;
            Metadata newMetaData = new Metadata();
            newMediaItem.setMetadata(newMetaData);
            newModule.setMediaContents(newContents);

            newMediaModule = new MediaModule();
            newMediaModule.module = newModule;
        } else {
            throw new CarbonException(
View Full Code Here

TOP

Related Classes of com.sun.syndication.feed.module.mediarss.MediaEntryModuleImpl

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.