Package org.bridgedb.rdf
Class UriPattern
- java.lang.Object
-
- org.bridgedb.rdf.RdfBase
-
- org.bridgedb.rdf.UriPattern
-
- All Implemented Interfaces:
Comparable<UriPattern>
public class UriPattern extends RdfBase implements Comparable<UriPattern>
- Author:
- Christian
-
-
Field Summary
-
Fields inherited from class org.bridgedb.rdf.RdfBase
DEFAULT_BASE_URI, DEFAULT_FILE_FORMAT
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidadd(org.eclipse.rdf4j.repository.RepositoryConnection repositoryConnection)static voidaddAll(org.eclipse.rdf4j.repository.RepositoryConnection repositoryConnection)static Set<UriPattern>byCode(String code)static SortedSet<UriPattern>byCodeAndType(String code, UriPatternType patternType)static UriPatternbyPattern(String pattern)static voidcheckRegexPatterns()intcompareTo(UriPattern other)static UriPatternexistingByPattern(String pattern)static UriPatternexistingByPrefixAndPostfix(String prefix, String postfix)StringgetIdFromUri(String uri)StringgetPostfix()StringgetPrefix()org.eclipse.rdf4j.model.IRIgetResourceId()Set<String>getSysCodes()UriPatternTypegetType()StringgetUri(String id)StringgetUriPattern()static SortedSet<UriPattern>getUriPatterns()booleanhasPostfix()static UriPatternreadUriPattern(org.eclipse.rdf4j.repository.RepositoryConnection repositoryConnection, org.eclipse.rdf4j.model.Resource uriPatternId, String code, UriPatternType patternType)static voidrefreshUriPatterns()static UriPatternregister(String pattern, String sysCode, UriPatternType patternType)static voidregisterUriPatterns()StringtoString()-
Methods inherited from class org.bridgedb.rdf.RdfBase
getPossibleSingletonString, getSingletonString, shutDown
-
-
-
-
Method Detail
-
getPrefix
public String getPrefix()
-
getPostfix
public String getPostfix()
-
hasPostfix
public boolean hasPostfix()
-
refreshUriPatterns
public static void refreshUriPatterns() throws BridgeDBException- Throws:
BridgeDBException
-
registerUriPatterns
public static void registerUriPatterns() throws BridgeDBException- Throws:
BridgeDBException
-
getUriPatterns
public static SortedSet<UriPattern> getUriPatterns()
-
register
public static UriPattern register(String pattern, String sysCode, UriPatternType patternType) throws BridgeDBException
- Throws:
BridgeDBException
-
byPattern
public static UriPattern byPattern(String pattern) throws BridgeDBException
- Throws:
BridgeDBException
-
existingByPattern
public static UriPattern existingByPattern(String pattern) throws BridgeDBException
- Throws:
BridgeDBException
-
existingByPrefixAndPostfix
public static UriPattern existingByPrefixAndPostfix(String prefix, String postfix) throws BridgeDBException
- Throws:
BridgeDBException
-
getResourceId
public final org.eclipse.rdf4j.model.IRI getResourceId()
-
getUriPattern
public String getUriPattern()
-
addAll
public static void addAll(org.eclipse.rdf4j.repository.RepositoryConnection repositoryConnection) throws IOException, org.eclipse.rdf4j.repository.RepositoryException, BridgeDBException- Throws:
IOExceptionorg.eclipse.rdf4j.repository.RepositoryExceptionBridgeDBException
-
add
public void add(org.eclipse.rdf4j.repository.RepositoryConnection repositoryConnection) throws org.eclipse.rdf4j.repository.RepositoryException- Throws:
org.eclipse.rdf4j.repository.RepositoryException
-
readUriPattern
public static UriPattern readUriPattern(org.eclipse.rdf4j.repository.RepositoryConnection repositoryConnection, org.eclipse.rdf4j.model.Resource uriPatternId, String code, UriPatternType patternType) throws BridgeDBException, org.eclipse.rdf4j.repository.RepositoryException
- Throws:
BridgeDBExceptionorg.eclipse.rdf4j.repository.RepositoryException
-
compareTo
public int compareTo(UriPattern other)
- Specified by:
compareToin interfaceComparable<UriPattern>
-
getIdFromUri
public String getIdFromUri(String uri) throws BridgeDBException
- Throws:
BridgeDBException
-
byCodeAndType
public static SortedSet<UriPattern> byCodeAndType(String code, UriPatternType patternType)
-
byCode
public static Set<UriPattern> byCode(String code)
-
getType
public UriPatternType getType()
-
checkRegexPatterns
public static void checkRegexPatterns() throws BridgeDBException- Throws:
BridgeDBException
-
-