Examples of MultiFiling


Examples of org.apache.chemistry.opencmis.inmemory.storedobj.api.MultiFiling

            if (so instanceof SingleFiling) {
                SingleFiling pathObj = (SingleFiling) so;
                pathObj.setParent(newParent);
            } else if (so instanceof MultiFiling) {
                MultiFiling pathObj = (MultiFiling) so;
                pathObj.addParent(newParent);
                pathObj.removeParent(oldParent);
            }
        } finally {
            fObjStore.unlock();
        }
    }
View Full Code Here

Examples of org.apache.chemistry.opencmis.inmemory.storedobj.api.MultiFiling

                String soPath = ((SingleFiling) so).getPath();
                if (soPath.equals(path)) {
                    return so;
                }
            } else if (so instanceof MultiFiling) {
                MultiFiling mfo = (MultiFiling) so;
                List<Folder> parents = mfo.getParents(user);
                for (Folder parent : parents) {
                    String parentPath = parent.getPath();
                    String mfPath = parentPath.equals(Folder.PATH_SEPARATOR) ? parentPath + mfo.getPathSegment()
                            : parentPath + Folder.PATH_SEPARATOR + mfo.getPathSegment();
                    if (mfPath.equals(path)) {
                        return so;
                    }
                }
            } else {
View Full Code Here

Examples of org.apache.chemistry.opencmis.inmemory.storedobj.api.MultiFiling

            } else {
                result = Collections.emptyList();
            }
        } else if (sop instanceof MultiFiling) {
            result = new ArrayList<ObjectParentData>();
            MultiFiling multiParentObj = (MultiFiling) sop;
            List<Folder> parents = multiParentObj.getParents(user);
            if (null != parents) {
                for (Folder parent : parents) {
                    ObjectParentDataImpl parentData = new ObjectParentDataImpl();
                    TypeDefinition typeDef = fStoreManager.getTypeById(repositoryId, parent.getTypeId()).getTypeDefinition();
                    ObjectData objData = PropertyCreationHelper.getObjectData(typeDef, parent, filter, user, includeAllowableActions,
                            includeRelationships, "", false, true, null);

                    parentData.setObject(objData);
                    parentData.setRelativePathSegment(multiParentObj.getPathSegment());
                    result.add(parentData);
                    if (objectInfos != null) {
                        ObjectInfoImpl objectInfo = new ObjectInfoImpl();
                        fAtomLinkProvider.fillInformationForAtomLinks(repositoryId, parent, objectInfo);
                        objectInfos.addObjectInfo(objectInfo);
View Full Code Here

Examples of org.apache.chemistry.opencmis.inmemory.storedobj.api.MultiFiling

            } else {
                result = Collections.emptyList();
            }
        } else if (sop instanceof MultiFiling) {
            result = new ArrayList<ObjectParentData>();
            MultiFiling multiParentObj = (MultiFiling) sop;
            List<Folder> parents = multiParentObj.getParents(user);
            if (null != parents) {
                for (Folder parent : parents) {
                    ObjectParentDataImpl parentData = new ObjectParentDataImpl();
                    TypeDefinition typeDef = fStoreManager.getTypeById(repositoryId, parent.getTypeId()).getTypeDefinition();
                    ObjectData objData = PropertyCreationHelper.getObjectData(typeDef, parent, filter, user, includeAllowableActions,
                            includeRelationships, "", false, true, null);

                    parentData.setObject(objData);
                    parentData.setRelativePathSegment(multiParentObj.getPathSegment());
                    result.add(parentData);
                    if (objectInfos != null) {
                        ObjectInfoImpl objectInfo = new ObjectInfoImpl();
                        fAtomLinkProvider.fillInformationForAtomLinks(repositoryId, parent, objectInfo);
                        objectInfos.addObjectInfo(objectInfo);
View Full Code Here

Examples of org.apache.chemistry.opencmis.inmemory.storedobj.api.MultiFiling

                String soPath = ((SingleFiling) so).getPath();
                if (soPath.equals(path)) {
                    return so;
                }
            } else if (so instanceof MultiFiling) {
                MultiFiling mfo = (MultiFiling) so;
                List<Folder> parents = mfo.getParents(user);
                for (Folder parent : parents) {
                    String parentPath = parent.getPath();
                    String mfPath = parentPath.equals(Folder.PATH_SEPARATOR) ? parentPath + mfo.getPathSegment()
                            : parentPath + Folder.PATH_SEPARATOR + mfo.getPathSegment();
                    if (mfPath.equals(path)) {
                        return so;
                    }
                }
            } else {
View Full Code Here

Examples of org.apache.chemistry.opencmis.inmemory.storedobj.api.MultiFiling

            if (so instanceof SingleFiling) {
                SingleFiling pathObj = (SingleFiling) so;
                pathObj.setParent(newParent);
            } else if (so instanceof MultiFiling) {
                MultiFiling pathObj = (MultiFiling) so;
                pathObj.addParent(newParent);
                pathObj.removeParent(oldParent);
            }
        } finally {
            fObjStore.unlock();
        }
    }
View Full Code Here

Examples of org.apache.chemistry.opencmis.inmemory.storedobj.api.MultiFiling

            } else {
                result = Collections.emptyList();
            }
        } else if (sop instanceof MultiFiling) {
            result = new ArrayList<ObjectParentData>();
            MultiFiling multiParentObj = (MultiFiling) sop;
            List<Folder> parents = multiParentObj.getParents(user);
            if (null != parents) {
                for (Folder parent : parents) {
                    ObjectParentDataImpl parentData = new ObjectParentDataImpl();
                    TypeDefinition typeDef = fStoreManager.getTypeById(repositoryId, parent.getTypeId()).getTypeDefinition();
                    ObjectData objData = PropertyCreationHelper.getObjectData(typeDef, parent, filter, user, includeAllowableActions,
                            includeRelationships, "", false, true, null);

                    parentData.setObject(objData);
                    parentData.setRelativePathSegment(multiParentObj.getPathSegment());
                    result.add(parentData);
                    if (objectInfos != null) {
                        ObjectInfoImpl objectInfo = new ObjectInfoImpl();
                        fAtomLinkProvider.fillInformationForAtomLinks(repositoryId, parent, objectInfo);
                        objectInfos.addObjectInfo(objectInfo);
View Full Code Here

Examples of org.apache.chemistry.opencmis.inmemory.storedobj.api.MultiFiling

                String soPath = ((SingleFiling) so).getPath();
                if (soPath.equals(path)) {
                    return so;
                }
            } else if (so instanceof MultiFiling) {
                MultiFiling mfo = (MultiFiling) so;
                List<Folder> parents = mfo.getParents(user);
                for (Folder parent : parents) {
                    String parentPath = parent.getPath();
                    String mfPath = parentPath.equals(Folder.PATH_SEPARATOR) ? parentPath + mfo.getPathSegment()
                            : parentPath + Folder.PATH_SEPARATOR + mfo.getPathSegment();
                    if (mfPath.equals(path)) {
                        return so;
                    }
                }
            } else {
View Full Code Here

Examples of org.apache.chemistry.opencmis.inmemory.storedobj.api.MultiFiling

        StoredObject so = so2[0];
        StoredObject folder = so2[1];
        checkObjects(so, folder);

        Folder newParent = (Folder) folder;
        MultiFiling obj = (MultiFiling) so;
        obj.addParent(newParent);

        if (context.isObjectInfoRequired()) {
            ObjectInfoImpl objectInfo = new ObjectInfoImpl();
            fAtomLinkProvider.fillInformationForAtomLinks(repositoryId, so, objectInfo);
            fAtomLinkProvider.fillInformationForAtomLinks(repositoryId, folder, objectInfo);
View Full Code Here

Examples of org.apache.chemistry.opencmis.inmemory.storedobj.api.MultiFiling

        ObjectStore objectStore = fStoreManager.getObjectStore(repositoryId);
        StoredObject folder = checkExistingObjectId(objectStore, folderId);

        checkObjects(so, folder);
        Folder parent = (Folder) folder;
        MultiFiling obj = (MultiFiling) so;
        obj.removeParent(parent);

        // To be able to provide all Atom links in the response we need
        // additional information:
        if (context.isObjectInfoRequired()) {
            ObjectInfoImpl objectInfo = new ObjectInfoImpl();
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.