Search in sources :

Example 1 with RemoteIterator

use of org.apache.jackrabbit.rmi.remote.RemoteIterator in project jackrabbit by apache.

the class ClientGroup method members.

public Enumeration<? extends Principal> members() {
    try {
        final RemoteIterator remote = ((RemoteGroup) getRemotePrincipal()).members();
        final Iterator<Principal> pi = factory.getPrincipalIterator(remote);
        return new Enumeration<Principal>() {

            public boolean hasMoreElements() {
                return pi.hasNext();
            }

            public Principal nextElement() {
                return pi.next();
            }
        };
    } catch (RemoteException re) {
        throw new RemoteRuntimeException(re);
    }
}
Also used : RemoteIterator(org.apache.jackrabbit.rmi.remote.RemoteIterator) RemoteGroup(org.apache.jackrabbit.rmi.remote.principal.RemoteGroup) Enumeration(java.util.Enumeration) RemoteRuntimeException(org.apache.jackrabbit.rmi.client.RemoteRuntimeException) RemoteException(java.rmi.RemoteException) Principal(java.security.Principal) RemotePrincipal(org.apache.jackrabbit.rmi.remote.principal.RemotePrincipal)

Aggregations

RemoteException (java.rmi.RemoteException)1 Principal (java.security.Principal)1 Enumeration (java.util.Enumeration)1 RemoteRuntimeException (org.apache.jackrabbit.rmi.client.RemoteRuntimeException)1 RemoteIterator (org.apache.jackrabbit.rmi.remote.RemoteIterator)1 RemoteGroup (org.apache.jackrabbit.rmi.remote.principal.RemoteGroup)1 RemotePrincipal (org.apache.jackrabbit.rmi.remote.principal.RemotePrincipal)1