Skip to content

Commit

Permalink
Document setEnabled
Browse files Browse the repository at this point in the history
[doc only]
  • Loading branch information
badboy committed Nov 26, 2024
1 parent 42247e4 commit efa3bf5
Showing 1 changed file with 78 additions and 0 deletions.
78 changes: 78 additions & 0 deletions docs/user/reference/pings/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,84 @@ GleanPings.search.submit("performed");

{{#include ../../../shared/tab_footer.md}}

### `setEnabled`

TODO

{{#include ../../../shared/tab_header.md}}

<div data-lang="Kotlin" class="tab">

```kotlin
import org.mozilla.yourApplication.GleanMetrics.Pings

Pings.search.setEnabled(false)
```

</div>

<div data-lang="Java" class="tab">

```java
import org.mozilla.yourApplication.GleanMetrics.Pings

Pings.INSTANCE.search.setEnabled(false);
```

</div>

<div data-lang="Swift" class="tab">

```swift
import Glean

GleanMetrics.Pings.shared.search.setEnabled(false)
```

</div>

<div data-lang="Python" class="tab">

```Python
from glean import load_pings

pings = load_pings("pings.yaml")

pings.search.set_enabled(False)
```

</div>

<div data-lang="Rust" class="tab">

```Rust
use glean::Pings;

pings::search.set_enabled(false);
```

</div>

<div data-lang="JavaScript" class="tab"></div>

<div data-lang="Firefox Desktop" class="tab">

**C++**

```cpp
mozilla::glean_pings::Search.SetEnabled(false);
```

**JavaScript**

```js
GleanPings.search.setEnabled(false);
```

</div>

{{#include ../../../shared/tab_footer.md}}

## Testing API

### `getRegisteredPingNames`
Expand Down

0 comments on commit efa3bf5

Please sign in to comment.