Search in sources :

Example 26 with FenceAgent

use of org.ovirt.engine.core.common.businessentities.pm.FenceAgent in project ovirt-engine by oVirt.

the class BackendFenceAgentResource method update.

@Override
public Agent update(Agent agent) {
    QueryIdResolver<Guid> agentResolver = new QueryIdResolver<>(QueryType.GetFenceAgentById, IdQueryParameters.class);
    FenceAgent entity = getEntity(agentResolver, true);
    return performUpdate(agent, entity, map(entity), agentResolver, ActionType.UpdateFenceAgent, new UpdateParametersProvider());
}
Also used : FenceAgent(org.ovirt.engine.core.common.businessentities.pm.FenceAgent) Guid(org.ovirt.engine.core.compat.Guid)

Example 27 with FenceAgent

use of org.ovirt.engine.core.common.businessentities.pm.FenceAgent in project ovirt-engine by oVirt.

the class BackendFenceAgentsResource method mapCollection.

private Agents mapCollection(List<FenceAgent> fenceAgents) {
    Agents agents = new Agents();
    for (FenceAgent fenceAgent : fenceAgents) {
        Agent agent = map(fenceAgent, null);
        agents.getAgents().add(addLinks(populate(agent, fenceAgent)));
    }
    return agents;
}
Also used : Agent(org.ovirt.engine.api.model.Agent) FenceAgent(org.ovirt.engine.core.common.businessentities.pm.FenceAgent) Agents(org.ovirt.engine.api.model.Agents) FenceAgent(org.ovirt.engine.core.common.businessentities.pm.FenceAgent)

Aggregations

FenceAgent (org.ovirt.engine.core.common.businessentities.pm.FenceAgent)27 VDS (org.ovirt.engine.core.common.businessentities.VDS)5 Guid (org.ovirt.engine.core.compat.Guid)5 ArrayList (java.util.ArrayList)4 LinkedList (java.util.LinkedList)4 Cluster (org.ovirt.engine.core.common.businessentities.Cluster)4 Comparator (java.util.Comparator)2 HashMap (java.util.HashMap)2 HashSet (java.util.HashSet)2 List (java.util.List)2 Map (java.util.Map)2 Test (org.junit.Test)2 Window (com.google.gwt.user.client.Window)1 Inject (com.google.inject.Inject)1 Arrays (java.util.Arrays)1 Collection (java.util.Collection)1 Collections (java.util.Collections)1 Objects (java.util.Objects)1 Set (java.util.Set)1 Before (org.junit.Before)1