Package org.apache.jackrabbit.core.version

Examples of org.apache.jackrabbit.core.version.VersionHistoryInfo


             * had been exported, removed and re-imported with either
             * IMPORT_UUID_COLLISION_REMOVE_EXISTING or
             * IMPORT_UUID_COLLISION_REPLACE_EXISTING;
             * otherwise create a new version history
             */
            VersionHistoryInfo history =
                versionManager.getVersionHistory(session, node);
            InternalValue historyId = InternalValue.create(
                    history.getVersionHistoryId().getUUID());
            InternalValue versionId = InternalValue.create(
                    history.getRootVersionId().getUUID());

            // jcr:isCheckedOut
            conditionalAddProperty(
                    node, NameConstants.JCR_ISCHECKEDOUT,
                    PropertyType.BOOLEAN, false, InternalValue.create(true));
View Full Code Here


                         * node had been exported, removed and re-imported with
                         * either IMPORT_UUID_COLLISION_REMOVE_EXISTING or
                         * IMPORT_UUID_COLLISION_REPLACE_EXISTING;
                         * otherwise create a new version history
                         */
                        VersionHistoryInfo history =
                            vMgr.getVersionHistory(session, nodeState);
                        InternalValue historyId = InternalValue.create(
                                history.getVersionHistoryId().getUUID());
                        InternalValue versionId = InternalValue.create(
                                history.getRootVersionId().getUUID());
                        node.internalSetProperty(
                                NameConstants.JCR_VERSIONHISTORY, historyId);
                        node.internalSetProperty(
                                NameConstants.JCR_BASEVERSION, versionId);
                        node.internalSetProperty(
View Full Code Here

                     */
                    VersionManager manager = session.getVersionManager();
                    if (fullVersionable) {
                        if (propName.equals(NameConstants.JCR_VERSIONHISTORY)) {
                            // jcr:versionHistory
                            VersionHistoryInfo history =
                                manager.getVersionHistory(session, newState);
                            InternalValue value = InternalValue.create(
                                    history.getVersionHistoryId().getUUID());
                            newChildState.setValues(new InternalValue[] { value });
                        } else if (propName.equals(NameConstants.JCR_BASEVERSION)
                                || propName.equals(NameConstants.JCR_PREDECESSORS)) {
                            // jcr:baseVersion or jcr:predecessors
                            VersionHistoryInfo history =
                                manager.getVersionHistory(session, newState);
                            InternalValue value = InternalValue.create(
                                    history.getRootVersionId().getUUID());
                            newChildState.setValues(new InternalValue[] { value });
                        } else if (propName.equals(NameConstants.JCR_ISCHECKEDOUT)) {
                            // jcr:isCheckedOut
                            newChildState.setValues(new InternalValue[]{InternalValue.create(true)});
                        }
View Full Code Here

TOP

Related Classes of org.apache.jackrabbit.core.version.VersionHistoryInfo

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.