[Gambas-user] protected for a variable inherited from a class
Jussi Lahtinen
jussi.lahtinen at gmail.com
Thu Apr 20 22:36:16 CEST 2023
No, sorry I messed up. Inherent private variables/subs/functions can only
be overridden, not accessed.
If class1 is merely a base class, then you can prevent its usage with
"create private". But not just a single variable/method.
Jussi
On Thu, Apr 20, 2023 at 10:25 PM Mayost Sharon <sharon at 455.co.il> wrote:
> Hello
>
> Is there a way to access a variable inherited from class1
> but
> that it will not be visible to other non-inherited classes
>
> something like this:
> https://www.w3schools.com/cpp/cpp_inheritance_access.asp
>
> I tried to think maybe with: STATIC PRIVATE
> But it's not working
>
>
> Many thanks to everyone
>
> ----[ http://gambaswiki.org/wiki/doc/netiquette ]----
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20230420/933794ae/attachment.htm>
More information about the User
mailing list