void removeRange(RowCursor min, RowCursor max, Predicate<RowCursor> predicate, @Service BackupKelp backup, Result<Boolean> cont);
void update(RowCursor minCursor, RowCursor maxCursor, EnvKelp envKelp, UpdateKelp update, @Service BackupKelp backup, Result<Integer> result);
/** * Watch this file for changes. * * @param watch */ void watch(@Service Watch watch, Result<Cancel> result); }
/** * Watch this file for changes. * * @param watch */ Cancel watch(@Service Watch watch); }
@Service public interface DatabaseKrakenSync extends DatabaseKraken { Object execute(String sql, Object... params); ResultSetKraken query(String sql, Object... params); }
@Service("/hello") public static class Q_basicServiceImpl { public void test(Result<String> result) { result.ok("Hello World!"); } } }
@Service public static class Q_basicService { public void test(Result<String> result) { result.ok("Hello World!"); } } }
@Service public static class Q_basicServiceImpl implements Q_basicService { public void test(Result<String> result) { result.ok("Hello World!"); } } }
@Service public abstract static class Q_fooVault implements Vault<IdAsset,Q_fooBean> { @Get("/create") public abstract void createWithValue(@Query("v") String value, Result<IdAsset> result); @Get("/foo/{id}") public void get(@Path("id") Q_fooBean foo, Result<Q_fooBean> result) { foo.value(result.then()); } }
@Service public static class Q_subString { @PipeIn("pipe:///test") private void onMessage(String msg) { State.add("\nonMessage(" + msg + ")"); } } }
@Service("/bar") public static class Q_barServiceImpl { public void test(Result<String> result) { result.ok("Hello " + ServiceRef.current()); } } }
@Service public interface Q_entityVault extends Vault<IdAsset,Q_entity> { void create(String value, Result<IdAsset> id); void findByValue(String value, Result<Q_entity> result); }
@Override public void watch(@Service Watch watch, Result<Cancel> result) { _root.watch(_path, watch, result); }
@Service public static class Q_basicService { public void test(Result<String> result) { result.ok("Hello World!"); } } }
@Service("/foo") public static class Q_fooServiceImpl { public void test(Result<String> result) { result.ok("Hello " + ServiceRef.current()); } }
class QjunitSuper { @Inject @Service QjunitExtends.Q_basicService _service; }
@Service public static class Q_basicService { @Inject Q_bean _q_bean; public void test(Result<String> result) { result.ok(_q_bean.hello()); } }
@Test public void test(@Service("/hello") Q_basicService service) { ResultFuture<String> result = new ResultFuture<>(); service.test(result); Assert.assertEquals("Hello World!", result.get(1, TimeUnit.SECONDS)); }
@Test public void test(@Service("pipe:///test") PipeBrokerSync<Message<String>> pipes) { pipes.send(Message.newMessage("hello")); State.sleep(100); assertEquals("\nonMessage(hello)", State.state()); }