Java Pointers and Missing method body

  • Thread starter Pattielli
  • Start date
  • #1
290
0
I declare my pointer as char* ptr and my function as public boolean FuncFoo() but java compiler complains that I have some problem with identifier right at * and my function is missing the method body...
I couldn't figure out what was wrong with them. Would you please help me ?
Thank you,
 

Answers and Replies

  • #2
691
1
Firts part: Java doesn't have pointers.

Second part
Code:
public boolean FuncFoo()
     {
          you need a body even if you leave it bank
     }

Java doesn't require function definitions either (is that why you're not using the {}?). Simply create your function and call it.

http://leepoint.net/notes-java/10background/10applications_and_applets/05intro/60JavaVsC.html [Broken]
 
Last edited by a moderator:

Related Threads on Java Pointers and Missing method body

Replies
4
Views
667
  • Last Post
Replies
20
Views
4K
  • Last Post
Replies
2
Views
2K
  • Last Post
Replies
1
Views
4K
  • Last Post
Replies
4
Views
3K
  • Last Post
Replies
4
Views
2K
  • Last Post
Replies
11
Views
9K
  • Last Post
Replies
4
Views
3K
  • Last Post
6
Replies
129
Views
22K
  • Last Post
Replies
22
Views
4K
Top