The transient is a keyword defined in the java programming language. Keywords are basically reserved words which have specific meaning relevant to a compiler in java programming language likewise the transient keyword indicates the following :
-- The transient keyword is applicable to the member variables of a
class.
-- The transient keyword is used to indicate that the member variable should not be serialized when the class instance
containing that transient variable is needed to be serialized.
Example to use the transient keyword with a var
iable:|
public class Class 1{private transient String password; |
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.
Ask Questions? Discuss: transient Java Keyword View All Comments
Post your Comment