use of org.yamcs.studio.core.client.YamcsClient in project yamcs-studio by yamcs.
the class ArchiveCatalogue method listTags.
public CompletableFuture<byte[]> listTags(TimeInterval interval) {
String instance = ManagementCatalogue.getCurrentYamcsInstance();
URLBuilder urlb = new URLBuilder("/archive/" + instance + "/tags");
if (interval.hasStart())
urlb.setParam("start", interval.getStartUTC());
if (interval.hasStop())
urlb.setParam("stop", interval.getStopUTC());
YamcsClient yamcsClient = YamcsPlugin.getYamcsClient();
return yamcsClient.get(urlb.toString(), null);
}
use of org.yamcs.studio.core.client.YamcsClient in project yamcs-studio by yamcs.
the class ArchiveCatalogue method deleteTag.
public CompletableFuture<byte[]> deleteTag(long tagTime, int tagId) {
YamcsClient yamcsClient = YamcsPlugin.getYamcsClient();
String instance = ManagementCatalogue.getCurrentYamcsInstance();
return yamcsClient.delete("/archive/" + instance + "/tags/" + tagTime + "/" + tagId, null);
}
use of org.yamcs.studio.core.client.YamcsClient in project yamcs-studio by yamcs.
the class CommandingCatalogue method updateCommandComment.
public CompletableFuture<byte[]> updateCommandComment(String processor, CommandId cmdId, String newComment) {
String instance = ManagementCatalogue.getCurrentYamcsInstance();
YamcsClient yamcsClient = YamcsPlugin.getYamcsClient();
KeyValue keyValue = KeyValue.newBuilder().setKey("Comment").setValue(newComment).build();
UpdateCommandHistoryRequest request = UpdateCommandHistoryRequest.newBuilder().setCmdId(cmdId).addHistoryEntry(keyValue).build();
return yamcsClient.post("/processors/" + instance + "/" + processor + "/commandhistory" + cmdId.getCommandName(), request);
}
use of org.yamcs.studio.core.client.YamcsClient in project yamcs-studio by yamcs.
the class CommandingCatalogue method editQueue.
public CompletableFuture<byte[]> editQueue(CommandQueueInfo queue, EditCommandQueueRequest request) {
String instance = ManagementCatalogue.getCurrentYamcsInstance();
YamcsClient yamcsClient = YamcsPlugin.getYamcsClient();
return yamcsClient.patch("/processors/" + instance + "/" + queue.getProcessorName() + "/cqueues/" + queue.getName(), request);
}
use of org.yamcs.studio.core.client.YamcsClient in project yamcs-studio by yamcs.
the class CommandingCatalogue method editQueuedCommand.
public CompletableFuture<byte[]> editQueuedCommand(CommandQueueEntry entry, EditCommandQueueEntryRequest request) {
String instance = ManagementCatalogue.getCurrentYamcsInstance();
YamcsClient yamcsClient = YamcsPlugin.getYamcsClient();
return yamcsClient.patch("/processors/" + instance + "/" + entry.getProcessorName() + "/cqueues/" + entry.getQueueName() + "/entries/" + entry.getUuid(), request);
}
Aggregations