@Test @Deploy("org.nuxeo.ecm.core.tests:permissions-override3-contrib.xml") public void testOverridedVisiblePermission3() throws Exception { PermissionProvider pp = service.getPermissionProvider(); List<UserVisiblePermission> orderedVisiblePermissions = pp.getUserVisiblePermissionDescriptors(); assertNotNull(orderedVisiblePermissions); assertEquals(Arrays.asList("Write", "Read", "Everything"), permStrings(orderedVisiblePermissions)); orderedVisiblePermissions = pp.getUserVisiblePermissionDescriptors("Section"); assertNotNull(orderedVisiblePermissions); assertEquals(Arrays.asList("Write", "Everything", "Read"), permStrings(orderedVisiblePermissions)); orderedVisiblePermissions = pp.getUserVisiblePermissionDescriptors("Workspace"); assertNotNull(orderedVisiblePermissions); assertEquals(Arrays.asList("Write", "Read", "Everything"), permStrings(orderedVisiblePermissions)); }
public PermissionProvider getPermissionProvider() { return permissionProvider; }
SecurityService extends DefaultComponent { public PermissionProvider getPermissionProvider() { return permissionProvider; } }
SecurityService extends DefaultComponent { public PermissionProvider getPermissionProvider() { return permissionProvider; }  }
SecurityService extends DefaultComponent { public PermissionProvider getPermissionProvider() { return permissionProvider; }  @Override void activate(ComponentContext context); @Override void deactivate(ComponentContext context); @Override void registerContribution(Object contribution, String extensionPoint, ComponentInstance contributor); @Override void unregisterContribution(Object contribution, String extensionPoint, ComponentInstance contributor); PermissionProvider getPermissionProvider(); boolean arePoliciesRestrictingPermission(String permission); boolean arePoliciesExpressibleInQuery(String repositoryName); Collection<SQLQuery.Transformer> getPoliciesQueryTransformers(String repositoryName); boolean checkPermission(Document doc, NuxeoPrincipal principal, String permission); Collection<String> filterGrantedPermissions(Document doc, NuxeoPrincipal principal,
            Collection<String> permissions); String[] getPermissionsToCheck(String permission); static String[] getPrincipalsToCheck(NuxeoPrincipal principal); @SuppressWarnings("unchecked") @Override T getAdapter(Class<T> adapter); }
SecurityService extends DefaultComponent { public PermissionProvider getPermissionProvider() { return permissionProvider; }  @Override void activate(ComponentContext context); @Override void deactivate(ComponentContext context); @Override void registerContribution(Object contribution, String extensionPoint, ComponentInstance contributor); @Override void unregisterContribution(Object contribution, String extensionPoint, ComponentInstance contributor); PermissionProvider getPermissionProvider(); boolean arePoliciesRestrictingPermission(String permission); boolean arePoliciesExpressibleInQuery(String repositoryName); Collection<SQLQuery.Transformer> getPoliciesQueryTransformers(String repositoryName); boolean checkPermission(Document doc, NuxeoPrincipal principal, String permission); Collection<String> filterGrantedPermissions(Document doc, NuxeoPrincipal principal,
            Collection<String> permissions); String[] getPermissionsToCheck(String permission); static String[] getPrincipalsToCheck(NuxeoPrincipal principal); @SuppressWarnings("unchecked") @Override T getAdapter(Class<T> adapter); static final ComponentName NAME; static final String PERMISSIONS_EXTENSION_POINT; }