Package java.beans

Examples of java.beans.XMLDecoder$Elem


                // Load layout
                Element layout = getElement(element, "layout");
                if (layout != null) {
                    String text = layout.getTextContent();
                    XMLDecoder decoder = new XMLDecoder(new ByteArrayInputStream(text.getBytes()));
                    ((MutableContext) context).put(ContextKey.MultiSplitContentManagerUILayout, decoder.readObject());
                } else
                    ((MutableContext) context).put(ContextKey.MultiSplitContentManagerUILayout, null);
            }

            return false;
View Full Code Here


                // load the XML data for the participant
                String filePath = PathUtils.buildPath(participantStoragePath, participantId);
                logger.trace("filePath: " + filePath);
                logger.info("Loading local participant from file: " + filePath);

                XMLDecoder dec = new XMLDecoder(new BufferedInputStream(new FileInputStream(filePath)));
                Participant p = (Participant)dec.readObject();
                logger.trace("participant: " + p);

                dec.close();

                participants.add(p);
                count++;
            }
            catch(Exception e) {
View Full Code Here

            // load the XML data for the campaign
            String filePath = PathUtils.buildPath(campaignStoragePath, id);
            logger.trace("filePath: " + filePath);
            logger.info("Loading campaign metadata from file: " + filePath);

            XMLDecoder dec = new XMLDecoder(new BufferedInputStream(new FileInputStream(filePath)));
            CampaignMetadata cm = (CampaignMetadata)dec.readObject();
            logger.trace("campaign metadata: " + cm);

            dec.close();

            return cm;
        }
        catch(Exception e) {
            logger.error("Exception caught while trying to load campaign metadata for campaign: " + id + ": "
View Full Code Here

        e.close();
        return os.toByteArray();
    }

    protected MultiSplitLayout.Split decode(byte[] bytes) {
        XMLDecoder d = new XMLDecoder(new ByteArrayInputStream(bytes));
        return (MultiSplitLayout.Split) (d.readObject());
    }
View Full Code Here

            ToolWindowAnchor anchor = ToolWindowAnchor.valueOf(element.getAttribute("anchor"));

            Element modelElement = getElement(element, "model");
            if (modelElement != null) {
                String text = modelElement.getTextContent();
                XMLDecoder decoder = new XMLDecoder(new ByteArrayInputStream(text.getBytes()));
                MultiSplitLayout.Node model = (MultiSplitLayout.Node) decoder.readObject();

                toolWindowManager.getBar(anchor).getToolsContainer().setModel(model);
            }

            return false;
View Full Code Here

        try {
            String path = PathUtils.buildPath(storagePath, "campaigns", guid);
            logger.trace("path: " + path);

            XMLDecoder dec = new XMLDecoder(new BufferedInputStream(new FileInputStream(path)));
            CampaignSO vo = (CampaignSO)dec.readObject();
            logger.trace("campaignVO: " + vo);

            dec.close();

            doSetStatus(CampaignStorageConstants.STORAGE_STATUS_ONLINE);

            return vo;
        }
View Full Code Here

        try {
            String path = PathUtils.buildPath(storagePath, "settings", id);
            logger.trace("path: " + path);

            XMLDecoder dec = new XMLDecoder(new BufferedInputStream(new FileInputStream(path)));
            SettingSO vo = (SettingSO)dec.readObject();
            logger.trace("settingVO: " + vo);

            dec.close();

            doSetStatus(CampaignStorageConstants.STORAGE_STATUS_ONLINE);

            return vo;
        }
View Full Code Here

        try {
            String path = PathUtils.buildPath(storagePath, "versions", id);
            logger.trace("path: " + path);

            XMLDecoder dec = new XMLDecoder(new BufferedInputStream(new FileInputStream(path)));
            VersionSO vo = (VersionSO)dec.readObject();
            logger.trace("versionVO: " + vo);

            dec.close();

            doSetStatus(CampaignStorageConstants.STORAGE_STATUS_ONLINE);

            return vo;
        }
View Full Code Here

        try {
            String path = PathUtils.buildPath(storagePath, "campaign-events", id.substring(0, 1), id.substring(0, 2),
                    id);
            logger.trace("path: " + path);

            XMLDecoder dec = new XMLDecoder(new BufferedInputStream(new FileInputStream(path)));
            CampaignEventSO vo = (CampaignEventSO)dec.readObject();
            logger.trace("campaignEventVO: " + vo);

            dec.close();

            doSetStatus(CampaignStorageConstants.STORAGE_STATUS_ONLINE);

            return vo;
        }
View Full Code Here

        try {
            String path = PathUtils.buildPath(storagePath, "libraries", id.substring(0, 1), id.substring(0, 2), id);
            logger.trace("path: " + path);

            XMLDecoder dec = new XMLDecoder(new BufferedInputStream(new FileInputStream(path)));
            LibrarySO vo = (LibrarySO)dec.readObject();
            logger.trace("libraryVO: " + vo);

            dec.close();

            doSetStatus(CampaignStorageConstants.STORAGE_STATUS_ONLINE);

            return vo;
        }
View Full Code Here

TOP

Related Classes of java.beans.XMLDecoder$Elem

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.