Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / May 2007

Tip: Looking for answers? Try searching our database.

method

Thread view: 
HMS Surprise - 08 May 2007 21:37 GMT
Looking at the snippet below I assume that method may be analogous to
self in other languages. But what is the purpose of this intial return
statement?

Thanks,

jh

//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

 protected boolean responseContainsURI(String uri) throws
URIException
 {
   return (method != null &&
                method.getURI().getPath().indexOf(uri) != -1);
Eric Smith - 08 May 2007 22:16 GMT
> Looking at the snippet below I assume that method may be analogous to
> self in other languages.

The java equivalent of "self" is "this".  In your code snippet,
"method" is most likely a class variable.

> But what is the purpose of this intial return statement?

It determines whether the contents of "method" are valid, for
some definition of valid.
HMS Surprise - 08 May 2007 22:35 GMT
> > Looking at the snippet below I assume that method may be analogous to
> > self in other languages.
[quoted text clipped - 6 lines]
> It determines whether the contents of "method" are valid, for
> some definition of valid.

Thanks, 'this' makes sense as much else looks like 'C'.

jh


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.