org.trellisldp.api.NamespaceServicepublic class NamespacesJsonContext
extends java.lang.Object
implements org.trellisldp.api.NamespaceService
| Modifier and Type | Field | Description |
|---|---|---|
static java.lang.String |
NAMESPACES_PATH |
| Constructor | Description |
|---|---|
NamespacesJsonContext() |
Create a JSON-based Namespace service.
|
NamespacesJsonContext(java.lang.String path) |
Create a JSON-based Namespace service.
|
| Modifier and Type | Method | Description |
|---|---|---|
java.util.Optional<java.lang.String> |
getNamespace(java.lang.String prefix) |
|
java.util.Map<java.lang.String,java.lang.String> |
getNamespaces() |
|
java.util.Optional<java.lang.String> |
getPrefix(java.lang.String namespace) |
|
java.lang.Boolean |
setPrefix(java.lang.String prefix,
java.lang.String namespace) |
public static final java.lang.String NAMESPACES_PATH
@Inject public NamespacesJsonContext()
public NamespacesJsonContext(java.lang.String path)
path - the path to the JSON filepublic java.util.Map<java.lang.String,java.lang.String> getNamespaces()
getNamespaces in interface org.trellisldp.api.NamespaceServicepublic java.util.Optional<java.lang.String> getNamespace(java.lang.String prefix)
getNamespace in interface org.trellisldp.api.NamespaceServicepublic java.util.Optional<java.lang.String> getPrefix(java.lang.String namespace)
getPrefix in interface org.trellisldp.api.NamespaceServicepublic java.lang.Boolean setPrefix(java.lang.String prefix,
java.lang.String namespace)
setPrefix in interface org.trellisldp.api.NamespaceService