target
stringlengths
20
113k
src_fm
stringlengths
11
86.3k
src_fm_fc
stringlengths
21
86.4k
src_fm_fc_co
stringlengths
30
86.4k
src_fm_fc_ms
stringlengths
42
86.8k
src_fm_fc_ms_ff
stringlengths
43
86.8k
@Test public void deserializeElection_unevenOuterList() throws Exception { AddressBasedAuthorizer mockedAuthorizer = mock(AddressBasedAuthorizer.class); byte[] rlpFirstElement = RLP.encodeElement(Hex.decode("010203")); byte[] data = RLP.encodeList(rlpFirstElement); try { BridgeSerializationUtils.deserializeElection(dat...
public static ABICallElection deserializeElection(byte[] data, AddressBasedAuthorizer authorizer) { if (data == null || data.length == 0) { return new ABICallElection(authorizer); } RLPList rlpList = (RLPList) RLP.decode2(data).get(0); if (rlpList.size() % 2 != 0) { throw new RuntimeException("deserializeElection: expe...
BridgeSerializationUtils { public static ABICallElection deserializeElection(byte[] data, AddressBasedAuthorizer authorizer) { if (data == null || data.length == 0) { return new ABICallElection(authorizer); } RLPList rlpList = (RLPList) RLP.decode2(data).get(0); if (rlpList.size() % 2 != 0) { throw new RuntimeException...
BridgeSerializationUtils { public static ABICallElection deserializeElection(byte[] data, AddressBasedAuthorizer authorizer) { if (data == null || data.length == 0) { return new ABICallElection(authorizer); } RLPList rlpList = (RLPList) RLP.decode2(data).get(0); if (rlpList.size() % 2 != 0) { throw new RuntimeException...
BridgeSerializationUtils { public static ABICallElection deserializeElection(byte[] data, AddressBasedAuthorizer authorizer) { if (data == null || data.length == 0) { return new ABICallElection(authorizer); } RLPList rlpList = (RLPList) RLP.decode2(data).get(0); if (rlpList.size() % 2 != 0) { throw new RuntimeException...
BridgeSerializationUtils { public static ABICallElection deserializeElection(byte[] data, AddressBasedAuthorizer authorizer) { if (data == null || data.length == 0) { return new ABICallElection(authorizer); } RLPList rlpList = (RLPList) RLP.decode2(data).get(0); if (rlpList.size() % 2 != 0) { throw new RuntimeException...
@Test public void deserializeElection_invalidCallSpec() throws Exception { AddressBasedAuthorizer authorizer = getTestingAddressBasedAuthorizer(); byte[] rlpFirstSpec = RLP.encodeList(RLP.encode(Hex.decode("010203"))); byte[] rlpFirstVoters = RLP.encodeList(RLP.encodeElement(Hex.decode("03"))); byte[] data = RLP.encode...
public static ABICallElection deserializeElection(byte[] data, AddressBasedAuthorizer authorizer) { if (data == null || data.length == 0) { return new ABICallElection(authorizer); } RLPList rlpList = (RLPList) RLP.decode2(data).get(0); if (rlpList.size() % 2 != 0) { throw new RuntimeException("deserializeElection: expe...
BridgeSerializationUtils { public static ABICallElection deserializeElection(byte[] data, AddressBasedAuthorizer authorizer) { if (data == null || data.length == 0) { return new ABICallElection(authorizer); } RLPList rlpList = (RLPList) RLP.decode2(data).get(0); if (rlpList.size() % 2 != 0) { throw new RuntimeException...
BridgeSerializationUtils { public static ABICallElection deserializeElection(byte[] data, AddressBasedAuthorizer authorizer) { if (data == null || data.length == 0) { return new ABICallElection(authorizer); } RLPList rlpList = (RLPList) RLP.decode2(data).get(0); if (rlpList.size() % 2 != 0) { throw new RuntimeException...
BridgeSerializationUtils { public static ABICallElection deserializeElection(byte[] data, AddressBasedAuthorizer authorizer) { if (data == null || data.length == 0) { return new ABICallElection(authorizer); } RLPList rlpList = (RLPList) RLP.decode2(data).get(0); if (rlpList.size() % 2 != 0) { throw new RuntimeException...
BridgeSerializationUtils { public static ABICallElection deserializeElection(byte[] data, AddressBasedAuthorizer authorizer) { if (data == null || data.length == 0) { return new ABICallElection(authorizer); } RLPList rlpList = (RLPList) RLP.decode2(data).get(0); if (rlpList.size() % 2 != 0) { throw new RuntimeException...
@Test public void isEmpty_Bytes() { Value val = new Value(new byte[0]); assertTrue(val.isEmpty()); }
public boolean isEmpty() { if (isNull()) { return true; } if (isBytes() && asBytes().length == 0) { return true; } if (isList() && asList().isEmpty()) { return true; } if (isString() && asString().equals("")) { return true; } return false; }
Value { public boolean isEmpty() { if (isNull()) { return true; } if (isBytes() && asBytes().length == 0) { return true; } if (isList() && asList().isEmpty()) { return true; } if (isString() && asString().equals("")) { return true; } return false; } }
Value { public boolean isEmpty() { if (isNull()) { return true; } if (isBytes() && asBytes().length == 0) { return true; } if (isList() && asList().isEmpty()) { return true; } if (isString() && asString().equals("")) { return true; } return false; } Value(); Value(Object obj); }
Value { public boolean isEmpty() { if (isNull()) { return true; } if (isBytes() && asBytes().length == 0) { return true; } if (isList() && asList().isEmpty()) { return true; } if (isString() && asString().equals("")) { return true; } return false; } Value(); Value(Object obj); static Value fromRlpEncoded(byte[] data);...
Value { public boolean isEmpty() { if (isNull()) { return true; } if (isBytes() && asBytes().length == 0) { return true; } if (isList() && asList().isEmpty()) { return true; } if (isString() && asString().equals("")) { return true; } return false; } Value(); Value(Object obj); static Value fromRlpEncoded(byte[] data);...
@Test public void web3_clientVersion() throws Exception { Web3 web3 = createWeb3(); String clientVersion = web3.web3_clientVersion(); assertTrue("client version is not including rsk!", clientVersion.toLowerCase().contains("rsk")); }
@Override public String web3_clientVersion() { String clientVersion = baseClientVersion + "/" + config.projectVersion() + "/" + System.getProperty("os.name") + "/Java1.8/" + config.projectVersionModifier() + "-" + buildInfo.getBuildHash(); if (logger.isDebugEnabled()) { logger.debug("web3_clientVersion(): {}", clientVe...
Web3Impl implements Web3 { @Override public String web3_clientVersion() { String clientVersion = baseClientVersion + "/" + config.projectVersion() + "/" + System.getProperty("os.name") + "/Java1.8/" + config.projectVersionModifier() + "-" + buildInfo.getBuildHash(); if (logger.isDebugEnabled()) { logger.debug("web3_cli...
Web3Impl implements Web3 { @Override public String web3_clientVersion() { String clientVersion = baseClientVersion + "/" + config.projectVersion() + "/" + System.getProperty("os.name") + "/Java1.8/" + config.projectVersionModifier() + "-" + buildInfo.getBuildHash(); if (logger.isDebugEnabled()) { logger.debug("web3_cli...
Web3Impl implements Web3 { @Override public String web3_clientVersion() { String clientVersion = baseClientVersion + "/" + config.projectVersion() + "/" + System.getProperty("os.name") + "/Java1.8/" + config.projectVersionModifier() + "-" + buildInfo.getBuildHash(); if (logger.isDebugEnabled()) { logger.debug("web3_cli...
Web3Impl implements Web3 { @Override public String web3_clientVersion() { String clientVersion = baseClientVersion + "/" + config.projectVersion() + "/" + System.getProperty("os.name") + "/Java1.8/" + config.projectVersionModifier() + "-" + buildInfo.getBuildHash(); if (logger.isDebugEnabled()) { logger.debug("web3_cli...
@Test public void test1() throws InterruptedException { final ScheduledExecutorService executor = Executors.newSingleThreadScheduledExecutor(); try { final TransportAsync transport = new TransportAsync(executor); final Instant start = Instant.now(); executor.schedule(() -> { transport.handleConnected(); }, 100, TimeUni...
public synchronized void handleConnected() { if (!this.state) { this.state = true; fireEvent(true, this.listener); } }
TransportAsync implements Transport { public synchronized void handleConnected() { if (!this.state) { this.state = true; fireEvent(true, this.listener); } } }
TransportAsync implements Transport { public synchronized void handleConnected() { if (!this.state) { this.state = true; fireEvent(true, this.listener); } } TransportAsync(final Executor executor); }
TransportAsync implements Transport { public synchronized void handleConnected() { if (!this.state) { this.state = true; fireEvent(true, this.listener); } } TransportAsync(final Executor executor); synchronized void handleConnected(); synchronized void handleDisconnected(); @Override void state(final Consumer<Boolean> ...
TransportAsync implements Transport { public synchronized void handleConnected() { if (!this.state) { this.state = true; fireEvent(true, this.listener); } } TransportAsync(final Executor executor); synchronized void handleConnected(); synchronized void handleDisconnected(); @Override void state(final Consumer<Boolean> ...
@Test public void testEmpty2() { final Topic topic = Topic.of(Collections.emptyList()); Assert.assertNull(topic); }
public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
@Test public void testEmpty3() { final Topic topic = Topic.of((String) null); Assert.assertNull(topic); }
public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
@Test(expected = IllegalArgumentException.class) public void testEmpty4() { Topic.of("foo", "bar", null); }
public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
@Test(expected = IllegalArgumentException.class) public void testSpecial1() { Topic.of("foo", "#"); }
public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
@Test(expected = IllegalArgumentException.class) public void testSpecial2() { Topic.of("foo", "+"); }
public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
@Test(expected = IllegalArgumentException.class) public void testSpecial3() { Topic.of("foo", ""); }
public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
@Test(expected = IllegalArgumentException.class) public void testSpecial4() { Topic.of("foo", "foo/bar"); }
public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
@Test(expected = IllegalArgumentException.class) public void testSpecial4a() { Topic.of("foo", "/bar"); }
public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
@Test(expected = IllegalArgumentException.class) public void testSpecial4b() { Topic.of("foo", "foo/"); }
public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
@Test public void testSplit5() { final Topic topic = Topic.split(" Assert.assertNull(topic); }
public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); }
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } }
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } private Topic(final List<String> segments); }
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Over...
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Over...
@Test public void testSplitNull() { final Topic topic = Topic.split(null); Assert.assertNull(topic); }
public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); }
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } }
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } private Topic(final List<String> segments); }
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Over...
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Over...
@Test public void testSplitEmpty() { final Topic topic = Topic.split(""); Assert.assertNull(topic); }
public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); }
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } }
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } private Topic(final List<String> segments); }
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Over...
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Over...
@Test public void testEquals1() { final Topic t1 = Topic.split("foo/bar/baz"); final Topic t2 = Topic.split("foo/bar/baz"); assertEquals(t1, t2); }
public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); }
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } }
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } private Topic(final List<String> segments); }
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Over...
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Over...
@Test public void testNotEquals1() { final Topic t1 = Topic.split("foo/bar"); final Topic t2 = Topic.split("foo/baz"); assertNotEquals(t1, t2); }
public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); }
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } }
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } private Topic(final List<String> segments); }
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Over...
Topic { public static Topic split(String path) { if (path == null) { return null; } path = path.replaceAll("(^/+|/$)+", ""); if (path.isEmpty()) { return null; } return new Topic(Arrays.asList(path.split("\\/+"))); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Over...
@Test public void testStream() { final String result = Topic.split("foo/bar").stream().collect(Collectors.joining()); assertEquals("foobar", result); }
public Stream<String> stream() { return segments.stream(); }
Topic { public Stream<String> stream() { return segments.stream(); } }
Topic { public Stream<String> stream() { return segments.stream(); } private Topic(final List<String> segments); }
Topic { public Stream<String> stream() { return segments.stream(); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override String toString(); @Override int hashCode(); @Override boolean equals(Object obj); static Topic split(String path); static Topic of(final List<...
Topic { public Stream<String> stream() { return segments.stream(); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override String toString(); @Override int hashCode(); @Override boolean equals(Object obj); static Topic split(String path); static Topic of(final List<...
@Test public void testToString() { assertEquals("foo/bar", Topic.of("foo", "bar").toString()); }
@Override public String toString() { return String.join("/", segments); }
Topic { @Override public String toString() { return String.join("/", segments); } }
Topic { @Override public String toString() { return String.join("/", segments); } private Topic(final List<String> segments); }
Topic { @Override public String toString() { return String.join("/", segments); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override String toString(); @Override int hashCode(); @Override boolean equals(Object obj); static Topic split(String path); static Topic o...
Topic { @Override public String toString() { return String.join("/", segments); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override String toString(); @Override int hashCode(); @Override boolean equals(Object obj); static Topic split(String path); static Topic o...
@Test public void testHashCode() { final Map<Topic, Object> map = new HashMap<>(); map.put(Topic.of("foo", "bar"), 1); map.put(Topic.of("foo", "baz"), 2); assertEquals(1, map.get(Topic.split("foo/bar"))); assertEquals(2, map.get(Topic.split("foo/baz"))); }
@Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + (segments == null ? 0 : segments.hashCode()); return result; }
Topic { @Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + (segments == null ? 0 : segments.hashCode()); return result; } }
Topic { @Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + (segments == null ? 0 : segments.hashCode()); return result; } private Topic(final List<String> segments); }
Topic { @Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + (segments == null ? 0 : segments.hashCode()); return result; } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override String toString(); @Override int hashCode()...
Topic { @Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + (segments == null ? 0 : segments.hashCode()); return result; } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override String toString(); @Override int hashCode()...
@Test(expected = NullPointerException.class) public void testNull1() { Payload.of((String) null, null); }
public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); }
Payload { public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); } }
Payload { public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); } private Payload(final Instant timestamp, final Map<String, ?> values, final boolean cloneValues); }
Payload { public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); } private Payload(final Instant timestamp, final Map<String, ?> values, final boolean cloneValues); Instant getTimestamp(); Map<String, ?> getValues(); @Ov...
Payload { public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); } private Payload(final Instant timestamp, final Map<String, ?> values, final boolean cloneValues); Instant getTimestamp(); Map<String, ?> getValues(); @Ov...
@Test(expected = NullPointerException.class) public void testNull2() { Payload.of(null); }
public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); }
Payload { public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); } }
Payload { public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); } private Payload(final Instant timestamp, final Map<String, ?> values, final boolean cloneValues); }
Payload { public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); } private Payload(final Instant timestamp, final Map<String, ?> values, final boolean cloneValues); Instant getTimestamp(); Map<String, ?> getValues(); @Ov...
Payload { public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); } private Payload(final Instant timestamp, final Map<String, ?> values, final boolean cloneValues); Instant getTimestamp(); Map<String, ?> getValues(); @Ov...
@Test(expected = NullPointerException.class) public void testNull3() { Payload.of(null, null, null); }
public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); }
Payload { public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); } }
Payload { public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); } private Payload(final Instant timestamp, final Map<String, ?> values, final boolean cloneValues); }
Payload { public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); } private Payload(final Instant timestamp, final Map<String, ?> values, final boolean cloneValues); Instant getTimestamp(); Map<String, ?> getValues(); @Ov...
Payload { public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); } private Payload(final Instant timestamp, final Map<String, ?> values, final boolean cloneValues); Instant getTimestamp(); Map<String, ?> getValues(); @Ov...
@Test(expected = NullPointerException.class) public void testNull4() { Payload.of((Instant) null, null); }
public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); }
Payload { public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); } }
Payload { public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); } private Payload(final Instant timestamp, final Map<String, ?> values, final boolean cloneValues); }
Payload { public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); } private Payload(final Instant timestamp, final Map<String, ?> values, final boolean cloneValues); Instant getTimestamp(); Map<String, ?> getValues(); @Ov...
Payload { public static Payload of(final String key, final Object value) { Objects.requireNonNull(key); return new Payload(now(), singletonMap(key, value), false); } private Payload(final Instant timestamp, final Map<String, ?> values, final boolean cloneValues); Instant getTimestamp(); Map<String, ?> getValues(); @Ov...
@Test public void testNull1() { final UserAndPassword c = Credentials.userAndPassword(null, (char[]) null); Assert.assertNull(c.getUsername()); Assert.assertNull(c.getPassword()); Assert.assertNull(c.getPasswordAsString()); }
public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); }
Credentials { public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); } }
Credentials { public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); } private Credentials(); }
Credentials { public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); } private Credentials(); static UserAndPassword userAndPassword(final String username, final String password); static UserA...
Credentials { public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); } private Credentials(); static UserAndPassword userAndPassword(final String username, final String password); static UserA...
@Test public void testNull2() { final UserAndPassword c = Credentials.userAndPassword(null, (String) null); Assert.assertNull(c.getUsername()); Assert.assertNull(c.getPassword()); Assert.assertNull(c.getPasswordAsString()); }
public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); }
Credentials { public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); } }
Credentials { public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); } private Credentials(); }
Credentials { public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); } private Credentials(); static UserAndPassword userAndPassword(final String username, final String password); static UserA...
Credentials { public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); } private Credentials(); static UserAndPassword userAndPassword(final String username, final String password); static UserA...
@Test public void testNonNull1() { final UserAndPassword c = Credentials.userAndPassword("user", "password".toCharArray()); Assert.assertNotNull(c.getUsername()); Assert.assertNotNull(c.getPassword()); Assert.assertNotNull(c.getPasswordAsString()); }
public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); }
Credentials { public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); } }
Credentials { public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); } private Credentials(); }
Credentials { public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); } private Credentials(); static UserAndPassword userAndPassword(final String username, final String password); static UserA...
Credentials { public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); } private Credentials(); static UserAndPassword userAndPassword(final String username, final String password); static UserA...
@Test public void testNonNull2() { final UserAndPassword c = Credentials.userAndPassword("user", "password"); Assert.assertNotNull(c.getUsername()); Assert.assertNotNull(c.getPassword()); Assert.assertNotNull(c.getPasswordAsString()); }
public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); }
Credentials { public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); } }
Credentials { public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); } private Credentials(); }
Credentials { public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); } private Credentials(); static UserAndPassword userAndPassword(final String username, final String password); static UserA...
Credentials { public static UserAndPassword userAndPassword(final String username, final String password) { return new UserAndPassword(username, password != null ? password.toCharArray() : null); } private Credentials(); static UserAndPassword userAndPassword(final String username, final String password); static UserA...
@Test public void test1() { Errors.ignore().handleError(new Exception(), Optional.empty()); }
public static ErrorHandler<RuntimeException> ignore() { return IGNORE; }
Errors { public static ErrorHandler<RuntimeException> ignore() { return IGNORE; } }
Errors { public static ErrorHandler<RuntimeException> ignore() { return IGNORE; } private Errors(); }
Errors { public static ErrorHandler<RuntimeException> ignore() { return IGNORE; } private Errors(); static ErrorHandler<RuntimeException> ignore(); static ErrorHandler<RuntimeException> handle(final BiConsumer<Throwable, Optional<Payload>> handler); static void ignore(final Throwable e, final Optional<Payload> payload...
Errors { public static ErrorHandler<RuntimeException> ignore() { return IGNORE; } private Errors(); static ErrorHandler<RuntimeException> ignore(); static ErrorHandler<RuntimeException> handle(final BiConsumer<Throwable, Optional<Payload>> handler); static void ignore(final Throwable e, final Optional<Payload> payload...
@Test public void test2() { Errors.handle((error, payload) -> { }).handleError(new Exception(), Optional.empty()); }
public static ErrorHandler<RuntimeException> handle(final BiConsumer<Throwable, Optional<Payload>> handler) { return new ErrorHandler<RuntimeException>() { @Override public void handleError(final Throwable e, final Optional<Payload> payload) throws RuntimeException { handler.accept(e, payload); } }; }
Errors { public static ErrorHandler<RuntimeException> handle(final BiConsumer<Throwable, Optional<Payload>> handler) { return new ErrorHandler<RuntimeException>() { @Override public void handleError(final Throwable e, final Optional<Payload> payload) throws RuntimeException { handler.accept(e, payload); } }; } }
Errors { public static ErrorHandler<RuntimeException> handle(final BiConsumer<Throwable, Optional<Payload>> handler) { return new ErrorHandler<RuntimeException>() { @Override public void handleError(final Throwable e, final Optional<Payload> payload) throws RuntimeException { handler.accept(e, payload); } }; } private ...
Errors { public static ErrorHandler<RuntimeException> handle(final BiConsumer<Throwable, Optional<Payload>> handler) { return new ErrorHandler<RuntimeException>() { @Override public void handleError(final Throwable e, final Optional<Payload> payload) throws RuntimeException { handler.accept(e, payload); } }; } private ...
Errors { public static ErrorHandler<RuntimeException> handle(final BiConsumer<Throwable, Optional<Payload>> handler) { return new ErrorHandler<RuntimeException>() { @Override public void handleError(final Throwable e, final Optional<Payload> payload) throws RuntimeException { handler.accept(e, payload); } }; } private ...
@Test public void test3() { Errors.handle(Errors::ignore).handleError(new Exception(), Optional.empty()); }
public static ErrorHandler<RuntimeException> handle(final BiConsumer<Throwable, Optional<Payload>> handler) { return new ErrorHandler<RuntimeException>() { @Override public void handleError(final Throwable e, final Optional<Payload> payload) throws RuntimeException { handler.accept(e, payload); } }; }
Errors { public static ErrorHandler<RuntimeException> handle(final BiConsumer<Throwable, Optional<Payload>> handler) { return new ErrorHandler<RuntimeException>() { @Override public void handleError(final Throwable e, final Optional<Payload> payload) throws RuntimeException { handler.accept(e, payload); } }; } }
Errors { public static ErrorHandler<RuntimeException> handle(final BiConsumer<Throwable, Optional<Payload>> handler) { return new ErrorHandler<RuntimeException>() { @Override public void handleError(final Throwable e, final Optional<Payload> payload) throws RuntimeException { handler.accept(e, payload); } }; } private ...
Errors { public static ErrorHandler<RuntimeException> handle(final BiConsumer<Throwable, Optional<Payload>> handler) { return new ErrorHandler<RuntimeException>() { @Override public void handleError(final Throwable e, final Optional<Payload> payload) throws RuntimeException { handler.accept(e, payload); } }; } private ...
Errors { public static ErrorHandler<RuntimeException> handle(final BiConsumer<Throwable, Optional<Payload>> handler) { return new ErrorHandler<RuntimeException>() { @Override public void handleError(final Throwable e, final Optional<Payload> payload) throws RuntimeException { handler.accept(e, payload); } }; } private ...
@Test public void testEmpty1() { final Topic topic = Topic.of((List<String>) null); Assert.assertNull(topic); }
public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); }
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
Topic { public static Topic of(final List<String> segments) { if (segments == null || segments.isEmpty()) { return null; } segments.forEach(Topic::ensureNotSpecial); return new Topic(new ArrayList<>(segments)); } private Topic(final List<String> segments); List<String> getSegments(); Stream<String> stream(); @Override...
@Test public void givenSslEnabledInConfiguration_whenHttpsPortIsMissingInConfiguration_thenShouldUseDefaultHttpsPort() throws Exception { configuration.put(SSL_CONFIGURATION_KEY, TRUE); configuration.remove(HTTPS_PORT); configureServer(); assertThat(options.getPort()).isEqualTo(DEFAULT_HTTPS_PORT); }
private int getPort(ServerConfiguration configuration) { return configuration.getInteger(ConfigKies.HTTPS_PORT, ConfigKies.DEFAULT_HTTPS_PORT); }
JksServerConfigurator implements HttpServerConfigurator { private int getPort(ServerConfiguration configuration) { return configuration.getInteger(ConfigKies.HTTPS_PORT, ConfigKies.DEFAULT_HTTPS_PORT); } }
JksServerConfigurator implements HttpServerConfigurator { private int getPort(ServerConfiguration configuration) { return configuration.getInteger(ConfigKies.HTTPS_PORT, ConfigKies.DEFAULT_HTTPS_PORT); } }
JksServerConfigurator implements HttpServerConfigurator { private int getPort(ServerConfiguration configuration) { return configuration.getInteger(ConfigKies.HTTPS_PORT, ConfigKies.DEFAULT_HTTPS_PORT); } @Override void configureHttpServer(VertxContext context, HttpServerOptions options); }
JksServerConfigurator implements HttpServerConfigurator { private int getPort(ServerConfiguration configuration) { return configuration.getInteger(ConfigKies.HTTPS_PORT, ConfigKies.DEFAULT_HTTPS_PORT); } @Override void configureHttpServer(VertxContext context, HttpServerOptions options); }
@Test public void givenServiceDiscovery_whenPublishHttpServiceAndAskingForItsWebClientByJsonWithConfiguration_thenShouldGetTheClient(TestContext context) throws Exception { publishHttpEndpoint(httpEndpointConfiguration.metadata(metadata)); getWebClient(jsonFilter, metadata, context.asyncAssertSuccess(Assert::assertNotN...
public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); }
HttpServiceDiscovery { public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); } }
HttpServiceDiscovery { public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); }
HttpServiceDiscovery { public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(HttpEndpointConfiguration configuration, Handler<AsyncResult<...
HttpServiceDiscovery { public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(HttpEndpointConfiguration configuration, Handler<AsyncResult<...
@Test public void givenServiceDiscovery_whenPublishingMessageSourceAndAskingForItsConsumer_thenShouldGetTheConsumer(TestContext context) throws Exception { publishMessageSourceService(messageSourceConfiguration); vertxServiceDiscovery.messageSource().getConsumer(record -> record.getName().equals(SERVICE_NAME), context....
public <T> void getConsumer(Function<Record, Boolean> filter, Handler<AsyncResult<MessageConsumer<T>>> handler) { MessageSource.getConsumer(serviceDiscovery, filter, handler); }
MessageSourceServiceDiscovery { public <T> void getConsumer(Function<Record, Boolean> filter, Handler<AsyncResult<MessageConsumer<T>>> handler) { MessageSource.getConsumer(serviceDiscovery, filter, handler); } }
MessageSourceServiceDiscovery { public <T> void getConsumer(Function<Record, Boolean> filter, Handler<AsyncResult<MessageConsumer<T>>> handler) { MessageSource.getConsumer(serviceDiscovery, filter, handler); } MessageSourceServiceDiscovery(ServiceDiscovery serviceDiscovery); }
MessageSourceServiceDiscovery { public <T> void getConsumer(Function<Record, Boolean> filter, Handler<AsyncResult<MessageConsumer<T>>> handler) { MessageSource.getConsumer(serviceDiscovery, filter, handler); } MessageSourceServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(MessageSourceConfiguration conf...
MessageSourceServiceDiscovery { public <T> void getConsumer(Function<Record, Boolean> filter, Handler<AsyncResult<MessageConsumer<T>>> handler) { MessageSource.getConsumer(serviceDiscovery, filter, handler); } MessageSourceServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(MessageSourceConfiguration conf...
@Test public void givenServiceDiscovery_whenPublishingMessageSourceAndAskingForItsConsumerByJson_thenShouldGetTheConsumer(TestContext context) throws Exception { publishMessageSourceService(messageSourceConfiguration); vertxServiceDiscovery.messageSource().getConsumer(new JsonObject().put("name", SERVICE_NAME), context...
public <T> void getConsumer(Function<Record, Boolean> filter, Handler<AsyncResult<MessageConsumer<T>>> handler) { MessageSource.getConsumer(serviceDiscovery, filter, handler); }
MessageSourceServiceDiscovery { public <T> void getConsumer(Function<Record, Boolean> filter, Handler<AsyncResult<MessageConsumer<T>>> handler) { MessageSource.getConsumer(serviceDiscovery, filter, handler); } }
MessageSourceServiceDiscovery { public <T> void getConsumer(Function<Record, Boolean> filter, Handler<AsyncResult<MessageConsumer<T>>> handler) { MessageSource.getConsumer(serviceDiscovery, filter, handler); } MessageSourceServiceDiscovery(ServiceDiscovery serviceDiscovery); }
MessageSourceServiceDiscovery { public <T> void getConsumer(Function<Record, Boolean> filter, Handler<AsyncResult<MessageConsumer<T>>> handler) { MessageSource.getConsumer(serviceDiscovery, filter, handler); } MessageSourceServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(MessageSourceConfiguration conf...
MessageSourceServiceDiscovery { public <T> void getConsumer(Function<Record, Boolean> filter, Handler<AsyncResult<MessageConsumer<T>>> handler) { MessageSource.getConsumer(serviceDiscovery, filter, handler); } MessageSourceServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(MessageSourceConfiguration conf...
@Test public void givenServiceDiscovery_whenPublishingRedisDataSourceAndAskingForItsClient_thenShouldGetTheClient(TestContext context) throws Exception { publishRedisDataSourceService(dataSourceConfiguration); vertxServiceDiscovery.redis().getClient(filter(), context.asyncAssertSuccess()); }
public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); }
RedisServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); } }
RedisServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); } RedisServiceDiscovery(ServiceDiscovery serviceDiscovery); }
RedisServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); } RedisServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<A...
RedisServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); } RedisServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<A...
@Test public void givenServiceDiscovery_whenPublishingRedisDataAndAskingForItsClientWithConfiguration_thenShouldGetTheClient(TestContext context) throws Exception { publishRedisDataSourceService(dataSourceConfiguration.metadata(metadata)); vertxServiceDiscovery.redis().getClient(filter(), metadata, context.asyncAssertS...
public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); }
RedisServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); } }
RedisServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); } RedisServiceDiscovery(ServiceDiscovery serviceDiscovery); }
RedisServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); } RedisServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<A...
RedisServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); } RedisServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<A...
@Test public void givenServiceDiscovery_whenPublishingRedisDataAndAskingForItsClientByJson_thenShouldGetTheClient(TestContext context) throws Exception { publishRedisDataSourceService(dataSourceConfiguration); vertxServiceDiscovery.redis().getClient(jsonFilter, context.asyncAssertSuccess()); }
public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); }
RedisServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); } }
RedisServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); } RedisServiceDiscovery(ServiceDiscovery serviceDiscovery); }
RedisServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); } RedisServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<A...
RedisServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); } RedisServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<A...
@Test public void givenServiceDiscovery_whenPublishingRedisDataAndAskingForItsClientByJsonWithConfiguration_thenShouldGetTheClient(TestContext context) throws Exception { publishRedisDataSourceService(dataSourceConfiguration.metadata(metadata)); vertxServiceDiscovery.redis().getClient(jsonFilter, metadata, context.asyn...
public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); }
RedisServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); } }
RedisServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); } RedisServiceDiscovery(ServiceDiscovery serviceDiscovery); }
RedisServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); } RedisServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<A...
RedisServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<RedisClient>> handler) { RedisDataSource.getRedisClient(serviceDiscovery, filter, handler); } RedisServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<A...
@Test public void givenServiceDiscovery_whenPublishEventBusServiceAndAskingForItsProxy_thenShouldGetTheService(TestContext context) throws Exception { publishEventBusService(eventBusConfiguration); vertxServiceDiscovery.eventBus().getProxy(TestService.class, context.asyncAssertSuccess(Assert::assertNotNull)); }
public <T> void getProxy(Class<T> serviceClass, Handler<AsyncResult<T>> handler) { EventBusService.getProxy(serviceDiscovery, serviceClass, handler); }
EventBusServiceDiscovery { public <T> void getProxy(Class<T> serviceClass, Handler<AsyncResult<T>> handler) { EventBusService.getProxy(serviceDiscovery, serviceClass, handler); } }
EventBusServiceDiscovery { public <T> void getProxy(Class<T> serviceClass, Handler<AsyncResult<T>> handler) { EventBusService.getProxy(serviceDiscovery, serviceClass, handler); } EventBusServiceDiscovery(ServiceDiscovery serviceDiscovery); }
EventBusServiceDiscovery { public <T> void getProxy(Class<T> serviceClass, Handler<AsyncResult<T>> handler) { EventBusService.getProxy(serviceDiscovery, serviceClass, handler); } EventBusServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(EventBusServiceConfiguration configuration, Handler<AsyncResult<Rec...
EventBusServiceDiscovery { public <T> void getProxy(Class<T> serviceClass, Handler<AsyncResult<T>> handler) { EventBusService.getProxy(serviceDiscovery, serviceClass, handler); } EventBusServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(EventBusServiceConfiguration configuration, Handler<AsyncResult<Rec...
@Test public void givenServiceDiscovery_whenPublishEventBusServiceAndAskingForItsServiceProxy_thenShouldGetTheService(TestContext context) throws Exception { publishEventBusService(eventBusConfiguration); vertxServiceDiscovery.eventBus().getServiceProxy(record -> record.getName().equals(SERVICE_NAME), TestService.class...
public <T> void getServiceProxy(Function<Record, Boolean> filter, Class<T> serviceClass, Handler<AsyncResult<T>> handler) { EventBusService.getServiceProxy(serviceDiscovery, filter, serviceClass, handler); }
EventBusServiceDiscovery { public <T> void getServiceProxy(Function<Record, Boolean> filter, Class<T> serviceClass, Handler<AsyncResult<T>> handler) { EventBusService.getServiceProxy(serviceDiscovery, filter, serviceClass, handler); } }
EventBusServiceDiscovery { public <T> void getServiceProxy(Function<Record, Boolean> filter, Class<T> serviceClass, Handler<AsyncResult<T>> handler) { EventBusService.getServiceProxy(serviceDiscovery, filter, serviceClass, handler); } EventBusServiceDiscovery(ServiceDiscovery serviceDiscovery); }
EventBusServiceDiscovery { public <T> void getServiceProxy(Function<Record, Boolean> filter, Class<T> serviceClass, Handler<AsyncResult<T>> handler) { EventBusService.getServiceProxy(serviceDiscovery, filter, serviceClass, handler); } EventBusServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(EventBusSer...
EventBusServiceDiscovery { public <T> void getServiceProxy(Function<Record, Boolean> filter, Class<T> serviceClass, Handler<AsyncResult<T>> handler) { EventBusService.getServiceProxy(serviceDiscovery, filter, serviceClass, handler); } EventBusServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(EventBusSer...
@Test public void givenServiceDiscovery_whenPublishEventBusServiceAndAskingForItsServiceProxyByJson_thenShouldGetTheService(TestContext context) throws Exception { publishEventBusService(eventBusConfiguration); vertxServiceDiscovery.eventBus().getServiceProxy(jsonFilter, TestService.class, context.asyncAssertSuccess(As...
public <T> void getServiceProxy(Function<Record, Boolean> filter, Class<T> serviceClass, Handler<AsyncResult<T>> handler) { EventBusService.getServiceProxy(serviceDiscovery, filter, serviceClass, handler); }
EventBusServiceDiscovery { public <T> void getServiceProxy(Function<Record, Boolean> filter, Class<T> serviceClass, Handler<AsyncResult<T>> handler) { EventBusService.getServiceProxy(serviceDiscovery, filter, serviceClass, handler); } }
EventBusServiceDiscovery { public <T> void getServiceProxy(Function<Record, Boolean> filter, Class<T> serviceClass, Handler<AsyncResult<T>> handler) { EventBusService.getServiceProxy(serviceDiscovery, filter, serviceClass, handler); } EventBusServiceDiscovery(ServiceDiscovery serviceDiscovery); }
EventBusServiceDiscovery { public <T> void getServiceProxy(Function<Record, Boolean> filter, Class<T> serviceClass, Handler<AsyncResult<T>> handler) { EventBusService.getServiceProxy(serviceDiscovery, filter, serviceClass, handler); } EventBusServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(EventBusSer...
EventBusServiceDiscovery { public <T> void getServiceProxy(Function<Record, Boolean> filter, Class<T> serviceClass, Handler<AsyncResult<T>> handler) { EventBusService.getServiceProxy(serviceDiscovery, filter, serviceClass, handler); } EventBusServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(EventBusSer...
@Test public void givenSslEnabledInConfiguration_whenHttpsPortIsSetInConfiguration_thenShouldUsePortFromConfiguration() throws Exception { configuration.put(SSL_CONFIGURATION_KEY, TRUE); configuration.put(HTTPS_PORT, DEFAULT_TEST_SSL_PORT); configureServer(); assertThat(options.getPort()).isEqualTo(DEFAULT_TEST_SSL_POR...
private int getPort(ServerConfiguration configuration) { return configuration.getInteger(ConfigKies.HTTPS_PORT, ConfigKies.DEFAULT_HTTPS_PORT); }
JksServerConfigurator implements HttpServerConfigurator { private int getPort(ServerConfiguration configuration) { return configuration.getInteger(ConfigKies.HTTPS_PORT, ConfigKies.DEFAULT_HTTPS_PORT); } }
JksServerConfigurator implements HttpServerConfigurator { private int getPort(ServerConfiguration configuration) { return configuration.getInteger(ConfigKies.HTTPS_PORT, ConfigKies.DEFAULT_HTTPS_PORT); } }
JksServerConfigurator implements HttpServerConfigurator { private int getPort(ServerConfiguration configuration) { return configuration.getInteger(ConfigKies.HTTPS_PORT, ConfigKies.DEFAULT_HTTPS_PORT); } @Override void configureHttpServer(VertxContext context, HttpServerOptions options); }
JksServerConfigurator implements HttpServerConfigurator { private int getPort(ServerConfiguration configuration) { return configuration.getInteger(ConfigKies.HTTPS_PORT, ConfigKies.DEFAULT_HTTPS_PORT); } @Override void configureHttpServer(VertxContext context, HttpServerOptions options); }
@Test public void givenServiceDiscovery_whenPublishingMessageSourceAndAskingForItsClient_thenShouldGetTheClient(TestContext context) throws Exception { publishJDBCDataSourceService(dataSourceConfiguration); vertxServiceDiscovery.jdbc().getClient(filter(), context.asyncAssertSuccess()); }
public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); }
JDBCServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); } }
JDBCServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); } JDBCServiceDiscovery(ServiceDiscovery serviceDiscovery); }
JDBCServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); } JDBCServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<AsyncR...
JDBCServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); } JDBCServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<AsyncR...
@Test public void givenServiceDiscovery_whenPublishingMessageSourceAndAskingForItsClientWithConfiguration_thenShouldGetTheClient(TestContext context) throws Exception { publishJDBCDataSourceService(dataSourceConfiguration.metadata(metadata)); vertxServiceDiscovery.jdbc().getClient(filter(), metadata, context.asyncAsser...
public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); }
JDBCServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); } }
JDBCServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); } JDBCServiceDiscovery(ServiceDiscovery serviceDiscovery); }
JDBCServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); } JDBCServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<AsyncR...
JDBCServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); } JDBCServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<AsyncR...
@Test public void givenServiceDiscovery_whenPublishingMessageSourceAndAskingForItsClientByJson_thenShouldGetTheClient(TestContext context) throws Exception { publishJDBCDataSourceService(dataSourceConfiguration); vertxServiceDiscovery.jdbc().getClient(jsonFilter, context.asyncAssertSuccess()); }
public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); }
JDBCServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); } }
JDBCServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); } JDBCServiceDiscovery(ServiceDiscovery serviceDiscovery); }
JDBCServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); } JDBCServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<AsyncR...
JDBCServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); } JDBCServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<AsyncR...
@Test public void givenServiceDiscovery_whenPublishingMessageSourceAndAskingForItsClientByJsonWithConfiguration_thenShouldGetTheClient(TestContext context) throws Exception { publishJDBCDataSourceService(dataSourceConfiguration.metadata(metadata)); vertxServiceDiscovery.jdbc().getClient(jsonFilter, metadata, context.as...
public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); }
JDBCServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); } }
JDBCServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); } JDBCServiceDiscovery(ServiceDiscovery serviceDiscovery); }
JDBCServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); } JDBCServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<AsyncR...
JDBCServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<JDBCClient>> handler) { JDBCDataSource.getJDBCClient(serviceDiscovery, filter, handler); } JDBCServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<AsyncR...
@Test public void givenServiceDiscovery_whenPublishingRedisDataSourceAndAskingForItsClient_thenShouldGetTheClient(TestContext context) throws Exception { publishMongoDataSourceService(dataSourceConfiguration); vertxServiceDiscovery.mongo().getClient(filter(), context.asyncAssertSuccess()); }
public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<MongoClient>> handler) { MongoDataSource.getMongoClient(serviceDiscovery, filter, handler); }
MongoServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<MongoClient>> handler) { MongoDataSource.getMongoClient(serviceDiscovery, filter, handler); } }
MongoServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<MongoClient>> handler) { MongoDataSource.getMongoClient(serviceDiscovery, filter, handler); } MongoServiceDiscovery(ServiceDiscovery serviceDiscovery); }
MongoServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<MongoClient>> handler) { MongoDataSource.getMongoClient(serviceDiscovery, filter, handler); } MongoServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<A...
MongoServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<MongoClient>> handler) { MongoDataSource.getMongoClient(serviceDiscovery, filter, handler); } MongoServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<A...
@Test public void givenServiceDiscovery_whenPublishingRedisDataAndAskingForItsClientByJson_thenShouldGetTheClient(TestContext context) throws Exception { publishMongoDataSourceService(dataSourceConfiguration); vertxServiceDiscovery.mongo().getClient(jsonFilter, context.asyncAssertSuccess()); }
public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<MongoClient>> handler) { MongoDataSource.getMongoClient(serviceDiscovery, filter, handler); }
MongoServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<MongoClient>> handler) { MongoDataSource.getMongoClient(serviceDiscovery, filter, handler); } }
MongoServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<MongoClient>> handler) { MongoDataSource.getMongoClient(serviceDiscovery, filter, handler); } MongoServiceDiscovery(ServiceDiscovery serviceDiscovery); }
MongoServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<MongoClient>> handler) { MongoDataSource.getMongoClient(serviceDiscovery, filter, handler); } MongoServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<A...
MongoServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<MongoClient>> handler) { MongoDataSource.getMongoClient(serviceDiscovery, filter, handler); } MongoServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<A...
@Test public void givenServiceDiscovery_whenPublishingRedisDataAndAskingForItsClientByJsonWithConfiguration_thenShouldGetTheClient(TestContext context) throws Exception { publishMongoDataSourceService(dataSourceConfiguration.metadata(metadata)); vertxServiceDiscovery.mongo().getClient(jsonFilter, metadata, context.asyn...
public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<MongoClient>> handler) { MongoDataSource.getMongoClient(serviceDiscovery, filter, handler); }
MongoServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<MongoClient>> handler) { MongoDataSource.getMongoClient(serviceDiscovery, filter, handler); } }
MongoServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<MongoClient>> handler) { MongoDataSource.getMongoClient(serviceDiscovery, filter, handler); } MongoServiceDiscovery(ServiceDiscovery serviceDiscovery); }
MongoServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<MongoClient>> handler) { MongoDataSource.getMongoClient(serviceDiscovery, filter, handler); } MongoServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<A...
MongoServiceDiscovery { public void getClient(Function<Record, Boolean> filter, Handler<AsyncResult<MongoClient>> handler) { MongoDataSource.getMongoClient(serviceDiscovery, filter, handler); } MongoServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(DataSourceServiceConfiguration configuration, Handler<A...
@Test public void givenServiceDiscovery_whenPublishingRecord_thenTheRecordShouldBePublished(TestContext context) throws Exception { vertxServiceDiscovery.publishRecord(record, context.asyncAssertSuccess()); }
public void publishRecord(Record record, Handler<AsyncResult<Record>> handler) { serviceDiscovery.publish(record, handler); }
VertxServiceDiscovery { public void publishRecord(Record record, Handler<AsyncResult<Record>> handler) { serviceDiscovery.publish(record, handler); } }
VertxServiceDiscovery { public void publishRecord(Record record, Handler<AsyncResult<Record>> handler) { serviceDiscovery.publish(record, handler); } VertxServiceDiscovery(Vertx vertx); }
VertxServiceDiscovery { public void publishRecord(Record record, Handler<AsyncResult<Record>> handler) { serviceDiscovery.publish(record, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServiceDiscovery m...
VertxServiceDiscovery { public void publishRecord(Record record, Handler<AsyncResult<Record>> handler) { serviceDiscovery.publish(record, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServiceDiscovery m...
@Test(expected = InvalidFilterException.class) public void givenServiceDiscovery_whenLookupForARecordWithNullFilter_thenShouldThrowException() throws Exception { lookup(null, ar -> { }); }
public void lookup(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, false, handler); }
VertxServiceDiscovery { public void lookup(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, false, handler); } }
VertxServiceDiscovery { public void lookup(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, false, handler); } VertxServiceDiscovery(Vertx vertx); }
VertxServiceDiscovery { public void lookup(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, false, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServiceDiscovery ...
VertxServiceDiscovery { public void lookup(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, false, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServiceDiscovery ...
@Test public void givenServiceDiscovery_whenLookupForARecordUnmatchingPredicate_thenShouldGetNullRecord(TestContext context) throws Exception { publishTestRecord(record); lookup(r -> r.getName().equals(NOT_EXISTED_NAME), context.asyncAssertSuccess(context::assertNull)); }
public void lookup(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, false, handler); }
VertxServiceDiscovery { public void lookup(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, false, handler); } }
VertxServiceDiscovery { public void lookup(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, false, handler); } VertxServiceDiscovery(Vertx vertx); }
VertxServiceDiscovery { public void lookup(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, false, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServiceDiscovery ...
VertxServiceDiscovery { public void lookup(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, false, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServiceDiscovery ...
@Test public void givenSslEnabledInConfigurationWithJksPathAndPassword_whenConfiguringServer_thenHttpOptionSslShouldBeEnabledAndConfiguredWithThePathAndPassword() throws Exception { configuration.put(SSL_CONFIGURATION_KEY, TRUE); configureServer(); assertThat(options.isSsl()).isTrue(); assertThat(options.getKeyStoreOpt...
private String getPath(ServerConfiguration configuration) { return configuration.getString(ConfigKies.SSL_JKS_PATH); }
JksServerConfigurator implements HttpServerConfigurator { private String getPath(ServerConfiguration configuration) { return configuration.getString(ConfigKies.SSL_JKS_PATH); } }
JksServerConfigurator implements HttpServerConfigurator { private String getPath(ServerConfiguration configuration) { return configuration.getString(ConfigKies.SSL_JKS_PATH); } }
JksServerConfigurator implements HttpServerConfigurator { private String getPath(ServerConfiguration configuration) { return configuration.getString(ConfigKies.SSL_JKS_PATH); } @Override void configureHttpServer(VertxContext context, HttpServerOptions options); }
JksServerConfigurator implements HttpServerConfigurator { private String getPath(ServerConfiguration configuration) { return configuration.getString(ConfigKies.SSL_JKS_PATH); } @Override void configureHttpServer(VertxContext context, HttpServerOptions options); }
@Test public void givenServiceDiscovery_whenLookupForARecordMatchingPredicate_thenShouldGetTheRecord(TestContext context) throws Exception { publishTestRecord(record); lookup(r -> r.getName().equals(SERVICE_NAME), context.asyncAssertSuccess(record -> { context.assertEquals(SERVICE_NAME, record.getName()); })); }
public void lookup(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, false, handler); }
VertxServiceDiscovery { public void lookup(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, false, handler); } }
VertxServiceDiscovery { public void lookup(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, false, handler); } VertxServiceDiscovery(Vertx vertx); }
VertxServiceDiscovery { public void lookup(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, false, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServiceDiscovery ...
VertxServiceDiscovery { public void lookup(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, false, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServiceDiscovery ...
@Test(expected = InvalidFilterException.class) public void givenServiceDiscovery_whenLookupForARecordIncludingOutOfServicePassingNullFilter_thenShouldThrowException(TestContext context) throws Exception { lookupIncludeOutOfService(null, ar -> { }); }
public void lookupIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, true, handler); }
VertxServiceDiscovery { public void lookupIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, true, handler); } }
VertxServiceDiscovery { public void lookupIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, true, handler); } VertxServiceDiscovery(Vertx vertx); }
VertxServiceDiscovery { public void lookupIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, true, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourc...
VertxServiceDiscovery { public void lookupIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, true, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourc...
@Test public void givenServiceDiscovery_whenLookupForARecordIncludingOutOfService_thenShouldGetTheRecord(TestContext context) throws Exception { publishTestRecord(record.setStatus(Status.OUT_OF_SERVICE)); lookupIncludeOutOfService(r -> r.getName().equals(SERVICE_NAME), context.asyncAssertSuccess(record -> { context.ass...
public void lookupIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, true, handler); }
VertxServiceDiscovery { public void lookupIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, true, handler); } }
VertxServiceDiscovery { public void lookupIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, true, handler); } VertxServiceDiscovery(Vertx vertx); }
VertxServiceDiscovery { public void lookupIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, true, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourc...
VertxServiceDiscovery { public void lookupIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<Record>> handler) { lookup(filter, true, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourc...
@Test public void givenServiceDiscovery_whenLookupByJsonForARecordPassingNull_thenShouldGetTheRecord(TestContext context) throws Exception { publishTestRecord(record); lookupByJson(null, context.asyncAssertSuccess(record -> { context.assertEquals(SERVICE_NAME, record.getName()); })); }
public void lookupByJson(JsonObject jsonFilter, Handler<AsyncResult<Record>> handler) { serviceDiscovery.getRecord(jsonFilter, handler); }
VertxServiceDiscovery { public void lookupByJson(JsonObject jsonFilter, Handler<AsyncResult<Record>> handler) { serviceDiscovery.getRecord(jsonFilter, handler); } }
VertxServiceDiscovery { public void lookupByJson(JsonObject jsonFilter, Handler<AsyncResult<Record>> handler) { serviceDiscovery.getRecord(jsonFilter, handler); } VertxServiceDiscovery(Vertx vertx); }
VertxServiceDiscovery { public void lookupByJson(JsonObject jsonFilter, Handler<AsyncResult<Record>> handler) { serviceDiscovery.getRecord(jsonFilter, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServi...
VertxServiceDiscovery { public void lookupByJson(JsonObject jsonFilter, Handler<AsyncResult<Record>> handler) { serviceDiscovery.getRecord(jsonFilter, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServi...
@Test public void givenServiceDiscovery_whenLookupByJsonForARecordWithAName_thenShouldGetARecordWithThatName(TestContext context) throws Exception { publishTestRecord(record); lookupByJson(jsonFilter, context.asyncAssertSuccess(record -> { context.assertEquals(SERVICE_NAME, record.getName()); })); }
public void lookupByJson(JsonObject jsonFilter, Handler<AsyncResult<Record>> handler) { serviceDiscovery.getRecord(jsonFilter, handler); }
VertxServiceDiscovery { public void lookupByJson(JsonObject jsonFilter, Handler<AsyncResult<Record>> handler) { serviceDiscovery.getRecord(jsonFilter, handler); } }
VertxServiceDiscovery { public void lookupByJson(JsonObject jsonFilter, Handler<AsyncResult<Record>> handler) { serviceDiscovery.getRecord(jsonFilter, handler); } VertxServiceDiscovery(Vertx vertx); }
VertxServiceDiscovery { public void lookupByJson(JsonObject jsonFilter, Handler<AsyncResult<Record>> handler) { serviceDiscovery.getRecord(jsonFilter, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServi...
VertxServiceDiscovery { public void lookupByJson(JsonObject jsonFilter, Handler<AsyncResult<Record>> handler) { serviceDiscovery.getRecord(jsonFilter, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServi...
@Test(expected = InvalidFilterException.class) public void givenServiceDiscovery_whenLookupForAllRecordsPassingNullFilter_thenShouldThrowException() throws Exception { lookupAll(null, ar -> { }); }
public void lookupAll(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, false, handler); }
VertxServiceDiscovery { public void lookupAll(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, false, handler); } }
VertxServiceDiscovery { public void lookupAll(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, false, handler); } VertxServiceDiscovery(Vertx vertx); }
VertxServiceDiscovery { public void lookupAll(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, false, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServi...
VertxServiceDiscovery { public void lookupAll(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, false, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServi...
@Test public void givenServiceDiscovery_whenLookupForAllRecordsWithUnmatchingPredicate_thenShouldNotGetAnyRecord(TestContext context) throws Exception { publishTestRecord(record); publishTestRecord(otherRecord); lookupAll(record -> record.getName().equals(NOT_EXISTED_NAME), context.asyncAssertSuccess(records -> { conte...
public void lookupAll(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, false, handler); }
VertxServiceDiscovery { public void lookupAll(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, false, handler); } }
VertxServiceDiscovery { public void lookupAll(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, false, handler); } VertxServiceDiscovery(Vertx vertx); }
VertxServiceDiscovery { public void lookupAll(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, false, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServi...
VertxServiceDiscovery { public void lookupAll(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, false, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServi...
@Test public void givenServiceDiscovery_whenLookupForAllRecordsWithMatchingPredicate_thenShouldGetAllRecordsMatching(TestContext context) throws Exception { publishTestRecord(record); publishTestRecord(otherRecord); lookupAll(record -> record.getName().contains(SERVICE_NAME), context.asyncAssertSuccess(records -> { con...
public void lookupAll(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, false, handler); }
VertxServiceDiscovery { public void lookupAll(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, false, handler); } }
VertxServiceDiscovery { public void lookupAll(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, false, handler); } VertxServiceDiscovery(Vertx vertx); }
VertxServiceDiscovery { public void lookupAll(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, false, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServi...
VertxServiceDiscovery { public void lookupAll(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, false, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServi...
@Test(expected = InvalidFilterException.class) public void givenServiceDiscovery_whenLookupForAllRecordsIncludingOutOfServicePassingNullFilter_thenShouldThrowException(TestContext context) throws Exception { lookupAllIncludeOutOfService(null, ar -> { }); }
public void lookupAllIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, true, handler); }
VertxServiceDiscovery { public void lookupAllIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, true, handler); } }
VertxServiceDiscovery { public void lookupAllIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, true, handler); } VertxServiceDiscovery(Vertx vertx); }
VertxServiceDiscovery { public void lookupAllIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, true, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); ...
VertxServiceDiscovery { public void lookupAllIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, true, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); ...
@Test public void givenServiceDiscovery_whenLookupForAllRecordsIncludingOutOfService_thenShouldGetAllRecordsIncludingOutOfService(TestContext context) throws Exception { publishTestRecord(record.setStatus(Status.OUT_OF_SERVICE)); publishTestRecord(otherRecord); lookupAllIncludeOutOfService(record -> record.getName().co...
public void lookupAllIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, true, handler); }
VertxServiceDiscovery { public void lookupAllIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, true, handler); } }
VertxServiceDiscovery { public void lookupAllIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, true, handler); } VertxServiceDiscovery(Vertx vertx); }
VertxServiceDiscovery { public void lookupAllIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, true, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); ...
VertxServiceDiscovery { public void lookupAllIncludeOutOfService(Function<Record, Boolean> filter, Handler<AsyncResult<List<Record>>> handler) { lookupAll(filter, true, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); ...
@Test public void givenServiceDiscovery_whenPublishHttpServiceAndAskingForItsHttpClientByFilter_thenShouldGetTheClient(TestContext context) throws Exception { publishHttpEndpoint(httpEndpointConfiguration); getHttpClient(record -> record.getName().equals(SERVICE_NAME), context.asyncAssertSuccess(Assert::assertNotNull))...
public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); }
HttpServiceDiscovery { public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); } }
HttpServiceDiscovery { public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); }
HttpServiceDiscovery { public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(HttpEndpointConfiguration configuration, Handler<AsyncResult<R...
HttpServiceDiscovery { public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(HttpEndpointConfiguration configuration, Handler<AsyncResult<R...
@Test public void givenServiceDiscovery_whenLookupForAllRecordsByJsonPassingNull_thenShouldGetAllRecords(TestContext context) throws Exception { publishTestRecord(record); publishTestRecord(otherRecord); lookupAllByJson(null, context.asyncAssertSuccess(records -> { context.assertEquals(2, records.size()); })); }
public void lookupAllByJson(JsonObject jsonFilter, Handler<AsyncResult<List<Record>>> handler) { serviceDiscovery.getRecords(jsonFilter, handler); }
VertxServiceDiscovery { public void lookupAllByJson(JsonObject jsonFilter, Handler<AsyncResult<List<Record>>> handler) { serviceDiscovery.getRecords(jsonFilter, handler); } }
VertxServiceDiscovery { public void lookupAllByJson(JsonObject jsonFilter, Handler<AsyncResult<List<Record>>> handler) { serviceDiscovery.getRecords(jsonFilter, handler); } VertxServiceDiscovery(Vertx vertx); }
VertxServiceDiscovery { public void lookupAllByJson(JsonObject jsonFilter, Handler<AsyncResult<List<Record>>> handler) { serviceDiscovery.getRecords(jsonFilter, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageS...
VertxServiceDiscovery { public void lookupAllByJson(JsonObject jsonFilter, Handler<AsyncResult<List<Record>>> handler) { serviceDiscovery.getRecords(jsonFilter, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageS...
@Test public void givenServiceDiscovery_whenLookupForAllRecordsWithNameByJson_thenShouldGetAllRecordsMatching(TestContext context) throws Exception { publishTestRecord(record.setMetadata(metadata)); publishTestRecord(otherRecord.setMetadata(metadata)); lookupAllByJson(metadata, context.asyncAssertSuccess(records -> { c...
public void lookupAllByJson(JsonObject jsonFilter, Handler<AsyncResult<List<Record>>> handler) { serviceDiscovery.getRecords(jsonFilter, handler); }
VertxServiceDiscovery { public void lookupAllByJson(JsonObject jsonFilter, Handler<AsyncResult<List<Record>>> handler) { serviceDiscovery.getRecords(jsonFilter, handler); } }
VertxServiceDiscovery { public void lookupAllByJson(JsonObject jsonFilter, Handler<AsyncResult<List<Record>>> handler) { serviceDiscovery.getRecords(jsonFilter, handler); } VertxServiceDiscovery(Vertx vertx); }
VertxServiceDiscovery { public void lookupAllByJson(JsonObject jsonFilter, Handler<AsyncResult<List<Record>>> handler) { serviceDiscovery.getRecords(jsonFilter, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageS...
VertxServiceDiscovery { public void lookupAllByJson(JsonObject jsonFilter, Handler<AsyncResult<List<Record>>> handler) { serviceDiscovery.getRecords(jsonFilter, handler); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageS...
@Test public void givenServiceDiscovery_whenPublishServiceAndLookupForItsServiceReference_thenShouldGetTheReference(TestContext context) throws Exception { publishTestRecord(record, context.asyncAssertSuccess(record -> { assertNotNull(vertxServiceDiscovery.lookupForAReference(record)); })); }
public ServiceReference lookupForAReference(Record record) { return serviceDiscovery.getReference(record); }
VertxServiceDiscovery { public ServiceReference lookupForAReference(Record record) { return serviceDiscovery.getReference(record); } }
VertxServiceDiscovery { public ServiceReference lookupForAReference(Record record) { return serviceDiscovery.getReference(record); } VertxServiceDiscovery(Vertx vertx); }
VertxServiceDiscovery { public ServiceReference lookupForAReference(Record record) { return serviceDiscovery.getReference(record); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServiceDiscovery messageSource(); J...
VertxServiceDiscovery { public ServiceReference lookupForAReference(Record record) { return serviceDiscovery.getReference(record); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusServiceDiscovery eventBus(); MessageSourceServiceDiscovery messageSource(); J...
@Test public void givenServiceDiscovery_whenPublishServiceWithMetadataAndLookupForItsServiceReferencePassingConfiguration_thenShouldGetTheReferenceUponTheseConfigurations(TestContext context) throws Exception { publishTestRecord(record, context.asyncAssertSuccess(record -> { ServiceReference reference = vertxServiceDis...
public ServiceReference lookupForAReferenceWithConfiguration(Record record, JsonObject configuration) { return serviceDiscovery.getReferenceWithConfiguration(record, configuration); }
VertxServiceDiscovery { public ServiceReference lookupForAReferenceWithConfiguration(Record record, JsonObject configuration) { return serviceDiscovery.getReferenceWithConfiguration(record, configuration); } }
VertxServiceDiscovery { public ServiceReference lookupForAReferenceWithConfiguration(Record record, JsonObject configuration) { return serviceDiscovery.getReferenceWithConfiguration(record, configuration); } VertxServiceDiscovery(Vertx vertx); }
VertxServiceDiscovery { public ServiceReference lookupForAReferenceWithConfiguration(Record record, JsonObject configuration) { return serviceDiscovery.getReferenceWithConfiguration(record, configuration); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusSe...
VertxServiceDiscovery { public ServiceReference lookupForAReferenceWithConfiguration(Record record, JsonObject configuration) { return serviceDiscovery.getReferenceWithConfiguration(record, configuration); } VertxServiceDiscovery(Vertx vertx); ServiceDiscovery serviceDiscovery(); HttpServiceDiscovery http(); EventBusSe...
@Test public void givenServiceDiscovery_whenPublishHttpServiceAndAskingForItsHttpClientByFilterWithConfiguration_thenShouldGetTheClient(TestContext context) throws Exception { publishHttpEndpoint(httpEndpointConfiguration.metadata(metadata)); getHttpClient(record -> record.getName().equals(SERVICE_NAME), metadata, cont...
public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); }
HttpServiceDiscovery { public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); } }
HttpServiceDiscovery { public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); }
HttpServiceDiscovery { public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(HttpEndpointConfiguration configuration, Handler<AsyncResult<R...
HttpServiceDiscovery { public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(HttpEndpointConfiguration configuration, Handler<AsyncResult<R...
@Test public void givenServiceDiscovery_whenPublishHttpServiceAndAskingForItsHttpClientByJson_thenShouldGetTheClient(TestContext context) throws Exception { publishHttpEndpoint(httpEndpointConfiguration); getHttpClient(jsonFilter, context.asyncAssertSuccess(Assert::assertNotNull)); }
public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); }
HttpServiceDiscovery { public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); } }
HttpServiceDiscovery { public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); }
HttpServiceDiscovery { public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(HttpEndpointConfiguration configuration, Handler<AsyncResult<R...
HttpServiceDiscovery { public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(HttpEndpointConfiguration configuration, Handler<AsyncResult<R...
@Test public void givenServiceDiscovery_whenPublishHttpServiceAndAskingForItsHttpClientByJsonWithConfiguration_thenShouldGetTheClient(TestContext context) throws Exception { publishHttpEndpoint(httpEndpointConfiguration.metadata(metadata)); getHttpClient(jsonFilter, metadata, context.asyncAssertSuccess(Assert::assertNo...
public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); }
HttpServiceDiscovery { public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); } }
HttpServiceDiscovery { public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); }
HttpServiceDiscovery { public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(HttpEndpointConfiguration configuration, Handler<AsyncResult<R...
HttpServiceDiscovery { public void getHttpClient(Function<Record, Boolean> filter, Handler<AsyncResult<HttpClient>> handler) { HttpEndpoint.getClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(HttpEndpointConfiguration configuration, Handler<AsyncResult<R...
@Test public void givenServiceDiscovery_whenPublishHttpServiceAndAskingForItsWebClientByFilter_thenShouldGetTheClient(TestContext context) throws Exception { publishHttpEndpoint(httpEndpointConfiguration); getWebClient(record -> record.getName().equals(SERVICE_NAME), context.asyncAssertSuccess(Assert::assertNotNull)); ...
public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); }
HttpServiceDiscovery { public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); } }
HttpServiceDiscovery { public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); }
HttpServiceDiscovery { public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(HttpEndpointConfiguration configuration, Handler<AsyncResult<...
HttpServiceDiscovery { public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(HttpEndpointConfiguration configuration, Handler<AsyncResult<...
@Test public void givenServiceDiscovery_whenPublishHttpServiceAndAskingForItsWebClientByFilterWithConfiguration_thenShouldGetTheClient(TestContext context) throws Exception { publishHttpEndpoint(httpEndpointConfiguration.metadata(metadata)); getWebClient(record -> record.getName().equals(SERVICE_NAME), metadata, contex...
public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); }
HttpServiceDiscovery { public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); } }
HttpServiceDiscovery { public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); }
HttpServiceDiscovery { public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(HttpEndpointConfiguration configuration, Handler<AsyncResult<...
HttpServiceDiscovery { public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(HttpEndpointConfiguration configuration, Handler<AsyncResult<...
@Test public void givenServiceDiscovery_whenPublishHttpServiceAndAskingForItsWebClientByJson_thenShouldGetTheClient(TestContext context) throws Exception { publishHttpEndpoint(httpEndpointConfiguration); getWebClient(jsonFilter, context.asyncAssertSuccess(Assert::assertNotNull)); }
public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); }
HttpServiceDiscovery { public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); } }
HttpServiceDiscovery { public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); }
HttpServiceDiscovery { public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(HttpEndpointConfiguration configuration, Handler<AsyncResult<...
HttpServiceDiscovery { public void getWebClient(Function<Record, Boolean> filter, Handler<AsyncResult<WebClient>> handler) { HttpEndpoint.getWebClient(serviceDiscovery, filter, handler); } HttpServiceDiscovery(ServiceDiscovery serviceDiscovery); void publish(HttpEndpointConfiguration configuration, Handler<AsyncResult<...
@Test public void testEventsOnPropertyChange() { ObservableList<ValueHolder> list = new ArrayListModel<ValueHolder>(); ValueHolder v1 = new ValueHolder("A"); list.add(v1); ValueHolder v2 = new ValueHolder("B"); list.add(v2); ListItemsUniqueModel<ValueHolder> unique = new ListItemsUniqueModel<ValueHolder>(list, ValueHol...
public void setValue(Object newValue) { throw new UnsupportedOperationException("ListItemsUniqueModel is read-only"); }
ListItemsUniqueModel extends AbstractValueModel { public void setValue(Object newValue) { throw new UnsupportedOperationException("ListItemsUniqueModel is read-only"); } }
ListItemsUniqueModel extends AbstractValueModel { public void setValue(Object newValue) { throw new UnsupportedOperationException("ListItemsUniqueModel is read-only"); } ListItemsUniqueModel(ObservableList<E> list, Class<E> beanClass, String propertyName); }
ListItemsUniqueModel extends AbstractValueModel { public void setValue(Object newValue) { throw new UnsupportedOperationException("ListItemsUniqueModel is read-only"); } ListItemsUniqueModel(ObservableList<E> list, Class<E> beanClass, String propertyName); Object getValue(); boolean calculate(); void setValue(Object ne...
ListItemsUniqueModel extends AbstractValueModel { public void setValue(Object newValue) { throw new UnsupportedOperationException("ListItemsUniqueModel is read-only"); } ListItemsUniqueModel(ObservableList<E> list, Class<E> beanClass, String propertyName); Object getValue(); boolean calculate(); void setValue(Object ne...
@Test public void testGetElementAtIndex() { assertEquals("A", CollectionUtil.getElementAtIndex(d_set, 0)); assertEquals("B", CollectionUtil.getElementAtIndex(d_set, 1)); }
public static <E> E getElementAtIndex(Collection<E> set, int idx) { if (idx >= set.size() || idx < 0) { throw new IndexOutOfBoundsException(); } Iterator<E> it = set.iterator(); for (int i = 0; i < idx; ++i) { it.next(); } return it.next(); }
CollectionUtil { public static <E> E getElementAtIndex(Collection<E> set, int idx) { if (idx >= set.size() || idx < 0) { throw new IndexOutOfBoundsException(); } Iterator<E> it = set.iterator(); for (int i = 0; i < idx; ++i) { it.next(); } return it.next(); } }
CollectionUtil { public static <E> E getElementAtIndex(Collection<E> set, int idx) { if (idx >= set.size() || idx < 0) { throw new IndexOutOfBoundsException(); } Iterator<E> it = set.iterator(); for (int i = 0; i < idx; ++i) { it.next(); } return it.next(); } }
CollectionUtil { public static <E> E getElementAtIndex(Collection<E> set, int idx) { if (idx >= set.size() || idx < 0) { throw new IndexOutOfBoundsException(); } Iterator<E> it = set.iterator(); for (int i = 0; i < idx; ++i) { it.next(); } return it.next(); } static E getElementAtIndex(Collection<E> set, int idx); sta...
CollectionUtil { public static <E> E getElementAtIndex(Collection<E> set, int idx) { if (idx >= set.size() || idx < 0) { throw new IndexOutOfBoundsException(); } Iterator<E> it = set.iterator(); for (int i = 0; i < idx; ++i) { it.next(); } return it.next(); } static E getElementAtIndex(Collection<E> set, int idx); sta...
@Test(expected=IndexOutOfBoundsException.class) public void testGetElementAtIndexTooHigh() { CollectionUtil.getElementAtIndex(d_set, 2); }
public static <E> E getElementAtIndex(Collection<E> set, int idx) { if (idx >= set.size() || idx < 0) { throw new IndexOutOfBoundsException(); } Iterator<E> it = set.iterator(); for (int i = 0; i < idx; ++i) { it.next(); } return it.next(); }
CollectionUtil { public static <E> E getElementAtIndex(Collection<E> set, int idx) { if (idx >= set.size() || idx < 0) { throw new IndexOutOfBoundsException(); } Iterator<E> it = set.iterator(); for (int i = 0; i < idx; ++i) { it.next(); } return it.next(); } }
CollectionUtil { public static <E> E getElementAtIndex(Collection<E> set, int idx) { if (idx >= set.size() || idx < 0) { throw new IndexOutOfBoundsException(); } Iterator<E> it = set.iterator(); for (int i = 0; i < idx; ++i) { it.next(); } return it.next(); } }
CollectionUtil { public static <E> E getElementAtIndex(Collection<E> set, int idx) { if (idx >= set.size() || idx < 0) { throw new IndexOutOfBoundsException(); } Iterator<E> it = set.iterator(); for (int i = 0; i < idx; ++i) { it.next(); } return it.next(); } static E getElementAtIndex(Collection<E> set, int idx); sta...
CollectionUtil { public static <E> E getElementAtIndex(Collection<E> set, int idx) { if (idx >= set.size() || idx < 0) { throw new IndexOutOfBoundsException(); } Iterator<E> it = set.iterator(); for (int i = 0; i < idx; ++i) { it.next(); } return it.next(); } static E getElementAtIndex(Collection<E> set, int idx); sta...
@Test(expected=IndexOutOfBoundsException.class) public void testGetElementAtIndexNegative() { CollectionUtil.getElementAtIndex(d_set, -1); }
public static <E> E getElementAtIndex(Collection<E> set, int idx) { if (idx >= set.size() || idx < 0) { throw new IndexOutOfBoundsException(); } Iterator<E> it = set.iterator(); for (int i = 0; i < idx; ++i) { it.next(); } return it.next(); }
CollectionUtil { public static <E> E getElementAtIndex(Collection<E> set, int idx) { if (idx >= set.size() || idx < 0) { throw new IndexOutOfBoundsException(); } Iterator<E> it = set.iterator(); for (int i = 0; i < idx; ++i) { it.next(); } return it.next(); } }
CollectionUtil { public static <E> E getElementAtIndex(Collection<E> set, int idx) { if (idx >= set.size() || idx < 0) { throw new IndexOutOfBoundsException(); } Iterator<E> it = set.iterator(); for (int i = 0; i < idx; ++i) { it.next(); } return it.next(); } }
CollectionUtil { public static <E> E getElementAtIndex(Collection<E> set, int idx) { if (idx >= set.size() || idx < 0) { throw new IndexOutOfBoundsException(); } Iterator<E> it = set.iterator(); for (int i = 0; i < idx; ++i) { it.next(); } return it.next(); } static E getElementAtIndex(Collection<E> set, int idx); sta...
CollectionUtil { public static <E> E getElementAtIndex(Collection<E> set, int idx) { if (idx >= set.size() || idx < 0) { throw new IndexOutOfBoundsException(); } Iterator<E> it = set.iterator(); for (int i = 0; i < idx; ++i) { it.next(); } return it.next(); } static E getElementAtIndex(Collection<E> set, int idx); sta...
@Test public void testGetIndexOfElement() { assertEquals(0, CollectionUtil.getIndexOfElement(d_set, "A")); assertEquals(1, CollectionUtil.getIndexOfElement(d_set, "B")); assertEquals(-1, CollectionUtil.getIndexOfElement(d_set, "C")); }
public static <E> int getIndexOfElement(Collection<E> set, Object child) { int i = 0; for (E e : set) { if (e.equals(child)) { return i; } ++i; } return -1; }
CollectionUtil { public static <E> int getIndexOfElement(Collection<E> set, Object child) { int i = 0; for (E e : set) { if (e.equals(child)) { return i; } ++i; } return -1; } }
CollectionUtil { public static <E> int getIndexOfElement(Collection<E> set, Object child) { int i = 0; for (E e : set) { if (e.equals(child)) { return i; } ++i; } return -1; } }
CollectionUtil { public static <E> int getIndexOfElement(Collection<E> set, Object child) { int i = 0; for (E e : set) { if (e.equals(child)) { return i; } ++i; } return -1; } static E getElementAtIndex(Collection<E> set, int idx); static int getIndexOfElement(Collection<E> set, Object child); static boolean containsA...
CollectionUtil { public static <E> int getIndexOfElement(Collection<E> set, Object child) { int i = 0; for (E e : set) { if (e.equals(child)) { return i; } ++i; } return -1; } static E getElementAtIndex(Collection<E> set, int idx); static int getIndexOfElement(Collection<E> set, Object child); static boolean containsA...
@Test public void testNextLexicographicElement() { int c[] = new int[] {1, 2, 3, 1}; int x[] = new int[] {0, 0, 0, 0}; assertTrue(CollectionUtil.nextLexicographicElement(x, c)); assertArrayEquals(new int[] {0, 0, 1, 0}, x); assertTrue(CollectionUtil.nextLexicographicElement(x, c)); assertArrayEquals(new int[] {0, 0, 2,...
public static boolean nextLexicographicElement(int x[], int c[]) { assert(x.length == c.length); final int l = x.length; if (l < 1) { return false; } for (int i = l - 1; i >= 0; --i) { ++x[i]; if (x[i] == c[i]) { x[i] = 0; } else { return true; } } return false; }
CollectionUtil { public static boolean nextLexicographicElement(int x[], int c[]) { assert(x.length == c.length); final int l = x.length; if (l < 1) { return false; } for (int i = l - 1; i >= 0; --i) { ++x[i]; if (x[i] == c[i]) { x[i] = 0; } else { return true; } } return false; } }
CollectionUtil { public static boolean nextLexicographicElement(int x[], int c[]) { assert(x.length == c.length); final int l = x.length; if (l < 1) { return false; } for (int i = l - 1; i >= 0; --i) { ++x[i]; if (x[i] == c[i]) { x[i] = 0; } else { return true; } } return false; } }
CollectionUtil { public static boolean nextLexicographicElement(int x[], int c[]) { assert(x.length == c.length); final int l = x.length; if (l < 1) { return false; } for (int i = l - 1; i >= 0; --i) { ++x[i]; if (x[i] == c[i]) { x[i] = 0; } else { return true; } } return false; } static E getElementAtIndex(Collection...
CollectionUtil { public static boolean nextLexicographicElement(int x[], int c[]) { assert(x.length == c.length); final int l = x.length; if (l < 1) { return false; } for (int i = l - 1; i >= 0; --i) { ++x[i]; if (x[i] == c[i]) { x[i] = 0; } else { return true; } } return false; } static E getElementAtIndex(Collection...
@Test(expected=IllegalArgumentException.class) public void testConstructionWithNonEmptyList() { ObservableList<Integer> list = new ArrayListModel<Integer>(); list.add(1); d_list = new GuardedObservableList<Integer>(list, new Predicate<Number>() { public boolean evaluate(Number object) { return object.doubleValue() > 0....
@Override public void add(int index, E element) { check(element); d_nested.add(index, element); }
GuardedObservableList extends AbstractObservableList<E> { @Override public void add(int index, E element) { check(element); d_nested.add(index, element); } }
GuardedObservableList extends AbstractObservableList<E> { @Override public void add(int index, E element) { check(element); d_nested.add(index, element); } GuardedObservableList(ObservableList<E> nested, Predicate<? super E> predicate); }
GuardedObservableList extends AbstractObservableList<E> { @Override public void add(int index, E element) { check(element); d_nested.add(index, element); } GuardedObservableList(ObservableList<E> nested, Predicate<? super E> predicate); @Override E get(int index); @Override int size(); @Override void add(int index, E e...
GuardedObservableList extends AbstractObservableList<E> { @Override public void add(int index, E element) { check(element); d_nested.add(index, element); } GuardedObservableList(ObservableList<E> nested, Predicate<? super E> predicate); @Override E get(int index); @Override int size(); @Override void add(int index, E e...
@Test(expected=IllegalArgumentException.class) public void testAddBadValue() { d_list.add(-1); }
@Override public void add(int index, E element) { check(element); d_nested.add(index, element); }
GuardedObservableList extends AbstractObservableList<E> { @Override public void add(int index, E element) { check(element); d_nested.add(index, element); } }
GuardedObservableList extends AbstractObservableList<E> { @Override public void add(int index, E element) { check(element); d_nested.add(index, element); } GuardedObservableList(ObservableList<E> nested, Predicate<? super E> predicate); }
GuardedObservableList extends AbstractObservableList<E> { @Override public void add(int index, E element) { check(element); d_nested.add(index, element); } GuardedObservableList(ObservableList<E> nested, Predicate<? super E> predicate); @Override E get(int index); @Override int size(); @Override void add(int index, E e...
GuardedObservableList extends AbstractObservableList<E> { @Override public void add(int index, E element) { check(element); d_nested.add(index, element); } GuardedObservableList(ObservableList<E> nested, Predicate<? super E> predicate); @Override E get(int index); @Override int size(); @Override void add(int index, E e...
@Test(expected=IllegalArgumentException.class) public void testSetBadValue() { d_list.set(1, -1); }
@Override public E set(int index, E element) { check(element); return d_nested.set(index, element); }
GuardedObservableList extends AbstractObservableList<E> { @Override public E set(int index, E element) { check(element); return d_nested.set(index, element); } }
GuardedObservableList extends AbstractObservableList<E> { @Override public E set(int index, E element) { check(element); return d_nested.set(index, element); } GuardedObservableList(ObservableList<E> nested, Predicate<? super E> predicate); }
GuardedObservableList extends AbstractObservableList<E> { @Override public E set(int index, E element) { check(element); return d_nested.set(index, element); } GuardedObservableList(ObservableList<E> nested, Predicate<? super E> predicate); @Override E get(int index); @Override int size(); @Override void add(int index,...
GuardedObservableList extends AbstractObservableList<E> { @Override public E set(int index, E element) { check(element); return d_nested.set(index, element); } GuardedObservableList(ObservableList<E> nested, Predicate<? super E> predicate); @Override E get(int index); @Override int size(); @Override void add(int index,...
@Test public void testContentsUpdateAddNone() { ListDataListener mock = createStrictMock(ListDataListener.class); replay(mock); d_outer.addListDataListener(mock); d_inner.add(2, "Haank"); assertEquals(Arrays.asList("Gert", "Jan"), d_outer); verify(mock); }
@Override public void add(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter of " + this); if(index < d_indices.size()) { d_inner.add(d_indices.get(index), element); } else { d_inner.add(d_inner.size(), element)...
FilteredObservableList extends AbstractObservableList<E> { @Override public void add(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter of " + this); if(index < d_indices.size()) { d_inner.add(d_indices.get(inde...
FilteredObservableList extends AbstractObservableList<E> { @Override public void add(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter of " + this); if(index < d_indices.size()) { d_inner.add(d_indices.get(inde...
FilteredObservableList extends AbstractObservableList<E> { @Override public void add(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter of " + this); if(index < d_indices.size()) { d_inner.add(d_indices.get(inde...
FilteredObservableList extends AbstractObservableList<E> { @Override public void add(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter of " + this); if(index < d_indices.size()) { d_inner.add(d_indices.get(inde...
@Test public void testContentsUpdateAddAllIndex() { ListDataListener mock = createStrictMock(ListDataListener.class); mock.intervalAdded(ListDataEventMatcher.eqListDataEvent(new ListDataEvent(d_outer, ListDataEvent.INTERVAL_ADDED, 1, 2))); replay(mock); d_outer.addListDataListener(mock); d_inner.addAll(2, Arrays.asList...
private void intervalAdded(final int lower, final int upper) { final int delta = upper - lower + 1; final int first = firstAtLeast(lower); updateIndices(first, delta); final int oldSize = d_indices.size(); for(int i = upper; i >= lower; --i) { if (d_filter.evaluate(d_inner.get(i))) { d_indices.add(first, i); } } final ...
FilteredObservableList extends AbstractObservableList<E> { private void intervalAdded(final int lower, final int upper) { final int delta = upper - lower + 1; final int first = firstAtLeast(lower); updateIndices(first, delta); final int oldSize = d_indices.size(); for(int i = upper; i >= lower; --i) { if (d_filter.eval...
FilteredObservableList extends AbstractObservableList<E> { private void intervalAdded(final int lower, final int upper) { final int delta = upper - lower + 1; final int first = firstAtLeast(lower); updateIndices(first, delta); final int oldSize = d_indices.size(); for(int i = upper; i >= lower; --i) { if (d_filter.eval...
FilteredObservableList extends AbstractObservableList<E> { private void intervalAdded(final int lower, final int upper) { final int delta = upper - lower + 1; final int first = firstAtLeast(lower); updateIndices(first, delta); final int oldSize = d_indices.size(); for(int i = upper; i >= lower; --i) { if (d_filter.eval...
FilteredObservableList extends AbstractObservableList<E> { private void intervalAdded(final int lower, final int upper) { final int delta = upper - lower + 1; final int first = firstAtLeast(lower); updateIndices(first, delta); final int oldSize = d_indices.size(); for(int i = upper; i >= lower; --i) { if (d_filter.eval...
@Test public void testInitialValues() { assertFalse(new ListMinimumSizeModel(new ArrayListModel<String>(), 1).getValue()); assertTrue(new ListMinimumSizeModel(new ArrayListModel<String>(Arrays.asList("Test")), 1).getValue()); assertFalse(new ListMinimumSizeModel(new ArrayListModel<String>(Arrays.asList("Test")), 2).get...
public Boolean getValue() { return d_val; }
ListMinimumSizeModel extends AbstractValueModel { public Boolean getValue() { return d_val; } }
ListMinimumSizeModel extends AbstractValueModel { public Boolean getValue() { return d_val; } ListMinimumSizeModel(ListModel list, int minSize); }
ListMinimumSizeModel extends AbstractValueModel { public Boolean getValue() { return d_val; } ListMinimumSizeModel(ListModel list, int minSize); Boolean getValue(); void setValue(Object value); }
ListMinimumSizeModel extends AbstractValueModel { public Boolean getValue() { return d_val; } ListMinimumSizeModel(ListModel list, int minSize); Boolean getValue(); void setValue(Object value); }
@Test public void testContentsUpdateAddAllEnd() { ListDataListener mock = createStrictMock(ListDataListener.class); mock.intervalAdded(ListDataEventMatcher.eqListDataEvent(new ListDataEvent(d_outer, ListDataEvent.INTERVAL_ADDED, 2, 3))); replay(mock); d_outer.addListDataListener(mock); d_inner.addAll(Arrays.asList("Hen...
private void intervalAdded(final int lower, final int upper) { final int delta = upper - lower + 1; final int first = firstAtLeast(lower); updateIndices(first, delta); final int oldSize = d_indices.size(); for(int i = upper; i >= lower; --i) { if (d_filter.evaluate(d_inner.get(i))) { d_indices.add(first, i); } } final ...
FilteredObservableList extends AbstractObservableList<E> { private void intervalAdded(final int lower, final int upper) { final int delta = upper - lower + 1; final int first = firstAtLeast(lower); updateIndices(first, delta); final int oldSize = d_indices.size(); for(int i = upper; i >= lower; --i) { if (d_filter.eval...
FilteredObservableList extends AbstractObservableList<E> { private void intervalAdded(final int lower, final int upper) { final int delta = upper - lower + 1; final int first = firstAtLeast(lower); updateIndices(first, delta); final int oldSize = d_indices.size(); for(int i = upper; i >= lower; --i) { if (d_filter.eval...
FilteredObservableList extends AbstractObservableList<E> { private void intervalAdded(final int lower, final int upper) { final int delta = upper - lower + 1; final int first = firstAtLeast(lower); updateIndices(first, delta); final int oldSize = d_indices.size(); for(int i = upper; i >= lower; --i) { if (d_filter.eval...
FilteredObservableList extends AbstractObservableList<E> { private void intervalAdded(final int lower, final int upper) { final int delta = upper - lower + 1; final int first = firstAtLeast(lower); updateIndices(first, delta); final int oldSize = d_indices.size(); for(int i = upper; i >= lower; --i) { if (d_filter.eval...
@Test public void testContentsUpdateRemoveNone() { ListDataListener mock = createStrictMock(ListDataListener.class); replay(mock); d_outer.addListDataListener(mock); d_inner.remove("Daan"); assertEquals(Arrays.asList("Gert", "Jan"), d_outer); verify(mock); }
@Override public E remove(final int index) { return d_inner.remove((int) d_indices.get(index)); }
FilteredObservableList extends AbstractObservableList<E> { @Override public E remove(final int index) { return d_inner.remove((int) d_indices.get(index)); } }
FilteredObservableList extends AbstractObservableList<E> { @Override public E remove(final int index) { return d_inner.remove((int) d_indices.get(index)); } FilteredObservableList(final ObservableList<E> inner, final Predicate<E> filter); }
FilteredObservableList extends AbstractObservableList<E> { @Override public E remove(final int index) { return d_inner.remove((int) d_indices.get(index)); } FilteredObservableList(final ObservableList<E> inner, final Predicate<E> filter); void setFilter(final Predicate<E> filter); @Override E get(final int index); @Ove...
FilteredObservableList extends AbstractObservableList<E> { @Override public E remove(final int index) { return d_inner.remove((int) d_indices.get(index)); } FilteredObservableList(final ObservableList<E> inner, final Predicate<E> filter); void setFilter(final Predicate<E> filter); @Override E get(final int index); @Ove...
@Test public void testContentsUpdateRemoveAll() { ListDataListener mock = createStrictMock(ListDataListener.class); mock.intervalRemoved(ListDataEventMatcher.eqListDataEvent(new ListDataEvent(d_outer, ListDataEvent.INTERVAL_REMOVED, 0, 1))); replay(mock); d_outer.addListDataListener(mock); d_inner.clear(); assertEquals...
private void intervalRemoved(final int lower, final int upper) { final int first = firstAtLeast(lower); if (first >= d_indices.size()) { return; } final int last = firstOver(upper); d_indices.removeAll(new ArrayList<Integer>(d_indices.subList(first, last))); final int delta = upper - lower + 1; updateIndices(first, -de...
FilteredObservableList extends AbstractObservableList<E> { private void intervalRemoved(final int lower, final int upper) { final int first = firstAtLeast(lower); if (first >= d_indices.size()) { return; } final int last = firstOver(upper); d_indices.removeAll(new ArrayList<Integer>(d_indices.subList(first, last))); fi...
FilteredObservableList extends AbstractObservableList<E> { private void intervalRemoved(final int lower, final int upper) { final int first = firstAtLeast(lower); if (first >= d_indices.size()) { return; } final int last = firstOver(upper); d_indices.removeAll(new ArrayList<Integer>(d_indices.subList(first, last))); fi...
FilteredObservableList extends AbstractObservableList<E> { private void intervalRemoved(final int lower, final int upper) { final int first = firstAtLeast(lower); if (first >= d_indices.size()) { return; } final int last = firstOver(upper); d_indices.removeAll(new ArrayList<Integer>(d_indices.subList(first, last))); fi...
FilteredObservableList extends AbstractObservableList<E> { private void intervalRemoved(final int lower, final int upper) { final int first = firstAtLeast(lower); if (first >= d_indices.size()) { return; } final int last = firstOver(upper); d_indices.removeAll(new ArrayList<Integer>(d_indices.subList(first, last))); fi...
@Test public void testContentsUpdateFirstElement() { d_inner.set(0, "Gaart"); assertEquals(Arrays.asList("Jan"), d_outer); d_inner.set(0, "Gert"); assertEquals(Arrays.asList("Gert", "Jan"), d_outer); }
@Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); }
FilteredObservableList extends AbstractObservableList<E> { @Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); } }
FilteredObservableList extends AbstractObservableList<E> { @Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); } FilteredObservableLis...
FilteredObservableList extends AbstractObservableList<E> { @Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); } FilteredObservableLis...
FilteredObservableList extends AbstractObservableList<E> { @Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); } FilteredObservableLis...
@Test public void testContentsUpdateLastElement() { d_inner.set(3, "Klees"); assertEquals(Arrays.asList("Gert", "Jan", "Klees"), d_outer); }
@Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); }
FilteredObservableList extends AbstractObservableList<E> { @Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); } }
FilteredObservableList extends AbstractObservableList<E> { @Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); } FilteredObservableLis...
FilteredObservableList extends AbstractObservableList<E> { @Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); } FilteredObservableLis...
FilteredObservableList extends AbstractObservableList<E> { @Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); } FilteredObservableLis...
@Test public void testContentsUpdateSetNoChangeExcl() { ListDataListener mock = createStrictMock(ListDataListener.class); replay(mock); d_outer.addListDataListener(mock); d_inner.set(3, "Paard"); assertEquals(Arrays.asList("Gert", "Jan"), d_outer); verify(mock); }
@Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); }
FilteredObservableList extends AbstractObservableList<E> { @Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); } }
FilteredObservableList extends AbstractObservableList<E> { @Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); } FilteredObservableLis...
FilteredObservableList extends AbstractObservableList<E> { @Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); } FilteredObservableLis...
FilteredObservableList extends AbstractObservableList<E> { @Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); } FilteredObservableLis...
@Test public void testSetFilter() { ListDataListener mock = createStrictMock(ListDataListener.class); mock.intervalRemoved(ListDataEventMatcher.eqListDataEvent(new ListDataEvent(d_outer, ListDataEvent.INTERVAL_REMOVED, 0, 1))); mock.intervalAdded(ListDataEventMatcher.eqListDataEvent(new ListDataEvent(d_outer, ListDataE...
public void setFilter(final Predicate<E> filter) { d_filter = filter; final int oldSize = size(); if(!isEmpty()) { d_indices.clear(); fireIntervalRemoved(0, oldSize - 1); } initializeIndices(); if(!isEmpty()) { fireIntervalAdded(0, size() - 1); } }
FilteredObservableList extends AbstractObservableList<E> { public void setFilter(final Predicate<E> filter) { d_filter = filter; final int oldSize = size(); if(!isEmpty()) { d_indices.clear(); fireIntervalRemoved(0, oldSize - 1); } initializeIndices(); if(!isEmpty()) { fireIntervalAdded(0, size() - 1); } } }
FilteredObservableList extends AbstractObservableList<E> { public void setFilter(final Predicate<E> filter) { d_filter = filter; final int oldSize = size(); if(!isEmpty()) { d_indices.clear(); fireIntervalRemoved(0, oldSize - 1); } initializeIndices(); if(!isEmpty()) { fireIntervalAdded(0, size() - 1); } } FilteredObse...
FilteredObservableList extends AbstractObservableList<E> { public void setFilter(final Predicate<E> filter) { d_filter = filter; final int oldSize = size(); if(!isEmpty()) { d_indices.clear(); fireIntervalRemoved(0, oldSize - 1); } initializeIndices(); if(!isEmpty()) { fireIntervalAdded(0, size() - 1); } } FilteredObse...
FilteredObservableList extends AbstractObservableList<E> { public void setFilter(final Predicate<E> filter) { d_filter = filter; final int oldSize = size(); if(!isEmpty()) { d_indices.clear(); fireIntervalRemoved(0, oldSize - 1); } initializeIndices(); if(!isEmpty()) { fireIntervalAdded(0, size() - 1); } } FilteredObse...
@Test public void testSublistUpdating() { ObservableList<String> list = new SortedSetModel<String>(Arrays.asList("Aa", "Ab", "Ba", "Bb")); ObservableList<String> aList = new FilteredObservableList<String>(list, new Predicate<String>(){ public boolean evaluate(String obj) { return obj.charAt(0) == 'A'; }}); ObservableLi...
@Override public void add(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter of " + this); if(index < d_indices.size()) { d_inner.add(d_indices.get(index), element); } else { d_inner.add(d_inner.size(), element)...
FilteredObservableList extends AbstractObservableList<E> { @Override public void add(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter of " + this); if(index < d_indices.size()) { d_inner.add(d_indices.get(inde...
FilteredObservableList extends AbstractObservableList<E> { @Override public void add(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter of " + this); if(index < d_indices.size()) { d_inner.add(d_indices.get(inde...
FilteredObservableList extends AbstractObservableList<E> { @Override public void add(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter of " + this); if(index < d_indices.size()) { d_inner.add(d_indices.get(inde...
FilteredObservableList extends AbstractObservableList<E> { @Override public void add(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter of " + this); if(index < d_indices.size()) { d_inner.add(d_indices.get(inde...
@Test(expected=IllegalArgumentException.class) public void testAddNonAcceptable() { d_outer.add("Maarten"); }
@Override public void add(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter of " + this); if(index < d_indices.size()) { d_inner.add(d_indices.get(index), element); } else { d_inner.add(d_inner.size(), element)...
FilteredObservableList extends AbstractObservableList<E> { @Override public void add(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter of " + this); if(index < d_indices.size()) { d_inner.add(d_indices.get(inde...
FilteredObservableList extends AbstractObservableList<E> { @Override public void add(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter of " + this); if(index < d_indices.size()) { d_inner.add(d_indices.get(inde...
FilteredObservableList extends AbstractObservableList<E> { @Override public void add(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter of " + this); if(index < d_indices.size()) { d_inner.add(d_indices.get(inde...
FilteredObservableList extends AbstractObservableList<E> { @Override public void add(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter of " + this); if(index < d_indices.size()) { d_inner.add(d_indices.get(inde...
@Test(expected=IllegalArgumentException.class) public void testSetNonAcceptable() { d_outer.set(1, "Maarten"); }
@Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); }
FilteredObservableList extends AbstractObservableList<E> { @Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); } }
FilteredObservableList extends AbstractObservableList<E> { @Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); } FilteredObservableLis...
FilteredObservableList extends AbstractObservableList<E> { @Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); } FilteredObservableLis...
FilteredObservableList extends AbstractObservableList<E> { @Override public E set(final int index, final E element) { if(!d_filter.evaluate(element)) throw new IllegalArgumentException("Cannot add " + element + ", it does not pass the filter."); return d_inner.set(d_indices.get(index), element); } FilteredObservableLis...