jsr344-experts@javaserverfaces-spec-public.java.net

[jsr344-experts] Re: 1087-ViewScoped: PROPOSAL

From: Werner Keil <werner.keil_at_gmail.com>
Date: Mon, 6 Aug 2012 16:30:05 +0200

Have you asked Pete and/or Mark Struberg?

On Mon, Aug 6, 2012 at 3:05 PM, Kito Mann <kito.mann_at_virtua.com> wrote:

>
>
> On Fri, Aug 3, 2012 at 12:24 PM, Frank Caputo <frank_at_frankcaputo.de>wrote:
>
>> Hi Ed,
>>
>> how does the new CDI scope fit into the javax.faces.flow package? It is
>> not a specific feature of flows.
>>
>
> +1 for the idea, but I have the same question.
>
>>
>> Ciao Frank
>>
>> Am 02.08.2012 um 21:48 schrieb Edward Burns:
>>
>> > Hello Experts,
>> >
>> > JSF 2.0 added the annotation javax.faces.bean.ViewScoped [1].
>> > Currently, it's specification is tightly bound to the pre-CDI Managed
>> > Bean specification, which will eventually be deprecated.
>> >
>> > When this annotation, along with ManagedBean is found on a class, the
>> > runtime must act as if a <managed-bean-scope>view<managed-bean-scope>
>> > element was declared for the corresponding managed bean.
>> >
>> > 730-FacesFlows introduces a @FlowScoped [2].
>> >
>> > FlowScoped is a CDI scope that causes the runtime to consider classes
>> > with this annotation to be in the scope of the specified Flow. The
>> > implementation must provide an implementation of
>> > javax.enterprise.inject.spi.Extension that implements the semantics
>> > such that beans with this annotation are created when the user enters
>> > into the specified Flow, and de-allocated when the user exits the
>> > specified Flow.
>> >
>> > PROPOSAL
>> >
>> > Create a new annotation javax.faces.flow.ViewScoped with this
>> > specification.
>> >
>> > ViewScoped is a CDI scope that causes the runtime to consider classes
>> > with this annotation to be in scope as long as the user stays on the
>> > same view. When the user navigates to a different view, @ViewScoped
>> > beans must be made available for garbage collection.
>> >
>> > Ed
>> >
>> > [1]
>> https://maven.java.net/service/local/repositories/snapshots/archive/javax/faces/javax.faces-api/2.2-SNAPSHOT/javax.faces-api-2.2-20120802.084909-40-javadoc.jar/!/managed-bean-javadocs/javax/faces/bean/ViewScoped.html
>> >
>> > [2]
>> https://maven.java.net/service/local/repositories/snapshots/archive/javax/faces/javax.faces-api/2.2-SNAPSHOT/javax.faces-api-2.2-20120802.084909-40-javadoc.jar/!/javadocs/javax/faces/flow/FlowScoped.html
>> >
>> > --
>> > | edward.burns_at_oracle.com | office: +1 407 458 0017
>> > | homepage: | http://ridingthecrest.com/
>> >
>>
>>
>


-- 
 Werner Keil | JCP Executive Committee Member | Eclipse UOMo Lead
 Twitter @wernerkeil | #Java_Social | #EclipseUOMo | #OpenDDR
Skype werner.keil | Google+ gplus.to/wernerkeil
* Eclipse Day Poland: September 13 2012, Krakow, Poland. Werner Keil,
Eclipse Committer, UOMo Lead, Mærsk Build Manager will present "Eclipse
STEM, UOMo and Hudson"
* Chip-to-Cloud Security Forum: September 19 2012, Nice, French Riviera.
Werner Keil, JCP Executive Committee, JSR-321 EG Member will present
"Trusted Computing API for Java™"
* Eclipse Day Delft: September 27 2012, Delft, Netherlands. Werner Keil,
Eclipse Committer, UOMo Lead, Mærsk Build Manager will present "Triple-E
class Continuous Delivery with Hudson, Maven and Mylyn"
* JavaOne: September 30-October 4 2012, San Francisco, USA. Werner Keil,  JCP
Executive Committee will represent "Eclipse UOMo, STEM, and JSRs involved
in, e.g. 331 or JCP.next"