diff options
| author | Chris Manton <cmanton@google.com> | 2014-08-13 16:38:57 -0700 |
|---|---|---|
| committer | Andre Eisenbach <eisenbach@google.com> | 2015-03-16 16:51:38 -0700 |
| commit | 78a51cb6c9efdc643aa812964adf5de6367eb477 (patch) | |
| tree | 100737a63b80336398be44d0e6ae8fdd05f6926e /osi/include | |
| parent | f95157c12f7fe1cea51bfe60b9d00d1546236b56 (diff) | |
| download | android_system_bt-78a51cb6c9efdc643aa812964adf5de6367eb477.tar.gz android_system_bt-78a51cb6c9efdc643aa812964adf5de6367eb477.tar.bz2 android_system_bt-78a51cb6c9efdc643aa812964adf5de6367eb477.zip | |
counter implementation
Diffstat (limited to 'osi/include')
| -rw-r--r-- | osi/include/counter.h | 43 |
1 files changed, 0 insertions, 43 deletions
diff --git a/osi/include/counter.h b/osi/include/counter.h deleted file mode 100644 index 891183ecf..000000000 --- a/osi/include/counter.h +++ /dev/null @@ -1,43 +0,0 @@ -/****************************************************************************** - * - * Copyright (C) 2014 Google, Inc. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at: - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - ******************************************************************************/ - -#pragma once - -#include <stdbool.h> -#include <stdint.h> - -// Used to iterate across all counters. -typedef bool (*counter_iter_cb)(const char *name, uint64_t val, void *context); - -// Global lifecycle -bool counter_init(); -void counter_exit(); - -// Accessors. -uint64_t counter_get(const char *name); - -// Mutators. -void counter_set(const char *name, uint64_t val); -void counter_clear(const char *name); -void counter_inc(const char *name); -void counter_dec(const char *name); -void counter_add(const char *name, uint64_t val); -void counter_sub(const char *name, uint64_t val); - -// Iteration. -bool counter_foreach(counter_iter_cb, void *context); |
