Trace.IsEnabled Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Checks whether or not tracing is currently enabled.
public static bool IsEnabled { [Android.Runtime.Register("isEnabled", "()Z", "", ApiSince=29)] get; }
[<get: Android.Runtime.Register("isEnabled", "()Z", "", ApiSince=29)>]
static member IsEnabled : bool
Property Value
true if tracing is currently enabled, false otherwise
- Attributes
Remarks
Checks whether or not tracing is currently enabled. This is useful to avoid intermediate string creation for trace sections that require formatting. It is not necessary to guard all Trace method calls as they internally already check this. However it is recommended to use this to prevent creating any temporary objects that would then be passed to those methods to reduce runtime cost when tracing isn't enabled.
Java documentation for android.os.Trace.isEnabled()
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.