RE: Spring, myfaces, hibernate

2006-03-30 Thread Jesse Alexander \(KBSA 21\)



valid point. 1-pagers often grow to ugly multi-page 
spaghetti-apps...
 
introducing and therefor experimenting stuff like spring 
helps
tremendously... maybe spring is enough, 
tough
 
regards
Alexander

  
  
  From: Jurgen Lust 
  [mailto:[EMAIL PROTECTED] Sent: Friday, March 31, 2006 9:05 
  AMTo: MyFaces DiscussionSubject: Re: Spring, myfaces, 
  hibernate
  In my experience, apps that start out with 1 page and 1 bean tend 
  to end up being much more complex. So even in that case I would recommend 
  adding Spring en Hibernate to the mix, especially because of the KISS 
  principal:Removing messy JDBC code and introducing IoC on all levels 
  simplifies a project tremendously.JurgenAlexandre Poitras 
  schreef: 
  I agree with the previous poster but I would definitly take a look at
Spring's JDBCTemplate if I was you, which is very simple and makes
your jdbc code much easier to write. Say farewell to your messy
exception handling code :) Plus, if you want to switch to iBatis or
Hibernate later on, it will be much easier this way.

On 3/30/06, Adrian Merrall <[EMAIL PROTECTED]> wrote:
  
If your app really is 1 page and 1 bean (and likely to stay around
this size) then I would think adding multiple frameworks is overkill,
remember the KISS principal.  Some plain java and jdbc is fine.

If you are thinking about persistance/data mapping frameworks to
replace writing JDBC, don't forget to evaluate Apache iBatis as well
as Hibernate.  There are some tutorials on the ibatis site under
downloads.

Regards,

Adrian
Auckland, NZ

On 3/30/06, 101questionjsf <[EMAIL PROTECTED]> wrote:

  Currently I'm using only myfaces to do my application. Is it advisable to use
Spring and Hibernate? Can I proceed without them?

Currently, whenever connect to db to do something, I'm writing jdbc
statements, not using hibernate.

And never use Spring.

Only 1 jsp page linked to 1 managed bean.

Is my approach alright? or something wrong?
--
View this message in context: http://www.nabble.com/Spring%2C-myfaces%2C-hibernate-t1367883.html#a3668253
Sent from the MyFaces - Users forum at Nabble.com.


  

--
Alexandre Poitras
Québec, Canada
  


RE: myfaces support in a hosting provider

2006-03-30 Thread Jesse Alexander \(KBSA 21\)



isn't the tomcat-manager active?
 
regards
Alexander

  
  
  From: Rogerio Pereira 
  [mailto:[EMAIL PROTECTED] Sent: Thursday, March 30, 2006 
  10:15 PMTo: MyFaces DiscussionSubject: myfaces support 
  in a hosting provider
  Hi,I have one tomcat context avaliable for me at my hosting 
  provider, initially my WEB-INF folder was empty, but today i put web.xml, 
  faces-config.xml and all myfaces jars in WEB-INF-lib folder in my website, now 
  how can i tell to tomcat read this files to configure myfaces apps properly 
  there since i don't have any way to reload the website context? Thanks for any answer.-- Yours truly 
  (Atenciosamente),Rogério 


RE: many facelets libraries

2006-03-13 Thread Jesse Alexander \(KBSA 21\)
hmm... try this link
 
Seems that the solution is to specify multiple libraries as a 
semicolon-separated list:

facelets.LIBRARIES  
  A semicolon (;) delimitted list of paths to Facelet tag libraries, 
  relative to your application's root. These libraries will be loaded 
  when the first request hits the FaceletViewHandler for page
compilation.

hth
Alexander

> -Original Message-
> From: ::SammyRulez:: [mailto:[EMAIL PROTECTED] 
> Sent: Monday, March 13, 2006 10:02 AM
> To: MyFaces Discussion
> Subject: many facelets libraries
> 
> What if I want to add more then one extra component library 
> to my facelet app?
> More than ore context-parameter will breack the context.
> 
> should I build a custom taglib xml descritpor with all my tags? I will
> lost different namespace for each one...
> 
>  
> facelets.LIBRARIES
> /WEB-INF/tomahawk.taglib.xml
> 
> 
> --
> ::SammyRulez::
> 


RE: how to run MyFaces examples on SunApplication Server 8.2 ???? URGENT!

2006-03-06 Thread Jesse Alexander \(KBSA 21\)



In such a case extracts form the server-logs might help 
more...
Have yo checked: http://wiki.apache.org/myfaces/Installation_and_Configuration?
 
hth
Alexander

  
  
  From: [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED] On Behalf Of DuduSent: 
  Monday, March 06, 2006 1:47 PMTo: MyFaces Official 
  ListSubject: how to run MyFaces examples on SunApplication Server 
  8.2  URGENT!
  How to run MyFaces examples on SunApplication Server 8.2  I've 
  deployed on jboss and the example works fine But at SAS not happens..See 
  on attachment.And how to run Adf + MyFaces Application on this 
  container. I need to deploy it today? Thanks a 
lot!!


RE: what is the worse thing that could happen - escape=false

2006-02-26 Thread Jesse Alexander \(KBSA 21\)



That kind of security is a wasp's 
nest...
_javascript_ is not the only possible fountain of problems... 
SQL-Code-injection is another one...
 
My take is that JSF's validation might be already too far 
within the application's scope to deal with
such attack-oportunities. I would prefer to have it on a 
"box" / "appliance" / "sw-firewall" put in front of
the actual webapplication container...
 
regards
Alexander

  
  
  From: Dave [mailto:[EMAIL PROTECTED] 
  Sent: Sunday, February 26, 2006 11:34 PMTo: 
  users@myfaces.apache.orgSubject: what is the worse thing that could 
  happen - escape=false
  
   allows users to input a description including any 
  HTML tags,
  then display back to client using   
  escape="false".
   
  Users can type in _javascript_ and anything else. What is the security 
  hole? client side or server side?  Can users break in server side 
  security this way? I believe it is client side only. On server side, just do 
  model update and store it in database.
   
  Even for client side, it is a big issue, since the 
  description is viewable by all users.
   
  Is there a way to prevent this, but support HTML tags?
  Is adding a validator checking 

RE: JSF log activity

2006-02-15 Thread Jesse Alexander \(KBSA 21\)



Cool...
I was evaluating the possibilities as 
well...
This is the proof, that this itches a lot of us 
;-)
 
regards
Alexander

  
  
  From: Cagatay Civici 
  [mailto:[EMAIL PROTECTED] Sent: Wednesday, February 15, 
  2006 3:23 PMTo: MyFaces Discussion; 
  [EMAIL PROTECTED]Subject: Re: JSF log 
  activity
  Hi,I am currently working on this subject, here are the 
  areas I'm dealing with.- Calculating phase times- Variables and 
  values in different scopes.- State size- Request and Response 
  Info- Performances of components I am using aspects and listeners 
  to collect the information above;Regards,Cagatay 
  Civici,
  On 2/15/06, Martin 
  Marinschek < 
  [EMAIL PROTECTED]> wrote:
  Navigation 
Listener?ViewHandler?Combo of 
both?regards,MartinOn 2/15/06, Jesse Alexander (KBSA 
21) <[EMAIL PROTECTED]> 
wrote:> Hi>> Cool idea.. some instrumentation in this 
direction would be great... > hmm.. could a phase-listener be used... 
need to check the API's>> thanks for the idea> 
Alexander>> > -Original Message-> > From: 
Csík Norbert [mailto: 
[EMAIL PROTECTED]]> > Sent: Wednesday, February 15, 2006 
2:22 PM> > To: users@myfaces.apache.org> 
> Subject: JSF log activity> > > > Hi!> 
>> > I would like to log the activity of my JSF application. 
Which> > actions/pages are used frequently, and which ones run too 
slowly.> >> > Is there any framework or library where I 
can do this? I tried to > > write my simple one using a Filter, 
but in that case getting the name> > of the page is not so easy 
because the naviagtion rule decides which> > JSF should be 
displayed.> >> > Thaaks, > >> > 
--> >  Norbert Csík> 
>>--http://www.irian.atYour JSF 
powerhouse -JSF Consulting, Development andCourses in English and 
German Professional Support for Apache 
  MyFaces


RE: JSF log activity

2006-02-15 Thread Jesse Alexander \(KBSA 21\)
Hi

Cool idea.. some instrumentation in this direction would be great...
hmm.. could a phase-listener be used... need to check the API's

thanks for the idea
Alexander 

> -Original Message-
> From: Csík Norbert [mailto:[EMAIL PROTECTED] 
> Sent: Wednesday, February 15, 2006 2:22 PM
> To: users@myfaces.apache.org
> Subject: JSF log activity
> 
> Hi!
> 
> I would like to log the activity of my JSF application. Which
> actions/pages are used frequently, and which ones run too slowly.
> 
> Is there any framework or library where I can do this? I tried to
> write my simple one using a Filter, but in that case getting the name
> of the page is not so easy because the naviagtion rule decides which
> JSF should be displayed.
> 
> Thaaks,
> 
> --
>  Norbert Csík
> 


RE: online TLD API docs gone?

2006-02-14 Thread Jesse Alexander \(KBSA 21\)
The fastest way is to open a "bug-report"...
Gets the developers attention first...

regards
Alexander

> -Original Message-
> From: Philippe Lamote [mailto:[EMAIL PROTECTED] 
> Sent: Tuesday, February 14, 2006 12:11 PM
> To: MyFaces Discussion
> Subject: Re: online TLD API docs gone?
> 
> Yeah, so it seems. Also the version numbers aren't consitent.  
> (API-113 - Download-111)
> Hopefully they get online back soon.
> Philippe
> On 14 Feb 2006, at 11:45, Jesse Alexander (KBSA 21) wrote:
> 
> Might result from the migration of the website to the maven
> build-system.
> 
> regards
> Alexander
> 
> > -Original Message-
> > From: Philippe Lamote [mailto:[EMAIL PROTECTED]
> > Sent: Tuesday, February 14, 2006 11:29 AM
> > To: MyFaces Discussion
> > Subject: online TLD API docs gone?
> >
> > I get a 404 error when I try to access them.
> > Philippe
> >
> 
> 


RE: online TLD API docs gone?

2006-02-14 Thread Jesse Alexander \(KBSA 21\)
Might result from the migration of the website to the maven
build-system.

regards
Alexander 

> -Original Message-
> From: Philippe Lamote [mailto:[EMAIL PROTECTED] 
> Sent: Tuesday, February 14, 2006 11:29 AM
> To: MyFaces Discussion
> Subject: online TLD API docs gone?
> 
> I get a 404 error when I try to access them.
> Philippe
> 


RE: MyFaces + Weblogic = Classloading Problems

2006-02-11 Thread Jesse Alexander \(KBSA 21\)



The problem you mention (and the code you found) were 
needed  for WLS-versions
prior to 8.1.4 From that patchlevel on a patch has been 
added to WLS to fix the 
contextlistener-init problem.
 
I just deployed the MyFaces simple application (just had to 
remove the
description tags from the context-params, nothing else) as 
an exploded
webapp to the autodeploy directory. Every change to a 
jsp-file was immediately 
recognized and resulted in a different 
html-view...
 
Hmm... what could be the differences?
I use OpenSuse 10.0 (linux) and a 9.0 download from 
yesterday evening.
 
regards
Alexander

  
  
  From: Adam Brod [mailto:[EMAIL PROTECTED] 
  Sent: Friday, February 10, 2006 3:43 PMTo: MyFaces 
  DiscussionSubject: Re: MyFaces + Weblogic = Classloading 
  Problems
  Yes, I have tried it with and 
  without the context-listener. Any 
  additional ideas?  I'm sure there must be other people developing on 
  weblogic, right?Adam 
  BrodProduct Development 
  Team
  


  Martin Marinschek 
<[EMAIL PROTECTED]> 
02/10/2006 12:57 AM 

  
  

  Please respond 
  to"MyFaces Discussion" 
  
  

  
  

  To
MyFaces Discussion 
   
  

  cc

  

  Subject
Re: MyFaces + Weblogic 
  = Classloading Problems

  
  

Have you tried to setup your context-listener in the web.xml 
  directly?regards,MartinOn 2/9/06, Adam Brod 
  <[EMAIL PROTECTED]> wrote:>> Hi->> I am 
  running into a problem with Classloading with MyFaces 1.1.1 on 
  Weblogic> 9.  Weblogic allows you to deploy your webapp in an 
  exploded directory> format.  That means that you can modify a JSP 
  (or Facelet xhtml) and copy it> to the deployment directory to be 
  automatically redeployed.  This> functionality works fine in the 
  old Struts/JSP world.>> Now that I'm using MyFaces, I'm running 
  into problems with the> FactoryFinder.  As I understand it, 
  FacesServlet or FactoryFinder "stores"> the Factories based on the 
  current classloader.  When Weblogic redeploys a> JSP, it drops the 
  current ClassLoader and creates a new one.  That means> that the 
  next time I hit a JSF page, I get an IllegalStateException (see> full 
  stack trace below).>> I looked at the code in FacesServlet and I 
  see this comment, "//TODO:> null-check for Weblogic, that tries to 
  initialize Servlet before> ContextListener".  Obviously I'm not 
  the first to run into this problem.  I> browsed the source of the 
  trunk online and I see the same code is still> there.  Does 
  anybody have a fix for this?  Is there any work around other> than 
  doing a full redeploy for each JSP modification?>> Thanks for 
  your help.>> Adam>>> 
  java.lang.IllegalStateException: No Factories configured for this> 
  Application - typically this is because a context listener is not setup 
  in> your web.xml.>  A typical config looks like 
  this;>  >> 
  org.apache.myfaces.webapp.StartupServletContextListener> 
   >>           
         at> 
  javax.faces.FactoryFinder.getFactory(FactoryFinder.java:84)>   
                 at> 
  javax.faces.webapp.FacesServlet.init(FacesServlet.java:84)>   
                 at> 
  weblogic.servlet.internal.StubSecurityHelper$ServletInitAction.run(StubSecurityHelper.java:265)> 
                   at> 
  weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)> 
                   at> 
  weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)> 
                   at> 
  weblogic.servlet.internal.StubSecurityHelper.createServlet(StubSecurityHelper.java:61)> 
                   at> 
  weblogic.servlet.internal.StubLifecycleHelper.createOneInstance(StubLifecycleHelper.java:58)> 
                   at> 
  weblogic.servlet.internal.StubLifecycleHelper.(StubLifecycleHelper.java:48)> 
                   at> 
  weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:502)> 
                   at> 
  weblogic.servlet.internal.ServletStubImpl.checkForReload(ServletStubImpl.java:429)> 
                   at> 
  weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:221)> 
                   at> 
  weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:165)> 
                   at> 
  weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3022)> 
                   at> 
  weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)> 
                   at> 
  weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)> 
                   at> 
  weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:1925)> 
           

RE: Components disappearing!

2006-02-10 Thread Jesse Alexander \(KBSA 21\)
> HI !
> 
> I am trying to make a custom component, a sortable column 
> which is a column
> with an output text and 2 command buttons at its header.
> 
> I extends the UIcolumn component and put a htmlPanelGrid in it header.
> HtmlPanelGrid contains an output text and 2 command buttons.
> 
> I am trying to a assign id to these component using View as
> 
> FacesContext.getCurrentInstance().getViewRoot().createUniqueId();
> 
> Now it displays everything fine for the first time. But when 
> I click any of
> these buttons, cells of the column disappears and I left with 
> empty column.
> 
> Does any one have any idea why this is happening.

Not really an idea what's happening... but maybe an idea how to find it
out...
Have you set the logging in MyFaces to the highest level?
MyFaces then logs the component-tree (with usefull info) to the log and
in
my components that tree-logging in restore- and render-phase have helped
my
a lot.

You can activate the logging by adding the correct log4j options...
in my xml-log4j-config I have these entries:







hth
Alexander

> 
> With regards
> Amit
> ps: When I don't assign ids everything works fine except that I got a
> warning saying automatic id is assigned to these components.
> 
> 


RE: Architecture question

2006-02-08 Thread Jesse Alexander \(KBSA 21\)
> -Original Message-
> If an application has 3 tiers: presentation, business, 
> backend - in which of
> those would you put the JSF Model (the Backing Beans?)

Usual answer: depends... ;-)

> 
> When I read through the www, I have to assume that it belongs in the
> business tier while the "rest" of the "JSF stuff" belongs into the
> presentation tier, right?

I often subdivide the managed beans in two groups:
- the usecase beans
and
- the model beans

I allow the usecase beans to depend on javax.faces.**.* classes but the
model
beans must be kept clean. The usecase beans are used to control the flow
within the usecase. The model beans are pure data-keeper.

It has worked in a medium-complex application, but I consider it as
"just
ONE working" model...

> 
> But if you want a "good" architecture - shouldn't there be 
> some sort of
> interface or facade centralizing the business tier access? (Like: all
> requests go through one gate?)

For this we request that all usecase-beans make requests from the
backend
(persistency,...) through facades. Those facades are not allowed to have
framework-dependencies. They use services, which depend on the 
backend-frameworks to get at the actual data. Usually they return 
the model-beans from above...

> Does anyone have a good JSF based architecture in UML (easier 
> to talk about
> a diagram instead of trying to describe it with words)

Not yet ;-)

hth (at least (new?) ideas...)
Alexander


RE: charater/number on an image?

2006-02-07 Thread Jesse Alexander \(KBSA 21\)
checkout: 
- wiki: (links at the bottom)  

hth
Alexander

> -Original Message-
> From: Mike Kienenberger [mailto:[EMAIL PROTECTED] 
> Sent: Tuesday, February 07, 2006 4:28 PM
> To: MyFaces Discussion
> Subject: Re: charater/number on an image?
> 
> I read an article on this recently.
> 
> Try looking here:
> 
> http://www.captcha.net/
> 
> I don't know if there's any source out there, but you could email the
> researchers.
> 
> On 2/6/06, Dave <[EMAIL PROTECTED]> wrote:
> > Is there component that I can print some number/characters 
> on it and that
> > component will be rendered as an image?  or an image 
> generator(public open
> > source)? The purpose is to prevent automatic registration.  Thanks!
> >
> >  
> > Relax. Yahoo! Mail virus scanning helps detect nasty viruses!
> 


RE: Variable Resolver

2006-02-06 Thread Jesse Alexander \(KBSA 21\)
Then it must be the other possibility... it is not on the loginPage.jsp
where your problem lies but:

from your stacktrace: resources.pages.portal_jsp:210)

might be something like .../resources/pages/portal.jsp

hth
Alexander

 

> -Original Message-
> From: Philippe Lamote [mailto:[EMAIL PROTECTED] 
> Sent: Monday, February 06, 2006 3:07 PM
> To: MyFaces Discussion
> Subject: Re: Variable Resolver
> 
> No, I have a "labels" bean.
> The only beans I declared so far are these:
> 
>   
>   loginbean
>   
> be.mnemonica.web.beans.LoginBean class>
>   session
>   
>   
>   portalbean
>   
> be.mnemonica.web.beans.PortalBean class>
>   session
>   
> 
>
>   calpickerbean
>   
> be.mnemonica.web.beans.CalPickerBean bean-class>
>   session
>   
>   
>   regcalbean
>   
> be.mnemonica.web.beans.RegisterCalBean bean-class>
>   session
>   
> 
> 
> On 06 Feb 2006, at 15:01, Jesse Alexander (KBSA 21) wrote:
> 
> The stacktrace also talks about HtmlOutputLabel searching for this
> property..
> 
> there is   in his jsp..
> 
> could it be that the labels bean (snippet from faces-config does not
> contain that bean)
> is also of class be.mnemonica.web.beans.LoginBean?
> That would explain it clearly.
> 
> OR
> 
> He did send us the JSP the request is started from, but the problem is
> only during
> the rendering phase of the resulting JSP...
> 
> hth
> Alexander
> 
> > -Original Message-
> > From: Volker Weber [mailto:[EMAIL PROTECTED]
> > Sent: Monday, February 06, 2006 2:49 PM
> > To: MyFaces Discussion
> > Subject: Re: Variable Resolver
> >
> > This stacktrace says the class 
> be.mnemonica.web.beans.LoginBean has no
> > getLoginName() method.
> >
> > must be referenced somewhere in the jsf, but i don't see it in your
> > posted code.
> >
> > Philippe Lamote wrote:
> >> True, thx, corrected that immediately. (Oops)
> >> However, still no change.
> >> The stack trace I'm getting is:
> >>
> >> 006-02-06 14:33:09,147 ERROR
> >> [org.apache.myfaces.renderkit.RendererUtils] - Property not found -
> >> called by component : {Component-Path : [Class:
> >> javax.faces.component.UIViewRoot,ViewId:
> >> /WEB-INF/resources/pages/portal.jsp][Class:
> >> javax.faces.component.html.HtmlOutputLabel,Id: _idJsp0]}
> >> javax.faces.el.PropertyNotFoundException: Bean:
> >> be.mnemonica.web.beans.LoginBean
> > <http://web.beans.LoginBean>, property:
> >> loginName
> > -- 
> > Don't answer to From: address!
> > Mail to this account are droped if not recieved via mailinglist.
> > To contact me direct create the mail address by
> > concatenating my forename to my senders domain.
> >
> 
> 


RE: Variable Resolver

2006-02-06 Thread Jesse Alexander \(KBSA 21\)
The stacktrace also talks about HtmlOutputLabel searching for this
property..

there is   in his jsp..

could it be that the labels bean (snippet from faces-config does not
contain that bean)
is also of class be.mnemonica.web.beans.LoginBean?
That would explain it clearly.

OR

He did send us the JSP the request is started from, but the problem is
only during
the rendering phase of the resulting JSP...

hth
Alexander

> -Original Message-
> From: Volker Weber [mailto:[EMAIL PROTECTED] 
> Sent: Monday, February 06, 2006 2:49 PM
> To: MyFaces Discussion
> Subject: Re: Variable Resolver
> 
> This stacktrace says the class be.mnemonica.web.beans.LoginBean has no
> getLoginName() method.
> 
> must be referenced somewhere in the jsf, but i don't see it in your
> posted code.
> 
> Philippe Lamote wrote:
> > True, thx, corrected that immediately. (Oops)
> > However, still no change. 
> > The stack trace I'm getting is:
> > 
> > 006-02-06 14:33:09,147 ERROR
> > [org.apache.myfaces.renderkit.RendererUtils] - Property not found -
> > called by component : {Component-Path : [Class:
> > javax.faces.component.UIViewRoot,ViewId:
> > /WEB-INF/resources/pages/portal.jsp][Class:
> > javax.faces.component.html.HtmlOutputLabel,Id: _idJsp0]}
> > javax.faces.el.PropertyNotFoundException: Bean:
> > be.mnemonica.web.beans.LoginBean 
> , property:
> > loginName
> -- 
> Don't answer to From: address!
> Mail to this account are droped if not recieved via mailinglist.
> To contact me direct create the mail address by
> concatenating my forename to my senders domain.
> 


RE: Variable Resolver

2006-02-06 Thread Jesse Alexander \(KBSA 21\)
No need for the VariableResolver for such stuff...
As Volker pointed out, it depends on the getter/setter methods.

VariableResolver in ManagedBeans is only needed when you need to look up
some beans with which you basolutely no direct connection. I dare
to guesitmate that this will hit less than 1% of all JSF-applications...

hth
Alexander 

> -Original Message-
> From: Philippe Lamote [mailto:[EMAIL PROTECTED] 
> Sent: Monday, February 06, 2006 12:02 PM
> To: MyFaces Discussion
> Subject: Re: Variable Resolver
> 
> Yes I did...
> I'll reconstruct the code, for the moment I have bypassed the 
> prob by  
> having LoginBean extend Person. :-(
> Originally loginPerson(the field itself) itself was private, made it  
> public just in case, but that didn't change anything.
> I have also googled for this (perhaps with the wrong terms, 
> like "JSF  
> and recursive variable resolving") but that didn't came up with  
> much. :-)
> 
> What I don't know is whether the Variabe Resolver was specified to  
> also resolve in that fashion in the first place.
> What I also tried was to make the model.Person class a 
> (managed) bean  
> to see whether that would make a diff, but it didn't.
> 
> Philippe
> 
> On 06 Feb 2006, at 11:49, Volker Weber wrote:
> 
> Hi Philippe,
> 
> did you have public getter and setter for Person in loginBean?
> 
> the expression #{loginbean.loginPerson.lastName} is resoved to
> 
> "loginbean.getLoginPerson().getLastName()"
> 
> where loginBean is the object from session scope.
> 
> otherwise please post the stacktrace and more of your relevant code.
> 
> Regards,
>Volker
> 
> Philippe Lamote wrote:
> > Hi,
> >
> > I have a Variable Resolver question.
> > To set the scene first:
> >
> > Trying to follow good practice, I build up my model classes in
> > "XXX.model.modelClass". e.g. "XXX.model.Person"
> > For the front end, there's a package "XXX.web.beans" e.g.
> > "XXX.web.beans.LoginBean"
> >
> > & In that LoginBean I had a field declared:
> > "Person loginPerson;"
> >
> > --> In the JSF page I obviously tried:
> > Login: #{loginbean.loginPerson.lastName}  (I declared "loginbean"
> > properly in the faces-config, session scope)
> >
> > Yet this continues to give me errors. (of type conversion/validation
> > "while updating model")
> >
> > Which made me wonder whether the Variable Resolver was made for this
> > sort of schemas after all?
> > If not that would be a pitty I think.
> >
> > I made it work by having LoginBean extend Person but qua design I   
> > think
> > this is much less elegant.
> > (but still way better than copy all fields again in front-end  
> > classes  -
> > why make a model then?!)
> >
> > Philippe
> >
> >
> 
> -- 
> Don't answer to From: address!
> Mail to this account are droped if not recieved via mailinglist.
> To contact me direct create the mail address by
> concatenating my forename to my senders domain.
> 
> 


FW: Any way to disable/sidestep converters/validators while processing a ActionListener event?

2006-02-01 Thread Jesse Alexander \(KBSA 21\)
 

-Original Message-
From: Jesse Alexander (KBSA 21) 
Sent: Thursday, February 02, 2006 8:24 AM
To: MyFaces Development
Subject: RE: Any way to disable/sidestep converters/validators while
processing a ActionListener event?

Hello:
 
We would like to be able to handle the ActionListener event
without converters
and validators (associated with fields on the form) generating
error messages.
When the form is submitted, we do want the field converters and
validators to 
generate appropriate error messages.  Is there a way to
disable/sidestep 
converters and validators while processing an ActionListener
event?  Further
details are provided below.

The situation:
--
1. Have a date input field
2. Have a link next to the input field that is used to set a
default value in the date field.
   An ActionListener is associated with the link.
3. When the link is clicked, the form is posted and the
ActionListener method is invoked.  This 
   method sets and default value in the date field and returns.
4. Since it is an ActionListener event, JSP redisplays the same
page.

A well known usecase...


Problem:

1. If an illegal date format has been entered into the date
field before clicking the link,
   the converter on the date field detects an error.  JSF
redisplays the page with the
   error message. 
2. Even if the date field is empty or has a legal value, other
fields on the form can have
   bad values such that their converter or validator will detect
an error.  Again, JSP 
   redisplays the page with the error message. 


UI Goal:  Have the link set the default value and ignore any
illegal fields on the form.
---   At this point in time, the user in interested in
defaulting the date field, not
  validating fields.  The fields will be validated when
the form is submitted. 


Current Solution:
-
1. The link has: immediate="true" set.
2. ActionListener associated with link runs early in the JSF
lifecycle. This method
   accesses the component and sets the date value by calling
.setSubmittedValue() 
3  ActionListener method then terminates JSF lifecyle
4. JSF redisplays page.  Since the date component's submitted
value has been modified, the
   default value now appears in the date field.

What we found is that some fields would not show the values the user had
entered before...


Why We are Looking for a Better Solution:
-
We have other situations where the ActionListener method needs
access to several fields
on the form. These fields are currently not available to the
ActionListener since it is 
invoked early in the JSF lifecycle.

If the converters/validators could be disabled, the
ActionListener method could run
at the normal place in the JSF lifecycle.  It is understood that
JSF could not do the data
binding for any fields where the converter fails.  But all other
fields would be properly 
bound and accessible to the AtionListener method.

You might have a look at the OptionalValidators described here:
<http://wiki.apache.org/myfaces/OptionalValidationFramework>

Comments, testcases and problem-reports are welcome.

regards
Alexander
 
 
Thanks for your time.
 
Jay



RE: Packaging up Custom Components and Convertersl

2006-01-31 Thread Jesse Alexander \(KBSA 21\)
 

> -Original Message-
> From: CONNER, BRENDAN (SBCSI) [mailto:[EMAIL PROTECTED] 
> Sent: Tuesday, January 31, 2006 8:07 PM
> To: MyFaces Discussion
> Subject: RE: Packaging up Custom Components and Convertersl
> 
> > BUT, what resource-files are you referring too?
> > a) message- or text-files (*.properties in NLS-versions) or
> > b) images and css and similar files?
> 
> I was thinking of tag library descriptor files (*.tld)


/META-INF/

> 
> - Brendan
> 
> -----Original Message-
> From: Jesse Alexander (KBSA 21)
> [mailto:[EMAIL PROTECTED] 
> Sent: Tuesday, January 31, 2006 11:58 AM
> To: MyFaces Discussion
> Subject: RE: Packaging up Custom Components and Convertersl
> 
> 
> > -Original Message-
> > Is there documentation (either in a wiki or somewhere else) 
> > showing how
> > to package up the classes and resource files used in a custom 
> > components
> > and converters into their own JAR file, so that the JAR file can be
> > shared among different applications?
> Best doc I have found in "JSF in Action". But Martin's description is
> a good short version of it.
> 
> BUT, what resource-files are you referring too?
> a) message- or text-files (*.properties in NLS-versions) or
> b) images and css and similar files?
> 
> regards
> Alexander
> 


RE: Packaging up Custom Components and Convertersl

2006-01-31 Thread Jesse Alexander \(KBSA 21\)
> -Original Message-
> Is there documentation (either in a wiki or somewhere else) 
> showing how
> to package up the classes and resource files used in a custom 
> components
> and converters into their own JAR file, so that the JAR file can be
> shared among different applications?
Best doc I have found in "JSF in Action". But Martin's description is
a good short version of it.

BUT, what resource-files are you referring too?
a) message- or text-files (*.properties in NLS-versions) or
b) images and css and similar files?

regards
Alexander


RE: Howto add faces-config.xml file to /META-INF in a jar to create a deployable jsf component?

2006-01-21 Thread Jesse Alexander \(KBSA 21\)
The faces-config.xml in the META-INF directory is necessary to have
JSF automagically include your component in its runtime configuration.
The JSF-spec say, that every jar-file in the WEB-INF/lib directory of
a webapp is to be searched for a META-INF/faces-config.xml and if found 
the faces-config.xml is to be merged into the runtime config.

hth
Alexander

