/** Add all vocabulary items from all declaring classes. */ private void addAllDecls() { for (VocabularyDecl decl : decls) { final Iterator<URI> itr = decl.values(); while (itr.hasNext()) { // Convert to BigdataValues when adding to the collection. final BigdataValue value = valueFactory.asValue(itr.next()); // Add to the collection. if (val2iv.put(value, value) != null) { /* * This has already been declared by some vocabulary. There * is no harm in this, but the vocabularies should be * distinct. */ log.warn("Duplicate declaration: " + value); } else { if (log.isDebugEnabled()) log.debug(decl.getClass().getName() + ":" + value); } } } }
/** * Add a declared vocabulary. * * @param decl The vocabulary declaration. */ protected final void addDecl(final VocabularyDecl decl) { if (decl == null) throw new IllegalArgumentException(); if (log.isInfoEnabled()) log.info(decl.getClass().getName()); decls.add(decl); }