All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.labkey.remoteapi.test.LineageDemo Maven / Gradle / Ivy

Go to download

The client-side library for Java developers is a separate JAR from the LabKey Server code base. It can be used by any Java program, including another Java web application.

There is a newer version: 6.2.0
Show newest version
package org.labkey.remoteapi.test;

import org.labkey.remoteapi.Connection;
import org.labkey.remoteapi.experiment.LineageCommand;
import org.labkey.remoteapi.experiment.LineageResponse;

class LineageDemo
{
    public static void main(String[] args) throws Exception
    {
        String url = "http://localhost:8080/labkey";
        String folderPath = "/AssayImportProvenance Test";
        String user = "[email protected]";
        String password = "xxxxxx";

        String lsid = "urn:lsid:labkey.com:GeneralAssayRun.Folder-4780:40166791-3d3f-1039-a854-9b7575483a25";

        LineageCommand cmd = new LineageCommand.Builder(lsid)
                .setParents(false)
                .setChildren(true)
                .setIncludeProperties(true)
                .setIncludeInputsAndOutputs(true)
                .setIncludeRunSteps(true)
                .build();

        Connection conn = new Connection(url, user, password);
        LineageResponse resp = cmd.execute(conn, folderPath);
        System.out.println(resp.dump());
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy