<inject-state> --> <inject-special> --> <inject>

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

<inject-state> --> <inject-special> --> <inject>

Howard Lewis Ship
I've been thinking that I want to change the <inject-state> element
into something more generalized.

I was just thinking about how cool it would be to be able to inject a
compiled script template (an IScript instance).  The approach would be
similar to injecting state.  This it hit me, that these are two
different strategies, so.

<inject-state property="foo" object="visit"/>

Would become:

<inject-special property="foo" type="state" value="visit"/>

And we could add:

<inject-special property="foo" type="script" value="MyScript.script"/>


.... then I realized that <inject> is itself just a special case,
where the type is, for example, "object" (meaning, an object resolved
using HiveMind)..  So we can just make "object" the default for type
and do-away with <inject-state> (and <inject-special>), i.e.

<inject property="request" value="infrastructure:request"/>
<inject property="visit" type="state" value="visit"/>
<inject property="script" type="script" value="MyScript.script"/>

Thoughts?

--
Howard M. Lewis Ship
Independent J2EE / Open-Source Java Consultant
Creator, Jakarta Tapestry
Creator, Jakarta HiveMind

Professional Tapestry training, mentoring, support
and project work.  http://howardlewisship.com

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: <inject-state> --> <inject-special> --> <inject>

Geoff Longman
>  So we can just make "object" the default for type
> and do-away with <inject-state> (and <inject-special>), i.e.
>
> <inject property="request" value="infrastructure:request"/>
> <inject property="visit" type="state" value="visit"/>
> <inject property="script" type="script" value="MyScript.script"/>
>
> Thoughts?

+1 Geoff Longman

Anything that simplifies the DTD get my vote.

Geoff

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: <inject-state> --> <inject-special> --> <inject>

Harish Krishnaswamy
In reply to this post by Howard Lewis Ship
+1 from me too.

-Harish

On 5/11/05, Howard Lewis Ship <[hidden email]> wrote:

> I've been thinking that I want to change the <inject-state> element
> into something more generalized.
>
> I was just thinking about how cool it would be to be able to inject a
> compiled script template (an IScript instance).  The approach would be
> similar to injecting state.  This it hit me, that these are two
> different strategies, so.
>
> <inject-state property="foo" object="visit"/>
>
> Would become:
>
> <inject-special property="foo" type="state" value="visit"/>
>
> And we could add:
>
> <inject-special property="foo" type="script" value="MyScript.script"/>
>
> .... then I realized that <inject> is itself just a special case,
> where the type is, for example, "object" (meaning, an object resolved
> using HiveMind)..  So we can just make "object" the default for type
> and do-away with <inject-state> (and <inject-special>), i.e.
>
> <inject property="request" value="infrastructure:request"/>
> <inject property="visit" type="state" value="visit"/>
> <inject property="script" type="script" value="MyScript.script"/>
>
> Thoughts?
>
> --
> Howard M. Lewis Ship
> Independent J2EE / Open-Source Java Consultant
> Creator, Jakarta Tapestry
> Creator, Jakarta HiveMind
>
> Professional Tapestry training, mentoring, support
> and project work.  http://howardlewisship.com
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: <inject-state> --> <inject-special> --> <inject>

Howard Lewis Ship
Working on this right now.

I really like how its coming out; it will open up the possibility of
application-specific injections (by contributing new types of
injection workers into the configuraiton point).

On 5/12/05, Harish Krishnaswamy <[hidden email]> wrote:

> +1 from me too.
>
> -Harish
>
> On 5/11/05, Howard Lewis Ship <[hidden email]> wrote:
> > I've been thinking that I want to change the <inject-state> element
> > into something more generalized.
> >
> > I was just thinking about how cool it would be to be able to inject a
> > compiled script template (an IScript instance).  The approach would be
> > similar to injecting state.  This it hit me, that these are two
> > different strategies, so.
> >
> > <inject-state property="foo" object="visit"/>
> >
> > Would become:
> >
> > <inject-special property="foo" type="state" value="visit"/>
> >
> > And we could add:
> >
> > <inject-special property="foo" type="script" value="MyScript.script"/>
> >
> > .... then I realized that <inject> is itself just a special case,
> > where the type is, for example, "object" (meaning, an object resolved
> > using HiveMind)..  So we can just make "object" the default for type
> > and do-away with <inject-state> (and <inject-special>), i.e.
> >
> > <inject property="request" value="infrastructure:request"/>
> > <inject property="visit" type="state" value="visit"/>
> > <inject property="script" type="script" value="MyScript.script"/>
> >
> > Thoughts?
> >
> > --
> > Howard M. Lewis Ship
> > Independent J2EE / Open-Source Java Consultant
> > Creator, Jakarta Tapestry
> > Creator, Jakarta HiveMind
> >
> > Professional Tapestry training, mentoring, support
> > and project work.  http://howardlewisship.com
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [hidden email]
> > For additional commands, e-mail: [hidden email]
> >
> >
>


--
Howard M. Lewis Ship
Independent J2EE / Open-Source Java Consultant
Creator, Jakarta Tapestry
Creator, Jakarta HiveMind

Professional Tapestry training, mentoring, support
and project work.  http://howardlewisship.com

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: <inject-state> --> <inject-special> --> <inject>

Shawn Church
+1 here also.  I can think of a couple of instances where I could use
this today.

Shawn


Quoting Howard Lewis Ship <[hidden email]>:

> Working on this right now.
>
> I really like how its coming out; it will open up the possibility of
> application-specific injections (by contributing new types of
> injection workers into the configuraiton point).
>
> On 5/12/05, Harish Krishnaswamy <[hidden email]> wrote:
> > +1 from me too.
> >
> > -Harish
> >
> > On 5/11/05, Howard Lewis Ship <[hidden email]> wrote:
> > > I've been thinking that I want to change the <inject-state>
> element
> > > into something more generalized.
> > >
> > > I was just thinking about how cool it would be to be able to
> inject a
> > > compiled script template (an IScript instance).  The approach
> would be
> > > similar to injecting state.  This it hit me, that these are two
> > > different strategies, so.
> > >
> > > <inject-state property="foo" object="visit"/>
> > >
> > > Would become:
> > >
> > > <inject-special property="foo" type="state" value="visit"/>
> > >
> > > And we could add:
> > >
> > > <inject-special property="foo" type="script"
> value="MyScript.script"/>
> > >
> > > .... then I realized that <inject> is itself just a special
> case,
> > > where the type is, for example, "object" (meaning, an object
> resolved
> > > using HiveMind)..  So we can just make "object" the default for
> type
> > > and do-away with <inject-state> (and <inject-special>), i.e.
> > >
> > > <inject property="request" value="infrastructure:request"/>
> > > <inject property="visit" type="state" value="visit"/>
> > > <inject property="script" type="script"
> value="MyScript.script"/>
> > >
> > > Thoughts?
> > >
> > > --
> > > Howard M. Lewis Ship
> > > Independent J2EE / Open-Source Java Consultant
> > > Creator, Jakarta Tapestry
> > > Creator, Jakarta HiveMind
> > >
> > > Professional Tapestry training, mentoring, support
> > > and project work.  http://howardlewisship.com
> > >
> > >
> ---------------------------------------------------------------------
> > > To unsubscribe, e-mail:
> [hidden email]
> > > For additional commands, e-mail:
> [hidden email]
> > >
> > >
> >
>
>
> --
> Howard M. Lewis Ship
> Independent J2EE / Open-Source Java Consultant
> Creator, Jakarta Tapestry
> Creator, Jakarta HiveMind
>
> Professional Tapestry training, mentoring, support
> and project work.  http://howardlewisship.com
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail:
> [hidden email]
>
>




---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]