コード例 #1
0
    def edit(self):
        if self._annotation_pid is None:
            raise AnnotationError("pid is required for Editing")

        # Dublin Core Datastream
        if self._dc_title is not None:
            dc_annotation = "DC"
            dublin_core = Foxml.get_dublin_core_element(pid=self._annotation_pid, title=self._dc_title)
            Fedora.put_datastream(pid=self._annotation_pid, dsid=dc_annotation, element=dubln_core)
コード例 #2
0
 def test_put(self):
     ele = Foxml.get_annotation_rdf_element(pid='changeme:9', body_uri='changeme:8', body_mimetype='text/xml')
     Fedora.put_datastream(pid='changeme:9', dsid='annotation', element=ele)