@Test public void getMarkTest() throws ExecutionException, InterruptedException { var mark = List.of( 100, 500 ); assertNormalBehavior( () -> CompletableFuture.completedFuture(new ResponseMessage(1, null, mark)), () -> bufferStreamApi.getMark("name"), request -> assertMethodAndArguments(request, NeovimBufferApi.GET_MARK, buffer, "name"), result -> { assertEquals(100, result.getRow()); assertEquals(500, result.getCol()); result.toString(); } ); assertErrorBehavior( () -> bufferStreamApi.getMark("badName"), request -> assertMethodAndArguments(request, NeovimBufferApi.GET_MARK, buffer, "badName") ); }
@Override public CompletableFuture<VimCoords> getMark(String name) { return sendWithResponseOfType(prepareMessage(GET_MARK).addArgument(name), VimCoords.class); }
BufferStreamApi extends BaseStreamApi implements NeovimBufferApi { @Override public CompletableFuture<VimCoords> getMark(String name) { return sendWithResponseOfType(prepareMessage(GET_MARK).addArgument(name), VimCoords.class); } }
BufferStreamApi extends BaseStreamApi implements NeovimBufferApi { @Override public CompletableFuture<VimCoords> getMark(String name) { return sendWithResponseOfType(prepareMessage(GET_MARK).addArgument(name), VimCoords.class); } BufferStreamApi(ReactiveRpcStreamer reactiveRpcStreamer,
                           Buffer model); }
BufferStreamApi extends BaseStreamApi implements NeovimBufferApi { @Override public CompletableFuture<VimCoords> getMark(String name) { return sendWithResponseOfType(prepareMessage(GET_MARK).addArgument(name), VimCoords.class); } BufferStreamApi(ReactiveRpcStreamer reactiveRpcStreamer,
                           Buffer model); @Override Buffer get(); @Override CompletableFuture<Integer> getLineCount(); @Override CompletableFuture<List<String>> getLines(int start, int end, boolean strictIndexing); @Override CompletableFuture<Void> setLines(int start, int end, boolean strictIndexing, List<String> replacement); @Override CompletableFuture<Integer> getOffset(int index); @Override CompletableFuture<Object> getVar(String name); @Override CompletableFuture<Void> deleteVar(String name); @Override CompletableFuture<Void> setVar(String name, Object value); @Override CompletableFuture<Object> getOption(String name); @Override CompletableFuture<Void> setOption(String name, Object value); @Override CompletableFuture<Integer> getNumber(); @Override CompletableFuture<String> getName(); @Override CompletableFuture<Void> setName(String name); @Override CompletableFuture<Boolean> isLoaded(); @Override CompletableFuture<Boolean> isValid(); @Override CompletableFuture<VimCoords> getMark(String name); @Override CompletableFuture<Object> getChangedTick(); @Override CompletableFuture<List<VimKeyMap>> getKeymap(String mode); @Override CompletableFuture<Void> setKeymap(String mode, String lhs, String rhs, Map<String, Boolean> options); @Override CompletableFuture<Void> deleteKeymap(String mode, String lhs); @Override CompletableFuture<Integer> addHighlight(int srcId, String hlGroup, int line, int colStart, int colEnd); @Override CompletableFuture<Void> clearHighlight(int srcId, int lineStart, int lineEnd); @Override CompletableFuture<Void> clearNamespace(int namespaceId, int lineStart, int lineEnd); @Override CompletableFuture<Integer> setVirtualText(int namespaceId, int line, List<HighlightedText> chunks, Map optionalParams); @Override CompletableFuture<Boolean> attach(boolean loadFullBufferOnStart, Map opts); @Override CompletableFuture<Boolean> detach(); @Override CompletableFuture<Map<String, CommandInfo>> getCommands(GetCommandsOptions commandsOptions); @Override String toString(); }
BufferStreamApi extends BaseStreamApi implements NeovimBufferApi { @Override public CompletableFuture<VimCoords> getMark(String name) { return sendWithResponseOfType(prepareMessage(GET_MARK).addArgument(name), VimCoords.class); } BufferStreamApi(ReactiveRpcStreamer reactiveRpcStreamer,
                           Buffer model); @Override Buffer get(); @Override CompletableFuture<Integer> getLineCount(); @Override CompletableFuture<List<String>> getLines(int start, int end, boolean strictIndexing); @Override CompletableFuture<Void> setLines(int start, int end, boolean strictIndexing, List<String> replacement); @Override CompletableFuture<Integer> getOffset(int index); @Override CompletableFuture<Object> getVar(String name); @Override CompletableFuture<Void> deleteVar(String name); @Override CompletableFuture<Void> setVar(String name, Object value); @Override CompletableFuture<Object> getOption(String name); @Override CompletableFuture<Void> setOption(String name, Object value); @Override CompletableFuture<Integer> getNumber(); @Override CompletableFuture<String> getName(); @Override CompletableFuture<Void> setName(String name); @Override CompletableFuture<Boolean> isLoaded(); @Override CompletableFuture<Boolean> isValid(); @Override CompletableFuture<VimCoords> getMark(String name); @Override CompletableFuture<Object> getChangedTick(); @Override CompletableFuture<List<VimKeyMap>> getKeymap(String mode); @Override CompletableFuture<Void> setKeymap(String mode, String lhs, String rhs, Map<String, Boolean> options); @Override CompletableFuture<Void> deleteKeymap(String mode, String lhs); @Override CompletableFuture<Integer> addHighlight(int srcId, String hlGroup, int line, int colStart, int colEnd); @Override CompletableFuture<Void> clearHighlight(int srcId, int lineStart, int lineEnd); @Override CompletableFuture<Void> clearNamespace(int namespaceId, int lineStart, int lineEnd); @Override CompletableFuture<Integer> setVirtualText(int namespaceId, int line, List<HighlightedText> chunks, Map optionalParams); @Override CompletableFuture<Boolean> attach(boolean loadFullBufferOnStart, Map opts); @Override CompletableFuture<Boolean> detach(); @Override CompletableFuture<Map<String, CommandInfo>> getCommands(GetCommandsOptions commandsOptions); @Override String toString();  }