Win a copy of Practical SVG this week in the HTML/CSS/JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

hi

 
anita dhar
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
My doubt is about the transient varaiables and what is the use of it
 
dhwani mathur
Ranch Hand
Posts: 621
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ok!!!
By defination i can say transient is a variable which cannot be serialed.
Transient is useful when you either don't need the value on the other end or you can reconstruct it from other information.

An example would be a file handle or database connection. Such objects are only meaningful locally. In fact, you *have* to declare them transient in a Serializable class because they don't implement Serializable themselves. You can write code to re-initialize the handles on the "other side" with locally significant values, but you can't transport the objects directly.


Transient variables are used when we wanted to hide some information while transferring the data to some remote server.
e.g Password,CreditCardNo,CVV no.these info are very sensitive and cant be sent during transfer of data into n/w .
 
Yes, my master! Here is the tiny ad you asked for:
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!