@Override
    public Collection<Permission> getPermissions(Action action) {
        if (!(action instanceof DestinationAction)) {
            throw new IllegalArgumentException("Action argument must be a " + DestinationAction.class.getName() + " instance.");
        }
        DestinationAction da = (DestinationAction) action;
        return getPermissions(da);
    }
@Test
    public void testGetPermissionsWithQueue() {
        ActiveMQQueue queue = new ActiveMQQueue("myQueue");
        DestinationAction action = new DestinationAction(new ConnectionContext(), queue, "write");
        Collection<Permission> perms = resolver.getPermissions(action);
        assertPermString("queue:myQueue:write", perms);
    }