def GET(self, file_path=None):
     director = LinkedDataDirector(
         c["occ_base_path"],
         c["html"],
         c["oc_base_url"],
         c["json_context_path"],
         c["corpus_local_url"],
         label_conf={
             "http://www.w3.org/1999/02/22-rdf-syntax-ns#type": "is a",
             "http://xmlns.com/foaf/0.1/givenName": "given name",
             "http://xmlns.com/foaf/0.1/familyName": "family name",
             "http://prismstandard.org/namespaces/basic/2.0/startingPage":
             "first page",
             "http://prismstandard.org/namespaces/basic/2.0/endingPage":
             "last page",
             "http://purl.org/dc/terms/issued": "publication date",
             "http://purl.org/dc/terms/modified": "modification date",
             "http://purl.org/spar/biro/references": "references"
         },
         tmp_dir=c["tmp_dir"],
         dir_split_number=int(c["dir_split_number"]),
         file_split_number=int(c["file_split_number"]))
     cur_page = director.redirect(file_path)
     if cur_page is None:
         raise web.notfound()
     else:
         web_logger.mes()
         return cur_page
Beispiel #2
0
 def GET(self, file_path=None):
     ldd = LinkedDataDirector(
         c["occ_base_path"], c["html"], c["oc_base_url"],
         c["json_context_path"], c["corpus_local_url"],
         label_conf=c["label_conf"], tmp_dir=c["tmp_dir"],
         dir_split_number=int(c["dir_split_number"]),
         file_split_number=int(c["file_split_number"]))
     cur_page = ldd.redirect(file_path)
     if cur_page is None:
         raise web.notfound()
     else:
         web_logger.mes()
         return cur_page
Beispiel #3
0
 def GET(self, file_path=None):
     ldd = LinkedDataDirector(c["occ_base_path"],
                              c["html"],
                              c["oc_base_url"],
                              c["json_context_path"],
                              c["corpus_local_url"],
                              label_conf=c["label_conf"],
                              tmp_dir=c["tmp_dir"],
                              dir_split_number=int(c["dir_split_number"]),
                              file_split_number=int(c["file_split_number"]))
     cur_page = ldd.redirect(file_path)
     if cur_page is None:
         raise web.notfound()
     else:
         web_logger.mes()
         return cur_page
Beispiel #4
0
 def GET(self, file_path=None):
     ldd = LinkedDataDirector(c["occ_base_path"],
                              c["html"],
                              self.base_url,
                              self.context_path,
                              self.local_url,
                              label_conf=c["label_conf"],
                              tmp_dir=c["tmp_dir"],
                              dir_split_number=int(c["dir_split_number"]),
                              file_split_number=int(c["file_split_number"]),
                              default_dir=c["default_dir"],
                              from_triplestore=self.from_triplestore,
                              label_func=self.label_func)
     cur_page = ldd.redirect(file_path)
     if cur_page is None:
         raise web.notfound()
     else:
         web_logger.mes()
         return cur_page