Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Doubt about wrapper classes

 
suneetha75
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can anybody tell me Is wrapper classes are included in the SCJP
exam?
one more thing, I want to KNow some thing about the keyword Transient, How we can use it? What is the use?
Thank you
Sunee
 
Kathy Rogers
Ranch Hand
Posts: 104
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Wrapper classes are included in the SCJP exam.
The transient keyword is used with serialization. You can serialize objects to transmit them in streams but when you do this, there may be sensitive class data that you don't want to transmit - for example, if you have a User object which has several attributes (name, password, age, address), you may not want to transmit the password for security reasons - you use the transient keyword to identify that data which is not included in an object's serialization. So you might declare password
private transient String password;
to indicate that it shouldn't be serialised.
Hope this helps,
Kathy
[This message has been edited by Kathy Rogers (edited February 08, 2001).]
 
Shrini Kulkarni
Ranch Hand
Posts: 63
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There is also one more aspect of transient key word. This is deals with Threads. A piece of transient data - tells compiler that several threads may be accessing it simulatneously. Hence data should be completely refershed everytime from memory and completely stored back after each access.
This is generally not mentioned while mentioning about transient data.
Hope this helps
Shrinivas
 
Angela Poynton
Ranch Hand
Posts: 3143
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm moving the to Programmers Certification Study!
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic