[PEAK] Re: Survey: PEAK community site

Phillip J. Eby pje at telecommunity.com
Wed Jul 7 02:56:27 EDT 2004


At 10:43 AM 7/3/04 -0700, Dave Kuhlman wrote:

>I very much need information about how to:
>
>1. Implement PEAK components.

Without a more specific use case than this, I can only say:

    from peak.api import *

    class MyComponent(binding.Component):
        pass

:)


>2. Implement PEAK components that use other PEAK components.

Again, without a more specific statement of what you want to do, I can only 
suggest:

    class MyComponent(binding.Component):

        somethingIneed = binding.Obtain(...)

Where '...' is any 'binding.IComponentKey' such as a string path, an 
interface to look up, a property name, etc.

Refer to 'self.somethingIneed' to access the something, so long as your 
component is part of an application tree.  (For how to do that, see the 
IntroToPeak tutorial on the Wiki.)


>3. Implement applications that use PEAK components.

See the IntroToPeak tutorial lessons in the Wiki, which cover quite a bit 
on building command-line apps with PEAK, and touches a fair bit on your 
other questions as well.

If you have more specific questions, please post them, and I'll do my best 
to answer them.  Thanks.




More information about the PEAK mailing list