All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.enonic.xp.security.PrincipalRelationships Maven / Gradle / Ivy

The newest version!
package com.enonic.xp.security;

import com.google.common.collect.ImmutableList;

import com.enonic.xp.annotation.PublicApi;
import com.enonic.xp.support.AbstractImmutableEntityList;

@PublicApi
public final class PrincipalRelationships
    extends AbstractImmutableEntityList
{
    private PrincipalRelationships( final ImmutableList list )
    {
        super( list );
    }

    @Override
    public String toString()
    {
        return this.list.toString();
    }

    public static PrincipalRelationships empty()
    {
        return new PrincipalRelationships( ImmutableList.of() );
    }

    public static PrincipalRelationships from( final PrincipalRelationship... principalRelationships )
    {
        return new PrincipalRelationships( ImmutableList.copyOf( principalRelationships ) );
    }

    public static PrincipalRelationships from( final Iterable principalRelationships )
    {
        return new PrincipalRelationships( ImmutableList.copyOf( principalRelationships ) );
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy