Search in sources :

Example 1 with EditLinkRequest

use of org.yamcs.protobuf.Rest.EditLinkRequest in project yamcs-studio by yamcs.

the class LinkCatalogue method enableLink.

public CompletableFuture<byte[]> enableLink(String instance, String name) {
    YamcsClient yamcsClient = YamcsPlugin.getYamcsClient();
    EditLinkRequest req = EditLinkRequest.newBuilder().setState("enabled").build();
    return yamcsClient.patch("/links/" + instance + "/" + name, req);
}
Also used : YamcsClient(org.yamcs.studio.core.client.YamcsClient) EditLinkRequest(org.yamcs.protobuf.Rest.EditLinkRequest)

Example 2 with EditLinkRequest

use of org.yamcs.protobuf.Rest.EditLinkRequest in project yamcs-studio by yamcs.

the class LinkCatalogue method disableLink.

public CompletableFuture<byte[]> disableLink(String instance, String name) {
    YamcsClient yamcsClient = YamcsPlugin.getYamcsClient();
    EditLinkRequest req = EditLinkRequest.newBuilder().setState("disabled").build();
    return yamcsClient.patch("/links/" + instance + "/" + name, req);
}
Also used : YamcsClient(org.yamcs.studio.core.client.YamcsClient) EditLinkRequest(org.yamcs.protobuf.Rest.EditLinkRequest)

Aggregations

EditLinkRequest (org.yamcs.protobuf.Rest.EditLinkRequest)2 YamcsClient (org.yamcs.studio.core.client.YamcsClient)2