Re: How Can I Access Properties of Script Applications?
Re: How Can I Access Properties of Script Applications?
- Subject: Re: How Can I Access Properties of Script Applications?
- From: "S. J. Cunningham" <email@hidden>
- Date: Mon, 09 Mar 2015 21:12:38 -0400
On Mar 9, 2015, at 7:53 PM, Shane Stanley wrote:
> On 10 Mar 2015, at 9:46 am, S. J. Cunningham <email@hidden> wrote:
>>
>> But if you want to access multiple properties it requires multiple handlers [...]. Not undoable, but messy and inelegant.
>
> Each to their own opinion, but the concept of encapsulating instance variables (which is what AS properties are, essentially) and requiring accessors for external access to them is one of the fundamentals of object-oriented programming. So you might be advised to be a little careful where you start calling it messy and inelegant
The inelegance referred to my way of doing it. I guess I was puzzled why you can access the properties of script objects directly but not script applications. I don't claim to have any expertise in object-oriented programming but why doesn't the same logic apply to both? When I create an instance of a script object, aren't it's properties instance variables?
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden