You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by "F. Da Costa" <da...@xs4all.nl> on 2004/02/14 15:56:55 UTC
Instantiation error
Just switched b4 and got this error.
Have been running the (cvs'ed) version a while now and i thought the border
was definitely ok by now.
org.apache.tapestry.ApplicationRuntimeException
Unable to instantiate an instance of class org.dcg.platform.ui.Border.
component: org.dcg.platform.HomeContent@1b158db[HomeContent]
location: classpath:/org/dcg/platform/ui/Border.jwc, line 6
java.lang.InstantiationException
Stack Trace:
*
sun.reflect.InstantiationExceptionConstructorAccessorImpl.newInstance(InstantiationExceptionConstructorAccessorImpl.java:30)
* java.lang.reflect.Constructor.newInstance(Constructor.java:274)
* java.lang.Class.newInstance0(Class.java:308)
* java.lang.Class.newInstance(Class.java:261)
*
org.apache.tapestry.pageload.PageLoader.instantiateComponent(PageLoader.java:650)
...
I can find the class in the dir so it does exist.
What else would be a good place to look?
TIA
Fermin DCG
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
Re: Instantiation error
Posted by Mirko Viviani <mi...@objectlab.org>.
F. Da Costa wrote:
> Just switched b4 and got this error.
> Have been running the (cvs'ed) version a while now and i thought the
> border was definitely ok by now.
>
> org.apache.tapestry.ApplicationRuntimeException
> Unable to instantiate an instance of class org.dcg.platform.ui.Border.
[...]
> I can find the class in the dir so it does exist.
> What else would be a good place to look?
The class is declared abstract without abstract properties?
I've had the same problem switching to b4...
Ciao
Mirko
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
RE: Instantiation error
Posted by "Howard M. Lewis Ship" <hl...@comcast.net>.
Right on the money. Because you provided concrete properties for your connected parameters,
Tapestry did not create a subclass.
I think the difference is that between beta-3 and beta-4, Richard Lewis-Shell made some changes to
how the IBinding object for each parameter is stored. The older code is beta-3 would create a new
property for the binding, the new code stores it in a HashMap.
--
Howard M. Lewis Ship
Independent J2EE / Open-Source Java Consultant
Creator, Tapestry: Java Web Components
http://howardlewisship.com
> -----Original Message-----
> From: Petter Måhlén [mailto:petter.mahlen@chello.se]
> Sent: Saturday, February 14, 2004 11:23 AM
> To: 'Tapestry users'
> Subject: RE: Instantiation error
>
>
> InstantiationException means that the target class is abstract or an
> interface. Have you tried dropping the 'abstract' from the
> class definition?
>
> / Petter
>
> > -----Original Message-----
> > From: news [mailto:news@sea.gmane.org] On Behalf Of F. Da Costa
> > Sent: den 14 februari 2004 17:19
> > To: tapestry-user@jakarta.apache.org
> > Subject: Re: Instantiation error
> >
> >
> > Howard M. Lewis Ship wrote:
> > > Do you have a public constructor? Looks like the error is
> > occuring when the constructor is invoked.
> > >
> > Noop, never had one actually. As it has been working for
> > months now i never
> > bothered with it anymore either. Am i misusing the abstract &
> > parameter
> > thing perhaps?
> >
> >
> > Border.java:
> > public abstract class Border extends BaseComponent {
> > private String _title;
> >
> > public String getResult() {
> > return _result;
> > }
> >
> > public void setTitle(String subtitle) {
> > _title = subtitle;
> > }
> >
> > public String getTitle() {
> > return _title;
> > }
> >
> > protected int getPageType() {
> > ...
> > return _pageType;
> > }
> > }
> >
> >
> > Border.jwc:
> > <component-specification class="org.dcg.platform.ui.Border"
> > allow-informal-parameters="no">
> > <parameter name="title" type="java.lang.String" required="yes" />
> >
> > ...
> > </component-specification>
> >
> >
> > > --
> > > Howard M. Lewis Ship
> > > Independent J2EE / Open-Source Java Consultant
> > > Creator, Tapestry: Java Web Components
> > > http://howardlewisship.com
> > >
> > >
> > >
> > >>-----Original Message-----
> > >>From: news [mailto:news@sea.gmane.org] On Behalf Of F. Da Costa
> > >>Sent: Saturday, February 14, 2004 9:57 AM
> > >>To: tapestry-user@jakarta.apache.org
> > >>Subject: Instantiation error
> > >>
> > >>
> > >>Just switched b4 and got this error.
> > >>Have been running the (cvs'ed) version a while now and i
> > >>thought the border
> > >>was definitely ok by now.
> > >>
> > >>org.apache.tapestry.ApplicationRuntimeException
> > >>Unable to instantiate an instance of class
> > org.dcg.platform.ui.Border.
> > >>component:
> org.dcg.platform.HomeContent@1b158db[HomeContent]
> > >>location:
> classpath:/org/dcg/platform/ui/Border.jwc, line 6
> > >>
> > >>java.lang.InstantiationException
> > >>Stack Trace:
> > >>
> > >> *
> > >>sun.reflect.InstantiationExceptionConstructorAccessorImpl.newI
> > >>nstance(InstantiationExceptionConstructorAccessorImpl.java:30)
> > >> *
> > java.lang.reflect.Constructor.newInstance(Constructor.java:274)
> > >> * java.lang.Class.newInstance0(Class.java:308)
> > >> * java.lang.Class.newInstance(Class.java:261)
> > >> *
> > >>org.apache.tapestry.pageload.PageLoader.instantiateComponent(P
> > >>ageLoader.java:650)
> > >>...
> > >>
> > >>I can find the class in the dir so it does exist.
> > >>What else would be a good place to look?
> > >>
> > >>TIA
> > >>Fermin DCG
> > >>
> > >>
> > >>------------------------------------------------------------
> > ---------
> > >>To unsubscribe, e-mail:
> tapestry-user-unsubscribe@jakarta.apache.org
> > >>For additional commands, e-mail:
> > tapestry-user-help@jakarta.apache.org
> > >>
> > >
> > >
> > >
> > >
> >
> ---------------------------------------------------------------------
> > > To unsubscribe, e-mail:
> tapestry-user-unsubscribe@jakarta.apache.org
> > > For additional commands, e-mail:
> > tapestry-user-help@jakarta.apache.org
> > >
> > >
> >
> >
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail:
> tapestry-user-help@jakarta.apache.org
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
RE: Instantiation error
Posted by Petter Måhlén <pe...@chello.se>.
InstantiationException means that the target class is abstract or an
interface. Have you tried dropping the 'abstract' from the class definition?
/ Petter
> -----Original Message-----
> From: news [mailto:news@sea.gmane.org] On Behalf Of F. Da Costa
> Sent: den 14 februari 2004 17:19
> To: tapestry-user@jakarta.apache.org
> Subject: Re: Instantiation error
>
>
> Howard M. Lewis Ship wrote:
> > Do you have a public constructor? Looks like the error is
> occuring when the constructor is invoked.
> >
> Noop, never had one actually. As it has been working for
> months now i never
> bothered with it anymore either. Am i misusing the abstract &
> parameter
> thing perhaps?
>
>
> Border.java:
> public abstract class Border extends BaseComponent {
> private String _title;
>
> public String getResult() {
> return _result;
> }
>
> public void setTitle(String subtitle) {
> _title = subtitle;
> }
>
> public String getTitle() {
> return _title;
> }
>
> protected int getPageType() {
> ...
> return _pageType;
> }
> }
>
>
> Border.jwc:
> <component-specification class="org.dcg.platform.ui.Border"
> allow-informal-parameters="no">
> <parameter name="title" type="java.lang.String" required="yes" />
>
> ...
> </component-specification>
>
>
> > --
> > Howard M. Lewis Ship
> > Independent J2EE / Open-Source Java Consultant
> > Creator, Tapestry: Java Web Components
> > http://howardlewisship.com
> >
> >
> >
> >>-----Original Message-----
> >>From: news [mailto:news@sea.gmane.org] On Behalf Of F. Da Costa
> >>Sent: Saturday, February 14, 2004 9:57 AM
> >>To: tapestry-user@jakarta.apache.org
> >>Subject: Instantiation error
> >>
> >>
> >>Just switched b4 and got this error.
> >>Have been running the (cvs'ed) version a while now and i
> >>thought the border
> >>was definitely ok by now.
> >>
> >>org.apache.tapestry.ApplicationRuntimeException
> >>Unable to instantiate an instance of class
> org.dcg.platform.ui.Border.
> >>component: org.dcg.platform.HomeContent@1b158db[HomeContent]
> >>location: classpath:/org/dcg/platform/ui/Border.jwc, line 6
> >>
> >>java.lang.InstantiationException
> >>Stack Trace:
> >>
> >> *
> >>sun.reflect.InstantiationExceptionConstructorAccessorImpl.newI
> >>nstance(InstantiationExceptionConstructorAccessorImpl.java:30)
> >> *
> java.lang.reflect.Constructor.newInstance(Constructor.java:274)
> >> * java.lang.Class.newInstance0(Class.java:308)
> >> * java.lang.Class.newInstance(Class.java:261)
> >> *
> >>org.apache.tapestry.pageload.PageLoader.instantiateComponent(P
> >>ageLoader.java:650)
> >>...
> >>
> >>I can find the class in the dir so it does exist.
> >>What else would be a good place to look?
> >>
> >>TIA
> >>Fermin DCG
> >>
> >>
> >>------------------------------------------------------------
> ---------
> >>To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> >>For additional commands, e-mail:
> tapestry-user-help@jakarta.apache.org
> >>
> >
> >
> >
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail:
> tapestry-user-help@jakarta.apache.org
> >
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
Re: Instantiation error
Posted by "F. Da Costa" <da...@xs4all.nl>.
Howard M. Lewis Ship wrote:
> Do you have a public constructor? Looks like the error is occuring when the constructor is invoked.
>
Noop, never had one actually. As it has been working for months now i never
bothered with it anymore either. Am i misusing the abstract & parameter
thing perhaps?
Border.java:
public abstract class Border extends BaseComponent {
private String _title;
public String getResult() {
return _result;
}
public void setTitle(String subtitle) {
_title = subtitle;
}
public String getTitle() {
return _title;
}
protected int getPageType() {
...
return _pageType;
}
}
Border.jwc:
<component-specification class="org.dcg.platform.ui.Border"
allow-informal-parameters="no">
<parameter name="title" type="java.lang.String" required="yes" />
...
</component-specification>
> --
> Howard M. Lewis Ship
> Independent J2EE / Open-Source Java Consultant
> Creator, Tapestry: Java Web Components
> http://howardlewisship.com
>
>
>
>>-----Original Message-----
>>From: news [mailto:news@sea.gmane.org] On Behalf Of F. Da Costa
>>Sent: Saturday, February 14, 2004 9:57 AM
>>To: tapestry-user@jakarta.apache.org
>>Subject: Instantiation error
>>
>>
>>Just switched b4 and got this error.
>>Have been running the (cvs'ed) version a while now and i
>>thought the border
>>was definitely ok by now.
>>
>>org.apache.tapestry.ApplicationRuntimeException
>>Unable to instantiate an instance of class org.dcg.platform.ui.Border.
>>component: org.dcg.platform.HomeContent@1b158db[HomeContent]
>>location: classpath:/org/dcg/platform/ui/Border.jwc, line 6
>>
>>java.lang.InstantiationException
>>Stack Trace:
>>
>> *
>>sun.reflect.InstantiationExceptionConstructorAccessorImpl.newI
>>nstance(InstantiationExceptionConstructorAccessorImpl.java:30)
>> * java.lang.reflect.Constructor.newInstance(Constructor.java:274)
>> * java.lang.Class.newInstance0(Class.java:308)
>> * java.lang.Class.newInstance(Class.java:261)
>> *
>>org.apache.tapestry.pageload.PageLoader.instantiateComponent(P
>>ageLoader.java:650)
>>...
>>
>>I can find the class in the dir so it does exist.
>>What else would be a good place to look?
>>
>>TIA
>>Fermin DCG
>>
>>
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>>For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
RE: Instantiation error
Posted by "Howard M. Lewis Ship" <hl...@comcast.net>.
Do you have a public constructor? Looks like the error is occuring when the constructor is invoked.
--
Howard M. Lewis Ship
Independent J2EE / Open-Source Java Consultant
Creator, Tapestry: Java Web Components
http://howardlewisship.com
> -----Original Message-----
> From: news [mailto:news@sea.gmane.org] On Behalf Of F. Da Costa
> Sent: Saturday, February 14, 2004 9:57 AM
> To: tapestry-user@jakarta.apache.org
> Subject: Instantiation error
>
>
> Just switched b4 and got this error.
> Have been running the (cvs'ed) version a while now and i
> thought the border
> was definitely ok by now.
>
> org.apache.tapestry.ApplicationRuntimeException
> Unable to instantiate an instance of class org.dcg.platform.ui.Border.
> component: org.dcg.platform.HomeContent@1b158db[HomeContent]
> location: classpath:/org/dcg/platform/ui/Border.jwc, line 6
>
> java.lang.InstantiationException
> Stack Trace:
>
> *
> sun.reflect.InstantiationExceptionConstructorAccessorImpl.newI
> nstance(InstantiationExceptionConstructorAccessorImpl.java:30)
> * java.lang.reflect.Constructor.newInstance(Constructor.java:274)
> * java.lang.Class.newInstance0(Class.java:308)
> * java.lang.Class.newInstance(Class.java:261)
> *
> org.apache.tapestry.pageload.PageLoader.instantiateComponent(P
> ageLoader.java:650)
> ...
>
> I can find the class in the dir so it does exist.
> What else would be a good place to look?
>
> TIA
> Fermin DCG
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org