Examples of WGContentKey


Examples of de.innovationgate.webgate.api.WGContentKey

            }
           
            // Choose content versions to return
            List<WGContentKey> contentsToReturn = new ArrayList<WGContentKey>();
            for (Map<String,WGContentKey> pageMap : pages.values()) {
                WGContentKey chosenContent = null;
                if (pageMap.size() == 1) {
                    chosenContent = pageMap.values().iterator().next();
                }
                else {
                    for (WGLanguage lang : queryLanguages) {
                        WGContentKey conKey = pageMap.get(lang.getName());
                        if (conKey != null) {
                            chosenContent = conKey;
                            break;
                        }
                    }
View Full Code Here

Examples of de.innovationgate.webgate.api.WGContentKey

    boolean isBI = (context.getDesignContext().getTag() != null ? context.getDesignContext().getTag().isBrowserInterface() : false);

    // Retrieve context by content key or unid
    if (contextFunction.equals("docid") || contextFunction.equals("content")) {
        WGContent content = null;
        WGContentKey tmpKey;
        try {
            tmpKey = WGContentKey.parse(contextExpression, context.getdocument().getDatabase());
        }
        catch (WGAPIException e) {
            context.setLastError("Error parsing contextExpression. Exception: " + e.getClass().getName() + " message: " + e.getMessage());
View Full Code Here

Examples of de.innovationgate.webgate.api.WGContentKey



    protected WGRelationData createWGRelationData(ContentRelation rel) {
        Content content = rel.getParentcontent();
        WGContentKey cKey = new WGContentKey(content.getStructentry().getKey(), content.getLanguage().getName(), content.getVersion().intValue());
        WGRelationData relData = new WGRelationData(cKey, rel.getName(), rel.getTargetstructentry(), rel.getTargetlanguage(), rel.getType(), rel.getGroup());
        return relData;
    }
View Full Code Here

Examples of de.innovationgate.webgate.api.WGContentKey

        WGLanguage langObj;
        // Block with various attempts to search content by this key
        WGContent content = null;

        // Try to retrieve content via content key - Fastest way
        WGContentKey key = id.asContentKey();
        if (key != null) {
            content = database.getContentByKey(key);
            if (content != null) {
                return content;
            }
View Full Code Here

Examples of de.innovationgate.webgate.api.WGContentKey

            WGContentIterator docsIt = (WGContentIterator)db.getAllContent(true);
            if (docsIt != null) {
                Iterator contentKeys = docsIt.getContentKeys().iterator();
                while (contentKeys.hasNext()) {
                    Thread.yield();
                    WGContentKey key = (WGContentKey) contentKeys.next();                   
                    addAdditionRequest(new IndexingRequest(dbkey, WGDocument.TYPENAME_CONTENT + "/" + key.toString()));
                }               
            }
            else {
                _core.getLog().error("Fetching all contenkeys from db '" + dbkey + "' returned 'null'. Database will not be indexed.");
            }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.