Search in sources :

Example 1 with Projects

use of org.obiba.opal.web.model.Projects in project mica2 by obiba.

the class OpalService method getProjectDtos.

public List<Projects.ProjectDto> getProjectDtos(String opalUrl) throws URISyntaxException {
    if (Strings.isNullOrEmpty(opalUrl))
        opalUrl = getDefaultOpal();
    OpalJavaClient opalJavaClient = getOpalJavaClient(opalUrl);
    URI uri = opalJavaClient.newUri().segment("projects").build();
    return opalJavaClient.getResources(Projects.ProjectDto.class, uri, Projects.ProjectDto.newBuilder());
}
Also used : Projects(org.obiba.opal.web.model.Projects) URI(java.net.URI) OpalJavaClient(org.obiba.opal.rest.client.magma.OpalJavaClient)

Aggregations

URI (java.net.URI)1 OpalJavaClient (org.obiba.opal.rest.client.magma.OpalJavaClient)1 Projects (org.obiba.opal.web.model.Projects)1