aspose file tools*
The moose likes PHP and the fly likes Self? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Languages » PHP
Bookmark "Self?" Watch "Self?" New topic
Author

Self?

Josh Huynh
Greenhorn

Joined: Dec 15, 2013
Posts: 3
I'm trying to figure out the answer this question. I tried googling and looking through my PDF text book none of which is able to tell me the value when "self" is used. I understand the basics, ex is a object of method example and 7 is placed in x making val=7.

Winston Gutkowski
Bartender

Joined: Mar 17, 2011
Posts: 8008
    
  22

Josh Huynh wrote:I'm trying to figure out the answer this question. I tried googling and looking through my PDF text book none of which is able to tell me the value when "self" is used. I understand the basics, ex is a object of method example and 7 is placed in x making val=7.

This sounds like PHP to me - regular Java does not have a "self" keyword. So I'm moving this post to that forum.

If I'm wrong, let me know, and I'll move it to somewhere more appropriate.

Winston

[Edit] Oops, might have jumped the gun.
@Josh: Let me know if this was intended to be a Java question or whether you are, in fact, writing PHP code. If the first, I'll move it back.

Isn't it funny how there's always time and money enough to do it WRONG?
Articles by Winston can be found here
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 42264
    
  64
Welcome to JavaRanch. Given that the code doesn't compile, the question is moot My guess is that the author of this code meant to use this, not self (which doesn't exist in Java): http://en.wikipedia.org/wiki/This_%28computer_programming%29#Java


Ping & DNS - my free Android networking tools app
Josh Huynh
Greenhorn

Joined: Dec 15, 2013
Posts: 3
Updating this. You guys were right. I basically wrote in the question that there is no self in java and explained the differences between self and this. Teacher gave me full credit for doing the research. Thanks for your help!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Self?