What are the access-specifiers available in c#?
Answer Posted / faiyazul islam
public - allow to access member functions and member
variable of a class from other class that can be inside or
outside of namespace collection.
private - only allow to access member functions and member
variable of a class within the same class.
protected- allow to access member functions and member
variable of a class from within same class and child classes
that can be inside or outside the namespace collection.
internal - allow to access member functions and member
variable of a class from within same class and class within
the inside namespace collection.
internal protected - allow to access member functions and
member variable of a class from within same class and and
child class within the inside namespace.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is the difference between array and arraylist in c#?
What is Garbage Collection in .Net?
What is the difference between array and arraylist c#?
Can abstract class have constructor in c#?
Is std :: string null terminated?
What are the advantages of properties in c#?
How does the lifecycle of Windows services differ from Standard EXE?
How many constructors can a class have c#?
How assembly versioning in .NET prevent DLL Hell problem?
What is an enumerator in c#?
Is c# code is unmanaged or managed code?
What is property c#?
Define encapsulation?
Can we create instance of private class in c#?
what is scope of a protected internal member variable of a c# class