Examples of StoreTransaction


Examples of com.hp.hpl.jena.gvs.StoreTransaction

          }
          final FCAGraph revokeGraph = revokeGraphTmp;
          final FCAGraph assertGraph = new FCAGraphImpl(graph);
          // store.assertGraph(identity, new FCAGraphImpl(graph),
          // now);
          store.perform(identity, new StoreTransaction() {

            public void execute(SourceStoreView storeView) {
              if (revokeGraph != null)
                storeView.revokeGraph(revokeGraph);
              storeView.assertGraph(assertGraph);
View Full Code Here

Examples of com.hp.hpl.jena.gvs.StoreTransaction

   * @param now
   * @param aggregatedSource
   * @param logEntryGraph
   */
  private static void updateWorkingGraph(Store store, Source identity, Date now, final Source aggregatedSource, final Graph logEntryGraph) {
    store.perform(identity, new StoreTransaction() {

      public void execute(SourceStoreView storeView) {
        SimpleGraph newWorkingGraph = new SimpleGraph();
        FCAGraph oldWorkingGraph = storeView.getGraph();
        Node downloadAttemptNode = null;
View Full Code Here

Examples of com.hp.hpl.jena.gvs.StoreTransaction

    infoBitResource.addProperty(DISCOBITS.mediaType, formFile
        .getMimeType().toString());
    infoBitResource.addProperty(DISCOBITS.bytes, editableModel
        .createTypedLiteral(formFile.getContent()));
    infoBitResource.addProperty(RDF.type, DISCOBITS.InfoBit);
    store.perform(identity, new StoreTransaction() {

      public void execute(SourceStoreView storeView) {
        NamedNode locationNode = new NamedNodeImpl(locationString);
        FCAGraph origGraph = storeView.getGraph().filter(
            Collections.singleton((GroundedNode) locationNode));
View Full Code Here

Examples of com.hp.hpl.jena.gvs.StoreTransaction

      for (String uriString : resourceURIStrings) {
        onlyForGroundedNodes.add(new NamedNodeImpl(uriString));
      }
      // response.setBody(reconstructGraph(filterableDecomposition,
      // onlyForGroundedNodes));
      store.perform(source, new StoreTransaction() {

        public void execute(SourceStoreView storeView) {
          FCAGraph fcaGraph = storeView.getGraph();
          storeView
              .revokeGraph(fcaGraph.filter(onlyForGroundedNodes));
View Full Code Here

Examples of com.thinkaurelius.titan.diskstorage.keycolumnvalue.StoreTransaction

        } while (retryAttempts<maxRetryAttempts);
        throw new TitanException("Could not successfully complete backend operation due to repeated temporary exceptions after "+maxRetryAttempts+" attempts",lastException);
    }

    public static<R> R execute(Transactional<R> exe, TransactionalProvider provider) throws StorageException {
        StoreTransaction txh = null;
        try {
            txh = provider.openTx();
            return exe.call(txh);
        } catch (StorageException e) {
            if (txh!=null) txh.rollback();
            txh=null;
            throw e;
        } finally {
            if (txh!=null) txh.commit();
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.