Package org.apache.chemistry.opencmis.inmemory.storedobj.api

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


    public List<Folder> getFolderChildren(int maxItems, int skipCount, String user) {
        List<Folder> result = new ArrayList<Folder>();
        for (String id : fObjStore.getIds()) {
            StoredObject obj = fObjStore.getObject(id);
            if (obj instanceof SingleFiling) {
                SingleFiling pathObj = (SingleFiling) obj;
                if (pathObj.getParent() == this && pathObj instanceof Folder) {
                    result.add((Folder) obj);
                }
            }
        }
        sortFolderList(result);
View Full Code Here


            if (!(so instanceof Filing)) {
                throw new IllegalArgumentException("Cannot move object, object does not have a path.");
            }

            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

    public List<Folder> getFolderChildren(int maxItems, int skipCount, String user) {
        List<Folder> result = new ArrayList<Folder>();
        for (String id : fObjStore.getIds()) {
            StoredObject obj = fObjStore.getObject(id);
            if (fObjStore.hasReadAccess(user, obj) && obj instanceof SingleFiling) {
                SingleFiling pathObj = (SingleFiling) obj;
                if (pathObj.getParent() == this && pathObj instanceof Folder) {
                    result.add((Folder) obj);
                }
            }
        }
        sortFolderList(result);
View Full Code Here

            if (!(so instanceof Filing)) {
                throw new IllegalArgumentException("Cannot move object, object does not have a path.");
            }

            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

    public List<Folder> getFolderChildren(int maxItems, int skipCount) {
        List<Folder> result = new ArrayList<Folder>();
        for (String id : fObjStore.getIds()) {
            StoredObject obj = fObjStore.getObject(id);
            if (obj instanceof SingleFiling) {
                SingleFiling pathObj = (SingleFiling) obj;
                if (pathObj.getParent() == this && pathObj instanceof Folder) {
                    result.add((Folder) obj);
                }
            }
        }
        sortFolderList(result);
View Full Code Here

            if (!(so instanceof Filing)) {
                throw new IllegalArgumentException("Cannot move object, object does not have a path.");
            }

            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

    public List<Folder> getFolderChildren(int maxItems, int skipCount) {
        List<Folder> result = new ArrayList<Folder>();
        for (String id : fObjStore.getIds()) {
            StoredObject obj = fObjStore.getObject(id);
            if (obj instanceof SingleFiling) {
                SingleFiling pathObj = (SingleFiling) obj;
                if (pathObj.getParent() == this && pathObj instanceof Folder)
                    result.add((Folder) obj);
            }
        }
        sortFolderList(result);
        int from = Math.min(skipCount, result.size());
View Full Code Here

                throw new IllegalArgumentException("Cannot move object, this name already exists in target.");
            if (!(so instanceof Filing))
                throw new IllegalArgumentException("Cannot move object, object does not have a path.");

            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

    public ChildrenResult getFolderChildren(int maxItems, int skipCount, String user) {
        List<Folder> result = new ArrayList<Folder>();
        for (String id : fObjStore.getIds()) {
            StoredObject obj = fObjStore.getObject(id);
            if (fObjStore.hasReadAccess(user, obj) && obj instanceof SingleFiling) {
                SingleFiling pathObj = (SingleFiling) obj;
                if (pathObj.getParent() == this && pathObj instanceof Folder) {
                    result.add((Folder) obj);
                }
            }
        }
        sortFolderList(result);
View Full Code Here

            if (!(so instanceof Filing)) {
                throw new IllegalArgumentException("Cannot move object, object does not have a path.");
            }

            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

TOP

Related Classes of org.apache.chemistry.opencmis.inmemory.storedobj.api.SingleFiling

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.