001/* 002 * Licensed to DuraSpace under one or more contributor license agreements. 003 * See the NOTICE file distributed with this work for additional information 004 * regarding copyright ownership. 005 * 006 * DuraSpace licenses this file to you under the Apache License, 007 * Version 2.0 (the "License"); you may not use this file except in 008 * compliance with the License. You may obtain a copy of the License at 009 * 010 * http://www.apache.org/licenses/LICENSE-2.0 011 * 012 * Unless required by applicable law or agreed to in writing, software 013 * distributed under the License is distributed on an "AS IS" BASIS, 014 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 015 * See the License for the specific language governing permissions and 016 * limitations under the License. 017 */ 018 019package org.fcrepo.http.commons.responses; 020 021import org.apache.jena.graph.Triple; 022import org.apache.jena.riot.system.StreamRDF; 023import org.apache.jena.riot.system.StreamRDFWrapper; 024import org.apache.jena.sparql.core.Quad; 025 026/** 027 * @author Daniel Bernstein 028 * @since Mar 22, 2017 029 */ 030public class SynchonizedStreamRDFWrapper extends StreamRDFWrapper { 031 032 /** 033 * 034 * @param stream the StreamRDF 035 */ 036 public SynchonizedStreamRDFWrapper(final StreamRDF stream) { 037 super(stream); 038 } 039 040 /* 041 * (non-Javadoc) 042 * @see org.apache.jena.riot.system.StreamRDFWrapper#start() 043 */ 044 @Override 045 public synchronized void start() { 046 super.start(); 047 } 048 049 /* 050 * (non-Javadoc) 051 * @see org.apache.jena.riot.system.StreamRDFWrapper#finish() 052 */ 053 @Override 054 public synchronized void finish() { 055 super.finish(); 056 } 057 058 /* 059 * (non-Javadoc) 060 * @see org.apache.jena.riot.system.StreamRDFWrapper#triple(org.apache.jena.graph.Triple) 061 */ 062 @Override 063 public synchronized void triple(final Triple triple) { 064 super.triple(triple); 065 } 066 067 /* 068 * (non-Javadoc) 069 * @see org.apache.jena.riot.system.StreamRDFWrapper#prefix(java.lang.String, java.lang.String) 070 */ 071 @Override 072 public synchronized void prefix(final String prefix, final String iri) { 073 super.prefix(prefix, iri); 074 } 075 076 /* 077 * (non-Javadoc) 078 * @see org.apache.jena.riot.system.StreamRDFWrapper#quad(org.apache.jena.sparql.core.Quad) 079 */ 080 @Override 081 public synchronized void quad(final Quad quad) { 082 super.quad(quad); 083 } 084 085}