Java Forums

Main Menu
Home
Today's Posts
FAQ
Search
Contact Us

Java Network
Linux Archive
Java Tips
Java Tips Blog

Sponsored Links





Welcome to the Java Forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community, you will:

  • have access to post topics
  • communicate privately with other members (PM)
  • not see advertisements between posts
  • have the possibility to earn one of our surprises if you are an active member
  • access many other special features that will be introduced later.

Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 08-01-2007, 03:19 PM
Member
 
Join Date: Jul 2007
Posts: 51
mary is on a distinguished road
is void a type?
I'm new in java and when I was reading a tutorial about it.
I see this
Code:
public void setAge(int age){ this.age=age; }
what kind of type is void? what does it represent? what does it mean?
can you help me?
please
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 08-01-2007, 03:39 PM
Member
 
Join Date: Jul 2007
Location: England, Bath
Posts: 47
shanePreater is on a distinguished road
Void is kind of a type! In the context that you have shown in your code it represents nothing. This means in the case of your method you are not expecting anything to be returned from the method.

Hope this helps.
__________________
Shane Preater -
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
Bookmark Post in Technorati
Reply With Quote
  #3 (permalink)  
Old 08-01-2007, 06:23 PM
Member
 
Join Date: Jul 2007
Posts: 51
mary is on a distinguished road
I finally understood what it means
thanks shanePreater
Bookmark Post in Technorati
Reply With Quote
  #4 (permalink)  
Old 08-01-2007, 10:12 PM
Member
 
Join Date: Jul 2007
Location: England, Bath
Posts: 47
shanePreater is on a distinguished road
No problems glad to help out
Shane
__________________
Shane Preater -
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Java Native Access (JNA) return types of void * burnumd Advanced Java 0 04-03-2008 07:12 PM
Type Casting Help rhm54 New To Java 2 02-07-2008 02:06 PM
The different of static void,protected,and void in methods? Winarto New To Java 5 01-25-2008 01:53 AM
The return type Marcus New To Java 1 07-05-2007 08:28 AM


All times are GMT +3. The time now is 11:06 AM.


VBulletin, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2006 - 2007, www.java-forums.org