[#BloombergLP-ball-AttributeContext-getContext]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/ball.adoc[ball]::xref:BloombergLP/ball/AttributeContext.adoc[AttributeContext]::getContext
:relfileprefix: ../../../
:mrdocs:

Return the address of the current thread&apos;s attribute context, creating one if needed&period;

== Synopsis

Declared in `&lt;ball&lowbar;attributecontext&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
static
xref:BloombergLP/ball/AttributeContext.adoc[AttributeContext]*
getContext();
----

== Description

Return the address of the current thread&apos;s attribute context, if such context exists&semi; otherwise, create an attribute context, install it in thread&hyphen;local storage, and return the address of the newly created context&period; Note that this method can be invoked safely even if the `initialize` class method has not yet been called&period;

== Return Value

address of this thread&apos;s attribute context


[.small]#Created with https://www.mrdocs.com[MrDocs]#
