Show: Delphi C++
Display Preferences

Accessing Elements Of A namespace

From RAD Studio
Jump to: navigation, search

Go Up to C++ namespaces Index

There are three ways to access the elements of a namespace: by explicit access qualification, the using-declaration, or the using-directive. Remember that no matter which namespace you add to your local scope, identifiers in global scope (global scope is just another namespace) are still accessible by using the scope resolution operator ::.

Accessing namespaces in classes

You cannot use a using directive inside a class. However, the using declarative is allowed and can be quite useful.

Personal tools
RAD Studio 10.2 Tokyo
In other languages
Previous Versions
Assistance