Child pages
  • openBIS General Information API
Skip to end of metadata
Go to start of metadata

Introduction

There are two interfaces for reading and changing meta data stored in openBIS:

ch.systemsx.cisd.openbis.generic.shared.api.v1.IGeneralInformationService : Reading meta data.

ch.systemsx.cisd.openbis.generic.shared.api.v1.IGeneralInformationChangingService : Changing some meta data

Usage

In a Java client application these services are created most easily with a ServiceFinder . Only host name and port of openBIS Application Server are needed. Here is an example for IGeneralInformationService:

ServiceFinder serviceFinder = new ServiceFinder("openbis", IGeneralInformationService.SERVICE_URL);
IGeneralInformationService infoService = 
    serviceFinder.createService(IGeneralInformationService.class, "https://sprint-openbis.ethz.ch:8446");

Similar code is needed for IGeneralInformationChangingService.

In order to use IGeneralInformationChangingService you need to login into IGeneralInformationService and using the returned session token. Example:

String sessionToken = infoService.tryToAuthenticateForAllServices("user-id", "user-password");
infoChangingService.createMetaproject(sessionToken, "my-project", null);

The following library is needed: openbis-query-api.jar. It is part of the openBIS Clients and APIs distribution.

  • No labels