@Test public void testList() throws Exception { underTest.start(); createRoutingRule("asdf1", "asdf1"); createRoutingRule("asdf2", "asdf2"); createRoutingRule("asdf3", "asdf3"); List<RoutingRule> matchers = underTest.list(); assertThat(matchers.size(), is(3)); }
@Override @Guarded(by = STARTED) public List<RoutingRule> list() { return inTx(databaseInstance).call(db -> ImmutableList.copyOf(entityAdapter.browse(db))); }
OrientRoutingRuleStore extends StateGuardLifecycleSupport implements RoutingRuleStore { @Override @Guarded(by = STARTED) public List<RoutingRule> list() { return inTx(databaseInstance).call(db -> ImmutableList.copyOf(entityAdapter.browse(db))); } }
OrientRoutingRuleStore extends StateGuardLifecycleSupport implements RoutingRuleStore { @Override @Guarded(by = STARTED) public List<RoutingRule> list() { return inTx(databaseInstance).call(db -> ImmutableList.copyOf(entityAdapter.browse(db))); } @Inject  OrientRoutingRuleStore(@Named(DatabaseInstanceNames.CONFIG) final Provider<DatabaseInstance> databaseInstance,
                                final OrientRoutingRuleEntityAdapter entityAdapter); }
OrientRoutingRuleStore extends StateGuardLifecycleSupport implements RoutingRuleStore { @Override @Guarded(by = STARTED) public List<RoutingRule> list() { return inTx(databaseInstance).call(db -> ImmutableList.copyOf(entityAdapter.browse(db))); } @Inject  OrientRoutingRuleStore(@Named(DatabaseInstanceNames.CONFIG) final Provider<DatabaseInstance> databaseInstance,
                                final OrientRoutingRuleEntityAdapter entityAdapter); @Override @Guarded(by = STARTED) RoutingRule create(final RoutingRule rule); @Override @Guarded(by = STARTED) void update(final RoutingRule rule); @Override @Guarded(by = STARTED) List<RoutingRule> list(); @Override void delete(final RoutingRule rule); @Override RoutingRule getByName(final String name); @Override RoutingRule getById(final String id); @Override RoutingRule newRoutingRule(); }
OrientRoutingRuleStore extends StateGuardLifecycleSupport implements RoutingRuleStore { @Override @Guarded(by = STARTED) public List<RoutingRule> list() { return inTx(databaseInstance).call(db -> ImmutableList.copyOf(entityAdapter.browse(db))); } @Inject  OrientRoutingRuleStore(@Named(DatabaseInstanceNames.CONFIG) final Provider<DatabaseInstance> databaseInstance,
                                final OrientRoutingRuleEntityAdapter entityAdapter); @Override @Guarded(by = STARTED) RoutingRule create(final RoutingRule rule); @Override @Guarded(by = STARTED) void update(final RoutingRule rule); @Override @Guarded(by = STARTED) List<RoutingRule> list(); @Override void delete(final RoutingRule rule); @Override RoutingRule getByName(final String name); @Override RoutingRule getById(final String id); @Override RoutingRule newRoutingRule();  }