@Test public void notBelongsToMissingComponent() { assertFalse(query.belongsToComponent("componentD")); }
@Override public Boolean belongsToComponent(String component) { return handlers.entrySet().stream().anyMatch( entry -> component.equals(entry.getKey()) && entry.getValue() != null && !entry.getValue().isEmpty() ); }
DefaultQuery implements Query { @Override public Boolean belongsToComponent(String component) { return handlers.entrySet().stream().anyMatch( entry -> component.equals(entry.getKey()) && entry.getValue() != null && !entry.getValue().isEmpty() ); } }
DefaultQuery implements Query { @Override public Boolean belongsToComponent(String component) { return handlers.entrySet().stream().anyMatch( entry -> component.equals(entry.getKey()) && entry.getValue() != null && !entry.getValue().isEmpty() ); } DefaultQuery(QueryDefinition definition,
                        Map<String, Set<QueryHandler<?>>> handlers, Set<String> responseTypes); }
DefaultQuery implements Query { @Override public Boolean belongsToComponent(String component) { return handlers.entrySet().stream().anyMatch( entry -> component.equals(entry.getKey()) && entry.getValue() != null && !entry.getValue().isEmpty() ); } DefaultQuery(QueryDefinition definition,
                        Map<String, Set<QueryHandler<?>>> handlers, Set<String> responseTypes); @Override Boolean belongsToComponent(String component); @Override boolean belongsToContext(String context); @Override void printOn(Media media); }
DefaultQuery implements Query { @Override public Boolean belongsToComponent(String component) { return handlers.entrySet().stream().anyMatch( entry -> component.equals(entry.getKey()) && entry.getValue() != null && !entry.getValue().isEmpty() ); } DefaultQuery(QueryDefinition definition,
                        Map<String, Set<QueryHandler<?>>> handlers, Set<String> responseTypes); @Override Boolean belongsToComponent(String component); @Override boolean belongsToContext(String context); @Override void printOn(Media media);  }