Exemple #1
0
    def __init__(self):
        # create document
        self.ptr = libsbol.createDocument()

        # create sequences array
        fns = (libsbol.getNumDNASequences, libsbol.getNthDNASequence)
        self.sequences = SBOLObjectArray(self, *fns)

        # create annotations array
        fns = (libsbol.getNumSequenceAnnotations,
               libsbol.getNthSequenceAnnotation)
        self.annotations = SBOLObjectArray(self, *fns)

        # create components array
        fns = (libsbol.getNumDNAComponents, libsbol.getNthDNAComponent)
        self.components = SBOLObjectArray(self, *fns)

        # create collections array
        fns = (libsbol.getNumCollections, libsbol.getNthCollection)
        self.collections = SBOLObjectArray(self, *fns)

        # create lists of Python proxy objects to keep them
        # from being garbage collected, and for looking up
        # objects from SWIG pointers
        self._sequences = []
        self._annotations = []
        self._components = []
        self._collections = []
Exemple #2
0
    def __init__(self):
        # create document
        self.ptr = libsbol.createDocument()

        # create sequences array
        fns = (libsbol.getNumDNASequences,
               libsbol.getNthDNASequence)
        self.sequences = SBOLObjectArray(self, *fns)

        # create annotations array
        fns = (libsbol.getNumSequenceAnnotations,
               libsbol.getNthSequenceAnnotation)
        self.annotations = SBOLObjectArray(self, *fns)

        # create components array
        fns = (libsbol.getNumDNAComponents,
               libsbol.getNthDNAComponent)
        self.components = SBOLObjectArray(self, *fns)

        # create collections array
        fns = (libsbol.getNumCollections,
               libsbol.getNthCollection)
        self.collections = SBOLObjectArray(self, *fns)

        # create lists of Python proxy objects to keep them
        # from being garbage collected, and for looking up
        # objects from SWIG pointers
        self._sequences   = []
        self._annotations = []
        self._components  = []
        self._collections = []
Exemple #3
0
    def __init__(self):
        # create document
        ## Pointer to the encapsulated libSBOLc Document object
        self.ptr = libsbol.createDocument()

        # create sequences array
        fns = (libsbol.getDNASequenceURI,
               libsbol.removeDNASequence,
               libsbol.getNumDNASequences,
               libsbol.getNthDNASequence)
        ## Registers all DNASequence objects in Document
        self.sequences = SBOLObjectArray(self, *fns)

        # create annotations array
        fns = (libsbol.getSequenceAnnotationURI,
               libsbol.removeSequenceAnnotation,
               libsbol.getNumSequenceAnnotations,
               libsbol.getNthSequenceAnnotation)
        ## Registers all SequenceAnnotation objects in Document
        self.annotations = SBOLObjectArray(self, *fns)

        # create components array
        fns = (libsbol.getDNAComponentURI,
               libsbol.removeDNAComponent,
               libsbol.getNumDNAComponents,
               libsbol.getNthDNAComponent)
        ## Registers all DNAComponent objects in Document
        self.components = SBOLObjectArray(self, *fns)

        # create collections array
        fns = (libsbol.getCollectionURI,
               libsbol.removeCollection,
               libsbol.getNumCollections,
               libsbol.getNthCollection)
        ## Registers all Collection objects in Document
        self.collections = SBOLObjectArray(self, *fns)

        # create lists of Python proxy objects to keep them
        # from being garbage collected, and for looking up
        # objects from SWIG pointers
        ## Registers all PySBOL DNASequence wrapper objects in Document
        self._sequences   = []
        ## Registers all PySBOL SequenceAnnotation wrapper objects in Document
        self._annotations = []
        ## Registers all PySBOL DNAComponent wrapper objects in Document
        self._components  = []
        ## Registers all PySBOL Collection wrapper objects in Document
        self._collections = []
Exemple #4
0
    def __init__(self):
        # create document
        ## Pointer to the encapsulated libSBOLc Document object
        self.ptr = libsbol.createDocument()

        # create sequences array
        fns = (libsbol.getDNASequenceURI, libsbol.removeDNASequence,
               libsbol.getNumDNASequences, libsbol.getNthDNASequence)
        ## Registers all DNASequence objects in Document
        self.sequences = SBOLObjectArray(self, *fns)

        # create annotations array
        fns = (libsbol.getSequenceAnnotationURI,
               libsbol.removeSequenceAnnotation,
               libsbol.getNumSequenceAnnotations,
               libsbol.getNthSequenceAnnotation)
        ## Registers all SequenceAnnotation objects in Document
        self.annotations = SBOLObjectArray(self, *fns)

        # create components array
        fns = (libsbol.getDNAComponentURI, libsbol.removeDNAComponent,
               libsbol.getNumDNAComponents, libsbol.getNthDNAComponent)
        ## Registers all DNAComponent objects in Document
        self.components = SBOLObjectArray(self, *fns)

        # create collections array
        fns = (libsbol.getCollectionURI, libsbol.removeCollection,
               libsbol.getNumCollections, libsbol.getNthCollection)
        ## Registers all Collection objects in Document
        self.collections = SBOLObjectArray(self, *fns)

        # create lists of Python proxy objects to keep them
        # from being garbage collected, and for looking up
        # objects from SWIG pointers
        ## Registers all PySBOL DNASequence wrapper objects in Document
        self._sequences = []
        ## Registers all PySBOL SequenceAnnotation wrapper objects in Document
        self._annotations = []
        ## Registers all PySBOL DNAComponent wrapper objects in Document
        self._components = []
        ## Registers all PySBOL Collection wrapper objects in Document
        self._collections = []