Index: [Article Count Order] [Thread]

Date:  Thu, 21 Mar 2002 05:25:08 +0900 (JST)
From:  GOTOU Yuuzou <gotoyuzo@notwork.org>
Subject:  [webricken:62] Re: request attributes and handler creation
To:  webricken@notwork.org
Message-Id:  <20020321.052508.50050138.gotoyuzo@kotetsu.does.notwork.org>
In-Reply-To:  <3C9871D3.9060405@imperitek.com>
References:  <3C97D8FB.8090306@imperitek.com>	<20020320.200956.46637479.gotoyuzo@kotetsu.does.notwork.org>	<3C9871D3.9060405@imperitek.com>
X-Mail-Count: 00062

In message <3C9871D3.9060405@imperitek.com>,
 `David Corbin <dcorbin@imperitek.com>' wrote:
> To be useful, my handler needs a bunch of options.  I would rather do 
> like this
>     h = MyHandler.new(coreStuff")
>     h.addFunnyOption ("foo","bar")
>     h.addFunnyOption ("alpha","gamma")
>     h.setZoption("gamma")
>     mount ("/z",h)
> than do this
>     mount("/z",MyHandler {"CoreStuff"=> "coreStuff", 
> "FunnyOptions"=>[["alpha","gamma"],["foo","bar"]],"Zoption"=>"gamma"})

How about this way?

    app = YourApp.new("coreStuff")
    app.addFunnyOption("foo","bar")
    app.addFunnyOption("alpha","gamma")
    app.setZoption("gamma")
    mount("/z", YourHandler, app)

--
gotoyuzo