velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From john oh <ohj...@gmail.com>
Subject problem accessing extended methods from template
Date Mon, 12 Dec 2005 22:37:12 GMT
Hello,

I have a class (B) that extends another (A) like so
===============================================
class A{
protected String str = "A";
public String doA()
return this.str;
}

class B extends A{
}
===============================================

In my template, I use the inherited method doA(), but this does not
work. It doesn't print "A"
===============================================
template.tpl
$b.doA()
===============================================


I'm probably doing something wrong here. Can anyone see a problem with this?



Thank you,
John

---------------------------------------------------------------------
To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: velocity-user-help@jakarta.apache.org


Mime
View raw message