Re: [Vala] [Genie] Object members
- From: Jamie McCracken <jamie mccrack googlemail com>
- To: lemeia bigpond com
- Cc: vala-list gnome org
- Subject: Re: [Vala] [Genie] Object members
- Date: Wed, 28 Oct 2009 11:05:00 -0400
On Thu, 2009-10-29 at 01:50 +1100, Patrick Castle wrote:
Thanks for that. I looked back at the Genie page and did a bit of Googling. I think I understand the
distinction between field and property. It would seem from a good practice point of view that fields would
generally be private and properties would generally be public. Would that be a reasonable way to explain
it? If so - I understand where I would want to use one or the other.
no
You would use a property mainly for design time setting as they can be
introspected (EG think glade and setting properties on a widget when
designing) or if you needed explicit getter/setter methods or the
ability to override them.
Fields by comparison are for runtime usage only and cannot be
introspected nor can they have get/set methods or be readonly or
virtual/overridable etc
jamie
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]