Makes sense.

Thanks

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Friday, January 31, 2003 5:58 PM
To: CF-Talk
Subject: Re: RE: CFCs - property access best practices


2) No.  An Order class would be different than a Person class.

What you're think of is the "is-a" relationship.  For instance, a RushOrder
is an Order.  Therefore, you could extend Order to create a RushOrder class.

----- Original Message -----
From: Andy Ousterhout <[EMAIL PROTECTED]>
Date: Friday, January 31, 2003 2:39 pm
Subject: RE: CFCs - property access best practices

> Let me try to say back what I heard with an example to see if I
> understandcorrectly..
>
> A class is a generic form that is used to create specific objects as
> required.  Objects have a limited life, while classes live
> throughout the
> application.  For example, in an order management system, you may have
> classes for Users, Customers, People, Invoices, Orders and
> Payments.  When I
> create an new order, I instantiate the object from the Order
> Class, which
> contains definitions of all of the properties (or fields from my
> collegedays) and methods (no direct translation, but basically all
> of the
> activities that can happen to an order).
>
> Classes can build off of other classes in two ways:
>
> 1.  An Class can add additional properties and methods to an
> existing class,
> like User may extend Customer by adding User ID and Password
> properties and
> associated methods to those that already exist for a person.
> 2.  A Class can be built off of other classes, creating a "has-a"
> relationship.  For example, An Order is built off of multiple
> people (has-a
> Bill-To Person, has-a Ship-To Person, etc).  Is Order in this case a
> composite class?  Would a class like address be considered a Root
> class(fromVISIO).
>
> How'd I do?
>
> Andy
>
>
> -----Original Message-----
> From: Christian Cantrell [mailto:[EMAIL PROTECTED]]
> Sent: Friday, January 31, 2003 2:58 PM
> To: CF-Talk
> Subject: Re: CFCs - property access best practices
>
>
> Think of a class at a template or prototype from which object
> instancesare created.  Java files are compiled into class files,
> and class files
> are loaded from disk (usually) by the JVM's classloader and
> cached, and
> those classes are used to create instances of objects.  Also, you can
> typically think of object instances as having a relatively short life
> span.  Objects are usually instantiated, used for some purpose, and
> typically left to be garbage collected when they have gone out of
> scope.
> Does that make sense?
>
> Christian
>
> On Friday, January 31, 2003, at 10:05 AM, Andy Ousterhout wrote:
>
> > Thanks.
> >
> > I am so stoked about how easy this makes programming.  I am even
> > starting to
> > understand OO programming, although I still don't get what a
> class is.
> >  For
> > example, I thought that the Generic INVOICE was a class, while a
> > specific
> > Invoice was an object.  Now I am just confused.
> >
> > Oh well.  Keep coding and learn as you go.
> >
> > Andy
> >
> > -----Original Message-----
> > From: Raymond Camden [mailto:[EMAIL PROTECTED]]
> > Sent: Friday, January 31, 2003 8:23 AM
> > To: CF-Talk
> > Subject: RE: CFCs - property access best practices
> >
> >
> > CFCs can go in 3 places:
> >
> > Webroot (and under web root)
> > CF mappings folders
> > Custom tag paths
> >
> > Where you put them depends on how you want to use them. If you
> plan on
> > using Flash Remoting (or using the CFC as a web service), you
> need to
> > put it under the webroot.
> >
> > p.s. You can also build a CFC to handle remote calls that works
> as a
> > 'broker' for your CFCs not under webroot. I believe SCorfield
> has an
> > article about that on macromedia.com.
> >
> >
> =======================================================================>
Raymond Camden, ColdFusion Jedi Master for Mindseye, Inc
> >
> > Email    : [EMAIL PROTECTED]
> > WWW      : www.camdenfamily.com/morpheus
> > Yahoo IM : morpheus
> >
> > "My ally is the Force, and a powerful ally it is." - Yoda
> >
> >> -----Original Message-----
> >> From: Andy Ousterhout [mailto:[EMAIL PROTECTED]]
> >> Sent: Thursday, January 30, 2003 6:17 PM
> >> To: CF-Talk
> >> Subject: RE: CFCs - property access best practices
> >>
> >>
> >> Where do I put my CFC files so that CF finds them?  Root
> >> directory?  Do I need to define the location within Admin?
> >>
> >> Andy
> >>
> >> -----Original Message-----
> >> From: Dave Watts [mailto:[EMAIL PROTECTED]]
> >> Sent: Thursday, January 30, 2003 6:02 PM
> >> To: '[EMAIL PROTECTED]'
> >> Cc: '[EMAIL PROTECTED]'
> >> Subject: RE: CFCs - property access best practices
> >>
> >>
> >>>> Furthermore, you want to use the unnamed scope for
> >>>> your instance data
> >>>> (and this seems to be a popular idiom):
> >>>>
> >>>>  <!--- person.cfc --->
> >>>>  <cfcomponent>
> >>>>          <!--- create a single 'handle' for your
> >>>> instance data: --->
> >>>>          <cfset instance = structNew()>
> >>>
> >>> What does:
> >>>   <cfset instance = structNew()>
> >>>
> >>> do for your component?
> >>
> >> If called from within one of the component's functions, it
> >> would overwrite the structure "instance" with a new, empty
> >> structure, so all of the keys within the original structure
> >> would be lost. It can't be called outside of the component,
> >> since it's not exposed as a public member variable.
> >>
> >> Dave Watts, CTO, Fig Leaf Software
> >> http://www.figleaf.com/
> >> voice: (202) 797-5496
> >> fax: (202) 797-5444
> >>
> >>
> >>
> >>
> >>
> >
> >
>
>

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Get the mailserver that powers this list at http://www.coolfusion.com

                                Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
                                

Reply via email to