Give an example for setter/ write-only methods



Give an example for setter/ write-only methods..

Answer / hrindows@gmail.com

// A write-only class in Java
public class Student{
//private data member
private String institute;
//setter method for institute
public void setInstitute (String institute)
{ this.institute=institute;
}
}

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Dot Net General Interview Questions

What is an anonymous method?

0 Answers  


Please explain what is the difference between a class and an object?

0 Answers  


Is atl redundant in the .net world?

0 Answers  


Is .net an object oriented language? What are their components?

0 Answers  


Difference between user groups and code groups

0 Answers  


Give An example of a ctype and directcast.

2 Answers   Wipro,


Difference abstract class and interface in .net?

0 Answers  


What are data types in .NET?

0 Answers   UGC Corporation,


Explain why do we use the “using” statement?

0 Answers  


what are connection strings?

0 Answers   Manhattan, RTRT,


Can you share processes between Windows services?

2 Answers  


Tell about your technical profile ?

0 Answers   TNEB Tamil Nadu Electricity Board,


Categories