Added some view class methods
This commit is contained in:
@ -67,6 +67,9 @@ cdef class OBIView:
|
|||||||
cpdef select_line(self, index_t line_nb)
|
cpdef select_line(self, index_t line_nb)
|
||||||
cpdef select_lines(self, list line_selection)
|
cpdef select_lines(self, list line_selection)
|
||||||
cpdef save_and_close(self)
|
cpdef save_and_close(self)
|
||||||
|
cpdef str get_name(self)
|
||||||
|
cpdef dict get_columns(self)
|
||||||
|
cpdef int get_line_count(self)
|
||||||
|
|
||||||
|
|
||||||
cdef class OBIView_NUC_SEQS(OBIView):
|
cdef class OBIView_NUC_SEQS(OBIView):
|
||||||
|
@ -292,7 +292,7 @@ cdef class OBIView :
|
|||||||
self.pointer = view
|
self.pointer = view
|
||||||
self.name = bytes2str(view.infos.name)
|
self.name = bytes2str(view.infos.name)
|
||||||
|
|
||||||
# Go through columns to build list of corresponding python instances
|
# Go through columns to build dictionaries of corresponding python instances
|
||||||
self.columns = {}
|
self.columns = {}
|
||||||
for i in range(view.infos.column_count) :
|
for i in range(view.infos.column_count) :
|
||||||
column_p = <OBIDMS_column_p> (view.columns)[i]
|
column_p = <OBIDMS_column_p> (view.columns)[i]
|
||||||
@ -463,6 +463,18 @@ cdef class OBIView :
|
|||||||
return to_print
|
return to_print
|
||||||
|
|
||||||
|
|
||||||
|
cpdef str get_name(self):
|
||||||
|
return self.name
|
||||||
|
|
||||||
|
|
||||||
|
cpdef dict get_columns(self):
|
||||||
|
return self.columns
|
||||||
|
|
||||||
|
|
||||||
|
cpdef int get_line_count(self) :
|
||||||
|
return self.pointer.infos.line_count
|
||||||
|
|
||||||
|
|
||||||
#############################################
|
#############################################
|
||||||
|
|
||||||
cdef class OBIView_NUC_SEQS(OBIView):
|
cdef class OBIView_NUC_SEQS(OBIView):
|
||||||
|
Reference in New Issue
Block a user