View Javadoc
1   /**
2    * Licensed to the Apache Software Foundation (ASF) under one
3    * or more contributor license agreements. See the NOTICE file
4    * distributed with this work for additional information
5    * regarding copyright ownership. The ASF licenses this file
6    * to you under the Apache License, Version 2.0 (the
7    * "License"); you may not use this file except in compliance
8    * with the License.  You may obtain a copy of the License at
9    *
10   *     http://www.apache.org/licenses/LICENSE-2.0
11   *
12   * Unless required by applicable law or agreed to in writing, software
13   * distributed under the License is distributed on an "AS IS" BASIS,
14   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15   * See the License for the specific language governing permissions and
16   * limitations under the License.
17   */
18  package org.apache.commons.rdf.api;
19  
20  /**
21   * Factory for creating RDFTerm instances..
22   * <p>
23   * This interface is <strong>deprecated</strong> in favour of the richer
24   * {@link RDF}.
25   * 
26   * @see RDF
27   */
28  @Deprecated
29  public interface RDFTermFactory {
30  
31      default BlankNode createBlankNode() throws UnsupportedOperationException {
32          throw new UnsupportedOperationException("createBlankNode() not supported");
33      }
34  
35      default BlankNode createBlankNode(final String name) throws UnsupportedOperationException {
36          throw new UnsupportedOperationException("createBlankNode(String) not supported");
37      }
38  
39      default Graph createGraph() throws UnsupportedOperationException {
40          throw new UnsupportedOperationException("createGraph() not supported");
41      }
42  
43      default IRI createIRI(final String iri) throws IllegalArgumentException, UnsupportedOperationException {
44          throw new UnsupportedOperationException("createIRI(String) not supported");
45      }
46  
47      default Literal createLiteral(final String lexicalForm) throws IllegalArgumentException, UnsupportedOperationException {
48          throw new UnsupportedOperationException("createLiteral(String) not supported");
49      }
50  
51      default Literal createLiteral(final String lexicalForm, final IRI dataType)
52              throws IllegalArgumentException, UnsupportedOperationException {
53          throw new UnsupportedOperationException("createLiteral(String) not supported");
54      }
55  
56      default Literal createLiteral(final String lexicalForm, final String languageTag)
57              throws IllegalArgumentException, UnsupportedOperationException {
58          throw new UnsupportedOperationException("createLiteral(String,String) not supported");
59      }
60  
61      default Triple createTriple(final BlankNodeOrIRI subject, final IRI predicate, final RDFTerm object)
62              throws IllegalArgumentException, UnsupportedOperationException {
63          throw new UnsupportedOperationException("createTriple(BlankNodeOrIRI,IRI,RDFTerm) not supported");
64      }
65  
66  }