Re: Cannot access method of POJO

Stefan Großhauser <[email protected]> Wed, 26 Jan 2022 10:04:55 +0100
Newsgroups gmane.comp.jakarta.velocity.user
Message-ID <[email protected]>
--=-bCwumzD8Twc2HSGBzsN5
Content-Type: text/plain;
	charset="utf-8"
Content-Transfer-Encoding: quoted-printable


Thank you for having a look=2E
Actually=2C trying all sorts of things=2C I had removed the =27public=27 ke=
ywords=2E

I have just tried it again with a public inner class containing a public me=
thod=2C but unfortunately that does not make any difference=2C the error st=
ays the same=2E


///////////////
public class Toolbox =7B
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 public String rot13=28String s=
=29 =7B
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 StringBu=
ffer ret =3D new StringBuffer=28=29=3B
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 for =28i=
nt i =3D 0=3B i =3C s=2Elength=28=29=3B i++=29 =7B
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=
=C2=A0=C2=A0=C2=A0 char c =3D s=2EcharAt=28i=29=3B
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=
=C2=A0=C2=A0=C2=A0 if=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 =28c =3E=3D =27a=
=27 =26=26 c =3C=3D =27m=27=29 c +=3D 13=3B
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=
=C2=A0=C2=A0=C2=A0 else if=C2=A0 =28c =3E=3D =27A=27 =26=26 c =3C=3D =27M=
=27=29 c +=3D 13=3B
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=
=C2=A0=C2=A0=C2=A0 else if=C2=A0 =28c =3E=3D =27n=27 =26=26 c =3C=3D =27z=
=27=29 c -=3D 13=3B
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=
=C2=A0=C2=A0=C2=A0 else if=C2=A0 =28c =3E=3D =27N=27 =26=26 c =3C=3D =27Z=
=27=29 c -=3D 13=3B
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=
=C2=A0=C2=A0=C2=A0 ret=2Eappend=28c=29=3B
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 =7D
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 return r=
et=2EtoString=28=29=3B
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 =7D
=C2=A0=C2=A0=C2=A0 =7D
/////////////////////////

Stefan Gro=C3=9Fhauser
IT

Telefon=C2=A0=C2=A0 +49 =280=29 9181 2592-83
E-Mail =C2=A0=C2=A0=C2=A0 stefan=2Egrosshauser=40hammerbachergmbh=2Ede

Hammerbacher GmbH=2C Daimlerstra=C3=9Fe 4+6=2C 92318 Neumarkt
Internet=3A=C2=A0 www=2Ehammerbacher=2Ecom



 Von=3A   Ranil Wijeyratne =3Cranil=2Ewijeyratne=40ergon=2Ech=3E=20
 An=3A   Velocity Users List =3Cuser=40velocity=2Eapache=2Eorg=3E=20
 Gesendet=3A   26=2E01=2E2022 9=3A58=20
 Betreff=3A   Re=3A Cannot access method of POJO=20

I think the problem is that your rot13 method is package private and not pu=
blic=2E=20
=20


=20

JETZT NEWSLETTER ABONNIEREN=3A https=3A//hammerbacher=2Ecom/newsletter-anme=
ldung/
Hammerbacher GmbH Gesch=C3=A4ftsf=C3=BChrer Bernhard Hammerbacher=2C Ursula=
 Hammerbacher Registergericht N=C3=BCrnberg HRB 10908   =20
 =09Hausanschrift
Daimlerstra=C3=9Fe 4-6
D 92318 Neumarkt =09Telefon
+49=280=299181
2592-0 =09Telefax
+49=280=299181
2592-28 =09E-Mail
info=40hammerbachergmbh=2Ede
www=2Ehammerbacher=2Ecom


=20
Haftungsausschluss / Disclaimer=20
Die Informationen=2C die in dieser Kommunikation enthalten sind=2C sind aus=
schlie=C3=9Flich und allein f=C3=BCr den Empf=C3=A4nger bestimmt=2E Die Ver=
wendung durch Dritte ist untersagt=2E Die Firma Hammerbacher GmbH ist nur f=
=C3=BCr die von ihr eingegeben Informationen verantwortlich=2C jedoch nicht=
 f=C3=BCr die einwandfreie =C3=9Cbertragung oder im Zusammenhang mit der=20=
=C3=9Cbertragung oder dem Empfang eingetretene Ver=C3=A4nderungen oder Verz=
=C3=B6gerungen=2E
Diese E-Mail enth=C3=A4lt vetrtrauliche und/oder rechtlich gesch=C3=BCtzte=
 Informationen=2E Wenn Sie nicht der richtige Adressat sind oder diese E-Ma=
il irrt=C3=BCmlich erhalten=C2=A0 haben=2C informieren Sie bitte sofort den=
 Absender und vernichten Sie diese E-Mail=2E Das unerlaubte Kopieren sowie=
 die unbefugte Weitergabe dieser Mail ist nicht gestattet=2E

--=-bCwumzD8Twc2HSGBzsN5--