@Test public void getIdWithIgnorableURI() throws Exception { final String[] ignorableNamespaces = { "http: "http: "http: }; for (final String ignorableNamespace : ignorableNamespaces) { assertFalse(_cut.contains(ignorableNamespace)); final Value ignorableURI = buildResource(ignorableNamespace + randomString()); _cut.getID(ignorableURI, _isPredicate); verify(_decoratee).getID(ignorableURI, _isPredicate); } }
boolean contains(final String prefix) { for (final String domain : _domains) { if (domain.equals(prefix)) { return true; } } return false; }
KnownURIsDictionary extends SingleIndexValueDictionary implements ManageableKnownURIsDictionary { boolean contains(final String prefix) { for (final String domain : _domains) { if (domain.equals(prefix)) { return true; } } return false; } }
KnownURIsDictionary extends SingleIndexValueDictionary implements ManageableKnownURIsDictionary { boolean contains(final String prefix) { for (final String domain : _domains) { if (domain.equals(prefix)) { return true; } } return false; } KnownURIsDictionary(final String id, final ITopLevelDictionary decoratee);  KnownURIsDictionary(final String id, final ITopLevelDictionary decoratee, final String ... domains); }
KnownURIsDictionary extends SingleIndexValueDictionary implements ManageableKnownURIsDictionary { boolean contains(final String prefix) { for (final String domain : _domains) { if (domain.equals(prefix)) { return true; } } return false; } KnownURIsDictionary(final String id, final ITopLevelDictionary decoratee);  KnownURIsDictionary(final String id, final ITopLevelDictionary decoratee, final String ... domains); @Override void initialiseInternal(final DataAccessLayerFactory factory); @Override void removeValue(final Value value, final boolean p); @Override boolean isBNode(final byte[] id); @Override boolean isLiteral(final byte[] id); @Override boolean isResource(final byte[] id); @Override long getIdKnownURIsHitsCount(); @Override long getValueKnownURIsHitsCount(); }
KnownURIsDictionary extends SingleIndexValueDictionary implements ManageableKnownURIsDictionary { boolean contains(final String prefix) { for (final String domain : _domains) { if (domain.equals(prefix)) { return true; } } return false; } KnownURIsDictionary(final String id, final ITopLevelDictionary decoratee);  KnownURIsDictionary(final String id, final ITopLevelDictionary decoratee, final String ... domains); @Override void initialiseInternal(final DataAccessLayerFactory factory); @Override void removeValue(final Value value, final boolean p); @Override boolean isBNode(final byte[] id); @Override boolean isLiteral(final byte[] id); @Override boolean isResource(final byte[] id); @Override long getIdKnownURIsHitsCount(); @Override long getValueKnownURIsHitsCount();  }