private int getOPV(Tree nodeTree, PropertyState property) throws RepositoryException { return getNodeTypeManager().getDefinition(nodeTree, property, false).getOnParentVersion(); }
private int getOPV(Tree nodeTree, PropertyState property) throws RepositoryException { return getNodeTypeManager().getDefinition(nodeTree, property, false).getOnParentVersion(); }
private int getOPV(Tree nodeTree, PropertyState property) throws RepositoryException { return getNodeTypeManager().getDefinition(nodeTree, property, false).getOnParentVersion(); }
private int getOPV(NodeBuilder node, PropertyState property) throws RepositoryException { if (property.getName().charAt(0) == ':') { // FIXME: handle child order properly return OnParentVersionAction.COPY; } else { return ntMgr.getDefinition(TreeFactory.createReadOnlyTree(node.getNodeState()), property, false).getOnParentVersion(); } }
protected void setUp() throws Exception { super.setUp(); childNodeTypeName = getProperty("nodetype"); // set the property p = versionableNode.setProperty(propertyName1, initialPropValue); // assert that property has the proper opv-behaviour PropertyDefinition pd = p.getDefinition(); if (pd.getOnParentVersion() != OPVAction) { fail("JCR Property at '"+p.getPath()+"' does not have the required OnParentVersion "+OnParentVersionAction.nameFromValue(OPVAction)+" definition."); } testRootNode.getSession().save(); }
private int getOPV(NodeBuilder node, PropertyState property) throws RepositoryException { if (property.getName().charAt(0) == ':') { // FIXME: handle child order properly return OnParentVersionAction.COPY; } else { return ntMgr.getDefinition(TreeFactory.createReadOnlyTree(node.getNodeState()), property, false).getOnParentVersion(); } }
private int getOPV(NodeBuilder node, PropertyState property) throws RepositoryException { if (property.getName().charAt(0) == ':') { // FIXME: handle child order properly return OnParentVersionAction.COPY; } else { return ntMgr.getDefinition(TreeFactory.createReadOnlyTree(node.getNodeState()), property, false).getOnParentVersion(); } }
private int getOPV(PropertyState property) throws CommitFailedException { try { return this.vMgr.getNodeTypeManager().getDefinition(TreeFactory.createReadOnlyTree(this.node.getNodeState()), property, false).getOnParentVersion(); } catch (Exception e) { throw new CommitFailedException(CommitFailedException.VERSION, VersionExceptionCode.UNEXPECTED_REPOSITORY_EXCEPTION.ordinal(), e.getMessage()); } } }
private int getOPV(PropertyState property) throws CommitFailedException { try { return this.vMgr.getNodeTypeManager().getDefinition(TreeFactory.createReadOnlyTree(this.node.getNodeState()), property, false).getOnParentVersion(); } catch (Exception e) { throw new CommitFailedException(CommitFailedException.VERSION, VersionExceptionCode.UNEXPECTED_REPOSITORY_EXCEPTION.ordinal(), e.getMessage()); } } }
private int getOPV(PropertyState property) throws CommitFailedException { try { return this.vMgr.getNodeTypeManager().getDefinition(TreeFactory.createReadOnlyTree(this.node.getNodeState()), property, false).getOnParentVersion(); } catch (Exception e) { throw new CommitFailedException(CommitFailedException.VERSION, VersionExceptionCode.UNEXPECTED_REPOSITORY_EXCEPTION.ordinal(), e.getMessage()); } } }
@Override public void checkPreconditions() throws RepositoryException { super.checkPreconditions(); if (!getParent().isCheckedOut() && getDefinition().getOnParentVersion() != OnParentVersionAction.IGNORE) { throw new VersionException( "Cannot set property. Node is checked in."); } }
@Override public void checkPreconditions() throws RepositoryException { super.checkPreconditions(); if (!getParent().isCheckedOut() && getDefinition().getOnParentVersion() != OnParentVersionAction.IGNORE) { throw new VersionException( "Cannot set property. Node is checked in."); } }
@Override public void checkPreconditions() throws RepositoryException { super.checkPreconditions(); if (!getParent().isCheckedOut() && getDefinition().getOnParentVersion() != OnParentVersionAction.IGNORE) { throw new VersionException( "Cannot set property. Node is checked in."); } }
@Override public void checkPreconditions() throws RepositoryException { super.checkPreconditions(); if (!getParent().isCheckedOut() && getDefinition().getOnParentVersion() != OnParentVersionAction.IGNORE) { throw new VersionException( "Cannot set property. Node is checked in."); } }
@Override public void checkPreconditions() throws RepositoryException { super.checkPreconditions(); if (!getParent().isCheckedOut() && getDefinition().getOnParentVersion() != OnParentVersionAction.IGNORE) { throw new VersionException( "Cannot set property. Node is checked in."); } }
@Override public void checkPreconditions() throws RepositoryException { super.checkPreconditions(); if (!getParent().isCheckedOut() && getDefinition().getOnParentVersion() != OnParentVersionAction.IGNORE) { throw new VersionException( "Cannot set property. Node is checked in."); } }
@Override public void checkPreconditions() throws RepositoryException { super.checkPreconditions(); if (!getParent().isCheckedOut() && getDefinition().getOnParentVersion() != OnParentVersionAction.IGNORE) { throw new VersionException( "Cannot set property. Node is checked in."); } }
@Override public void checkPreconditions() throws RepositoryException { super.checkPreconditions(); if (!getParent().isCheckedOut() && getDefinition().getOnParentVersion() != OnParentVersionAction.IGNORE) { throw new VersionException( "Cannot set property. Node is checked in."); } }
@Override public void checkPreconditions() throws RepositoryException { super.checkPreconditions(); if (!getParent().isCheckedOut() && getDefinition().getOnParentVersion() != OnParentVersionAction.IGNORE) { throw new VersionException( "Cannot set property. Node is checked in."); } }
/** * Creates a new property definition. * * @param definition a {@code non-null} {@link PropertyDefinition} */ public RestPropertyType( PropertyDefinition definition ) { this.name = definition.getName(); this.requiredType = org.modeshape.jcr.api.PropertyType.nameFromValue(definition.getRequiredType()); NodeType declaringNodeType = definition.getDeclaringNodeType(); this.declaringNodeTypeName = declaringNodeType == null ? null : declaringNodeType.getName(); this.isAutoCreated = definition.isAutoCreated(); this.isMandatory = definition.isMandatory(); this.isProtected = definition.isProtected(); this.isFullTextSearchable = definition.isFullTextSearchable(); this.onParentVersion = OnParentVersionAction.nameFromValue(definition.getOnParentVersion()); this.isMultiple = definition.isMultiple(); }