Package org.apache.chemistry.opencmis.commons.impl.dataobjects

Examples of org.apache.chemistry.opencmis.commons.impl.dataobjects.PropertiesImpl.addProperty()


            if (isEmptyProperty(prop)) {
                throw new CmisConstraintException("Property '" + prop.getId() + "' must not be empty!");
            }

            // add it
            result.addProperty(prop);
            addedProps.add(prop.getId());
        }

        // check if required properties are missing
        for (PropertyDefinition<?> propDef : type.getPropertyDefinitions().values()) {
View Full Code Here


            // only add read/write properties
            if ((propType.getUpdatability() != Updatability.READWRITE)) {
                continue;
            }

            result.addProperty(prop);
        }

        // update properties
        for (PropertyData<?> prop : properties.getProperties().values()) {
            PropertyDefinition<?> propType = type.getPropertyDefinitions().get(prop.getId());
View Full Code Here

            // default or value
            if (isEmptyProperty(prop)) {
                addPropertyDefault(result, propType);
            } else {
                result.addProperty(prop);
            }
        }

        addPropertyId(result, typeId, null, PropertyIds.OBJECT_TYPE_ID, typeId);
        addPropertyString(result, typeId, null, PropertyIds.CREATED_BY, creator);
View Full Code Here

                propertyData = createPropertyData(propDef, controlParser.getValues(CONTROL_PROP_VALUE, i));
            } else {
                propertyData = createPropertyData(propDef, null);
            }

            result.addProperty(propertyData);

            i++;
        }

        return result;
View Full Code Here

        }

        PropertiesImpl result = new PropertiesImpl();

        for (CmisProperty property : properties.getProperty()) {
            result.addProperty(convert(property));
        }

        // handle extensions
        convertExtension(properties, result);
View Full Code Here

        Properties existingProps = PropertyCreationHelper.getPropertiesFromObject(so, td, requestedIds, true);

        PropertiesImpl newPD = new PropertiesImpl();
        // copy all existing properties
        for (PropertyData<?> prop : existingProps.getProperties().values()) {
            newPD.addProperty(prop);
        }
        // overwrite all new properties
        for (PropertyData<?> prop : properties.getProperties().values()) {
            newPD.addProperty(prop);
        }
View Full Code Here

        for (PropertyData<?> prop : existingProps.getProperties().values()) {
            newPD.addProperty(prop);
        }
        // overwrite all new properties
        for (PropertyData<?> prop : properties.getProperties().values()) {
            newPD.addProperty(prop);
        }

        String res = createDocument(context, repositoryId, newPD, folderId, content, versioningState, policies,
                addAces, removeAces, null);
        LOG.debug("stop createDocumentFromSource()");
View Full Code Here

                property.setQueryName(queryName);
                property.setLocalName(getString(jsonPropertyMap, JSON_PROPERTY_LOCALNAME));

                convertExtension(jsonPropertyMap, property, PROPERTY_KEYS);

                result.addProperty(property);
            }
        }

        if (extJson != null) {
            convertExtension(extJson, result, Collections.<String> emptySet());
View Full Code Here

                property.setDisplayName(id);
                property.setQueryName(null);
                property.setLocalName(null);
            }

            result.addProperty(property);
        }

        if (extJson != null) {
            convertExtension(extJson, result, Collections.<String> emptySet());
        }
View Full Code Here

        PropertiesImpl properties = new PropertiesImpl();
        object.setProperties(properties);

        PropertyIdImpl idProperty = new PropertyIdImpl(PropertyIds.OBJECT_ID, objectId);
        properties.addProperty(idProperty);

        return object;
    }

    /**
 
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.