Package org.jnode.fs

Examples of org.jnode.fs.FSAccessRights


     * Can the given file be read?
     *
     * @param file
     */
    public boolean canRead(String file) throws IOException {
        final FSAccessRights rights = getAccessRights(file);
        return (rights == null) || rights.canRead();
    }
View Full Code Here


     * Can the given file be written to?
     *
     * @param file
     */
    public boolean canWrite(String file) throws IOException {
        final FSAccessRights rights = getAccessRights(file);
        return (rights == null) || rights.canWrite();
    }
View Full Code Here

     * Can the given file be executed to?
     *
     * @param file
     */
    public boolean canExecute(String file) throws IOException {
        final FSAccessRights rights = getAccessRights(file);
        return (rights == null) || rights.canExecute();
    }
View Full Code Here

        final FSAccessRights rights = getAccessRights(file);
        return (rights == null) || rights.canExecute();
    }

    public boolean setReadable(String file, boolean enable, boolean owneronly) throws IOException {
        final FSAccessRights rights = getAccessRights(file);
        if (rights == null) {
            return false;
        }

        return rights.setReadable(enable, owneronly);
    }
View Full Code Here

        return rights.setReadable(enable, owneronly);
    }

    public boolean setWritable(String file, boolean enable, boolean owneronly) throws IOException {
        final FSAccessRights rights = getAccessRights(file);
        if (rights == null) {
            return false;
        }

        return rights.setWritable(enable, owneronly);
    }
View Full Code Here

        return rights.setWritable(enable, owneronly);
    }

    public boolean setExecutable(String file, boolean enable, boolean owneronly) throws IOException {
        final FSAccessRights rights = getAccessRights(file);
        if (rights == null) {
            return false;
        }

        return rights.setExecutable(enable, owneronly);
    }
View Full Code Here

TOP

Related Classes of org.jnode.fs.FSAccessRights

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.