Tim- you as a GI Joe type should know that, under the Geneva Convention, all the object has to tell you is its name, rank, and serial number.
<hee hee> -Ben > Also once you create an object can you get it to tell you what kind of an > object it is? > > Right now lets say I create an object that's a user. Then when it has an > access level of 3 I want to take it and turn it into an administrator so it > looks something like this in the newUser function: > > <cfif thisUser.accessLevel eq 3> > <cfset temp = createObject('component', > 'questionaire.Administrator')> > <cfset thisUser = temp.newAdministrator(thisUser)> > </cfif> > > Timothy Heald > Overseas Security Advisory Council > U.S. Department of State > > "that the free Constitution, which is the work of your hands, may be > sacredly maintained" - George Washington, Farewell Address 1796 > > -----Original Message----- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] > Sent: Wednesday, April 02, 2003 3:30 PM > To: CF-Community > Subject: RE: OOCF, CFCs and the questionnaire app > > > How do I let dream weaver and the CFMX administrator know that I changed the > name of the CFIDE directory so I can stop getting 404 errors every time I > try to use the tag inspection. > > Also I have the following line: > > <cfset temp = createObject('component', 'Administrator')> > > Inside my user.cfc if the person is an administrator. I was wondering three > things. > > 1. Why does it say it can't find the template Administrator.cfc. It's > their, in the same directory. Just to make sure I even used the specific > path like: > > <cfset temp = createObject('component', > 'questionaire.Administrator')> > Still errors out. > > 2. Can someone finally please explain the var keyword in CFCs in plain > english that I can understand when I need to use it and when I don't? > > 3. If I create an isAdmin() function in the user class, than an isAdmin() in > the administrator class will it override correctly when I instantiate an > administrator? > > Timothy Heald > Overseas Security Advisory Council > U.S. Department of State > > "that the free Constitution, which is the work of your hands, may be > sacredly maintained" - George Washington, Farewell Address 1796 > > > > -----Original Message----- > From: Haggerty, Mike [mailto:[EMAIL PROTECTED] > Sent: Wednesday, April 02, 2003 2:44 PM > To: CF-Community > Subject: RE: OOCF, CFCs and the questionnaire app > > > 1) The tag definitions are not set up correctly within studio (assuming that > is what you are using). You can edit tag definitions by hitting F8, > selecting 'Tag Completion', and adding these tags to the list. > > 2) Purely dependent on your object heirarchy, but it sounds like category is > an attribute of question. Of course, if you are going to create objects > called category which will possess other salient characteristics, such as > name, value, etc. you might need to rethink this approach. The whole point > is that objects have meaning enough that it makes sense to reuse them. > > M > > -----Original Message----- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] > Sent: Wednesday, April 02, 2003 2:10 PM > To: CF-Community > Subject: OOCF, CFCs and the questionnaire app > > > Ok, > The boss and I are using the questionnaire app to expand our skill set > some during lunch. We are looking at how to objectify it, what methods to > have, what might be good to break into a web service. During this process > several questions have arisen. > > 1. Why the hell won't CF 5 close my CFMX tags like cfcomponent or > cffunction? I know I am being lazy but so what. > > 2. How do you break up things that deal with one of an object > (getQuestion()) and deal with several instances at once > (getQuestionsByCat())? Say I want to list all the questions in a category. > Is that properly a method of the question object, or do I need a category > object? > > So far we have decided on the following objects and methods > > User > newUser - constructor, will be used after login to create as a > session object that will go through the site with the users credentials, > basically just a db query to pull the users info and check the login > > getUser - used to look up users, say in an address book like manner > > setUser - input new user info, used for registration. Should this > be broken up more in to things like setAddress, setEmail? Also can your > override functions in CFMX? I guess I could get the same effect just by > doing some conditional work inside the method right? > > addQuestion - enter a new question. Question would still need to be > approved by an administrator - calls question constructor?? > > Administrator - extends user > newAdministrtator - constructor - called if the user has admin > rights. What's the way to make this happen in the newUser constructor > automatically? > > approveQuestion - Approve a user entered question > > approveUsers - Approve a new user application. Figured make it so it > can handle many users at once. Should it be for a single user and then just > something you do many times? > > getNewUsers - Gets the listing of new user application > > Question > newQuestion - question constructor > > getQuestion - pulls a specific question > > getAnswers - pulls the answers for a specific question > > getAnswersByUser - pulls a users answers > > getQuestions - list of all questions > > getQuestionsByCategory - pulls questions by category > > answer - answer a question > > setCategory - set the questions category > > setQuestion - edit/enter a question > > I guess that's about it. See anything I am missing? Am I putting anything > in the wrong place? > > Timothy Heald > Overseas Security Advisory Council > U.S. Department of State > "that the free Constitution, which is the work of your hands, may be > sacredly maintained" - George Washington, Farewell Address 1796 > > > > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=5 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=5 Signup for the Fusion Authority news alert and keep up with the latest news in ColdFusion and related topics. http://www.fusionauthority.com/signup.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.5