[Biococoa-dev] more ramblings
Alexander Griekspoor
mek at mekentosj.com
Wed Dec 1 13:41:02 EST 2004
>>> The question then becomes how to determine which type of sequence to
>>> return.
>>> The way I would imagine is to have a flag to determine whether to ask
>>> for
>>> user input - this could put up a standard dialog box. If the flag is
>>> false,
>>> the factory method could create each type of possible sequence, then
>>> use the
>>> sequence counted set to look for undefined symbols. Compare the
>>> results,
>>> and take the one with the fewest undefined symbols. In case of a
>>> tie,
>>> default to DNA>RNA>protein.
>>
>> Sounds good, this code can also go in the factory class. However, I
>> don't think we should use a dialog box for the framework. This is the
>> sole responsibility of the developer who uses BioCocoa.
>
> Okay, skip the dialog. I'll try to spare some time this evening to
> implement this, since it's my idea and seems on the surface to be
> fairly
> simple (I'm sure that will be wrong). I guess it would go in the case
> BCSequence untyped section of the code you showed.
Ok guys I'll just sit back and relax while you two work this out....
>> If we add code to a wrapper that checks if the type of sequence then I
>> don't see any problem. If the sequence type by accident is the wrong
>> one (which I really don't think is going to happen), the wrapper
>> should
>> return nil, or an error, or an NSNotification. Hope that's more clear.
>
> You haven't coded for actual users much have you? ;).
> You'd be amazed at
> the seemingly impossible situations they generate on a regular basis -
> anything can and will happen.
That's quite a bold statement IMHO, in addition if your users do
impossible things, rethink your interface I would suggest...
Plus, we're not talking about end users here anyway...
>
> Anyway, personally, I feel that throwing errors at compile time rather
> than
> while a program is running is the better option
My point exactly! Tell the developer he does a stupid thing (or help
him to prevent his users do stupid things).
> , but I have no problem being
> outvoted on this. A compromise would be to have the wrapper accept any
> sequence, but only add the one liner to the specific sequence class
> that
> should call that method.
Sorry, but I have no clue what you're discussing here, what is the
problem with convenience methods in all (sub)classes?
Alex
*********************************************************
** Alexander Griekspoor **
*********************************************************
The Netherlands Cancer Institute
Department of Tumorbiology (H4)
Plesmanlaan 121, 1066 CX, Amsterdam
Tel: + 31 20 - 512 2023
Fax: + 31 20 - 512 2029
E-mail: a.griekspoor at nki.nl
AIM: mekentosj at mac.com
Web: http://www.mekentosj.com
EnzymeX - To cut or not to cut
http://www.mekentosj.com/enzymex
*********************************************************
*********************************************************
** Alexander Griekspoor **
*********************************************************
The Netherlands Cancer Institute
Department of Tumorbiology (H4)
Plesmanlaan 121, 1066 CX, Amsterdam
Tel: + 31 20 - 512 2023
Fax: + 31 20 - 512 2029
AIM: mekentosj at mac.com
E-mail: a.griekspoor at nki.nl
Web: http://www.mekentosj.com
iRNAi, do you?
http://www.mekentosj.com/irnai
*********************************************************
More information about the Biococoa-dev
mailing list