myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mike Kienenberger" <mkien...@gmail.com>
Subject Re: Possible bug in the columns tag with the convertDateTime tag
Date Mon, 04 Jun 2007 20:16:09 GMT
In Eclipse, if you're stopped at a breakpoint, you can then copy the
stack trace from the debug view.   I'm not sure how it works in other
IDEs, but that's probably your best bet.

I suppose the other quick-fix would be to change the EL expression to
"#{someBean.property}" and simply have that bean property getter throw
the stack trace.

On 6/4/07, Daniel Herb <physhh@gmail.com> wrote:
>
> Thank you for your fast replying.
>
> Maybe a dumb question but how can I make a stacktrace without the
> write-privilege in the tomahawk? I thought can copy the source-code directly
> in my project but something seems to be wrong.
>
> Is there an easy way to do a stacktrace within tomahawk?
>
>
> Mike Kienenberger wrote:
> >
> > I wasn't clear (or wasn't reading your post closely enough).
> >
> > Post the stack track for the execution of the following call:
> >
> > ============================
> > Further you can set a breakpoint to the line 197 in the file
> > "org.apache.myfaces.shared_impl.taglib.core.ConvertDateTimeTagBase.class".
> > - This method is called correctly (value is the EL-Expression
> > "#{columnData.dateString}").
> > - The method detects correctly that the value is an EL-Expression
> > - The correct value for the EL-Expression can't be found so the vale for
> > the
> > attribute is set to null.
> > ============================
> >
> >
> > On 6/4/07, Daniel Herb <physhh@gmail.com> wrote:
> >>
> >> Hi ,
> >> thank you for answering.
> >>
> >>
> >> Mike Kienenberger wrote:
> >> >
> >> > Can you post a stack trace from when getDateString() is called?
> >> >
> >> But the problem is that getDateString() is not called, so I can't make a
> >> stacktrace.
> >> As written in my last post the getDateString method can't be resolved by
> >> the
> >> "ELVariableResolver".
> >> Maybe I misunderstood you.
> >>
> >>
> >> Mike Kienenberger wrote:
> >> >
> >> > Can you post a stack trace from when getDateString() is called?
> >> >
> >> > Perhaps the converter is caching the value during component tree build
> >> > time or being called when the table row index is not set.
> >> >
> >> >
> >> > On 6/2/07, Daniel Herb <physhh@gmail.com> wrote:
> >> >>
> >> >> After some further testing I am relative sure that is it a bug from
> >> >> myfaces.
> >> >> I hope with this post I can clearly descibe the problem.
> >> >>
> >> >> I have set up a complete fresh
> >> >> System:
> >> >> - Tomcat 5.0.28
> >> >> - MyFaces/Tomahawk 1.1.5
> >> >>
> >> >> Bugdescription:
> >> >> The getter of the Attribute "date" is not called by the
> >> convertDateTime
> >> >> when
> >> >> you are using the var-variable which was set by the columns-tag.
> >> >> (Test that by setting a breakpoint in the getter-Method of the
> >> >> "date"-attribute)
> >> >> Also try to add the following line after the inputText-tag to confirm
> >> >> that
> >> >> the var-variable works correctly for other tags:
> >> >> <h:outputText value="#{columnData.dateString}"></h:outputText>
> >> >>
> >> >> It seems that all tags within "http://java.sun.com/jsf/core" can't
> >> access
> >> >> the var-variable which was set by the colums-tag. (That was not
> >> >> completely
> >> >> tested but it seems so)
> >> >>
> >> >> Further you can set a breakpoint to the line 197 in the file
> >> >>
> >> "org.apache.myfaces.shared_impl.taglib.core.ConvertDateTimeTagBase.class".
> >> >> - This method is called correctly (value is the EL-Expression
> >> >> "#{columnData.dateString}").
> >> >> - The method detects correctly that the value is an EL-Expression
> >> >> - The correct value for the EL-Expression can't be found so the vale
> >> for
> >> >> the
> >> >> attribute is set to null.
> >> >>
> >> >> Here are my testfiles:
> >> >> -ListItem.java-
> >> >> public class ListItem {
> >> >>         private String dateString;
> >> >>         public ListItem()
> >> >>         {
> >> >>                 dateString = "date";
> >> >>         }
> >> >>         public String getDateString() {
> >> >>                 return dateString;
> >> >>         }
> >> >>
> >> >>         public void setDateString(String tollerString) {
> >> >>                 this.dateString = tollerString;
> >> >>         }
> >> >> }
> >> >>
> >> >> -MyBean.java-
> >> >> import java.util.ArrayList;
> >> >> import java.util.List;
> >> >> public class MyBean {
> >> >>         private List justAList;
> >> >>         public MyBean()
> >> >>         {
> >> >>                 justAList = new ArrayList<ListItem>();
> >> >>                 justAList.add(new ListItem());
> >> >>         }
> >> >>         public List getJustAList() {
> >> >>                 return justAList;
> >> >>         }
> >> >>         public void setJustAList(List justAList) {
> >> >>                 this.justAList = justAList;
> >> >>         }
> >> >> }
> >> >>
> >> >> -columnsTest.jsp-
> >> >> <%@ page language="java" pageEncoding="ISO-8859-1"%>
> >> >> <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
> >> >> <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
> >> >> <%@ taglib uri="http://myfaces.apache.org/tomahawk" prefix="t"%>
> >> >> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
> >> >> <html>
> >> >> <body>
> >> >>         <f:view>
> >> >>                 <t:dataTable value="#{myBean.justAList}"
> >> var="rowData">
> >> >>                         <t:columns value="#{myBean.justAList}"
> >> >> var="columnData" >
> >> >>                                 <h:inputText>
> >> >>                                         <f:convertDateTime
> >> >> type="#{columnData.dateString}" />
> >> >>                                 </h:inputText>
> >> >>                         </t:columns>
> >> >>                 </t:dataTable>
> >> >>         </f:view>
> >> >> </body>
> >> >> </html>
> >> >> --
> >> >> View this message in context:
> >> >>
> >> http://www.nabble.com/Possible-bug-in-the-columns-tag-with-the-convertDateTime-tag-tf3845423.html#a10933120
> >> >> Sent from the My Faces - Dev mailing list archive at Nabble.com.
> >> >>
> >> >>
> >> >
> >> >
> >>
> >> --
> >> View this message in context:
> >> http://www.nabble.com/Possible-bug-in-the-columns-tag-with-the-convertDateTime-tag-tf3845423.html#a10955982
> >> Sent from the My Faces - Dev mailing list archive at Nabble.com.
> >>
> >>
> >
> >
>
> --
> View this message in context: http://www.nabble.com/Possible-bug-in-the-columns-tag-with-the-convertDateTime-tag-tf3845423.html#a10957369
> Sent from the My Faces - Dev mailing list archive at Nabble.com.
>
>

Mime
View raw message