@Test public final void testActions() { int expected = 4; Action[] actions = context.getActions(); if (actions.length != expected) { fail("Found " + actions.length + " actions while " + expected + " were expected"); } }
public Action[] getActions() { if (actions == null) { List<Action> permissionList = new ArrayList<Action>(); permissionList.addAll(aclAllow.keySet()); permissionList.addAll(aclAllowDefaults.keySet()); permissionList.addAll(aclDeny.keySet()); permissionList.addAll(aclDenyDefaults.keySet()); actions = permissionList.toArray(new Action[permissionList.size()]); } return actions; }
SecurityContextImpl extends AbstractSecurityContext implements Securable, Cloneable { public Action[] getActions() { if (actions == null) { List<Action> permissionList = new ArrayList<Action>(); permissionList.addAll(aclAllow.keySet()); permissionList.addAll(aclAllowDefaults.keySet()); permissionList.addAll(aclDeny.keySet()); permissionList.addAll(aclDenyDefaults.keySet()); actions = permissionList.toArray(new Action[permissionList.size()]); } return actions; } }
SecurityContextImpl extends AbstractSecurityContext implements Securable, Cloneable { public Action[] getActions() { if (actions == null) { List<Action> permissionList = new ArrayList<Action>(); permissionList.addAll(aclAllow.keySet()); permissionList.addAll(aclAllowDefaults.keySet()); permissionList.addAll(aclDeny.keySet()); permissionList.addAll(aclDenyDefaults.keySet()); actions = permissionList.toArray(new Action[permissionList.size()]); } return actions; } SecurityContextImpl();  SecurityContextImpl(User owner); }
SecurityContextImpl extends AbstractSecurityContext implements Securable, Cloneable { public Action[] getActions() { if (actions == null) { List<Action> permissionList = new ArrayList<Action>(); permissionList.addAll(aclAllow.keySet()); permissionList.addAll(aclAllowDefaults.keySet()); permissionList.addAll(aclDeny.keySet()); permissionList.addAll(aclDenyDefaults.keySet()); actions = permissionList.toArray(new Action[permissionList.size()]); } return actions; } SecurityContextImpl();  SecurityContextImpl(User owner); @Override boolean isDefaultAccess(); void setAllowDenyOrder(Order order); @Override Order getAllowDenyOrder(); @Override void addAccessRule(AccessRule rule); @Override SortedSet<AccessRule> getAccessRules(); void allow(Authority authority, Action action); void allowAll(); void allowAll(Action action); @Override boolean isAllowed(Action action, Authority authority); void allowDefault(Action action, Authority authority); void deny(Authority authority, Action action); void denyDefault(Action action, Authority authority); @Override boolean isDenied(Action action, Authority authority); void denyAll(Action action); void denyAll(); Authority[] getAllowed(Action p); Authority[] getDenied(Action p); Action[] getActions(); static SecurityContextImpl fromXml(Node context); static SecurityContextImpl fromXml(Node context, XPath xpath); String toXml(); Object clone(); }
SecurityContextImpl extends AbstractSecurityContext implements Securable, Cloneable { public Action[] getActions() { if (actions == null) { List<Action> permissionList = new ArrayList<Action>(); permissionList.addAll(aclAllow.keySet()); permissionList.addAll(aclAllowDefaults.keySet()); permissionList.addAll(aclDeny.keySet()); permissionList.addAll(aclDenyDefaults.keySet()); actions = permissionList.toArray(new Action[permissionList.size()]); } return actions; } SecurityContextImpl();  SecurityContextImpl(User owner); @Override boolean isDefaultAccess(); void setAllowDenyOrder(Order order); @Override Order getAllowDenyOrder(); @Override void addAccessRule(AccessRule rule); @Override SortedSet<AccessRule> getAccessRules(); void allow(Authority authority, Action action); void allowAll(); void allowAll(Action action); @Override boolean isAllowed(Action action, Authority authority); void allowDefault(Action action, Authority authority); void deny(Authority authority, Action action); void denyDefault(Action action, Authority authority); @Override boolean isDenied(Action action, Authority authority); void denyAll(Action action); void denyAll(); Authority[] getAllowed(Action p); Authority[] getDenied(Action p); Action[] getActions(); static SecurityContextImpl fromXml(Node context); static SecurityContextImpl fromXml(Node context, XPath xpath); String toXml(); Object clone();  }