[vlc-devel] commit: New C++ binding for libvlc. ( Rémi Duraffort )

Rémi Duraffort ivoire at videolan.org
Tue Jan 26 11:02:27 CET 2010


Hello,
> Why having a private getter for the instance ? If this getter is
> called, then the caller also has access to the private instance.
You are right.


> If you are really sure you want to use c++'s exception, I'd recommend
> you inherit std::exception.
> I like the use of the raii pattern for the exception :) that's pretty sexy :)
About the use of exceptions I don't really know what to do:
 * For the constructor that's cleaner to use exceptions.
 * For the others functions I don't really know. That's easier to return
error code this way but the applications using libvlc might want to
ignore some. For example for the function MediaPlayer::lenght, how can I
return an error without an exception (giving an argument for the error
code is not really cleaner) ?


> The last remark kinda break the thread chronology, but please, no,
> don't use overload to differenciate getters and setters. The "let's
> use c++ features" argument is void, otherwise let's overload "operator
> ,". I'm sure it can be used somehow.
I totally agree !


Best regards

-- 
Rémi Duraffort | ivoire



More information about the vlc-devel mailing list