O'Reilly logo

C# 5.0 Unleashed by Bart De Smet

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Visibility

To limit access to members, accessibility modifiers exist. This functionality is intertwined with support for object-oriented programming, as you will see in Chapter 14.

Type Visibility

Visibility exists not only on the member level but also on the type level. Let’s take a look at that first. A type’s visibility determines from where it can be used, in particular whether other assemblies can access it. Assemblies can be seen roughly as containers for types (as detailed in Chapter 25, “Assemblies and Application Domains”). For example, the System.String type lives in an assembly called mscorlib.dll and has been declared as “public,” which means other assemblies can access it.

If you were to take a look at mscorlib.dll in tools like ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required