diff options
author | Mikel Astiz <mikel.astiz@bmw-carit.de> | 2013-04-26 08:17:07 +0200 |
---|---|---|
committer | Johan Hedberg <johan.hedberg@intel.com> | 2013-04-26 10:24:53 +0300 |
commit | b5c339804950551cba3bc07051dc339ad0a1db2c (patch) | |
tree | 91c3350d52dd58efecc8f86bfa24da0e7d7a1cd6 /src/service.h | |
parent | 4d35439d8fb37edec6e833ca82a58dfa3ae7c171 (diff) | |
download | bluez-b5c339804950551cba3bc07051dc339ad0a1db2c.tar.gz |
core: Add btd_service to represent device services
Add a new object to centralize all data corresponding to a service
provided by a remote device, coupling a pair of btd_profile and
btd_device pointers.
Diffstat (limited to 'src/service.h')
-rw-r--r-- | src/service.h | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/src/service.h b/src/service.h new file mode 100644 index 000000000..4f8338796 --- /dev/null +++ b/src/service.h @@ -0,0 +1,37 @@ +/* + * + * BlueZ - Bluetooth protocol stack for Linux + * + * Copyright (C) 2012-2013 BMW Car IT GmbH. All rights reserved. + * + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + * + */ + +struct btd_service; +struct btd_device; +struct btd_profile; + +struct btd_service *btd_service_ref(struct btd_service *service); +void btd_service_unref(struct btd_service *service); + +/* Service management functions used by the core */ +struct btd_service *service_create(struct btd_device *device, + struct btd_profile *profile); + +/* Public member access */ +struct btd_device *btd_service_get_device(const struct btd_service *service); +struct btd_profile *btd_service_get_profile(const struct btd_service *service); |