Top "Namespaces" questions

A namespace is a container that provides context for identifiers, within which names are unique.

type object 'datetime.datetime' has no attribute 'datetime'

I have gotten the following error: type object 'datetime.datetime' has no attribute 'datetime' On the following line: date = datetime.…

python datetime namespaces
Declaring an enum within a class

In the following code snippet, the Color enum is declared within the Car class in order to limit the scope …

c++ class enums namespaces scope
What is the use of "using namespace std"?

What is the use of using namespace std? I'd like to see explanation in Layman terms.

c++ namespaces std using
socket.error:[errno 99] cannot assign requested address and namespace in python

My server software says errno99: cannot assign requested address while using an ip address other than 127.0.0.1 for binding. But if …

python sockets namespaces ip
Unnamed/anonymous namespaces vs. static functions

A feature of C++ is the ability to create unnamed (anonymous) namespaces, like so: namespace { int cannotAccessOutsideThisFile() { ... } } // namespace You would …

c++ namespaces
Should 'using' directives be inside or outside the namespace?

I have been running StyleCop over some C# code, and it keeps reporting that my using directives should be inside …

c# .net namespaces stylecop code-organization
What is the meaning of prepended double colon "::"?

I found this line of a code in a class which I have to modify: ::Configuration * tmpCo = m_configurationDB;//pointer …

c++ syntax namespaces scope-resolution global-namespace
PHP namespaces and "use"

I am having a little trouble with namespaces and the use statements. I have three files: ShapeInterface.php, Shape.php …

php namespaces
How do you properly use namespaces in C++?

I come from a Java background, where packages are used, not namespaces. I'm used to putting classes that work together …

c++ namespaces
Getting all types in a namespace via reflection

How do you get all the classes in a namespace through reflection in C#?

c# .net reflection namespaces