What are the access-specifiers available in c#?
Answer Posted / vakil vijay vamangari
Public: With respect to the assembly the variable,methods of
public class can be access any where .
Private: This is default in c#.net.With respect to the
assembly the variable,methods of private class can be
access only with in that class only.
Protected: With respect to the assembly the variable,methods
of protected class can be access with in that class(base
class) and accessed in class which is derived from that
base class.
Internal(friend in vb.net): With respect to the assembly the
variable,methods of internal class can be access with in
that assembly not the outside of that assembly
Protected Internal: Protected + Internal
With with respect to the assembly the variable,methods
of this class can be access with in that assembly and
protected out side the assembly
| Is This Answer Correct ? | 4 Yes | 13 No |
Post New Answer View All Answers
What is the use of convert toint32 in c#?
Differentiate between the public and private ?
Define multicast delegate? How it be used?
Compare and contrast between the System.Array.CopyTo() and Clone()?
What is windows forms in c#?
What is attribute c#?
What is parameters in c#?
Does unity use c++ or c#?
What can be done with c#?
What Is An Interface Class?
What is private in c#?
What language do desktop applications use?
What is lazy t?
How to add a readonly property in c#.net
Can properties be overloaded in c#?