use of io.nuls.consensus.poc.protocol.util.AgentComparator in project nuls by nuls-io.
the class CacheLoader method loadAgents.
public List<Agent> loadAgents() {
List<Agent> agentList = new ArrayList<>();
List<AgentPo> poList = this.agentStorageService.getList();
for (AgentPo po : poList) {
Agent agent = PoConvertUtil.poToAgent(po);
agentList.add(agent);
}
Collections.sort(agentList, new AgentComparator());
return agentList;
}
Aggregations