-Original Message-
From: Hendrik Neumann [mailto:[EMAIL PROTECTED] 
Sent: Saturday, January 21, 2006 8:56 AM
To: MyFaces Discussion
Subject: Howto add faces-config.xml file to /META-INF in a jar to create a 
deployable jsf component?

Hi List,

I have some problems to create a jar file which contains an
"out-of-the-box" usable JSF-Component.

I analyzed the jar-file from myfaces-all.jar and I noticed that you
put the tld and the faces-config.xml into the /META-INF directory of
the jar file. Is this step needed to let a servlet-container use the
component out of the box? So that you don't need to add the tld and
the faces-config of myfaces in the web.xml of your current project?
And how did you do this? I tried it the ugly way by creating a jar
file with Apache Maven and then using commands like "jar uf
mycomponents.jar META-INF/faces-config.xml" but this it not working
(Tomcat gives me a java.io.FileNotFoundException when it tries to
unpack the faces-config.xml and the webapplication is totally
unusable).

How can I create an out of the box usable jsf-jar-file with Maven?
What am I doing wrong?

--
Mit freundlichen Grüßen / Greetings,
Hendrik Neumann; Ruhr-University of Bochum


RE: Dynamically refer to a component from another component

2006-01-20 Thread Jesse Alexander \(KBSA 21\)



You could help _javascript_ by generating a hidden field with 
a given id and the number of rows as value...
 
hth
Alexander


From: Enrique Medina 
[mailto:[EMAIL PROTECTED] Sent: Friday, January 20, 2006 12:05 
PMTo: [EMAIL PROTECTED]; MyFaces DiscussionSubject: Re: 
Dynamically refer to a component from another component
Simon,The problem is that I don't know how many rows I will 
have, as it depens on the data the user enters in the normal use of the 
application.And I need to manipulate the value of the input object using 
_javascript_, but the value itself must be indicated in code the way you told me 
in your previous email. See what I mean? 
2006/1/20, Simon Kitching <[EMAIL PROTECTED]>:
If 
  your component is a column in a table, and the table has 5 rows thenthere 
  will be 5 HTML tags generated for that component. Each needs adistinct id 
  according to the rules for HTML.If you're planning on manipulating 
  those objects in _javascript_, your _javascript_ needs to handle the fact that 
  there are 5 of those HTMLelements around. That's not JSF-specific, that's 
  the nature of theproblem.On Fri, 2006-01-20 at 11:49 +0100, 
  Enrique Medina wrote:> Well, the problem is that I'm creating the table 
  in code using a > DataModel for columns and a DataModel for rows, so at 
  that time the> row  index is not known, is 
  it?>> And as I assign the client ID at code, how can I know the 
  row?>> 2006/1/20, Simon Kitching < [EMAIL PROTECTED]>:> 
  On Fri, 2006-01-20 at 11:22 +0100, Enrique Medina 
  wrote:> > I have 
  been implementing the dynamic creation of my 
  tree> component 
  as> > you mentioned, 
  i.e. adding all the components to 
  their> parents 
  before> > calling 
  getClientId().> 
  >> > But it seems 
  that there is something more to do, looking at 
  > 
  the> > generated 
  code:> 
  >> > >> 
  The extra _0 is because this input component is in the 0th row 
  > of 
  a> table. A table is 
  also a naming 
  container.>> In 
  order to get the id for a component in a particular row 
  of> a 
  table,> 
  call> 
  tableComponent.setRowIndex(index);>someChildComponentOfTable.getClientId(facesContext);>> 
  Normally the above is not necessary, as it's done 
  implicitly> by 
  the> framework; the 
  renderer for some component in a table is 
  > called once 
  for> each row of the 
  table, and the component's clientId is set 
  at> that 
  time.> That's the 
  normal JSF way of rendering: let the framework 
  make> calls 
  > into the renderer 
  with everything configured correctly. 
  If> 
  you're> somehow driving 
  rendering while bypassing the normal 
  flow> you'll need 
  to> ensure the rowIndex 
  is set correctly. 
  >> If you're not 
  getting the "_0" row bit, then clearly 
  your> rendering 
  code> is not being 
  called in the "normal rendering 
  flow".>> 
  Regards, >> 
  Simon>>>


RE: Custom components

2006-01-19 Thread Jesse Alexander \(KBSA 21\)
Hi

when I was lokking for something like that, I found it in "JSF in
Action" from 
Manning written by Kito D. Mann which is also available in eBook-format


hth
Alexander
 

-Original Message-
From: Jana Parvanova [mailto:[EMAIL PROTECTED] 
Sent: Friday, January 20, 2006 8:20 AM
To: MyFaces Discussion
Subject: Custom components

Hi!

Can someone point me to an example of real-life complex custom component
- I 
mean something with several inputs inside, complex validation, change 
listeners etc.
All samples I've seen so far are of simple components extending UIInput
or 
UIOutput.

Tnanks,
Jana 



RE: do conversion and update model values, but skip validation?

2006-01-19 Thread Jesse Alexander \(KBSA 21\)
Welcome to the club (of the potential OptionalValidator users).
As one of the initiants (together with Mike), I think I can say
there is not an easier way to do it. And OV is not yet working
perfectly when you do not use facelets. There are some loose
ends to be fixed...

We tried to make live simpler, but did not find a way in countless hours
of
chat-discussions...

regards
Alexander 

-Original Message-
From: Dave Brondsema [mailto:[EMAIL PROTECTED] 
Sent: Thursday, January 19, 2006 5:06 PM
To: MyFaces Discussion
Subject: Re: do conversion and update model values, but skip validation?

Dave Brondsema wrote:
> I need to implement a "Save as Draft" button for a page I'm working
on.
>  I want to save all the data in the model, so I need to convert values
> to the right data type and update the model values.  But I do not want
> to do any other validation.  Is this possible?  immediate="true" skips
> too much.  Can I use a phase listener before and after validation to
do
> this somehow?  Or perhaps I have to use immediate="true" and then
invoke
> some lifecycle methods in my saveAsDraft() backing bean method?
> 
> Any suggestions?
> 
> thanks,
> 

To answer my own questions, immediate="true" on the "Save as DRAFT"
button means that it is processed before anything else, so the other
data isn't even available.  Explained in detail at
http://wiki.apache.org/myfaces/How_The_Immediate_Attribute_Works

It looks like I can do what I need by using
http://wiki.apache.org/myfaces/OptionalValidationFramework but
unfortunately that requires significant changes to all my forms that
need "save as draft" functionality.

-- 
Dave Brondsema
Software Developer
Cornerstone University


RE: concurrency and t:dataTable (preserveDataModel, forceId, param)

2006-01-19 Thread Jesse Alexander \(KBSA 21\)
We solved the problem rendering an icon with a commandLink.
Then we passed the unique record id as parameter to the link, and in 
that way the backend was able to delete the correct record. It did not
need to
guess on the record using the relative position in the table, but hit 
directly the unique record-identifier.

hth
Alexander 

-Original Message-
From: Mathias Stein [mailto:[EMAIL PROTECTED] 
Sent: Thursday, January 19, 2006 11:08 PM
To: users@myfaces.apache.org
Subject: concurrency and t:dataTable (preserveDataModel, forceId, param)

I'm trying to implement a simple DataTable with a button on each row.
A click on one of the buttons should delete the corresponding row item.
In a singleuser environment my application works as expected.
But up to now I haven't found a proper soultion for multiuser
environments.

The DataTable has a value binding to a list property of a backing bean.

...
   
...
The property getter getAllItems() queries the items list for example
from a data base. In a multiuser environment the getter getAllItems()
could return a different list every time it is called.


Now my problem:
In case the data base was changed since the last view rendering, the
method doDelete() is called on the wrong item object.

For example:
If I select item3 for deletion in my browser and someone else meanwhile
deleted itemx x<3, my submission deletes item4 instead of item3.


Approach 1: (cached items list, no refresh)
The property getter getAllItems() could query the list only once from
the data base and store the list in the session for further evaluations.
So I always delete the correct item.
But in getAllItems() I'm unable to decide when to update the stored
list. Therefore the stored list stays constant for the whole session
unless I update it manually.


Approach 2: (tomahawk preserveDataModel)
Using 
But the id attribute unfortunately has to be a static value.


Approach 4: (h:commandLink, f:param and getRequestMap)
When you replace the commandButton by a commandLink, you can add a row
specific parameter to the request. In the action method you can extract
the parameter from the requestMap and use it as item primary key.
Since commandLinks need JavaScript, this hack is no solution either.


I'm quite new to JSF and the problem seems very common to me, so there's
probably a simple solution. Please let me know...


thx
Mathias


[1]
http://wiki.apache.org/myfaces/Working_With_DataTable_And_PreserveDataMo
del






RE: Dynamically refer to a component from another component

2006-01-19 Thread Jesse Alexander \(KBSA 21\)



No he says: You need to add the component to its parent 
component before you can receive a 
usefull clientId.
 
hthAlexander


From: Enrique Medina 
[mailto:[EMAIL PROTECTED] Sent: Thursday, January 19, 2006 5:12 
PMTo: MyFaces DiscussionSubject: Re: Dynamically refer to 
a component from another component
So your answer means that there is no way to accomplish what I am 
trying, isn't it?Maybe using some kind of events, when the component is 
created to advise another one or so?
2006/1/19, Volker Weber < [EMAIL PROTECTED]>:
After 
  adding the component to the component tree the full id shouldreturned. The 
  structure of the tree is needed to create this id.This is what is done 
  when rendering the 'htlmId' in the renderer.Without the tree structue 
  there is no way to find the resulting clientId. 
  Regards,  VolkerEnrique Medina wrote:> I 
  tried that, but at the time of creating the component in code,> 
  texto4.getClientId(facesContext) returns exactly the same used before> 
  when texto4.setId("_input"), so it doesn't help at all>> 
  2006/1/19, Volker Weber <[EMAIL PROTECTED]> 
   
  [EMAIL PROTECTED]>>:>> 
  Hi,>> you can get the rendered 'htmlId' 
  of a component by>   
  component.getCientId(facesContext);>> so 
  you can do : >>   UIOutput 
  texto5 = (HtmlOutputText) 
  FacesUtils.getApplication()>  .createComponent( 
  HtmlOutputText.COMPONENT_TYPE);>>   
  texto5.getAttributes().put("onclick", 
  >   
  "validate('" + texto4.getClientId(facesContext) + 
  "')");>> 
  Regards,>   
  Volker>> Enrique Medina 
  wrote:> > Also I forgot to say, that if I 
  wanted to use the onclick method > on 
  the> > same UIInput component, I could 
  define it easily by:> 
  >> 
  >  texto4.getAttributes().put("onclick", 
  "validate( this.value)");> > 
  > > As you can see, I know that 'this' 
  refers to my component. But what> > happens 
  if I need to refer to "texto4" component value from 
  another> > component. 
  Imagine:> >> 
  > 
  UIOutput texto5 = (HtmlOutputText)> 
  FacesUtils.getApplication()> 
  > 
  .createComponent(HtmlOutputText.COMPONENT_TYPE);> 
  >> 
  > 
  texto5.getAttributes().put("onclick", 
  validate(XX));> 
  >> > where XX is a _javascript_ 
  reference to the value of "texto4".> 
  >> >> > 
  2006/1/19, Enrique Medina <[EMAIL PROTECTED]> 
  [EMAIL PROTECTED]>> 
  > [EMAIL PROTECTED] [EMAIL PROTECTED]>>>:> 
  >> > Let me give 
  a more detailed explanation of what I am trying to 
  > achieve..> 
  >> > In my 
  application I need to work with data in a 
  spreadsheet> form, 
  so> > I decided to 
  use a PanelTabbed component, where each tab would 
  > > contain a 
  HtmlDataTable. All these would simulate an Excel 
  page,> > where I can 
  change the actual tab, make some modifications to 
  the> > elements in 
  the table, go to another tab, modify, etc, so at 
  > the end> 
  > I would press the save button, and all the 
  changes would be> > 
  persisted to the DB.> 
  >> > The big 
  problem I had with defining this page was the fact 
  > that all> 
  > the data that was used to populate the tables in 
  each tab was not> > 
  known at compile time, as it depended on the values entered by 
  the> > user during 
  the normal use of the application. > 
  >> > So I had to 
  create all the components dynamically through 
  Java> code.> 
  > To accomplish this objective, I created a JSP 
  file with simply a> 
  > PanelTabbed tag that I binded to a property in my 
  backing > bean, 
  so> > whenever JSF 
  called my setBindedTabbedPane method, I could 
  create> > all the 
  tabs, tables, labels, inputs, etc, in code.> 
  >> > Once done, 
  everything was perfect, in the sense that my > 
  application> > was 
  implemented to dynamically create all the components needed 
  to> > simulate an 
  Excel worksheet; i.e. dynamic number of columns 
  and> > rows, dynamic 
  number of tabs, etc. > 
  >> > On the other 
  hand, I have also added DWR to my application 
  in> order> 
  > to use Ajax for particular purposes, like showing 
  child data in a> > 
  datatable, or simply validate some specific fields without 
  > having to> 
  > make a JSF request. So I decided to add a DWR 
  Ajax validate> 
  process> > to my 
  recently created Excel worksheet.> 
  >> > But the 
  problem comes because when using DWR Ajax, I need to 
  > define> 
  > a callback function in _javascript_ where I have to 
  pass as a> > 
  parameter the value that I want to be validated. As you 
  already> > 

RE: Dynamically refer to a component from another component

2006-01-19 Thread Jesse Alexander \(KBSA 21\)



Do you know the parent bean?
Do you know the id of the 
other component?
 
 findComponent(java.lang.String expr) 
  Search for and 
return the UIComponent with an id that matches the specified search _expression_ (if any), 
according to the algorithm described below. 
 
This method exists in UIComponent
 
Could this be a ticket to ride?
Alexander


From: Enrique Medina 
[mailto:[EMAIL PROTECTED] Sent: Thursday, January 19, 2006 2:48 
PMTo: MyFaces DiscussionSubject: Re: Dynamically refer to 
a component from another component
But I don't want to inject another bean. When I talk about components 
I mean view components in the model component; e.g. refer to an HtmlInputText 
from another HtmlOutputText.The problem I have is that I need to refer 
to the value of one component from another one in code, and both of them are 
dynamically created in the same backing bean. 
2006/1/19, Mario Ivankovits <[EMAIL PROTECTED]>:
Hi 
  Enrique!But this is what Simon tries to show you.Its possible to 
  inject the other bean instance or to look it up throughthe 
  context.Ciao,Mario> Hi Simon,>> I mean 
  accesing one component to another from inside the same bean >> 
  2006/1/19, Simon Kitching <[EMAIL PROTECTED]> 
  [EMAIL PROTECTED]>>:>> 
  http://wiki.apache.org/myfaces/AccessingOneManagedBeanFromAnother> 
  < 
  http://wiki.apache.org/myfaces/AccessingOneManagedBeanFromAnother>>> 
  On Thu, 2006-01-19 at 12:57 +0100, Enrique Medina 
  wrote:> > Anyone can give me some hints on 
  how to refer from one component to > > 
  another using EL, or maybe when creating the components 
  dynamically> > through 
  code?>>>--Mario


RE: dataScroller total page number (large data set)

2006-01-18 Thread Jesse Alexander \(KBSA 21\)
And if you want a behaviour similar to Goolge... then you would not need
to
do a costly "select count(*)", you just would assume a value...

But basically getRowCount() makes thescroller think, the datamodel knows
the
amount of data...

hth
Alexander

-Original Message-
From: Bruno Aranda [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, January 18, 2006 11:29 AM
To: MyFaces Discussion
Subject: Re: dataScroller total page number (large data set)

You could implement a DataModel and in the "public int getRowCount()"
execute a sql to count(*) all the data.

Regards,

Bruno

2006/1/18, Emmanuel Jay <[EMAIL PROTECTED]>:
> How do you make the dataScroller "think" it has all the data ready?
>
> Thanks,
>
> Emmanuel
>
>
> On 1/18/06, Bruno Aranda < [EMAIL PROTECTED]> wrote:
> > You can also check this entry [1] in the wiki. It might help!
> >
> > Regards,
> >
> > Bruno
> >
> > [1] http://wiki.apache.org/myfaces/WorkingWithLargeTables
> >
> > 2006/1/18, Emmanuel Jay < [EMAIL PROTECTED]>:
> > > Looking at the HtmlDataScroller code getPageCount assumes that the
whole
> > > data model is loaded in memory to display the number of pages
available.
> > >
> > > Anybody knows a work around this that will allow the setting of
the
> > > pageCount independently of whether the model is fully loaded or
not...
> > >
> > >
> > >
> > > On 1/17/06, Emmanuel Jay <[EMAIL PROTECTED]> wrote:
> > > > Hi all,
> > > >
> > > > We are trying the use the dataScroller for a large data set (I
have
> read
> > > the threads about that). Our business logic is all there but we
can't
> figure
> > > out how to set the total number of pages on the dataScroller
without
> loading
> > > the whole model.
> > > >
> > > > Basically we just want to specify on the dataScroller that the
total
> > > number of pages is X, and we want the user to be able to see that
(then
> our
> > > logic handles the partial loading of the model)
> > > >
> > > > Any help is much appreciated,
> > > >
> > > > Emmanuel
> > > >
> > >
> > >
> >
>
>


RE: dataScroller total page number (large data set)

2006-01-18 Thread Jesse Alexander \(KBSA 21\)



Create your own datamodel, which makes dataScroller think 
it has all the data ready, but will not load the data into 
memory...
 
regards
Alexander


From: Emmanuel Jay [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, January 18, 2006 9:13 AMTo: MyFaces 
DiscussionSubject: Re: dataScroller total page number (large data 
set)
Looking at the HtmlDataScroller code getPageCount assumes that the 
whole data model is loaded in memory to display the number of pages available. 
Anybody knows a work around this that will allow the setting of the 
pageCount independently of whether the model is fully loaded or not... 

On 1/17/06, Emmanuel 
Jay <[EMAIL PROTECTED]> 
wrote:
Hi 
  all,We are trying the use the dataScroller for a large data set (I 
  have read the threads about that). Our business logic is all there but we 
  can't figure out how to set the total number of pages on the dataScroller 
  without loading the whole model. Basically we just want to specify on 
  the dataScroller that the total number of pages is X, and we want the user to 
  be able to see that (then our logic handles the partial loading of the 
  model)Any help is much appreciated, Emmanuel


RE: easiest way to get a jsf page as pdf download

2006-01-17 Thread Jesse Alexander \(KBSA 21\)
Reading this thread I came up with this idea:

Have the render-kit create a dom-representation of the UI-tree.
Then have a transform-mechanism convert it inot either html or pdf or wml, or...
according to the useragents needs or according to some other request-settings
that control the finaldisposition of the output

regards
Alexander



From: Jurgen Lust [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, January 17, 2006 11:19 AM
To: MyFaces Discussion
Subject: Re: easiest way to get a jsf page as pdf download


I would definitely write pdf renderers for some components if other people want 
to help...

Jurgen

Matthias Wessendorf schreef: 

Right Juergen!

would you like to volunteer ? :-)

SpringMVC has some *pdf* based rendering stuff.

-Matthias

On 1/17/06, Jurgen Lust <[EMAIL PROTECTED]>   
wrote:
  

 Theoretically, you could write a new RenderKit which renders a 
JSF page to
PDF instead of HTML. It would probably even work with 
AcroForms...

 Jurgen

 Simon Kitching schreef:
 Hi Hans,

What Matthias describes below is where you have a JSF page, and 
you want
a button labelled "generate report" or similar that creates 
some kind of
PDF document then serves it up to the user's browser. But that 
PDF isn't
"a picture of the current page", it's a PDF generated using 
data pulled
from a database or something like that. If that's really what 
you are
after then FOP is a good tool for that; your java code creates 
some xml
using the FO schema, then feeds it to the FOP library. Nothing 
to do
with JSF though.

There is no way to "generate a pdf that looks like my html 
screen" from
java code which I believe is what you want to do. Some browsers 
provide
a "print page" option, and some operating systems provide a 
"print to
PDF" option in the print dialog so that's one way of creating a 
PDF that
contains the current page but it's manual.

The FOP project is here:
 http://xmlgraphics.apache.org/fop/

Regards,

Simon




On Tue, 2006-01-17 at 09:58 +0100, Hansjörg Meuschel wrote:


 Hi Matthias,

thanks for your help... a friend of mine also recommended FOP in
between. I took a look at the api but it seems to me that FOP 
uses XML
to generate a PDF? !
--> So how can I convert my jsf page into the required FOP-input
format?? I could not find any docu to fop (except some broken 
links...) ?

regards,
Hans



Matthias Wessendorf wrote:



 Hansjoerg,

we have worked with Apache FOP for creating pdfs. iText or
JasperReports are also lib that help you on that task.

inside of your backing bean method (referenced by a commandLink 
or
cmdButton) you can do somthing like this:

public String pdf() {

 FacesContext ctx = FacesContext.getCurrentInstance();

 if(!ctx.getResponseComplete()) {


 HttpServletResponse response = (HttpServletResponse)
ctx.getExternalContext().getResponse();

 byte[] file = //do some FOP, or ... stuff;

 response.setContentType("application/pdf");
 response.setHeader("Content-Disposition", "inline;
filename=\"foo.pdf\"");
 response.setContentLength(file.length);

 OutputStream out = response.getOutputStream();
 out.write(file, 0, file.length);
 out.flush();
 out.close();

 ctx.responseComplete();

 return null;
}


This will work in p(l)ain servlet or struts world too (expect 
of the
usage of jsf api (like FacesContext))

However, the *magic* here is the responseComplete()

  

RE: An optimised pattern for using t:dataTable - please verify.

2006-01-13 Thread Jesse Alexander \(KBSA 21\)
in this direction. thanks for the hint.

Then come the other requirements as well:
- ability to render one record on more than one row
- dynamic col-spans according to different data-objects
- automatic datascroller
- sort and filter headers (multiple sort criterias)

Our users (read the developers here) are VERY creative...

But I still hope we find the cash to finance our inhous
infrastructure project... to make such components ;-)

regards
Alexander

-Original Message-
From: Simon Kitching [mailto:[EMAIL PROTECTED] 
Sent: Friday, January 13, 2006 2:11 PM
To: MyFaces Discussion
Subject: RE: An optimised pattern for using t:dataTable - please verify.

On Fri, 2006-01-13 at 13:34 +0100, Jesse Alexander (KBSA 21) wrote:
> I am milling around since quite some time on the subject of 
> datatables.
> 
> In our app we have the case that hibernates fetches a few megabytes of
> data, which will then be saved in the state and the hibernate-objects 
> remain referenced -> no gc...
> 
> My current thoughts are about a datamodel that does not keep all data
> but just a part of the data active and requests the missing data when
> paging is requested...
> 
> But I still have the unfinished business of the optional validation
for 
> JSF 1.1 (without facelets)
> 
> if we find some developers that want to start on such a better table-
> component... (without committer-rights) we can share the code on a
> temporary base on the js-comp.sf.net project

Have you read this? I'm using this with success, as are others:
  http://wiki.apache.org/myfaces/WorkingWithLargeTables

Regards,

Simon



RE: An optimised pattern for using t:dataTable - please verify.

2006-01-13 Thread Jesse Alexander \(KBSA 21\)
I am milling around since quite some time on the subject of 
datatables.

In our app we have the case that hibernates fetches a few megabytes of
data, which will then be saved in the state and the hibernate-objects 
remain referenced -> no gc...

My current thoughts are about a datamodel that does not keep all data
but just a part of the data active and requests the missing data when
paging is requested...

But I still have the unfinished business of the optional validation for 
JSF 1.1 (without facelets)

if we find some developers that want to start on such a better table-
component... (without committer-rights) we can share the code on a
temporary base on the js-comp.sf.net project

regards
Alexander

-Original Message-
From: Simon Kitching [mailto:[EMAIL PROTECTED] 
Sent: Friday, January 13, 2006 1:11 PM
To: 'MyFaces Discussion'
Subject: Re: An optimised pattern for using t:dataTable - please verify.

On Sat, 2006-01-14 at 00:58 +1300, Simon Kitching wrote:
> Hi Yee,
> 
> Yes, I agree with this. I think you've put it all very nicely.
> 
> The only concern is that point (6) can be hard to get right.

Oh - and also that the user will never see any changes to the database
made concurrently by other users. That may be desirable, or maybe not.
Of course if it is desirable, then a read before each render has to be
done. 

However as you point out in (2), the model used for rendering really
does need to be preserved until the start of the next render phase for
consistency - and that saves one database read too.

I would love to see t:dataTable (and maybe h:dataTable) avoid fetching
the datamodel during validation when there are no input components in
the table; that would make a nice project for someone wanting to get
involved in MyFaces coding!

Cheers,

Simon




RE: How to override the MyFaces 1.1.1 taglib listener registration?

2006-01-12 Thread Jesse Alexander \(KBSA 21\)
Why not use an apache webserver with its url-rewriting capabilities?

hth
Alexander 

-Original Message-
From: David G. Friedman [mailto:[EMAIL PROTECTED] 
Sent: Thursday, January 12, 2006 5:55 PM
To: MyFaces Discussion
Subject: RE: How to override the MyFaces 1.1.1 taglib listener registration?

Ronald,

I want to virtual host so the path /hello maps internally to /hostname/hello.  
I'm trying to do some sort of internal
redirect WITHOUT having to put dummy/stub files in the main /WEBAPP folder 
which would then include the relevant virtual
host file(s).  So, this kind of cancels out Facelets or Shale/Clay for that 
very purpose.  I've tried making another
ViewHandler.createView(context, "hostname" + viewId) but that ALSO changes the 
submitted path to /hostname/whatever.jsf
instead of retaining it as /whatever.jsf.

Now, I'm thinking I can use the servletContextListener to put my own 
ExternalContext in there so when the JSP calls
ExternalContext.dispatch(), I can override that method to invoke 
"/localhost/filename" since I won't have a generic
"/filename" setup.

I'm open to new ideas and suggestions.  I wonder sometimes why I go for the 
complicated stuff when I program application
services. *sigh*

Regards,
David

-Original Message-
From: "R. Müller" [mailto:[EMAIL PROTECTED]
Sent: Thursday, January 12, 2006 5:14 AM
To: MyFaces Discussion
Subject: Re: How to override the MyFaces 1.1.1 taglib listener
registration?


Hi David,

why you want to override - define your own in the web.xml !


myServletContextListener


You have to implement the 'javax.servlet.ServletContextListener' -
Interface with the following two methods :

public void contextInitialized(ServletContextEvent e);
public void contextDestroyed(ServletContextEvent e);

The same if want to listen for sessions. You have to additionally
implement the 'javax.servlet.http.HttpSessionListener'-Interface with

public void sessionCreated(HttpSessionEvent e);
public void sessionDestroyed(HttpSessionEvent e);

regards

Ronald

David G. Friedman wrote:
> In the MyFaces taglib, it has the listener declaration (which works in my 
> Tomcat 5.0.28 :
>
> 
> 
> org.apache.myfaces.webapp.StartupServletContextListener
> 
>
> Is there any way to override this other than:
>
> a) Edit the taglib file to change it.
>
> b) make my own 
> /WEB-INF/classes/org/apache/myfaces/webapp/StartupServletContextListener.java 
> file?
>
> Regards,
> David
>
>



RE: Question?

2006-01-11 Thread Jesse Alexander \(KBSA 21\)
Hi Marco

look at the datascroller.jsp sample...












 
pageIndex is what you are looking for

Just have it point to a managed-bean-attribute...

hth
Alexander



From: Marco [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, January 11, 2006 12:40 PM
To: MyFaces Discussion
Subject: Question?


Hi all;

I have dataScroller..How can i know the clicked page value from the
scroller ?

(For ex. the scroller shows that i have 3 pages of results (1,2,3) for a
dataTable, & i want if i clicked on 2 - for ex. - i can get 2 inside my
code ). 

Like in the dataTable there is an attribute "first" tells me where the
cursor now, is there anything like this in the dataScroller that tells
me which page I'm on now ?

Thanks a lot



RE: Free web-based project management apps?

2006-01-10 Thread Jesse Alexander \(KBSA 21\)
Hi

for some time we used XoopsForge... but it seems that development stopped...

available are:
- sourceforge (a slightly reduced version of what's online available)
- GForge  based on PostGreSQL-db
But with these I have no experience

hth
Alexander

-Original Message-
From: Hendrik Neumann [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, January 10, 2006 10:06 AM
To: users@myfaces.apache.org
Subject: Free web-based project management apps?

Hi List,

I'm looking for a good and free web-application which allows us to
manage our projects. It should have features like a ticket system for
todos/bugs/whatever, a roadmap with milestones, a wiki and other
features which are usefull for the software-development-process.

Currently the only good tool that I know is trac
(http://www.edgewall.com/trac/ and http://projects.edgewall.com/trac/)
but it seems so that there is not much more happening with this
project.

So does anybody of you guys know another good alternative to manage
software-projects? In fact it is not so important whether the software
is web-based or an Eclipse Plugin. The only thing I want to avoid is a
standalone programm.

Any hints/links?

--
Mit freundlichen Grüßen / Greetings,
Hendrik Neumann; Ruhr-University of Bochum


RE: dataTable with two rows per data row

2006-01-08 Thread Jesse Alexander \(KBSA 21\)
Hi Robert

-Original Message-
Is it possible to create a h:dataTable that has two HTML rows per row of

data? Its just that I want to display a long message that wont fit next 
to all the other columns, as hoping it might be possible to display it 
under the row.
-/Original Message-

I think you will need a custom renderer for one of the data-tables.
(have considered the same stuff for similar user-requirements)

You would not have to do all the stuff... when you extend the 
original renderer. Just look at the code of the renderer... it is
so obvious what to do... once you decide yourself to go that 
road...

hth
Alexander

PS: if you need more details, come online in the ##jsf chat


RE: Nighty build link does't work

2006-01-06 Thread Jesse Alexander \(KBSA 21\)
Hi Onur

Sean has sent a mail tothis list on Wednesday 4th January with this 
content:

--
   ---snipped
During the transition time the website will not be
updated and the nightly builds will not be running.
   ---snipped
--

The complete message is in the mail archive:


hth
Alexander


-Original Message-
From: Onur Tokan [mailto:[EMAIL PROTECTED] 
Sent: Friday, January 06, 2006 11:28 AM
To: MyFaces Discussion
Subject: Nighty build link does't work

Hi,

Nightly build link in myfaces home page doesn't work.

http://svn.apache.org/builds/myfaces/nightly/

Regards,

Onur


RE: JSF Chart Creator and JSF Client Side Validators

2006-01-05 Thread Jesse Alexander \(KBSA 21\)
I doubt that it will be possible to work without the servlet... (knowing
JFreeChart)

regards
Alexander



From: Legolas Woodland [mailto:[EMAIL PROTECTED] 
Sent: Thursday, January 05, 2006 1:24 PM
To: MyFaces Discussion
Subject: Re: JSF Chart Creator and JSF Client Side Validators


Martin Marinschek wrote: 

I'm very sorry, but this will surely not be finished in a week.
If you
need something in a week, you'll better use the component in its
current state.

regards,

Martin
  


What i need to learn to remove the component dependency over a servlet ?

Thank you.



On 1/5/06, Legolas Woodland <[EMAIL PROTECTED]>
  wrote:
  

 Cagatay Civici wrote:
Hi,

 JSF Chart Creator control requires JFreeChart to
compile but as you guys
said if it is not possible to include it in myFaces due
to licensing issues
the best solution for now might be to provide a link to
it from MyFaces so
users who need charting can find easily.

 JSF Client Validators has no external dependencies,
I've tested the
component only with the internet explorer and several
improvements might be
needed to make it run without problems in other
browsers.

 And yes I have time/interest to refactor and make the
components compatible
with the myFaces conventions. I am currently working on
getting familiar
with the internal structure of myFaces library.

 Per Legolas's question.
 Chart Creator uses a servlet which prevents it from
being used inside
portlets but I think can fix this issue soon.
 Thank you very much.
 Can i be optimistic that i will have A chart component
in this week ?
 Im not Expert programmer , so i can not make my chart
myself .



 Regards,
 Cagatay Civici
 www.jroller.com/page/cagataycivici






--

http://www.irian.at

Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German

Professional Support for Apache MyFaces

  




RE: JSF Chart Creator and JSF Client Side Validators

2006-01-05 Thread Jesse Alexander \(KBSA 21\)
And <http://www.ibiblio.org/maven2/jfreechart/jfreechart/>  
shows there is already the 1.0.0 version for maven 2...
<http://www.jfree.org/phpBB2/viewtopic.php?t=15696&highlight=maven>
says the same...




-Original Message-----
From: Jesse Alexander (KBSA 21) 
Sent: Thursday, January 05, 2006 10:34 AM
To: MyFaces Discussion; [EMAIL PROTECTED]
Subject: RE: JSF Chart Creator and JSF Client Side Validators

-Original Message-
Is JFreeChart in the maven-repository?
-/Original Message-

according to <http://www.ibiblio.org/maven/layout.html>
"Maven repository contents at Wed Nov 10 02:31:45 EST 2004"

JFreeChart is at: /jfreechart/jars/jfreechart-0.9.2.jar 1802240








RE: JSF Chart Creator and JSF Client Side Validators

2006-01-05 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
Is JFreeChart in the maven-repository?
-/Original Message-

according to 
"Maven repository contents at Wed Nov 10 02:31:45 EST 2004"

JFreeChart is at: /jfreechart/jars/jfreechart-0.9.2.jar 1802240








RE: JSF Chart Creator and JSF Client Side Validators

2006-01-05 Thread Jesse Alexander \(KBSA 21\)
> What is with *our* sourceforge project "jsf-comp" for the chart related stuff?
> could this be a possibility for a (unknown) timeframe?
That is the idea of the jsf-comp-project ;-)
-> easy access to a repository and distribution plattform with less
   restrictive rules on licences in order to have more components for 
   users

@Cagatay Civici : If you want, just send me (or mike kienenberger) an email 
with your sourceforge-id, and we will add you to the project.


About Licensing:
If we do not distribute the JFreeChart-Library with the component and just 
document the dependency, would this make it possible to include the component?

This would mean that to build the component ee need a LGPL-library and the
end-user using this component also needs the jar-file.  But all the others can
also live without it.
After all our stuff also depends on the JDK and I do not think that is released 
with an apache(-compatible)-license.


regards
Alexander  


-Original Message-
From: Matthias Wessendorf [mailto:[EMAIL PROTECTED] 
Sent: Thursday, January 05, 2006 9:57 AM
To: MyFaces Discussion; [EMAIL PROTECTED]
Subject: Re: JSF Chart Creator and JSF Client Side Validators

Hi,

> I think we've lost the originator of this thread along the way, so I
> am trying to include him again...

looks like ;)

> While we cannot include the chart stuff into the project due to
> license issues, I'd be highly interested in the client-side validation
> code.

+1 for client side from me

What is with *our* sourceforge project "jsf-comp" for the chart related stuff?
could this be a possibility for a (unknown) timeframe?

-Matthias


> @Ray Santiago: no, compatibility to the RI won't be hindered by being
> a tomahawk component. While it is true that there are still some
> tomahawk components which have RI compatibility issues, there is
> nothing in tomahawk architecture that would preclude compatibility.
>
> regards,
>
> Martin
>
> On 1/4/06, Matthias Wessendorf <[EMAIL PROTECTED]> wrote:
> > > they look great, but JFreeChart is LGPL based dependency.
> >
> > I guess there is no thing like "licences bridge", isn't it?
> >
>
>
> --
>
> http://www.irian.at
>
> Your JSF powerhouse -
> JSF Consulting, Development and
> Courses in English and German
>
> Professional Support for Apache MyFaces
>


--
Matthias Wessendorf
Zülpicher Wall 12, 239
50674 Köln
http://www.wessendorf.net
mwessendorf-at-gmail-dot-com


RE: SQL paging with dataScroller

2006-01-04 Thread Jesse Alexander \(KBSA 21\)
No way that you need to resort to stored procedures...
 
It's just a bit nasty to do especially if you want to sort on every
column.
Basically the technique is about 20 years old.

You need a special datamodel, which stores the key-information of the
first and
the last record. 
When you need the next few records you make something like:

Select top AAA --column-names-- from table where (--your selection
criterias) 
and (key_column_1 >= last_key_column_1 and key_column_2 >=
last_key_column_2)

Hope you can see the pattern.

hth 
Alexander



From: Yee CN [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, January 04, 2006 5:29 PM
To: 'MyFaces Discussion'
Subject: RE: SQL paging with dataScroller



You have to resort to stored procedures to do paging with Microsoft SQL
server. This is an example:
http://weblogs.asp.net/pwilson/archive/2003/10/10/31456.aspx. 

 

Maybe you should consider MySQL? It offers a very convenient "Limit
offset, limit" clause for paging.

 

Regards,

Yee

 

 



From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, 3 January 2006 9:37 PM
To: users@myfaces.apache.org
Subject: RE: SQL paging with dataScroller

 

Paging at the database level is feasible sometimes natively but it
depends what you are using. For example, it's easy with Oracle but not
with SQL Server natively. However, that means that any changes in
sorting dynamically require reordering your recordset to output it
properly. 

 

In this case, depending how it's done, it could mean running the query
again with a different SORT clause, which means it could be pretty less
efficient than keeping a map/list of results in a "buffer" that you just
play with. But of course different cases call for different solutions.
Maybe you can elaborate a bit on what you want to do exactly and what
you need to provide (sorting, size of recordsets, etc...)?

 

If it applies, then I think it should be fairly easy to implement using
a datascroller that is plugged on a bean method that retrieves the
required data on get() probably? I've never personally done it but I
believe some people do it here.

 

Greg

-Original Message- 
From: Rafael Nami [mailto:[EMAIL PROTECTED] 
Sent: Tue 1/3/2006 8:23 AM 
To: MyFaces Discussion 
Cc: 
Subject: SQL paging with dataScroller

 



RE: JSF web application test

2005-12-20 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
I believe you are looking for httpunit .
-/Original Message-

Or its abstraction JWebUnit.

Alexander

 Original message 
>   What is the way to write automatic tests for web
>   application using JSF? Right now I have to open web
>   browser to manually test it. I like to write tests
>   that can be executed as a batch to make sure that
>   new changes will not break existing features.
>
>   Thanks for advice.
>   Dave


RE: Simplifying column expression

2005-12-07 Thread Jesse Alexander \(KBSA 21\)
Not really all necessary...
You would need to 
a) replace the datatable-renderer (he is responsible for the
column-header-rendering)
b) create the column-header-component...

regards
Alexander

-Original Message-
From: Mike Kienenberger [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, December 07, 2005 4:30 PM
To: MyFaces Discussion; [EMAIL PROTECTED]
Subject: Re: Simplifying column expression

Unless you're using some sort of substitution technology like
facelets, it probably won't be trivial.   You'll need to subclass
UIColumn to create MyColumn, and then either read the
 tag in as a "header" facet, or have the
 component create a header facet on its parent
UIColumn on creation.  At least, that's my understanding of the
situation.

On 12/7/05, Juergen Melzer <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I want to simplify the expression
>   
>   
> 
>   
>   
> 
>
> with this one:
>
>   
> 
> 
>   
>
> Does anyone know how to make it?
>
> Thanks,
> Juergen
>
> _
> Die neue MSN Suche Toolbar mit Windows-Desktopsuche. Suchen Sie
gleichzeitig
> im Web, Ihren E-Mails und auf Ihrem PC! Jetzt neu!
http://desktop.msn.de/
> Jetzt gratis downloaden!
>
>


RE: Execute method automatically after page has been loaded and shown to user

2005-12-07 Thread Jesse Alexander \(KBSA 21\)
Hi Andy

the refresh tag is a standard-html-tag:


http://de.selfhtml.org/";>




as URL put something like http://myHost/myAppContext/faces/...
That will trigger the normal JSF-request processing, and, if you reference
a managed bean that will construct the connection (in its constructor?), it 
should be initiated.

A bit clearer now? Else we could discuss it inthe irc-channel  this evening... 
(at work I haveno connection)

regards
Alexander

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, December 07, 2005 10:44 AM
To: users@myfaces.apache.org
Subject: AW: Execute method automatically after page has been loaded and shown 
to user

Hi Alexander!

I just don't exactly know what you mean.

In my JSF there should be a meta tag, that refreshes the page only one time 
depending on a session attribute?
I don't know how to do that the connection will be build at first, when the 
refresh starts (when the page will be rendered the second time) and not when 
the page will be rendered the first time?

Regards,
Andy



-Ursprüngliche Nachricht-
Von: Jesse Alexander (KBSA 21)
[mailto:[EMAIL PROTECTED]
Gesendet: Mittwoch, 7. Dezember 2005 10:38
An: MyFaces Discussion
Betreff: RE: Execute method automatically after page has been loaded and
shown to user


Hi Andy

Have you thought about using the refresh-meta-tag?

You could render the page on first visit with a refresh header set to 1 second. 
The page would be rendered reading "--- please wait ---" and in the background 
initiate
a new request which then would build the connection, and render a new page...

A flag in the session could signal to your code whether the redirection is 
needed or not.

Advantages I see:
- standard request-processing
- the user would see the browser activity and could conclude: "ok, something is 
being 
  processed"

hth
Alexander

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, December 07, 2005 10:29 AM
To: users@myfaces.apache.org
Subject: AW: Execute method automatically after page has been loaded and shown 
to user

Hi Mike!

I like the idea with the Servlet Listener,but I see one problem:
The database connection is already openened when the Application Server is 
started
-So could there be a problem with database connection timeouts? What happens, 
when the database returns a timeout.
-If no timeout happens, isn't it a bad approach to let the connection open all 
the time, because database connection are expensive as long as I know?

What do you think about my thoughts?

Regards
Andy

-Ursprüngliche Nachricht-
Von: Mike Kienenberger [mailto:[EMAIL PROTECTED]
Gesendet: Dienstag, 6. Dezember 2005 17:22
An: MyFaces Discussion
Betreff: Re: Execute method automatically after page has been loaded and
shown to user


Andy,

There's many ways to do this.

Some ways you could do it:

1) Use the Shale ViewController stuff to define your backing bean to
be the controlling bean for your page.  It'd be able to receive events
like pre-render and post-render.

2) Create a phase listener that ran at pre-render and post-render phase.

3) Use a servlet filter -- this is how I manage my database
connections, but I have need for my database connection to be active
at all phases of JSF.

On 12/6/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
>
> Hi All!
>
> How can I execute a method from a backing bean AUTOMATICALLY after a page
> has been loaded and shown to the user?
>
> My exactly problem is the following:
> When the user opens the first page, this page should be shown normally (and
> quickly) to the user. In the background the connection to the database
> should be build (automatically, no button should be pressed) -->I use
> Hibernate and the first connection (building of connection pool) takes some
> seconds, so this should be done in background, but the user should already
> see something in his browser (with an info, that the connection to the
> database is just built)
>
> Is there a possibility to do that?
>
> Thx
>
> Regards
> Andy
> __
> This email and any files transmitted with it are confidential and intended
> solely for the use of the individual or entity to whom they are addressed.
> If you have received this email in error please notify your system manager.
> This footnote also confirms that this email message has been swept for the
> presence of computer viruses.
> __
>


__

This email and any files transmitted with it are confidential and
intended solel

RE: Execute method automatically after page has been loaded and shown to user

2005-12-07 Thread Jesse Alexander \(KBSA 21\)
Hi Andy

Have you thought about using the refresh-meta-tag?

You could render the page on first visit with a refresh header set to 1 second. 
The page would be rendered reading "--- please wait ---" and in the background 
initiate
a new request which then would build the connection, and render a new page...

A flag in the session could signal to your code whether the redirection is 
needed or not.

Advantages I see:
- standard request-processing
- the user would see the browser activity and could conclude: "ok, something is 
being 
  processed"

hth
Alexander

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, December 07, 2005 10:29 AM
To: users@myfaces.apache.org
Subject: AW: Execute method automatically after page has been loaded and shown 
to user

Hi Mike!

I like the idea with the Servlet Listener,but I see one problem:
The database connection is already openened when the Application Server is 
started
-So could there be a problem with database connection timeouts? What happens, 
when the database returns a timeout.
-If no timeout happens, isn't it a bad approach to let the connection open all 
the time, because database connection are expensive as long as I know?

What do you think about my thoughts?

Regards
Andy

-Ursprüngliche Nachricht-
Von: Mike Kienenberger [mailto:[EMAIL PROTECTED]
Gesendet: Dienstag, 6. Dezember 2005 17:22
An: MyFaces Discussion
Betreff: Re: Execute method automatically after page has been loaded and
shown to user


Andy,

There's many ways to do this.

Some ways you could do it:

1) Use the Shale ViewController stuff to define your backing bean to
be the controlling bean for your page.  It'd be able to receive events
like pre-render and post-render.

2) Create a phase listener that ran at pre-render and post-render phase.

3) Use a servlet filter -- this is how I manage my database
connections, but I have need for my database connection to be active
at all phases of JSF.

On 12/6/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
>
> Hi All!
>
> How can I execute a method from a backing bean AUTOMATICALLY after a page
> has been loaded and shown to the user?
>
> My exactly problem is the following:
> When the user opens the first page, this page should be shown normally (and
> quickly) to the user. In the background the connection to the database
> should be build (automatically, no button should be pressed) -->I use
> Hibernate and the first connection (building of connection pool) takes some
> seconds, so this should be done in background, but the user should already
> see something in his browser (with an info, that the connection to the
> database is just built)
>
> Is there a possibility to do that?
>
> Thx
>
> Regards
> Andy
> __
> This email and any files transmitted with it are confidential and intended
> solely for the use of the individual or entity to whom they are addressed.
> If you have received this email in error please notify your system manager.
> This footnote also confirms that this email message has been swept for the
> presence of computer viruses.
> __
>


__

This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
your system manager.
 
This footnote also confirms that this email message has been swept
for the presence of computer viruses. 
__


FW: Error in deploying jsf application

2005-12-06 Thread Jesse Alexander \(KBSA 21\)
 Sorry bad list again...

-Original Message-
From: Jesse Alexander (KBSA 21) 
Sent: Tuesday, December 06, 2005 1:44 PM
To: MyFaces Development
Subject: RE: Error in deploying jsf application

Hi Bill

do you mean tomcat.jar or tomahawk.jar

hth
Alexander 


I can't be sure but it looks like you are missing the tomcat jar from
your WEB-INF/lib directory.

On Dec 6, 2005, at 4:08 AM, Gabriele Morelli wrote:


Hi,
i found your email on mail-archives.org and thought to write you
because I am getting an error as I deploy my jsf application, this is
the error:
 
org.apache.jasper.JasperException: The absolute uri:
http://myfaces.apache.org/extensions
<http://myfaces.apache.org/extensions>  cannot be resolved in either
web.xml or the jar files deployed with this application
D:\Schede285_jsf\nbproject\build-impl.xml:330: Java returned: 1
 
Do you have any clue of what it might be? Thank you for you
time.
 
-=GAB=-





RE: myfaces in weblogic

2005-12-06 Thread Jesse Alexander \(KBSA 21\)
Hi Peter 

I think I read somewhere, that SP4 for WLS fixes the problem, that 
WLS initializes the Servlets before the listeners have finished.

That's why the MyFacesServlet explicetely can initialize
MyFaces in its init()-method. This Servlet is still in the 
MyFaces jar-files. It only changed its package-name.
-> org.apache.myfaces.webapp.MyFacesServlet

For the listener it could be something similar to the servlet:
repackaging...

hth
Alexander

--- Peter Maas <[EMAIL PROTECTED]> wrote:

> wl version 8.11, so SP1... and I don't have the
> option to install additional
> service packs... hopefully this is not mandatory?
> 
> -P
> 
> 
> On 12/6/05, Udo Schnurpfeil
> <[EMAIL PROTECTED]> wrote:
> >
> > Which service pack?
> >
> > Udo
> >
> > Peter Maas wrote:
> > > Hi all,
> > >
> > > I'm trying to get a basic myfaces application to
> run on weblogic 8.1
> > > but without any luck yet. I googled arround a
> bit and found some
> > > contradicting bits on form but no 'THIS is how
> to to it, THIS is why'.
> > >
> > > The problem I'm running into seems to be related
> to context
> > > initialisation:
> > >
> > >
> > > java.lang.ExceptionInInitializerError.
> > > at
> > >
>
weblogic.servlet.internal.ServletStubImpl.prepareServlet(
> > ServletStubImpl.java
> > > :822)
> > > at
> > >
>
weblogic.servlet.internal.WebAppServletContext.preloadServlet(
> > WebAppServletContext.java:3236)
> > > at
> > >
>
weblogic.servlet.internal.WebAppServletContext.preloadServlets(
> > WebAppServletContext.java:3181)
> > >
> > > at
> > >
>
weblogic.servlet.internal.WebAppServletContext.preloadResources(
> > WebAppServletContext.java:3154)
> > > at
> > >
>
weblogic.servlet.internal.HttpServer.preloadResources(HttpServer.java
> > :654)
> > > at
>
weblogic.servlet.internal.WebService.preloadResources
> > > (WebService.java:483)
> > > at
> > >
> weblogic.servlet.internal.ServletInitService.resume(
> > ServletInitService.java:30)
> > > at
> > >
>
weblogic.t3.srvr.SubsystemManager.resume(SubsystemManager.java:131)
> > > at weblogic.t3.srvr.T3Srvr.resume
> (T3Srvr.java:964)
> > > at
> weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:359)
> > > at weblogic.Server.main(Server.java:32)
> > >
> > >
> > > A forum on the sun site recommends the use of a
> specific listener,
> > > which is not included in the myfaces
> distribution... another post on
> > > yet another forum recommended the use of a
> different servlet (
> > > net.sourceforge.myfaces.webapp.MyFacesServlet)
> which is no part at of
> > > the myfaces distribution either?
> > >
> > > any help appriciated!
> > >
> > > -P
> >
> >
> 




__ 
Yahoo! DSL - Something to write home about. 
Just $16.99/mo. or less. 
dsl.yahoo.com 



RE: Re: MyFaces for production?

2005-12-02 Thread Jesse Alexander \(KBSA 21\)
Hi

just some figures from my profiling sessions for verification (meaning:
have sou seen similar/comparable numbers)

Application: VERY simple application (crossbar helloWorld) with no
business 
 logic, just one string attribute with a pure
getter/setter-access 
Servlet-Engine:  Tomcat 5.0
Hardware:IBM R50 laptop (1.5MHz Centrino, 1GB of memory)
Profiler:Yourkit 4.0
JDK: Sun 1.4.2
Usecase: results in 10 requests, 1 with a validation exception
Load:1 single user
Versions:
 - MyFaces   1.1.0
 - RI1_1_01


(all values in milliseconds)
Lifecycle-phase
State   RestApply   Proc.Upd.Invok Rendr  Total CPU
ViewReq.Valid. Model ApplResp
ms/Request
MF  Srvr   5010  10   10  0  32042
  Clnt  300  10   00 10  741   108
RI  Srvr 40  90  500 10  57077
  Clnt  711  70  40   20 20 1492   237 

retained memory after 10 requests
MyFaces Server: 64kB (4 kB in Session)
Client: 65kB (0.5 kB in Session)
RI  Server: 46kB (9 kB in Session)
Client: 29kB (0.5 kB in Session)

Size of transferred state-info (2 views...)
  welcome.jsf response.jsf
MyFaces (2Fields) 1836 Bytes  1532 Bytes
RI (1 Field)  1444 Bytes  1220 Bytes

Conclusions:
- MyFaces seems to be lighter on CPU (roughly 50% of RI)
- RI seems to be lighter on Memory (roughly 50-65% of MF)
- MyFaces-server-state produces a smaller session (roughly 50% of RI)
- RI-client-state transfers less (about 75% of MF)
- RI has less memory allocated outside the session (roughly 50-65% of
MF)

Unknowns:
- What happens with the memory-footprint when more than 1 concurrent
user 
  are producing load?
- How are the CPU-footprints when the views get more complex?

Comments/Ideas/Recommendations are VERY welcome
Alexander

PS: if someone creates a facelet-version of the sample-application I
would 
try to recreate the same measurements. Please contact me. The
Crossbar-
Application had to be changed to work with JSF 1.1!

-Original Message-
From: Martin Marinschek [mailto:[EMAIL PROTECTED] 
Sent: Friday, December 02, 2005 12:37 PM
To: MyFaces Discussion
Subject: Re: Re: MyFaces for production?

Hi,

no performance measurement here - but 5 JSF intranet and 3 internet
applications deployed here on MyFaces, no problems with performance
whatsoever.

Interesting for the performance is the switch between client-side and
server-side state saving - client-side is better for memory,
server-side is much better for CPU performance!

regards,

Martin

On 12/2/05, Jesse Alexander (KBSA 21)
<[EMAIL PROTECTED]> wrote:
> Sounds like time to do thread-dumps (and -analysis)...
>
> Have you two done some performance-measurements on your apps?
>
> regards
> Alexander
>
> -Original Message-
> From: news [mailto:[EMAIL PROTECTED] On Behalf Of Werner Punz
> Sent: Friday, December 02, 2005 9:59 AM
> To: users@myfaces.apache.org
> Subject: Re: MyFaces for production?
>
> Francesco Consumi wrote:
>
> > Performance is good, we have only some problem with
> > http://www.istitutodeglinnocenti.it, our main site, that somewhere
> locks
> > java process at 100% of cpu, but we're investigating
> >
> Interesting, I never have had that issue, with now two big JSF
programs
> an a number
> of small internal hacks.
> My guess is that there is some deadlock in the app code, to my
knowledge
> MyFaces does not have any isse in this area.
>
>
>


--

http://www.irian.at

Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German

Professional Support for Apache MyFaces


RE: Re: MyFaces for production?

2005-12-02 Thread Jesse Alexander \(KBSA 21\)
Sounds like time to do thread-dumps (and -analysis)...

Have you two done some performance-measurements on your apps?

regards
Alexander 

-Original Message-
From: news [mailto:[EMAIL PROTECTED] On Behalf Of Werner Punz
Sent: Friday, December 02, 2005 9:59 AM
To: users@myfaces.apache.org
Subject: Re: MyFaces for production?

Francesco Consumi wrote:

> Performance is good, we have only some problem with
> http://www.istitutodeglinnocenti.it, our main site, that somewhere
locks
> java process at 100% of cpu, but we're investigating
> 
Interesting, I never have had that issue, with now two big JSF programs
an a number
of small internal hacks.
My guess is that there is some deadlock in the app code, to my knowledge
MyFaces does not have any isse in this area.




RE: Using converters in non-JSF related code.

2005-12-01 Thread Jesse Alexander \(KBSA 21\)
Instead of subclassing it, I would "prefer" to delegate, that creates
two classes with a less tight coupling.

-Original Message-
There's not much in a converter and there shouldn't be any reason why
you couldn't do this.
However, since you're having to pass in a FacesContext and a
UIComponent, I think you'd have to reimplement a lot of unnecesary
support classes.

I'm not sure I'd stick it in a static utility method, but maybe that
makes sense in your use cases.

I'd probably go with a presentation-layer-independent converter class.
 Then subclass it to create the JSF converter.


When I look at my own JSF converters, this is a trivial refactoring. 
I've already got the non-JSF conversions being handled in separate
methods which are called by the getAs methods.

On 11/30/05, Sean Schofield <[EMAIL PROTECTED]> wrote:
> Has anyone ever used a JSF converter in code that wasn't specifically
> related to JSF?  The reason why I am asking is that we are migrating
> an application to JSF and a portion of the pages are in JSF but a
> portion are still in Struts.
>
> Two possible ideas come to mind:
>
> 1.) Use the converter's getAsString method inside of a static utility
method
>
> 2.) Move the logic from the getAsString method to a static utility
method.
>
> I suppose approach #2 is less of a hack since you avoid FacesContext
> and other JSF specific stuff in your static helper.
>
> Any other thoughts or approaches?
>
> TIA,
>
> sean
>


RE: Memory Management on Application Level?

2005-12-01 Thread Jesse Alexander \(KBSA 21\)
Hi Thierry

A quick solution might be a cache. Those libraries often include 
size-limiting strategies.

You then have to make sure that you do not keep links to the objects 
in your session-beans in order to release them gracefully...

hth
Alexander 

-Original Message-
From: Thierry Buecheler [mailto:[EMAIL PROTECTED] 
Sent: Thursday, December 01, 2005 3:47 PM
To: MyFaces Discussion
Subject: Re: Memory Management on Application Level?

Does nobody know this or is this the wrong mailing list?

T.

Thierry Buecheler wrote:
> Hi everybody
> 
> I'm looking for a possibility to prevent Java heap overflows due to
user 
> peaks for our JSF application. We would like to keep track of memory 
> usage for every user (for example by setting an application wide limit

> for generated objects). Is there a possibility to do that beyond
session 
> limits?
> 
> If, say, every user lists a unknown number of objects on a page and I 
> want to limit the entire webserver-load to n objects (for all current 
> sessions), how could I do that? Is there an appropriate method on 
> "application" which I missed?
> 
> Thank you very much,
> Thierry


RE: focus component

2005-11-25 Thread Jesse Alexander \(KBSA 21\)
those that want to participate... we usually meet in the #myfaces channel to
interactively discuss such stuff... often results in rapid solutions or
hints to pursue.

regards
Alexander 

-Original Message-
From: Matthias Wessendorf [mailto:[EMAIL PROTECTED] 
Sent: Friday, November 25, 2005 11:35 AM
To: MyFaces Discussion
Subject: Re: focus component

thanks jesse!

On 11/25/05, Jesse Alexander (KBSA 21)
<[EMAIL PROTECTED]> wrote:
> We have uploaded the component to the Jsf-Component (SF-)project.
> In this way we can collaborate better on this component.
> Yesterday we discovered that some additional work is needed to
> make the usage easier. We want to be able to use EL-expressions
> instead of the described code in the managed-bean
>
> regards
> Alexander
>
> -Original Message-
> From: Martin Marinschek [mailto:[EMAIL PROTECTED]
> Sent: Friday, November 25, 2005 5:51 AM
> To: MyFaces Discussion
> Subject: Re: focus component
>
> looks good.
>
> I think you did already open a jira on this, right? If not, please do
> it right now.
>
> I'll review this some time during next week, when I will hopefully get
> my open bugs closed as well ;)
>
> regards,
>
> Martin
>
> On 11/24/05, Rogerio Pereira <[EMAIL PROTECTED]> wrote:
> > Hi guys!
> >
> > I wrote a simple component that can set the focus in any form control
> > across multiple submissions, this is useful to control form
> > navigation.
> >
> > How to use:
> >
> > In jsp (before close h:form):
> >
> > 
> >
> > in managed bean:
> >
> > private HtmlFocus  focus;
> > focus   = (HtmlFocus)form.findComponent("focus");
> > focus.setComponent("txtNome");
> >
> >
> > --
> > Yours truly (Atenciosamente),
> >
> > Rogério
> >
> >
> >
>
>
> --
>
> http://www.irian.at
>
> Your JSF powerhouse -
> JSF Consulting, Development and
> Courses in English and German
>
> Professional Support for Apache MyFaces
>


--
Matthias Wessendorf
Zülpicher Wall 12, 239
50674 Köln
http://www.wessendorf.net
mwessendorf-at-gmail-dot-com


RE: focus component

2005-11-25 Thread Jesse Alexander \(KBSA 21\)
We have uploaded the component to the Jsf-Component (SF-)project.
In this way we can collaborate better on this component. 
Yesterday we discovered that some additional work is needed to 
make the usage easier. We want to be able to use EL-expressions
instead of the described code in the managed-bean

regards
Alexander

-Original Message-
From: Martin Marinschek [mailto:[EMAIL PROTECTED] 
Sent: Friday, November 25, 2005 5:51 AM
To: MyFaces Discussion
Subject: Re: focus component

looks good.

I think you did already open a jira on this, right? If not, please do
it right now.

I'll review this some time during next week, when I will hopefully get
my open bugs closed as well ;)

regards,

Martin

On 11/24/05, Rogerio Pereira <[EMAIL PROTECTED]> wrote:
> Hi guys!
>
> I wrote a simple component that can set the focus in any form control
> across multiple submissions, this is useful to control form
> navigation.
>
> How to use:
>
> In jsp (before close h:form):
>
> 
>
> in managed bean:
>
> private HtmlFocus  focus;
> focus   = (HtmlFocus)form.findComponent("focus");
> focus.setComponent("txtNome");
>
>
> --
> Yours truly (Atenciosamente),
>
> Rogério
>
>
>


--

http://www.irian.at

Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German

Professional Support for Apache MyFaces


RE: possible bug:

2005-11-25 Thread Jesse Alexander \(KBSA 21\)
To me it seems that the background of the popup is half-transparent.
Maybe it's working as designed by the browsers or an issue with css?

Have you tried with different browsers?

hth
Alexander



From: Jeffrey Porter [mailto:[EMAIL PROTECTED] 
Sent: Friday, November 25, 2005 10:43 AM
To: MyFaces Discussion
Subject: possible bug:



 

Why is it that when using  http://www.porter.eu.com/jeff/example.JPG

 



RE: Performance Question

2005-11-24 Thread Jesse Alexander \(KBSA 21\)
That does not sound like a performance problem... rather like a 
memory leak ...

Or a wls-instance with too less memory...

hth
Alexander

-Original Message-
From: rosalba bochicchio [mailto:[EMAIL PROTECTED] 
Sent: Thursday, November 24, 2005 6:13 PM
To: users@myfaces.apache.org
Subject: Performance Question

Hi all,
have anybody of you ever had problems with performance
in a web application based on JSF framework?

I'm using BEA WEblogic 8.1 and noticed that the server
suddenly gets 
OutOfMemory Errors ..and I need to restart it 

Any known issue or suggestion?

Thanks




__ 
Yahoo! Mail - PC Magazine Editors' Choice 2005 
http://mail.yahoo.com


RE: javadocs for 1.0.9

2005-11-17 Thread Jesse Alexander \(KBSA 21\)
Thanks Martin 

When I pass by close to Vienna, I'll remember.
Thanks for the info you sent to my colleague Robert. I hope in the long
run
that I can set up our production environment based on MyFaces. Right now

I need to get the numbers to have JSF be specified as our presentation
framework for future developments.

Right now the complete source (for RI it is not available) and the
better
support speak for MyFaces. The better Javadoc for RI ;-(

regards
Alexander

-Original Message-
From: Martin Marinschek [mailto:[EMAIL PROTECTED] 
Sent: Thursday, November 17, 2005 9:14 AM
To: MyFaces Discussion
Subject: Re: javadocs for 1.0.9

If not,

we'll do everything to change that to our favour - be it fixing
problems, be it buying you a beer ;)

regards,

Martin

On 11/17/05, Jesse Alexander (KBSA 21)
<[EMAIL PROTECTED]> wrote:
> Yes, I needed the sample apps, cause I'm having problems setting up
our
> application with MyFaces in a weblogic 8.1
> Now I check out the sample war-filesto get an idea where the bug in my
> setup is. Then I should finally be able to do a comparision in the
> area of single request profiling between the RI and MyFaces. (Let's
> hope the numbers speak for MyFaces ;-) )
>
> regards
> Alexander
>
> -Original Message-
> From: Sean Schofield [mailto:[EMAIL PROTECTED]
> Sent: Thursday, November 17, 2005 4:31 AM
> To: MyFaces Discussion
> Subject: Re: javadocs for 1.0.9
>
> I don't think the archived releases are mirrored so its ok to download
> them directly from the link in my last email.  There isn't to much
> interest in older releases so those are OK to host at ASF.
>
> There is a link to the "archive" on the download page but its kind of
> hidden in the text.  You did eventually find what you needed right?
>
> sean
>
> On 11/16/05, Jesse Alexander (KBSA 21)
> <[EMAIL PROTECTED]> wrote:
> > Sorry, I was looking some hours ago at the download-page.
> > As the use of mirrors is recommended I just found 1.1.0 and 1.1.1
> > but no 1.0.9.
> >
> > Shame on me
> > Alexander
> >
> > -Original Message-
> > From: Sean Schofield [mailto:[EMAIL PROTECTED]
> > Sent: Thursday, November 17, 2005 12:00 AM
> > To: MyFaces Discussion
> > Subject: Re: javadocs for 1.0.9
> >
> > There is a link to them on the download page [1].
> >
> > sean
> >
> > [1] http://archive.apache.org/dist/myfaces/
> >
> > On 11/16/05, Jesse Alexander (KBSA 21)
> > <[EMAIL PROTECTED]> wrote:
> > > just where are the 1.0.9 download-files?
> > >
> > > regards
> > > Alexander
> > >
> > > -Original Message-
> > > From: Sean Schofield [mailto:[EMAIL PROTECTED]
> > > Sent: Wednesday, November 16, 2005 7:24 PM
> > > To: MyFaces Discussion
> > > Subject: Re: javadocs for 1.0.9
> > >
> > > The javadoc should be in one of the release bundles (source?) for
> > > 1.0.9 already.  Just download that one.
> > >
> > > sean
> > >
> > > On 11/16/05, Dennis Byrne <[EMAIL PROTECTED]> wrote:
> > > > was t:graphicImage included in the 1.0.9 release?
> > > >
> > > > can we please get a seperate section on the web site for
> > > > 1.0.9 javadocs and 1.1.1 javadocs?
> > > >
> > > > Dennis Byrne
> > > >
> > >
> >
>


--

http://www.irian.at

Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German

Professional Support for Apache MyFaces


RE: javadocs for 1.0.9

2005-11-17 Thread Jesse Alexander \(KBSA 21\)
Yes, I needed the sample apps, cause I'm having problems setting up our
application with MyFaces in a weblogic 8.1
Now I check out the sample war-filesto get an idea where the bug in my
setup is. Then I should finally be able to do a comparision in the 
area of single request profiling between the RI and MyFaces. (Let's
hope the numbers speak for MyFaces ;-) )

regards
Alexander

-Original Message-
From: Sean Schofield [mailto:[EMAIL PROTECTED] 
Sent: Thursday, November 17, 2005 4:31 AM
To: MyFaces Discussion
Subject: Re: javadocs for 1.0.9

I don't think the archived releases are mirrored so its ok to download
them directly from the link in my last email.  There isn't to much
interest in older releases so those are OK to host at ASF.

There is a link to the "archive" on the download page but its kind of
hidden in the text.  You did eventually find what you needed right?

sean

On 11/16/05, Jesse Alexander (KBSA 21)
<[EMAIL PROTECTED]> wrote:
> Sorry, I was looking some hours ago at the download-page.
> As the use of mirrors is recommended I just found 1.1.0 and 1.1.1
> but no 1.0.9.
>
> Shame on me
> Alexander
>
> -Original Message-
> From: Sean Schofield [mailto:[EMAIL PROTECTED]
> Sent: Thursday, November 17, 2005 12:00 AM
> To: MyFaces Discussion
> Subject: Re: javadocs for 1.0.9
>
> There is a link to them on the download page [1].
>
> sean
>
> [1] http://archive.apache.org/dist/myfaces/
>
> On 11/16/05, Jesse Alexander (KBSA 21)
> <[EMAIL PROTECTED]> wrote:
> > just where are the 1.0.9 download-files?
> >
> > regards
> > Alexander
> >
> > -Original Message-
> > From: Sean Schofield [mailto:[EMAIL PROTECTED]
> > Sent: Wednesday, November 16, 2005 7:24 PM
> > To: MyFaces Discussion
> > Subject: Re: javadocs for 1.0.9
> >
> > The javadoc should be in one of the release bundles (source?) for
> > 1.0.9 already.  Just download that one.
> >
> > sean
> >
> > On 11/16/05, Dennis Byrne <[EMAIL PROTECTED]> wrote:
> > > was t:graphicImage included in the 1.0.9 release?
> > >
> > > can we please get a seperate section on the web site for
> > > 1.0.9 javadocs and 1.1.1 javadocs?
> > >
> > > Dennis Byrne
> > >
> >
>


RE: javadocs for 1.0.9

2005-11-16 Thread Jesse Alexander \(KBSA 21\)
Sorry, I was looking some hours ago at the download-page. 
As the use of mirrors is recommended I just found 1.1.0 and 1.1.1
but no 1.0.9.

Shame on me
Alexander 

-Original Message-
From: Sean Schofield [mailto:[EMAIL PROTECTED] 
Sent: Thursday, November 17, 2005 12:00 AM
To: MyFaces Discussion
Subject: Re: javadocs for 1.0.9

There is a link to them on the download page [1].

sean

[1] http://archive.apache.org/dist/myfaces/

On 11/16/05, Jesse Alexander (KBSA 21)
<[EMAIL PROTECTED]> wrote:
> just where are the 1.0.9 download-files?
>
> regards
> Alexander
>
> -Original Message-
> From: Sean Schofield [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, November 16, 2005 7:24 PM
> To: MyFaces Discussion
> Subject: Re: javadocs for 1.0.9
>
> The javadoc should be in one of the release bundles (source?) for
> 1.0.9 already.  Just download that one.
>
> sean
>
> On 11/16/05, Dennis Byrne <[EMAIL PROTECTED]> wrote:
> > was t:graphicImage included in the 1.0.9 release?
> >
> > can we please get a seperate section on the web site for
> > 1.0.9 javadocs and 1.1.1 javadocs?
> >
> > Dennis Byrne
> >
>


RE: javadocs for 1.0.9

2005-11-16 Thread Jesse Alexander \(KBSA 21\)
just where are the 1.0.9 download-files?

regards
Alexander 

-Original Message-
From: Sean Schofield [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, November 16, 2005 7:24 PM
To: MyFaces Discussion
Subject: Re: javadocs for 1.0.9

The javadoc should be in one of the release bundles (source?) for
1.0.9 already.  Just download that one.

sean

On 11/16/05, Dennis Byrne <[EMAIL PROTECTED]> wrote:
> was t:graphicImage included in the 1.0.9 release?
>
> can we please get a seperate section on the web site for
> 1.0.9 javadocs and 1.1.1 javadocs?
>
> Dennis Byrne
>


RE: Very puzzling out of order execution...

2005-11-15 Thread Jesse Alexander \(KBSA 21\)
Is this a request that is configured as Redirect? That could explain a
few problems...

hth
Alexander 



From: Yee CN [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, November 15, 2005 6:01 PM
To: 'MyFaces Discussion'
Subject: Very puzzling out of order execution...



INFO: AFTER UPDATE_MODEL_VALUES(4)

16/11/2005 00:45:12 com.traleva.erp.web.util.PhaseTracker afterPhase

INFO: AFTER RENDER_RESPONSE(6)

Hi,

 

I am having this very puzzling out of order execution. My setup is as
following:

 

I have 4 filters, in this order - SecurityFilter, HibernateFilterLong,
JSF-Spring filter, myfaces ExtensionFilter.

 

Now look at the following trace, my comments in brackets. Can somebody
please explain?

 

Regards,

Yee

 


-

 

16/11/2005 00:45:12 com.traleva.erp.web.util.PhaseTracker beforePhase

INFO: BEFORE INVOKE_APPLICATION(5)

00:45:12,975 DEBUG FacesServlet:132 - service end

 

(myfaces ExtensionFilter is finishing in the middle of JSF life cycle!
How can that be?)

 

00:45:12,985 DEBUG HibernateFilterLong:95 - Commiting any pending
company database txn

 

(HibernateFilterLong is beginning to wrap up after ExtensionFilter)

 

16/11/2005 00:45:13 com.traleva.erp.web.util.PhaseTracker beforePhase

INFO: BEFORE INVOKE_APPLICATION(5)

 

(And yet the JSF life cycle is still continuing, interleaving with
HibernateFilterLong execution ...)

 

00:45:13,045 DEBUG HibernateFilterLong:103 - Disconnecting Company
Hibernate Sessions

16/11/2005 00:45:13 com.traleva.erp.web.util.PhaseTracker afterPhase

INFO: AFTER INVOKE_APPLICATION(5)

00:45:13,055 DEBUG HibernateFilterLong:105 - Storing the hibernate
sessions in http session

16/11/2005 00:45:13 com.traleva.erp.web.util.PhaseTracker afterPhase

INFO: AFTER INVOKE_APPLICATION(5)

00:45:13,055 DEBUG HibernateFilterLong:114 - End of filter

 

(HibernateFilterLong finished...)

 

16/11/2005 00:45:13 com.traleva.erp.web.util.PhaseTracker beforePhase

INFO: BEFORE RENDER_RESPONSE(6)

16/11/2005 00:45:13 com.traleva.erp.web.util.PhaseTracker beforePhase

INFO: BEFORE RENDER_RESPONSE(6)

00:45:13,125 DEBUG LookupBean:67 - getLookupTypeSelectList() called

00:45:13,165 ERROR [jsp]:704 - Servlet.service() for servlet jsp threw
exception

 

(And finally I got an exception - because the Hibernate session is no
longer there!!!)

 

javax.faces.el.EvaluationException: Cannot get value for expression
'#{lookupBean.sortedLookupList}'

  at
org.apache.myfaces.el.ValueBindingImpl.getValue(ValueBindingImpl.java:39
7)

  at javax.faces.component.UIData.getValue(UIData.java:779)

  at
org.apache.myfaces.component.html.ext.HtmlDataTableHack.createDataModel(
HtmlDataTableHack.java:350)

  at
org.apache.myfaces.component.html.ext.HtmlDataTableHack.getDataModel(Htm
lDataTableHack.java:333)

  at
org.apache.myfaces.component.html.ext.HtmlDataTable.getDataModel(HtmlDat
aTable.java:428)



RE: contributing with components

2005-11-09 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
Yeah, i want one image call one method, can i render a commandLink
inside another component code, like my new Toolbar component?
-/Original Message-
Sure you can do that.

someComponent.getChildren().add(anotherComponent);


Then you can either render the child-components yourself or let JSF do it:
getRendersChildren() is the key...


When doing such stuff, I prefer to have myfaces' debugging output by adding
a corresponding log4j.xml to the classpath. This will dump you the 
pages component-tree to the log on RestoreView and RenderView

hth
Alexander



2005/11/9, Jesse Alexander (KBSA 21) <[EMAIL PROTECTED]>:
> Do you want single regions of one image to call different methods
> OR
> Do yo want to have one image call one method.
>
> If it is the second, then you could render a commandlink and have
> an image as its child. That's the way you might do it in HTML.
>
> Often thinking about how to do it in pure HTML (and posting that
> html-code) helps getting a clearer idea of what you want and
> often delivers the solution.
>
> regards
> Alexander
>
> -Original Message-
> From: Rogerio Pereira [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, November 09, 2005 2:20 PM
> To: MyFaces Discussion
> Subject: Re: contributing with components
>
> For add/remove buttons you use javascript code, but how can i make a
> click in an image call an method in backing bean? I need this to
> create the Toolbar in the future.
>
> --
> Yours truly (Atenciosamente),
>
> Rogério
>


--
Yours truly (Atenciosamente),

Rogério


RE: contributing with components

2005-11-09 Thread Jesse Alexander \(KBSA 21\)
Do you want single regions of one image to call different methods
OR
Do yo want to have one image call one method. 

If it is the second, then you could render a commandlink and have 
an image as its child. That's the way you might do it in HTML.

Often thinking about how to do it in pure HTML (and posting that
html-code) helps getting a clearer idea of what you want and
often delivers the solution.

regards
Alexander 

-Original Message-
From: Rogerio Pereira [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, November 09, 2005 2:20 PM
To: MyFaces Discussion
Subject: Re: contributing with components

For add/remove buttons you use javascript code, but how can i make a
click in an image call an method in backing bean? I need this to
create the Toolbar in the future.

--
Yours truly (Atenciosamente),

Rogério


RE: How to find out which implementation is running

2005-10-28 Thread Jesse Alexander \(KBSA 21\)
Well... 

I see two alternatives:

1) We add one/two method to javax.faces.application.Application 
eg. getImplName() and getSpecVersion()
   But that would require a spec change...

2) We ask that at startup one of the implementation classes adds
   the information as a managedBean or a external-context variable
   This could be added also without a spec change, just need to
   agree with the RI-people on an identifier to use...

regards
Alexander
  

-Original Message-
From: Martin Marinschek [mailto:[EMAIL PROTECTED] 
Sent: Friday, October 28, 2005 4:07 PM
To: MyFaces Discussion
Subject: Re: How to find out which implementation is running

Good question.

If you devise something like this, there should also be a way to check
for the spec version of the jsf implementation running.

regards,

Martin

On 10/28/05, Jesse Alexander (KBSA 21)
<[EMAIL PROTECTED]> wrote:
> Hi
>
> When I want to write a component that must run under more than
> JSF-implementation,
> I often should know (runtime not development time) which
implementation
> is running, in
> order to use the correct base-classes.
>
> Has somebody devised a clever method to find out which JSF-runtime is
> active?
> Or should we add something to enable this?
>
> regards
> Alexander
>


--

http://www.irian.at
Your JSF powerhouse -
JSF Trainings in English and German


How to find out which implementation is running

2005-10-28 Thread Jesse Alexander \(KBSA 21\)
Hi

When I want to write a component that must run under more than
JSF-implementation,
I often should know (runtime not development time) which implementation
is running, in
order to use the correct base-classes.

Has somebody devised a clever method to find out which JSF-runtime is
active?
Or should we add something to enable this?

regards
Alexander


RE: Wizard app

2005-10-26 Thread Jesse Alexander \(KBSA 21\)
We use 1 managedBean per Wizard (not per page).

This bean manages the flow-control and cross-attribute validation. It
then communicates with the DTO's provided by the service-layer. When
the final submit/validation is done, the service-layer is called to
persist.

All beans are session-context.

hth
Alexander


RE: [PROPOSAL] PRETTY_HTML, was [RE: JFS's html output]

2005-10-26 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
> OK
>
> I looked into what JTidy delivers. Unfortunately it is not what we
want
> :(
>
> The current jtidyServletFilter just VALIDATES the html and includes a
> validation-icon into the html-code delivered.The PrettyPrint feature
is
> only
> available in the full-featured jtidy.


I can't belive, and so i checked again. The filter can be configured to
do PrettyPrint. and it works!

just put
  jtidy-r8-SNAPSHOT.jar and jtidyservlet-r8-SNAPSHOT.jar
into WEB-INF/lib

and add

  
Filter for JSP
JTidyFilter
org.w3c.tidy.servlet.filter.JTidyFilter

  tee
  false

  
  
JTidyFilter
/faces/*
  

to your web.xml.

To enable PrettyPrint set init-param 'tree' to true, the default is
false!
-/Original Message-
Must have been blind when I looked through the doc ;-)

What worries me a bit is that they still have some issues with
stability,
buffering and multiple JTidy instances per JVM...


thanks
Alexander


RE: AW: FileDownload capability?

2005-10-26 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
The content-length is passed in the response header. Therefore it cannot
be
set once you have written data to the response body (after all, the
header
is written before the body, for details see http spec). 

If you know the length in advance you should set it (for example when
streaming data from a file or from a BLOB field in a database). If you
are
generating data on the fly and cannot predict the length, simply do not
call
setContentLength. Your browser will still receive the file, it just
won't
show a download percentage as it does not know how much it will receive.
Try
it out with a few MB of data, you'll see what I mean.
-/Original Message-
The problem with the missing content-length is that certain browsers are
tempted to redo the request, just because the length is missing...
At least some reports on problems with double-requests from IE to PDF-
producing servlets imply this...

regards
Alexander


-Original Message-
-Oorspronkelijk bericht-
Van: CONNER, BRENDAN (SBCSI) [mailto:[EMAIL PROTECTED] 
Verzonden: dinsdag 25 oktober 2005 21:46
Aan: MyFaces Discussion
Onderwerp: RE: AW: FileDownload capability?

I think I have most of the answers to my own questions, after consulting
the O'Reilly book "Java Servlet Programming":

1. The response, if set, has to be exact.  However, it does not have to
be set.  Using it allows Servlets to be able to take advantage of
persistent connections, if available.
2. It must be set before sending the response body.

So, given this, does (2) above imply that, if done, setting the length
has to precede the first write?  Or it just has to be done before
calling responseComplete()?

- Brendan

P.S. I realize this is more of a Servlet question than a MyFaces
question.  Sorry about that.

-Original Message-
From: CONNER, BRENDAN (SBCSI) 
Sent: Tuesday, October 25, 2005 2:38 PM
To: 'MyFaces Discussion'
Subject: RE: AW: FileDownload capability?


In earlier examples, one had to call response.setContentLength() with
the number of bytes being passed.  I have the following questions
regarding this:

1. What are the consequences if I get the length wrong?  Does it have to
be exact?
2. Can the setContentLength() be called after I have done all the
writes, or must it be done before the writes?  If I can call it
beforehand, then I can compute the length as I go.  Otherwise, it will
be more difficult.

Thanks,

- Brendan

-Original Message-
From: CONNER, BRENDAN (SBCSI) 
Sent: Tuesday, October 25, 2005 12:15 PM
To: 'MyFaces Discussion'
Subject: RE: AW: FileDownload capability?


And it's even easier if one is generating a text file (rather than a
binary file), for example, when writing out a comma-separated file for
use in a spreadsheet, since one can use
response.getWriter().print(String s) and
response.getWriter().println(String s).

- Brendan

-Original Message-
From: Nico Krijnen [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, October 25, 2005 3:00 AM
To: 'MyFaces Discussion'
Cc: [EMAIL PROTECTED]
Subject: RE: AW: FileDownload capability?


It is actualy much easier in JSF. You just need to have an action method
in
a (managed) bean, like this:


public String downloadFile() {
FacesContext facesContext = FacesContext.getCurrentInstance();
if (!facesContext.getResponseComplete()) {
String fileName = "myfile.pdf";

ServletContext servletContext = (ServletContext)
facesContext.getExternalContext().getContext();
String contentType =
servletContext.getMimeType(fileName);

HttpServletResponse response = (HttpServletResponse)
facesContext.getExternalContext().getResponse();
response.setContentType(contentType);
response.setHeader("Content-Disposition",
"attachment;filename=\"" + fileName + "\"");

try {
InputStream in = /* get your data */;
ServletOutputStream out =
response.getOutputStream();

byte[] buf = new byte[512];
int bytesRead;
while ((bytesRead = in.read(buf, 0, bufSize)) !=
-1)
{
out.write(buf, 0, bytesRead);
}

out.flush();
facesContext.responseComplete();
} catch (IOException e) {
throw new RuntimeException(e);
}
}
return null;
}


Then you can simply call the method from a commandLink or commandButton







Nico


-Oorspronkelijk bericht-
Van: news [mailto:[EMAIL PROTECTED] Namens Werner Punz
Verzonden: maandag 24 oktober 2005 23:34
Aan: users@myfaces.apache.org
Onderwerp: Re: AW: FileDownload capability?

It is rather easy, I usually have a download servlet for this
which generates the appropriate html code, I do not have the code handy
currently
but you basically set the

RE: [PROPOSAL] PRETTY_HTML, was [RE: JFS's html output]

2005-10-26 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
Hm, probably someone could extend Jtidy to support the Pretty HTML
feature also... 
-/Original Message-
We still can "give it back to them", if they want...

-Original Message-
Writing to log-files IMHO is a little bit difficult to work with. Often
you have some problems in the HTML (incorrect view in a special browser,
Jscript errors etc.) and then you have to check different files and
different lines of occurencies...
-/Original Message-
So far I was considering the problem of log-file-access. But I think
that
most developers should normally have access to log-files... 
On the plus-side for log-file-output: The are easier to post-process
(grepping, searching, archiving,...) than the browser's source-view

-Original Message-
I think, the Pretty-HTML is something for development and later you
disable it for live system to increase the performance.
-/Original Message-
Obvious. But it can make lots of sense to deploy it also to production
just in case you need a real html-copy in case of problems


-Original Message-
BTW: there is a issue on JIRA for this now:
http://issues.apache.org/jira/browse/MYFACES-744
-/Original Message-
I'v seen it (monitoring also the dev-list), but I think the 
discussion of the requirements for this "new" JTidyFilter should
be done here to reach more people. That should give us a good feeling
what we should implement...

regards
Alexander

PS: An alternative would be a chat-session in the #myfaces-channel...


RE: [PROPOSAL] PRETTY_HTML, was [RE: JFS's html output]

2005-10-26 Thread Jesse Alexander \(KBSA 21\)
OK

I looked into what JTidy delivers. Unfortunately it is not what we want
:(

The current jtidyServletFilter just VALIDATES the html and includes a 
validation-icon into the html-code delivered.The PrettyPrint feature is
only 
available in the full-featured jtidy.

What we could do is: Take the filter as a base and add the
pretty-print-feature 
to it.

What about writing the pretty-print-output not to the browser, but to a
log-file?
Would that be enough? Or must we include an option to send it to the
browser?

regards
Alexander

-Original Message-
I prefer to add a additional filter instead of doing this in the
ExtensionFilter.

jtidy has already a filter for this:

http://jtidy.sourceforge.net/multiproject/jtidyservlet/filter.html
That's what I had hopes for (just no time to check ;-)

thanks for checking it out
-/Original Message-


RE: Comparable validation design

2005-10-25 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
1) What should happen if the compared values do not implement
Comparable and no Comparable is provided?

Right now, it's passively passing validation.   I wonder if it should
throw a FacesException (not ValidationException) instead?
-Original Message-
FacesException.
We could try to catch it already in the tag, but for safety, throw
the exception during validation.

-Original Message-
2) If either the foreign component value or the parent component value
are null, perform no validation?  This is going to happen by default
if the parent component value is null since JSF won't execute
validators in that case.

We can't validate if:
a) value is null and foreign value is null
b) value is null and foreign value is not null.

We could try to validate if
c) value is not null and foreign value is null
d) value is not null and foreign value is not null

For consistency, I'd say we'd do the same thing for the foreign key,
and only try to validate for case d).
-Original Message-
+1: only d) should be validated

regards
Alexander


RE: [PROPOSAL] PRETTY_HTML, was [RE: JFS's html output]

2005-10-25 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
I prefer to add a additional filter instead of doing this in the
ExtensionFilter.

jtidy has already a filter for this:

http://jtidy.sourceforge.net/multiproject/jtidyservlet/filter.html
-/Original Message-
That's what I had hopes for (just no time to check ;-)

thanks for checking it out

regards
Alexander


RE: [PROPOSAL] PRETTY_HTML, was [RE: JFS's html output]

2005-10-25 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
Well, you might want to do it in IE?
-/Original Message-
EG. to check out the correct functioning of a renderer that has to 
render different html for differnet browsers...

-Original Message-
something like JTidy in our ExtensionFilter might be a good option.
-Original Message-
Filter: yes
But following the philosophy of unix-tools: a separate filter,
which (btw) can be of use also for non-jsf-applications...

regards,
Alexander


RE: [PROPOSAL] PRETTY_HTML, was [RE: JFS's html output]

2005-10-25 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
Just for discussion: 
Why implement the "pretty-html" option in every renderer?
I think, it would be easier to postprocess the content in the framework
before returning the complete html-content to the browser. What do you
think?
I found e.g. http://sourceforge.net/projects/jtidy which could do this
probably.
Does anybody know an other Java library which could do this job?

The big efford would be, that you could use the RI of SUN also and the
content would also be pretty formatted then.
-/Original Message-

Sort of writing a PrettyHtmlFilter? Might be the easiest way to go for
it.

regards
Alexander


RE: Comparable validation design

2005-10-25 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
@attribute name:

is there something like this in the RI 1.2? I think that yes, so maybe
we should go with their name for this.
-/Original Message-
+1

-Original Message-
@comparable: right, there is the interface name - I didn't think about that.

But then the "equalsValidator" is named by the method it calls - so
maybe we should take the method name here as well -
"compareToValidator" or more simple "compareValidator" ?

Forget about my suggestions if I start to enerve you - then just take
the interface name ;)
-/Original Message-
Consider the stage for this to be some sort of brain-storming...

-Original Message-
define an additional attribute (comparator) which allows the user to
specify a comparator instance which implements java.util.Comparator if
the objects don´t implement Comparable
-/Original Message-
Good idea

regards
Alexander


RE: The value of Google

2005-10-24 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
From: CONNER, BRENDAN (SBCSI) [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, October 25, 2005 1:03 AM
To: MyFaces Discussion
Subject: The value of Google

It's pretty ironic that, if I go to Sun's Web site and search on
"JavaBean specification", I get lots of stuff but can't find a link to
the actual specification, at least in the first 20 or so results.

However, if I do the same search using Google, the specification itself
pops up as the first result.

Google's great!
-/Original Message-

well that's why the youngsters nowadays are not "surfing" anymore, they
are "googling"

;-)
alexander


RE: Adding a Component to a custom component

2005-10-22 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
What I need is to render a CommandButton which is part of the above 
component (a child of the component I suppose) without having to specify

its HtmlCommandButton tag in the JSP.

I guess i'd use app.createComponent() method somehow...
-/Original Message-

myComponent.getChildren().add(mySubComponent); to add to the children
list
myComponent.getRendersChildren()
mySubComponent.encodeBegin(), encodeChildren() and encodeEnd() are other
methods to look at. Read them up in Javadoc (get Sun-RI for Javadoc).

That should give you some ideas to continue.
Alexander


RE: Comparable validation design

2005-10-22 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
Just a naming thing - shouldn't it be  or
 instead of ?
-/Original Message-
I guess the name is just a first throw... maybe comparable
because it accepts any Comparable object... But part of bringing
it up here is get some more opinions.


-Original Message-
By the way, are you guys going to move the optional validator
framework over as well?
-/Original Message-
Well, I opened the jsf-comp project as a means to try out stuff
in a shared way. the rules for getting access are more loose.
And when the community thinks our stuff is good enough, I would
really enjoy seeing it moved to the myfaces project. Consider
our project as a playground for shareable components, a testbed
before moving them to MyFaces.

the comparable/comparing validator most likely will depend on the 
optional validator stuff.

Does that sound good?

regards,
Alexander


RE: Comparable validation design

2005-10-21 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
> 

Ha ha!  You're the expert on designing validators that wrap other
validators.   I'll let you write that one!  :-)
-/Original Message-
Remember how I first objected to have OVW defined also as Validator...
Just a few seconds later a first flash of cascaded validators 
floated before my eyes... and while eating ... this idea solidified...

Should be possible ;-)

regards
Alexander



RE: Comparable validation design

2005-10-21 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
1)  is what I'm currently
doing.
2) 

a) Operator values being "eq", "ne", "lt", "gt", "ge", and "le" in
addition to (or maybe instead of)  
b) "==", "!=", ">", "<", "=>'", and "=<".
-/Original Message-
I'd prefer
  from 1 and 2: proposal 2
  from a and b: proposal a 

-Original Message-

-/Original Message-
How about specifying the identifier of the message as it is the 
message-files?

-Original Message-
I'm also planning on having the comparisons done using the Comparable
interface, so the validator would work only on objects implementing
Comparable (but that seems like it'd probably cover anything worth
comparing).
-/Original Message-
good idea


Additional idea:
How about cascading boolean validators added in? 
Something like this:


  


  


regards
Alexander


RE: Action Simulation

2005-10-20 Thread Jesse Alexander \(KBSA 21\)
Hi Patrick 

-Original Message-
How can I simulate an event (a click in a button or link) from java
code?
-/Original Message-

What do you want it for?
Maybe then it is easier to answer...

regards
Alexander


RE: User Management - advice needed.

2005-10-20 Thread Jesse Alexander \(KBSA 21\)
Add a user-info-bean when
a) the session is created (Session-listener)
b) the user-credentials are created (by JAAS?)
and just display them from within the JSF-page...

hth
Alexander 



From: Jeffrey Porter [mailto:[EMAIL PROTECTED] 
Sent: Thursday, October 20, 2005 2:39 PM
To: MyFaces Discussion
Subject: User Management - advice needed.



 

Hello again.

 

My question is this.

 

I want when a JSF page is displayed, to look up the current user and
display some information on them.

For example...

 

<%

Principal principal = request.getUserPrincipal();

  String userName = principal.getName();

  User user = SomeUserManagementServerThing.loadUser(userName);

%>

 

<%=userName%>

<%=user.isAdmin()%>

 

The above code is fine for the old JSP/Struts way of doing thing. But
what is the approach I should take in MyFaces?

 

If the action method that makes the call to display the page knew about
the Principle I could pass the User object in and all would be great.

But I don't see a way for an action method to find out the currently
logged in user.

 

What do you guys think? Is a there a paper / tutorial already on this
that I've missed?

 

Thanks

Jeff

 

Using: JBoss 4.02, JAAS, DatabaseAuthentication



RE: Re: survey: what tool are you using for JSF ?

2005-10-20 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
Just to get experience, what size was it?
-/Original Message-
effective project:
*.jsp : 194
*.java: 742
Number of jsp's s including includes...
faces-config:
files: 9
lines: 1480
managed-beans: 93
navigation-cases: 117
converter: 37

projects it depends on (custom components...):
*.jsp :  18
*.java: 117

workspace:
*.jar:  590 (some duplicates, because used in more than one project)


I think these numbers could give an idea...

regards

Jesse Alexander (KBSA 21) wrote:


RE: Re: survey: what tool are you using for JSF ?

2005-10-19 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
I only can say if speed is an issue, either move away from WTP based
plugins or wait for better times. To split the project into several
smaller subprojects and have ant doing the merge probably is the way to
go currently.

I cannot say how Nitrox behaves speedwise.
-/Original Message-
NitroX is no racecar. And I often have to use a "-clean" startup to
reset its internals...

But, to do justice to all tools, so far I have done no project
of a similar size with Exadel or any of the other competitors.



-Original Message-
As for Eclipse itself, Eclipse unless you run it on a Mac is fast,
memory is the keypoint, you should give Eclipse more ram that its
standard settings would give it (which are around 64MB)

I usually start my Eclipses with following settings:
 -vmargs -Xmx512m -Xms200m -XX:MaxPermSize=200m
-/Original Message-
Generally Java loves and eats memory. I have no Eclipse-setup with less
than
768MB (both -Xmx and -Xms, I do not like the JVM to size up and shrink
its
memory footprint).

regards
Alexander


RE: SelectItems generation using Providers

2005-10-18 Thread Jesse Alexander \(KBSA 21\)
don't sound bad.

But you would use it in the SelectItems-tag.

If you want you can provide a first shot using the jsf-comp project (on
sourceforge).
CVS access is easier than sandbox-committer rights. But for easy
transfer to the 
sandbox/extensions everything must be apache-compatible (licenses...).
If you want
we can discuss it late night (mid european late night) on the myfaces
irc-channel.

regards
Alexander



From: Guillermo Meyer [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, October 18, 2005 4:12 PM
To: 'MyFaces Discussion'
Subject: SelectItems generation using Providers



Hi all:

I'm planning to adapt Providers framework
(http://providers.sourceforge.net/) to JSF.

Mainly, Providers could be used to generate SelectItems inside UISelect*
components.

 

For example, you could declare a hypothetical Providers bean in the
faces-config.xml like this:

 



  providers

 
ar.com.koalas.providers.jsf.ProviderFacade

  request



 

Use it from a JSP like this:

 


 

And let Providers generate a list of SelectItems to populate the combo
(or whatever other component could be) using a fixed value, JDBC, Spring
or POJO approach, or your custom one
(http://providers.sourceforge.net/examples.html)

 

Using Providers you can eliminate your backing beans getters to retrieve
SelectItems, and even reuse it from other beans/applications. 

A further step could be to standardize Providers by implementing JSR 227
(http://www.jcp.org/en/jsr/detail?id=227) for DataBinding.

 

What do you think about this? Would it be valuable or useful in JSF
world?

 

Thanks for your time.

 

Guillermo.

 


NOTA DE CONFIDENCIALIDAD
Este mensaje (y sus anexos) es confidencial, esta dirigido
exclusivamente a las personas direccionadas en el mail y puede contener
informacion (i)de propiedad exclusiva de Interbanking S.A. o (ii)
amparada por el secreto profesional. Cualquier opinion en el contenido,
es exclusiva de su autor y no representa necesariamente la opinion de
Interbanking S.A. El acceso no autorizado, uso, reproduccion, o
divulgacion esta prohibido. Interbanking S.A no asumira responsabilidad
ni obligacion legal alguna por cualquier informacion incorrecta o
alterada contenida en este mensaje. Si usted ha recibido este mensaje
por error, le rogamos tenga la amabilidad de destruirlo inmediatamente
junto con todas las copias del mismo, notificando al remitente. No
debera utilizar, revelar, distribuir, imprimir o copiar este mensaje ni
ninguna de sus partes si usted no es el destinatario. Muchas gracias. 


RE: Re: survey: what tool are you using for JSF ?

2005-10-18 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
> trying: Exadel v3 pro:
> - good JSF-editor
> - good JSP-editor (Macromedia-style)
> 
Btw. Jesse Exadel now has the 3.0.5 released
Features: MyFaces 1.1.0

and some bugfixes to the biggest showstoppers I
have encountered, basically according to the Exadel guys
the forced upfront WebContent dir lockin is gone
the hibernate mapping now works on more complicated m:n binding tables.
Have not tried the fixes out yet but it is worth a shot.
I will add a more extensive wiki entry soon, if the WebContent
lockin problem really is gone.
-/Original Message-
Cool... Hope I find the time to do it allover...

-Original Message-
m7 always has been way out of my league pricewise, although their
hibernate
stuff looks interesting.
-/Original Message-
I had the oppurtinity to work with it for 6 months... (not the hibernate
stuff)
and I like it... but as you said: too costly for hobby...

regards
Alexander


RE: commandButton - how to set to ignore required Validation?

2005-10-18 Thread Jesse Alexander \(KBSA 21\)



If that does not completely solve your problem: Welcome to 
the club of the (potential)
users of OptionalValidator ;-)
 
Or in another mode: I needed that "soft" validation on 
something other than the 
cancel button...
 
regards
Alexander


From: Jeffrey Porter 
[mailto:[EMAIL PROTECTED] Sent: Tuesday, October 
18, 2005 11:45 AMTo: MyFaces DiscussionSubject: RE: 
commandButton - how to set to ignore required Validation?


 
immediate="true"
 
Add the 
immediate="true" value to the 
commandButton tag.
 
 
 
 
-Original 
Message-From: Jeffrey 
Porter [mailto:[EMAIL PROTECTED] Sent: 18 October 
2005 10:33To: MyFaces DiscussionSubject: commandButton - how to set to 
ignore required Validation?
 
 
 
Is there a way I can set a command 
button to ignore the validation required on the page?
 
I.e. To create a “cancel” button on 
a page
 
Thanks
Jeff
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
    



RE: survey: what tool are you using for JSF ?

2005-10-17 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
I'm asking what kind of IDE/Tool are you using for developing your JSF 
Web apps.
-/Original Message-

mostly: NitroX from M7:
- good JSF-editor
- good JSP-editor (Macromedia-style)
- good recognization for distributed applications (apps relying on other
apps...)

tried: MyEclipse v4:
- a bit disappointing support for JSF-components

trying: Exadel v3 pro:
- good JSF-editor
- good JSP-editor (Macromedia-style)

tried: Rational Developer:
- disappointing price to feature ratio

tried: Sun's IDE:
- I am not the NB-type...


RE: [MyFaces] Custom Validator???

2005-10-17 Thread Jesse Alexander \(KBSA 21\)
Mike and I have experimented for quite some time before diving into the 
rather complicated world of the optional validator... Guess why we
finally 
dived into that? Because there is no way around it.

As I see for the quick-solution your way might be a
Javascript-controlled
pop-up! (And I HATE JS...)

reagrds
Alexander


From: Rafael Nami [mailto:[EMAIL PROTECTED] 
Sent: Monday, October 17, 2005 1:30 PM
To: MyFaces Discussion
Subject: Re: [MyFaces] Custom Validator???


PS - The main problem that persists is that - if the user fills the
form1, and I use immediate="true" in "Add Details" button, the form1
values will be empty when the user navigate from detail page to form1
again (don't know FOR SURE, but I think immediate="true" skips the
validation, conversion and update values phases). 
What can I do just to mantain the POJO values between the pages, and
just validate the form1 values with a "Complete Process" click?
 
Thanks and Best All
 
Rafael Mauricio Nami
 
2005/10/17, Rafael Nami <[EMAIL PROTECTED]>: 

Thank you both for your support.
The point Jesse raised is cool, having a "optional validator"
component, and we ***WILL*** need something like it for our other
requirements, but in this one, I think we'll go for something like
Volker said, because in the "details" page, our team saw that we don't
need any information from "form1" to add the details to validate. We
simply can add as much details as we need, go back to the form1, and
then use the "Complete Process" button to validate all form1 fields. 
 
Thanks again
 
Rafael Mauricio Nami
 
2005/10/16, Volker Weber <[EMAIL PROTECTED]>: 

Hello,

if i understand you correct, you need to execute
updateModelPhase, but
skip validationPhase. 

Have you tryed immediate="true", to skip both, in your
"Go to Detail"
button and invoke viewRoot.processUpdates() in your "Go
to Detail" action?

Regards

  Volker


Rafael Nami wrote:
> Good morning everyone.
> Thank you guys for pointing me out a good solution for
the popup thing.
> The current problem is something like this:
>
> We developed a Wizard-Style to avoid the use of
Popups. The flow consists 
> in something like this:
> form1->details->back to form1 to confirm the flow.
> The main problem is that we need to go to the details
WITHOUT validation
> when the user clicks the "Go to Detail" button, but if
the details are 
> complete
> and the user clicks the "Complete Process" button, the
form1 HAVE to be
> validated.
>
> Did I have to use/write a custom Validator component
to addthis kind of
> behavior? 
>
> Thanks in advance, and Best All
>
> Rafael Mauricio Nami

--
Don't answer to From: address!
Mail to this account are droped if not recieved via
mailinglist.
To contact me direct create the mail address by 
concatenating my forename to my senders domain.






RE: [MyFaces] Custom Validator???

2005-10-15 Thread Jesse Alexander \(KBSA 21\)
Hi,

we have the same problem. Mike and I are trying to do something in that
direction. For validators that do not take parameters, we have a 
solution. Currently we are trying to create a wrapper for validators
that allows to switch the validation mode from "hard" (Complete Process)
to "soft" (all errors are converted to warnings, processing continues)
or "none" (validation is ignored)

Search for "Optional Validator" in the mailing list archives...
or visit the jsf-comp project at sourceforge. Mike and hopefully me
(after
my return from Italy) are also often on the MyFaces IRC-channel (20:00
GMT
till 24:00 GMT) (search the archives for IRC)

hth
Alexander 



From: Rafael Nami [mailto:[EMAIL PROTECTED] 
Sent: Friday, October 14, 2005 3:58 PM
To: MyFaces Discussion
Subject: [MyFaces] Custom Validator???


Good morning everyone.
Thank you guys for pointing me out a good solution for the popup thing.
The current problem is something like this:

We developed a Wizard-Style to avoid the use of Popups. The flow
consists
in something like this:
form1->details->back to form1 to confirm the flow.
The main problem is that we need to go to the details WITHOUT validation
when the user clicks the "Go to Detail" button, but if the details are
complete
and the user clicks the "Complete Process" button, the form1 HAVE to be
validated.
 
Did I have to use/write a custom Validator component to addthis kind of
behavior?
 
Thanks in advance, and Best All
 
Rafael Mauricio Nami


RE: Is JSF the right technology to adopt?

2005-09-30 Thread Jesse Alexander \(KBSA 21\)



The same question was heard when Struts delivered the 0.5 
version...
Guess what: Struts in that moment was used in 
productive
web apps...
 
regards
Alexander


From: Dave [mailto:[EMAIL PROTECTED] 
Sent: Saturday, October 01, 2005 1:05 AMTo: 
users@myfaces.apache.orgSubject: Is JSF the right technology to 
adopt?

Some people say: JSF technology has been available for several years, but 
has not been adopted by industry. That means JSF may not be the right 
technology. What technology is widely adopted by industry for web application 
today? Do you think JSF is the right technology to go?  Thanks. Dave


Yahoo! for GoodClick here 
to donate to the Hurricane Katrina relief effort. 


RE: Fwd: multiple component jars

2005-09-28 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
In any case - Ed's solution is very simple, might find its way even in
1.2, and is a whole lot better than having no possibility at all to
get this problem fixed in your webapp!
-/Original Message-
a) great to see it already in 1.2
b) easy enough to backport it to 1.1.modified ;-)
c) working
d) sort of transparent. For a big company which will fix the version
   of such libraries (as JSF...) for wuite some time, this solution
   will work quite well.

The only thing to keep in mind is the sorting sequence used by the 
OS hosting the JVM... (I remember some nightmares in that direction...)

regards
Alexander


RE: multiple component jars

2005-09-28 Thread Jesse Alexander \(KBSA 21\)
  -Original Message-
  too late for 1.2, I suppose!

  exactly the right time for 2.0...

  I think there is something like an issue tracker on dev.java.net.
  -/Original Message-

Not really. Ed Burns has answered this:

-Original Message-
Yes, this problem is real, but we may be able to solve it in 1.2.  As
you may know, the webtier specs tend to ignore the config file ordering
problem.  In this case, we don't know the order in which the jar files
containing the faces-config files will be encountered.  

I think I have a simple solution.  

I've filed it as

and will bring it to the EG.
-/Original Message-

I'd say: lightning fast response and in the best possible direction.

kudos to the EG!!!

regards
Alexander


RE: multiple component jars

2005-09-28 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
No way around this.
-/Original Message-
Feared so :(

-Original Message-
Same problem with PhaseListeners.
-/Original Message-
and any other configurable item...

-Original Message-
Maybe the spec should introduce something like a "priority" (like the
z-index in CSS) to get round such problems.
-/Original Message-
How are we supposed to contact the JSF 1.2 EG to include something this?
Do they have a "bug-tracker"?

Or are we already too late for such a request?

regards
Alexander


multiple component jars

2005-09-28 Thread Jesse Alexander \(KBSA 21\)
Hi

I use some components from the tomahawk collection and have 
written my own components as well. 

Now I am in the process of packaging my own components into 
jar-files and have run into a nasty feature of the JSF
configuration. 
It is nice that each component-jar-file can have its own 
faces-config.xml and in that way add its components to 
the overall JSF runtime configuration. It is also easy
to replace a single renderer for a componen, just add
the renderer to the jar-file and "overwrite" the 
renderer-configuration in your own jar-faces-config. This
works great for renderers delivered by JSF itself. BUT as 
soon as I want to override a renderer from the tomahawk
components I run into troubles.

The config mechanism first inserts the standard config,
then adds the jar-faces-config and at the end adds the
configured (in web.xml) config-files. Unfortunately
there seems no way to specify the order in which the 
jar-faces-configs are added. Therefor its getting 
difficult to override single definitions (as described 
above) when having more than one jar with custom components.

How do you deal with that problem?
Alexander


RE: [ANNOUNCE] MyFaces passed the JSF TCK 1.1

2005-09-12 Thread Jesse Alexander \(KBSA 21\)
YIPPIIEH


G R E A T

congrats to the team
Alexander 

-Original Message-
From: Manfred Geiler [mailto:[EMAIL PROTECTED] 
Sent: Monday, September 12, 2005 3:12 PM
To: MyFaces Development; MyFaces Discussion
Subject: [ANNOUNCE] MyFaces passed the JSF TCK 1.1

The MyFaces team is very proud to announce the fact, that the current
codebase has just passed *all* JSF TCK 1.1 tests!

This is a great milestone (actually the greatest since MyFaces has
started in 2003) and we are all looking forward to releasing the first
official certified free open source JSF implementation "Apache MyFaces
1.1.0" soon (after clarifying some legal and technical stuff).

Thanks to every single contributor, who helped making MyFaces another
open source success story.


...
...
...
 Thank you very much!


Let's head for the next challenges: beat ALL bugs :), JSF 1.2, JSF 2.0,
...

Manfred Geiler


RE: extentions vs. tomahawk

2005-09-10 Thread Jesse Alexander \(KBSA 21\)


Quick simple question.  Is there really a difference between

<%@ taglib uri="http://myfaces.apache.org/extensions"; prefix="x" %>

and

<%@ taglib uri="http://myfaces.apache.org/tomahawk"; prefix="t" %>


tomahawk is the new name of the former extensions.
Therefor the probable difference is the version...

hth
Alexander


RE: Optional Validation Framework

2005-09-09 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
Yes, we'll see...

it sure looks interesting!
-/Original Message-

It works and really solved our problem for our application. I just added
simpler version of the RequiredValidator(2).

I now will try to implement something for the other validators as well.
Our boss has licked some blood, now he wants more.

In the mean time I have made the jar-files (one for the runtime, one for
the sources) plus a small web-application (two war-files, one using
MyFaces
the other one using Sun RI) online at our sourceforge-site under the url
.

At our meeting we asked ourselves whether we are the only ones with this

problem:
On one form we have links that divert the usecase to some lookup-pages.
Upon return from there our users ask to see all data they have entered
before.
But the validation must not hinder them to jump to the lookup pages...
And for that problem we needed the optional validator...

Implementing the optionalValdiator I was a bit astonished to see that
the
MessageFactories for the validators are contained within
javax.faces.validator
but are incompatible (class-name and API) between the RI and MyFaces. I
sort of
had hoped that javax.faces... means compatibility...

Next steps will be
- trying to wrap the original validators within a
optionalValidatorWrapper
  -> in order not to have to reimplement all validators ourselves
- trying to add the possibility to specify custom error-messages per
  validator definition in the jsp-files

regards
Alexander


On 8/16/05, Mike Kienenberger <[EMAIL PROTECTED]> wrote:
> Hey Martin,
> 
> So far, none for the optional framework itself, other than Jesse and
> I.  And I think Jesse is still on vacation :)  One or two people have
> expressed interest in the RequiredValidator, but that appears to be
> mostly due to the inability to customize the required attribute error
> messages.
> 
> I'm finding it immensely useful, though.
> 
> The downside is that I now have the source code memorized for MyFace's
> implementation of  UIInput due to the amount of time I've spent there
> :)
> 
> Jesse predicted mass adoption, but that has yet to materialize :)
> 
> 
> On 8/16/05, Martin Marinschek <[EMAIL PROTECTED]> wrote:
> > Now I am curious about the feedback to this ;)
> >
> > regards,
> >
> > Martin
> >
> > On 8/16/05, Mike Kienenberger <[EMAIL PROTECTED]> wrote:
> > > I've just checked in and tagged the optional validation framework
as
> > > optional-validator-1-0 (version 1.0)
> > >
> > > This version is fully functional and seems to be bug free.   :)
> > >
> > > New features include optional conversion and UIInputs marked as
> > > invalid before the update-model phase if validation or conversion
> > > failed or was skipped.
> > >
> > > The only addition I might make in the future is the ability to
group
> > > and mark sets of controls for none, soft, or hard validation per
> > > action.
> > >
> > > I've also separated the RequiredValidation and
> > > RequiredValidationChecker code out into separate classes so it can
be
> > > used independently from the optional validation framework since
there
> > > was some interest in this.
> > >
> > > -Mike
> > >
> > > On 8/12/05, Mike Kienenberger <[EMAIL PROTECTED]> wrote:
> > > > The first #myfaces irc.freenode.net collaboration is now
available.  :)
> > > >
> > > > Alexander Jesse and I have come up with an optional validation
> > > > framework to use when the "immediate" attribute doesn't provide
enough
> > > > power.
> > > >
> > > > http://wiki.apache.org/myfaces/OptionalValidationFramework
> > > >
> > > > I'm not sure how long it'll take for the sourceforge cvs to
propage
> > > > out to anonymous cvs, but hopefully it'll be available soon.
> > > >
> > >
> >
> >
> > --
> >
> > http://www.irian.at
> > Your JSF powerhouse -
> > JSF Trainings in English and German
> >
> 


-- 

http://www.irian.at
Your JSF powerhouse - 
JSF Trainings in English and German


RE: RE : export dataTable in excel

2005-09-02 Thread Jesse Alexander \(KBSA 21\)
maybe to the project EPOI (Even Poorer ...)? 
Alexander

-Original Message-
From: Martin Marinschek [mailto:[EMAIL PROTECTED] 
Sent: Friday, September 02, 2005 11:23 PM
To: MyFaces Discussion
Subject: Re: RE : export dataTable in excel

And now they are trying to obfuscate with XML!

I'm curious as to what this will lead...

regards,

Martin

On 9/2/05, Jesse Alexander (KBSA 21) <[EMAIL PROTECTED]>
wrote:
> -Original Message-
> POI is an Apache open-source project to manipulate Excel sheets from
> Microsoft ;-)
> -/Original Message-
> 
> not exactly...
> 
> POI stands for Poor Obfuscation Implementation and is what the
> developers think of MShits attempt to hide the content of their office
> programs in a one-file FAT-filesystem like structure.
> 
> The POI projects wants to deliver api's for all office-formats.
> 
> The actual Excel-api is called: HSSF (Horrible SpreadSheet Format)
> 
> names tell a story every now and then ;-)
> Alexander
> 


-- 

http://www.irian.at
Your JSF powerhouse - 
JSF Trainings in English and German


RE: RE : export dataTable in excel

2005-09-02 Thread Jesse Alexander \(KBSA 21\)
-Original Message- 
POI is an Apache open-source project to manipulate Excel sheets from
Microsoft ;-)
-/Original Message- 

not exactly...

POI stands for Poor Obfuscation Implementation and is what the
developers think of MShits attempt to hide the content of their office
programs in a one-file FAT-filesystem like structure.

The POI projects wants to deliver api's for all office-formats.

The actual Excel-api is called: HSSF (Horrible SpreadSheet Format)

names tell a story every now and then ;-)
Alexander


RE: export dataTable in excel

2005-09-02 Thread Jesse Alexander \(KBSA 21\)
-Original Message-
hi I read a old post about how export dataTable data in excel format

http://www.mail-archive.com/users@myfaces.apache.org/msg03873.html

It seems there is no solution except building a custom POI servlet
with sepcific code (read duplicated code! ) for each datatable(my
actual solution).

Isn0t any convinient method to pass a full dataTable Object to an
actionMethod...

I have some code thath would be useful

http://sourceforge.net/projects/spreadobjects

see ya
-Original Message-

Depends on what you need...

As long as you do not need calculations and lots of formatting 
(sort of exporting the "raw" data) you could construct a comma-separated
file and send that to the client. (if you specify the correct mime-types
excel will open automagically...) AND if the client uses ne of the 
real operating system (then ones without excel) he can open it with just
about every spreadsheet-application because CSV is THE universal 
format...

hth
Alexander


  1   2   >