Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re: Perl 6 property mini-tutorial

by John M. Dlugosz (Monsignor)
on Aug 28, 2003 at 17:56 UTC ( [id://287473]=note: print w/replies, xml ) Need Help??


in reply to Perl 6 property mini-tutorial
in thread Perl 6 'is dim' point

Thanks for the additional information.

I suppose the "property methods" basically is a function that is given the thing to which it is applying, and it can monkey with it any way it wants.

—John

Replies are listed 'Best First'.
Re: Re: Perl 6 property mini-tutorial
by TheDamian (Vicar) on Aug 29, 2003 at 00:37 UTC
    Yes, exactly. Each property method is a method (i.e. an class-specific function) that can be set up to do a particular kind of monkeying with the referent to which the original property was applied.

    The two main advantages of encapsulating these functions in classes are that anyone who is defining a property can provide state (i.e. class attributes) for that property if necessary, and can also create sets of related properties using inheritance.

    A more subtle advantage is that using a class-based interface for specifying properties gives us a clean way to extend that interface at a later time, should we miss some useful feature in the initial design.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://287473]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (4)
As of 2024-04-18 04:10 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found