Skip to main content

What Is Accessible in Your Namespaces

What Is Accessible in Your Namespaces

When you create a namespace, the system automatically defines mappings for that namespace. As a result, in that namespace, you can use the following items (provided you are logged in as a user with suitable permissions for these items):

  • Any class whose package name starts with a percent sign (%). This includes most, but not all, classes provided by InterSystems IRIS.

  • All the code stored in the routines database for this namespace.

  • All the data stored in the globals database for this namespace.

  • Any routine whose name starts with a percent sign.

  • Any include file whose name starts with a percent sign.

  • Any global whose name starts with a caret and a percent sign (^%). These globals are generally referred to as percent globals. Note that via global mappings or subscript level mappings, it is possible to change where percent globals are stored, but that has no effect on their visibility. Percent globals are always visible in all namespaces.

  • Your own globals with names that start ^IRIS.TempUser — for example, ^IRIS.TempUser.MyApp. If you create such globals, these globals are written to the IRISTEMP database.

  • If the namespace is interoperability-enabled, you can use code in the Ens and EnsLib packages. The CSPX and EnsPortal packages are also visible but these are not meant for direct use.

    If a namespace is interoperability-enabled, you can define a production in this namespace. To read about this, see Introducing Interoperability Productions.

  • Any additional code or data that is made available via mappings defined in this namespace.

Via extended global references, your code can access globals that are defined in other namespaces. For information, see Global Structure.

The InterSystems IRIS security model controls which data and which code any user can access.

System Globals in Your Namespaces

Your namespaces contain additional system globals, which fall into two rough categories:

  • System globals that are in all namespaces. These include the globals in which InterSystems IRIS stores your routines, class definitions, include files, INT code, and OBJ code.

  • System globals that are created when you use specific InterSystems IRIS features. For example, if you use Analytics in a namespace, the system creates a set of globals for its own internal use.

In most cases, you should not manually write to or delete any of these globals. See Global Naming Conventions.

FeedbackOpens in a new tab