[Gambas-user] Sharing libraries across projects : new proposal!

Benoît Minisini gambas at ...1...
Sun Jan 31 04:55:01 CET 2016


Le 31/01/2016 01:42, Christof Thalhofer a écrit :
> Am 30.01.2016 um 20:48 schrieb Benoît Minisini:
>
>> 1) Add a new project option that allows to indicate the library search
>> directory at runtime. If specified, the libraries are searched in that
>> directory first. (Question: are multiple directories needed?)
>
> If there shall be the opportunity to embed foreign libraries, then yes,
> but as subdirs.
>
> So does it PHP with namespaces, where you can include classes with
> identical classnames but from different vendors:
>
> For example:
> 	lib/vendor1/mail.php
> 	lib/vendor2/mail.php
>
> And in your own PHP class you can say "use 'vendor1'" to point the
> classname "Mail" to lib/vendor1/mail.php.
>
>
>
> Alles Gute
>
> Christof Thalhofer
>

You can already do that, except that vendor name should be included in 
the library name.

I'm against using namespaces in Gambas, because I think it's mainly a 
workaround of the inhability to find good class names. :-)

-- 
Benoît Minisini




More information about the User mailing list