Package org.apache.hdt.core.hdfs.ResourceInformation

Examples of org.apache.hdt.core.hdfs.ResourceInformation.Permissions


      return this.fileStore.getServerResourceInfo() == null ? null : fileStore.getServerResourceInfo().getGroup();
    else if (Property.ISLOCAL.equals(id))
      return this.fileStore.isLocalFile();
    else if (Property.PERMISSIONS.equals(id)){
      String perms = "";
      final Permissions effectivePermissions = this.fileStore.getEffectivePermissions();
      if(effectivePermissions!=null){
        perms += effectivePermissions.read ? "r" : "-";
        perms += effectivePermissions.write ? "w" : "-";
        perms += effectivePermissions.execute ? "x" : "-";
      }else{
View Full Code Here


      else if (store.isRemoteFile())
        decoration.addOverlay(org.apache.hdt.ui.Activator.IMAGE_REMOTE_OVR, IDecoration.BOTTOM_LEFT);
      if (store.isLocalOnly())
        decoration.addOverlay(org.apache.hdt.ui.Activator.IMAGE_OUTGOING_OVR, IDecoration.BOTTOM_RIGHT);

      Permissions effectivePermissions = store.getEffectivePermissions();
      if (effectivePermissions != null && !effectivePermissions.read && !effectivePermissions.write)
        decoration.addOverlay(org.apache.hdt.ui.Activator.IMAGE_READONLY_OVR);
    }
  }
View Full Code Here

        Object object = itr.next();
        if (object instanceof IResource) {
          IResource r = (IResource) object;
          try {
            HDFSFileStore store = (HDFSFileStore) EFS.getStore(r.getLocationURI());
            Permissions effectivePermissions = store.getEffectivePermissions();
            if (enabled && effectivePermissions != null && !effectivePermissions.write)
              enabled = false;
            if (enabled)
              enabled = store.isLocalFile();
          } catch (Throwable t) {
View Full Code Here

        Object object = itr.next();
        if (object instanceof IResource) {
          IResource r = (IResource) object;
          try {
            HDFSFileStore store = (HDFSFileStore) EFS.getStore(r.getLocationURI());
            Permissions effectivePermissions = store.getEffectivePermissions();
            if (enabled && effectivePermissions != null && !effectivePermissions.read)
              enabled = false;
            if (enabled)
              enabled = !store.isLocalFile();
          } catch (Throwable t) {
View Full Code Here

      else if (store.isRemoteFile())
        decoration.addOverlay(org.apache.hdt.ui.Activator.IMAGE_REMOTE_OVR, IDecoration.BOTTOM_LEFT);
      if (store.isLocalOnly())
        decoration.addOverlay(org.apache.hdt.ui.Activator.IMAGE_OUTGOING_OVR, IDecoration.BOTTOM_RIGHT);

      Permissions effectivePermissions = store.getEffectivePermissions();
      if (effectivePermissions != null && !effectivePermissions.read && !effectivePermissions.write)
        decoration.addOverlay(org.apache.hdt.ui.Activator.IMAGE_READONLY_OVR);
    }
  }
View Full Code Here

TOP

Related Classes of org.apache.hdt.core.hdfs.ResourceInformation.Permissions

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.