jstatemachine-users Mailing List for JStateMachine
Brought to you by:
dixitsandeep,
pcauto
You can subscribe to this list here.
2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(3) |
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
---|
From: Robson M. <rmi...@so...> - 2002-06-03 00:00:04
|
Hi, I did some changes to check if a state was visited before, to deny access to users to states which the user doesn't visited before. This is because a user could enter directly into any state in the workflow. There is some way to send the patches and for who I can send? Thanks Robson |
From: Robson M. <rmi...@so...> - 2002-05-21 22:30:20
|
I solved it creating a ModelManager, which hold associations between the session id and a hashtable of session values. This way, there is no dependence with a servlet implementation of UserSession. Anyway, I also found that there is no checking of user access to a state which wasn't visitated... I'm working on this now. Robson. ----- Original Message ----- From: "Brian O'Byrne" <bo...@io...> To: <jst...@li...>; Sent: Sunday, May 19, 2002 5:37 PM Subject: Re: [JStateMachine-users] Session values > Robson, > > With the current interfaces, it will probably depend on which > session manager package you are using. > The org.jstatemachine.sessionmanagers.servlet.UserSession class > includes the getHttpSession() method, that allows you access the > HttpSession that is in scope. This in turn gives you the standard > Servlet API methods to put objects in the session context. > The org.jstatemachine.sessionmanagers.inmemory.UserSession > class does not include anything you can use as it stands. It > would, however, be trivial to extend that class to include the data > you require. > You would need to create the new class, and modify the > UserSessionManager to create your new class. > > Alternatively, I could add something to the IUserSession interface, > such as getProperties / setProperties, and then implement that in > both the current session manager packages. > > Finally, there is a way you could do it with the current framework > unchanged, though it is a bit of a hack: > After authentication is complete, add the authentication token to > the ResponseData. On each subsequent request, call > getHistoryStar from your Controller, passing in the application root > state. Retrieve the authentication token and check it. If it passes, > add it to the new ResponseData and continue. If it fails, the > Controller can throw a StateMachineUserException, forcing the UI > into an exception state that is outside the authenticated area of > your application. > > Let me know how it works, and I will look at adding something to > the IUserSession interface for the next release. > > Thanks, > Brian. > > On 18 May 2002, at 11:02, Robson Miranda wrote: > > > Hi, > > > > I'm beginning to use the JStateMachine framework, and I have one > > doubt: how can I put some values to be used during all the states > > visiteds by one user (such as the user identification)? > > > > Robson. > > > > > > > _______________________________________________________________ > Hundreds of nodes, one monster rendering program. > Now that's a super model! Visit http://clustering.foundries.sf.net/ > > _______________________________________________ > JStateMachine-users mailing list > JSt...@li... > https://lists.sourceforge.net/lists/listinfo/jstatemachine-users > > |
From: Brian O'B. <bo...@io...> - 2002-05-19 20:35:53
|
Robson, With the current interfaces, it will probably depend on which session manager package you are using. The org.jstatemachine.sessionmanagers.servlet.UserSession class includes the getHttpSession() method, that allows you access the HttpSession that is in scope. This in turn gives you the standard Servlet API methods to put objects in the session context. The org.jstatemachine.sessionmanagers.inmemory.UserSession class does not include anything you can use as it stands. It would, however, be trivial to extend that class to include the data you require. You would need to create the new class, and modify the UserSessionManager to create your new class. Alternatively, I could add something to the IUserSession interface, such as getProperties / setProperties, and then implement that in both the current session manager packages. Finally, there is a way you could do it with the current framework unchanged, though it is a bit of a hack: After authentication is complete, add the authentication token to the ResponseData. On each subsequent request, call getHistoryStar from your Controller, passing in the application root state. Retrieve the authentication token and check it. If it passes, add it to the new ResponseData and continue. If it fails, the Controller can throw a StateMachineUserException, forcing the UI into an exception state that is outside the authenticated area of your application. Let me know how it works, and I will look at adding something to the IUserSession interface for the next release. Thanks, Brian. On 18 May 2002, at 11:02, Robson Miranda wrote: > Hi, > > I'm beginning to use the JStateMachine framework, and I have one > doubt: how can I put some values to be used during all the states > visiteds by one user (such as the user identification)? > > Robson. > > |
From: Robson M. <rmi...@so...> - 2002-05-18 14:03:03
|
Hi, I'm beginning to use the JStateMachine framework, and I have one doubt: how can I put some values to be used during all the states visiteds by one user (such as the user identification)? Robson. |