[Biopython-dev] User friendly files

Jeffrey Chang jchang at SMI.Stanford.EDU
Wed May 30 02:58:49 EDT 2001


I think this is a good idea, but the timing may be a little off.  Would this
have applications beyond writing parsers?  We're trying to encourage people
to start using Martel and RecordReader, which essentially does this too.

Jeff


> From: "Cayte" <katel at worldpath.net>
> Date: Mon, 28 May 2001 22:58:31 -0700
> To: <biopython-dev at biopython.org>
> Subject: [Biopython-dev] User friendly files
> 
> .  I was thinking of ideas to minimize the need to edit, cut and paste
> files.  One idea is to subclass File and add a read_record_line routine.
> This would contain a state machine.  The SEARCHING_FOR_RECORD state would
> discard lines  up to the start of record tag, and retiurn this line and
> advance to the RECORD_FOUND state.  In the RECORD_FOUND state,
> read_record_line would call readline.  At the end of record tag it would
> advance to the END_RECORD state.  The next call would return an empty state
> and return to SEARCHING_FOR_RECORD.  The state would always go to the
> END_OF_FILE when the code finished reading all the file contents.  The state
> would go to an UNKNOWN state if the user forced the file pointer.
> 
> I feel the easier our tools are the more likey they'll be used.  Please
> share your ideas.
> 
> Cayte
> 
> _______________________________________________
> Biopython-dev mailing list
> Biopython-dev at biopython.org
> http://biopython.org/mailman/listinfo/biopython-dev
> 




More information about the Biopython-dev mailing list