Search in sources :

Example 1 with NetworkImpl

use of org.alfresco.rest.api.model.NetworkImpl in project alfresco-remote-api by Alfresco.

the class NetworksImpl method validateNetwork.

public Network validateNetwork(String networkId) {
    org.alfresco.repo.tenant.Network network = networksService.getNetwork(networkId);
    if (network == null) {
        throw new EntityNotFoundException(networkId);
    }
    Network restNetwork = new NetworkImpl(network);
    return restNetwork;
}
Also used : Network(org.alfresco.rest.api.model.Network) PersonNetwork(org.alfresco.rest.api.model.PersonNetwork) NetworkImpl(org.alfresco.rest.api.model.NetworkImpl) EntityNotFoundException(org.alfresco.rest.framework.core.exceptions.EntityNotFoundException)

Example 2 with NetworkImpl

use of org.alfresco.rest.api.model.NetworkImpl in project alfresco-remote-api by Alfresco.

the class NetworksImpl method getPersonNetwork.

private PersonNetwork getPersonNetwork(org.alfresco.repo.tenant.Network network) {
    Network restNetwork = new NetworkImpl(network);
    PersonNetwork personNetwork = new PersonNetwork(network.getIsHomeNetwork(), restNetwork);
    return personNetwork;
}
Also used : Network(org.alfresco.rest.api.model.Network) PersonNetwork(org.alfresco.rest.api.model.PersonNetwork) NetworkImpl(org.alfresco.rest.api.model.NetworkImpl) PersonNetwork(org.alfresco.rest.api.model.PersonNetwork)

Aggregations

Network (org.alfresco.rest.api.model.Network)2 NetworkImpl (org.alfresco.rest.api.model.NetworkImpl)2 PersonNetwork (org.alfresco.rest.api.model.PersonNetwork)2 EntityNotFoundException (org.alfresco.rest.framework.core.exceptions.EntityNotFoundException)1