-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
e7393ea
commit 440fbdc
Showing
1 changed file
with
18 additions
and
2 deletions.
There are no files selected for viewing
20 changes: 18 additions & 2 deletions
20
atramhasis/scaffolds/atramhasis_scaffold/+package+/skos/__init__.py_tmpl
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,25 @@ | ||
# -*- coding: utf-8 -*- | ||
from skosprovider.registry import Registry | ||
from skosprovider.uri import UriPatternGenerator | ||
from skosprovider_sqlalchemy.providers import SQLAlchemyProvider | ||
|
||
import logging | ||
log = logging.getLogger(__name__) | ||
|
||
|
||
def includeme(config): | ||
skosregis = config.get_skos_registry() | ||
def create_registry(request): | ||
# create the SKOS registry | ||
registry = Registry(instance_scope='threaded_thread') | ||
|
||
# create your own providers | ||
# | ||
# TREES = SQLAlchemyProvider( | ||
# {'id': 'TREES', 'conceptscheme_id': 1}, | ||
# request.db | ||
# ) | ||
|
||
# Add your custom provider to the registry | ||
# registry.register_provider(TREES) | ||
|
||
# return the SKOS registry | ||
return registry |