Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!news.glorb.com!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail From: subhabangalore@gmail.com Newsgroups: comp.lang.java.help Subject: Re: Data Encapsulation Question Date: Sat, 11 Aug 2012 13:29:30 -0700 (PDT) Organization: http://groups.google.com Lines: 31 Message-ID: References: <6jbd28tbfbfrvgl8hm8b6ironhgpggcngo@4ax.com> NNTP-Posting-Host: 122.161.34.135 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 X-Trace: posting.google.com 1344717066 10398 127.0.0.1 (11 Aug 2012 20:31:06 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Sat, 11 Aug 2012 20:31:06 +0000 (UTC) Cc: Roedy Green In-Reply-To: <6jbd28tbfbfrvgl8hm8b6ironhgpggcngo@4ax.com> Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=122.161.34.135; posting-account=6SonuQoAAACzSakS5dCECcJQe6ylLrzY User-Agent: G2/1.0 Xref: csiph.com comp.lang.java.help:1987 On Sunday, August 12, 2012 12:42:14 AM UTC+5:30, Roedy Green wrote: > On Fri, 10 Aug 2012 12:13:00 -0700 (PDT), subhabangalore@gmail.com > > wrote, quoted or indirectly quoted someone who said : > > > > >Thanks it worked. The code is working but only "Size:" of System.out.println("Size:"+b.getsize()); is giving error, if you drop it --it is coming nicely. > > > > Just copy and paste the output of the program. The code looks fine. > > -- > > Roedy Green Canadian Mind Products http://mindprod.com > > A new scientific truth does not triumph by convincing its opponents and making them see the light, > > but rather because its opponents eventually die, and a new generation grows up that is familiar with it. > > ~ Max Planck 1858-04-23 1947-10-04 Dear Sir, Thank you for your kind concern. The following error message is coming: Exception in thread "main" java.lang.Error: Unresolved compilation problem: The method getsize() is undefined for the type Box at BoxMain.main(BoxMain.java:16) Regards, Subhabrata.