On my second day of using cfc's I've come to a point where I
really want to overload a particular method.
Is there even a way to do overloading?

The docs for cfargument say that if the type parameter is not one of
the predefined types, CF will process it as a component. Unfortunately
the docs don't elaborate (Where are the MX books?). If I use a cfc as
the type parameter, what happens? I'm thinking CF will instantiate the
cfc, run the constructor code, so there may be a way to determine the
datatype of the argument passed.
I want to do something like this.

<cfset rs = insertEmail(emailAddressString)>
or
<cfset rs = insertEmail(emailAddressArray)>

and in my insertEmail method

<cffunction name="insertEmail" returntype="boolean">
  <cfargument name="emailAddress" required="Yes" type="determineType">

  What I am assuming will happen if I am reading the docs right is
  that the determineType cfc will get loaded, but is it possible to
  pass the actual argument back and forth between the cfcs, so I can
  determine the type?
  Can someone elaborate on exactly what happens when we use a
  component as the datatype?

-- 
 Jon
  mailto:[EMAIL PROTECTED]

______________________________________________________________________
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to