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

org.yamcs.sle.SlePlugin Maven / Gradle / Ivy

Go to download

Data links for connecting Yamcs to SLE (Space Link Extension) providers such as Ground Stations

There is a newer version: 1.6.0
Show newest version
package org.yamcs.sle;

import java.io.IOException;
import java.io.InputStream;

import org.yamcs.Plugin;
import org.yamcs.PluginException;
import org.yamcs.YConfiguration;
import org.yamcs.YamcsServer;
import org.yamcs.http.HttpServer;

public class SlePlugin implements Plugin {

    @Override
    public void onLoad(YConfiguration config) throws PluginException {
        HttpServer httpServer = YamcsServer.getServer().getGlobalServices(HttpServer.class).get(0);
        try (InputStream in = getClass().getResourceAsStream("/yamcs-sle.protobin")) {
            httpServer.getProtobufRegistry().importDefinitions(in);
        } catch (IOException e) {
            throw new PluginException(e);
        }
        httpServer.addApi(new SleApi());
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy