Previous CloneSet | Next CloneSet | Back to Main Report |
Clone Mass | Clones in CloneSet | Parameter Count | Clone Similarity | Syntax Category [Sequence Length] |
---|---|---|---|---|
29 | 3 | 4 | 0.991 | stmt_list[3] |
Clone Abstraction | Parameter Bindings |
Clone Instance (Click to see clone) | Line Count | Source Line | Source File |
---|---|---|---|
1 | 26 | 61 | Bio/Enzyme/__init__.py |
2 | 26 | 325 | Bio/Prosite/__init__.py |
3 | 29 | 288 | Bio/SwissProt/SProt.py |
| ||||
def _scan_line(self,line_type,uhandle,event_fn,exactly_one = None,one_or_more = None,any_number = None,up_to_one = None): # Callers must set exactly one of exactly_one, one_or_more, or # any_number to a true value. I do not explicitly check to # make sure this function is called correctly. # This does not guarantee any parameter safety, but I # like the readability. The other strategy I tried was have # parameters min_lines, max_lines. if exactly_one or one_or_more: read_and_call(uhandle,event_fn,start = line_type) if one_or_more or any_number: while 1: if not attempt_read_and_call(uhandle,event_fn,start = line_type): break if up_to_one: attempt_read_and_call(uhandle,event_fn,start = line_type) def _scan_id(self,uhandle,consumer): self._scan_line("ID",uhandle,consumer.identification,exactly_one = 1) def _scan_de(self,uhandle,consumer): self._scan_line("DE",uhandle,consumer.description,one_or_more = 1) |
| ||||
def _scan_line(self,line_type,uhandle,event_fn,exactly_one = None,one_or_more = None,any_number = None,up_to_one = None): # Callers must set exactly one of exactly_one, one_or_more, or # any_number to a true value. I do not explicitly check to # make sure this function is called correctly. # This does not guarantee any parameter safety, but I # like the readability. The other strategy I tried was have # parameters min_lines, max_lines. if exactly_one or one_or_more: read_and_call(uhandle,event_fn,start = line_type) if one_or_more or any_number: while 1: if not attempt_read_and_call(uhandle,event_fn,start = line_type): break if up_to_one: attempt_read_and_call(uhandle,event_fn,start = line_type) def _scan_id(self,uhandle,consumer): self._scan_line("ID",uhandle,consumer.identification,exactly_one = 1) def _scan_ac(self,uhandle,consumer): self._scan_line("AC",uhandle,consumer.accession,exactly_one = 1) |
| ||||
def _scan_line(self,line_type,uhandle,event_fn,exactly_one = None,one_or_more = None,any_number = None,up_to_one = None): # Callers must set exactly one of exactly_one, one_or_more, or # any_number to a true value. I do not explicitly check to # make sure this function is called correctly. # This does not guarantee any parameter safety, but I # like the readability. The other strategy I tried was have # parameters min_lines, max_lines. if exactly_one or one_or_more: read_and_call(uhandle,event_fn,start = line_type) if one_or_more or any_number: while 1: if not attempt_read_and_call(uhandle,event_fn,start = line_type): break if up_to_one: attempt_read_and_call(uhandle,event_fn,start = line_type) def _scan_id(self,uhandle,consumer): self._scan_line("ID",uhandle,consumer.identification,exactly_one = 1) def _scan_ac(self,uhandle,consumer): # Until release 38, this used to match exactly_one. # However, in release 39, 1A02_HUMAN has 2 AC lines, and the # definition needed to be expanded. self._scan_line("AC",uhandle,consumer.accession,any_number = 1) |
| |||
def _scan_line(self,line_type,uhandle,event_fn,exactly_one = None,one_or_more = None,any_number = None,up_to_one = None): # Callers must set exactly one of exactly_one, one_or_more, or # any_number to a true value. I do not explicitly check to # make sure this function is called correctly. # This does not guarantee any parameter safety, but I # like the readability. The other strategy I tried was have # parameters min_lines, max_lines. if exactly_one or one_or_more: read_and_call(uhandle,event_fn,start = line_type) if one_or_more or any_number: while 1: if not attempt_read_and_call(uhandle,event_fn,start = line_type): break if up_to_one: attempt_read_and_call(uhandle,event_fn,start = line_type) def _scan_id(self,uhandle,consumer): self._scan_line("ID",uhandle,consumer.identification,exactly_one = 1) def [[#variable3082c6a0]](self,uhandle,consumer): # Until release 38, this used to match exactly_one. # However, in release 39, 1A02_HUMAN has 2 AC lines, and the # definition needed to be expanded. self._scan_line( [[#variable5d24e3e0]],uhandle,consumer. [[#variable3082c660]], [[#variable5d7453a0]]= 1) |
CloneAbstraction |
Parameter Index | Clone Instance | Parameter Name | Value |
---|---|---|---|
1 | 1 | [[#3082c6a0]] | _scan_ac |
1 | 2 | [[#3082c6a0]] | _scan_ac |
1 | 3 | [[#3082c6a0]] | _scan_de |
2 | 1 | [[#5d24e3e0]] | "AC" |
2 | 2 | [[#5d24e3e0]] | "AC" |
2 | 3 | [[#5d24e3e0]] | "DE" |
3 | 1 | [[#3082c660]] | accession |
3 | 2 | [[#3082c660]] | accession |
3 | 3 | [[#3082c660]] | description |
4 | 1 | [[#5d7453a0]] | any_number |
4 | 2 | [[#5d7453a0]] | exactly_one |
4 | 3 | [[#5d7453a0]] | one_or_more |