Files @ 8784bdc90648
Branch filter:

Location: light9/light9/namespaces.py

drewp@bigasterisk.com
rm external gtk themes
from rdflib import URIRef, Namespace, RDF, RDFS  # noqa
from typing import Dict


# Namespace was showing up in profiles
class FastNs:

    def __init__(self, base):
        self.ns = Namespace(base)
        self.cache: Dict[str, URIRef] = {}

    def __getitem__(self, term) -> URIRef:
        if term not in self.cache:
            self.cache[term] = self.ns[term]
        return self.cache[term]

    __getattr__ = __getitem__


L9 = FastNs("http://light9.bigasterisk.com/")
FUNC = FastNs("http://light9.bigasterisk.com/effectFunction/")
MUS = Namespace("http://light9.bigasterisk.com/music/")
XSD = Namespace("http://www.w3.org/2001/XMLSchema#")
DCTERMS = Namespace("http://purl.org/dc/terms/")
DEV = Namespace("http://light9.bigasterisk.com/device/")