C
Claudio Bustos Navarrete
Hi:
I'm the developer of rb_cdio, a library to create bindings for libcdio.
I'm currently implementing the audio related functions of the library. CdIo=
::Cd is the base class and there are 5 methods related to CDDA: play, stop,=
pause, resume and subchannels(retrieve current information, like state of =
device, time and others).
I have to methods to create a Cd object: CdIo:pen (a la File:pen) and C=
d.new
Now, the question: is not very correct implement the audio functions on the=
Cd object by default. So, I have two options:
- subclass: create a CdIo::Cdda class, subclass of CdIo::Cd. So, CdIo:pen=
could instance the correct class according to the disc type. The positive =
consequence is that is easy to verify that the new object is a cdda type
- extending: create a CdIo::Cdda module. In CdIo::Cd, if the disc is cdda t=
ype, I extends the class with the audio methods. To me, is the best, becau=
se I easy to handle cd with mixed contents.
Can you give some advice? Thank you in advancec.
=20
Excuse me for my poor english (spanish is my native language)
--=20
Claudio Bustos Navarrete
Psic=F3logo
(e-mail address removed)
I'm the developer of rb_cdio, a library to create bindings for libcdio.
I'm currently implementing the audio related functions of the library. CdIo=
::Cd is the base class and there are 5 methods related to CDDA: play, stop,=
pause, resume and subchannels(retrieve current information, like state of =
device, time and others).
I have to methods to create a Cd object: CdIo:pen (a la File:pen) and C=
d.new
Now, the question: is not very correct implement the audio functions on the=
Cd object by default. So, I have two options:
- subclass: create a CdIo::Cdda class, subclass of CdIo::Cd. So, CdIo:pen=
could instance the correct class according to the disc type. The positive =
consequence is that is easy to verify that the new object is a cdda type
- extending: create a CdIo::Cdda module. In CdIo::Cd, if the disc is cdda t=
ype, I extends the class with the audio methods. To me, is the best, becau=
se I easy to handle cd with mixed contents.
Can you give some advice? Thank you in advancec.
=20
Excuse me for my poor english (spanish is my native language)
--=20
Claudio Bustos Navarrete
Psic=F3logo
(e-mail address removed)