@Test public void IsAllowedGraph() { VirtuosoRepositoryConnection conn = new VirtuosoRepositoryConnection(null, null, 0, new UID(TEST.NS), Collections.<UID> emptySet(), null); assertFalse(conn.isAllowedGraph(new UID(OWL.NS))); assertFalse(conn.isAllowedGraph(new UID(RDF.NS))); assertFalse(conn.isAllowedGraph(new UID(RDFS.NS))); assertFalse(conn.isAllowedGraph(new UID("http: assertTrue(conn.isAllowedGraph(new UID(TEST.NS, "test"))); }
boolean isAllowedGraph(UID context) { return !context.getId().startsWith(INTERNAL_PREFIX) && !context.getId().equals("http: && !context.getId().equals(RDF.NS) && !context.getId().equals(RDFS.NS) && !context.getId().equals(OWL.NS) && (context.equals(defaultGraph) || allowedGraphs.isEmpty() || allowedGraphs.contains(context)); }
VirtuosoRepositoryConnection implements RDFConnection { boolean isAllowedGraph(UID context) { return !context.getId().startsWith(INTERNAL_PREFIX) && !context.getId().equals("http: && !context.getId().equals(RDF.NS) && !context.getId().equals(RDFS.NS) && !context.getId().equals(OWL.NS) && (context.equals(defaultGraph) || allowedGraphs.isEmpty() || allowedGraphs.contains(context)); } }
VirtuosoRepositoryConnection implements RDFConnection { boolean isAllowedGraph(UID context) { return !context.getId().startsWith(INTERNAL_PREFIX) && !context.getId().equals("http: && !context.getId().equals(RDF.NS) && !context.getId().equals(RDFS.NS) && !context.getId().equals(OWL.NS) && (context.equals(defaultGraph) || allowedGraphs.isEmpty() || allowedGraphs.contains(context)); } protected  VirtuosoRepositoryConnection(
            IdSequence idSequence,
            Converter converter,
            int prefetchSize,
            UID defGraph,
            Collection<UID> allowedGraphs,
            Connection connection); }
VirtuosoRepositoryConnection implements RDFConnection { boolean isAllowedGraph(UID context) { return !context.getId().startsWith(INTERNAL_PREFIX) && !context.getId().equals("http: && !context.getId().equals(RDF.NS) && !context.getId().equals(RDFS.NS) && !context.getId().equals(OWL.NS) && (context.equals(defaultGraph) || allowedGraphs.isEmpty() || allowedGraphs.contains(context)); } protected  VirtuosoRepositoryConnection(
            IdSequence idSequence,
            Converter converter,
            int prefetchSize,
            UID defGraph,
            Collection<UID> allowedGraphs,
            Connection connection); static void bindBlankNode(PreparedStatement ps, int col, BID n); static void bindResource(PreparedStatement ps, int col, ID n); static void bindURI(PreparedStatement ps, int col, UID n); static void bindValue(PreparedStatement ps, int col, NODE n); void addBulk(Collection<STMT> addedStatements); void removeBulk(Collection<STMT> deletedStatements); @Override RDFBeanTransaction beginTransaction(boolean readOnly, int txTimeout, int isolationLevel); @Override void clear(); @Override void close(); @Override BID createBNode(); @SuppressWarnings("unchecked") @Override Q createUpdate(UpdateLanguage<D, Q> updateLanguage, final D definition); @SuppressWarnings("unchecked") @Override Q createQuery(QueryLanguage<D, Q> queryLanguage, D definition); @Override boolean exists(ID subject, UID predicate, NODE object, UID context, boolean includeInferred); @Override CloseableIterator<STMT> findStatements(
            @Nullable ID subject,
            @Nullable UID predicate,
            @Nullable NODE object,
            @Nullable UID context, boolean includeInferred); Connection getConnection(); @Override long getNextLocalId(); boolean isReadOnly(); void load(Format format, InputStream is, @Nullable UID context, boolean replace); @Override void remove(ID subject, UID predicate, NODE object, UID context); @Override void update(Collection<STMT> removedStatements, Collection<STMT> addedStatements); T doInConnection(SQLConnectionCallback<T> callback); @Override QueryOptions getQueryOptions(); @Override InferenceOptions getInferenceOptions(); }
VirtuosoRepositoryConnection implements RDFConnection { boolean isAllowedGraph(UID context) { return !context.getId().startsWith(INTERNAL_PREFIX) && !context.getId().equals("http: && !context.getId().equals(RDF.NS) && !context.getId().equals(RDFS.NS) && !context.getId().equals(OWL.NS) && (context.equals(defaultGraph) || allowedGraphs.isEmpty() || allowedGraphs.contains(context)); } protected  VirtuosoRepositoryConnection(
            IdSequence idSequence,
            Converter converter,
            int prefetchSize,
            UID defGraph,
            Collection<UID> allowedGraphs,
            Connection connection); static void bindBlankNode(PreparedStatement ps, int col, BID n); static void bindResource(PreparedStatement ps, int col, ID n); static void bindURI(PreparedStatement ps, int col, UID n); static void bindValue(PreparedStatement ps, int col, NODE n); void addBulk(Collection<STMT> addedStatements); void removeBulk(Collection<STMT> deletedStatements); @Override RDFBeanTransaction beginTransaction(boolean readOnly, int txTimeout, int isolationLevel); @Override void clear(); @Override void close(); @Override BID createBNode(); @SuppressWarnings("unchecked") @Override Q createUpdate(UpdateLanguage<D, Q> updateLanguage, final D definition); @SuppressWarnings("unchecked") @Override Q createQuery(QueryLanguage<D, Q> queryLanguage, D definition); @Override boolean exists(ID subject, UID predicate, NODE object, UID context, boolean includeInferred); @Override CloseableIterator<STMT> findStatements(
            @Nullable ID subject,
            @Nullable UID predicate,
            @Nullable NODE object,
            @Nullable UID context, boolean includeInferred); Connection getConnection(); @Override long getNextLocalId(); boolean isReadOnly(); void load(Format format, InputStream is, @Nullable UID context, boolean replace); @Override void remove(ID subject, UID predicate, NODE object, UID context); @Override void update(Collection<STMT> removedStatements, Collection<STMT> addedStatements); T doInConnection(SQLConnectionCallback<T> callback); @Override QueryOptions getQueryOptions(); @Override InferenceOptions getInferenceOptions();  }