MapsIndoors iOS SDK V3
Loading...
Searching...
No Matches
MPBookingService.h
Go to the documentation of this file.
1//
2// MPBookingService.h
3// MapsIndoors
4//
5// Created by Michael Bech Hansen on 06/07/2020.
6// Copyright © 2020 MapsPeople A/S. All rights reserved.
7//
8
9#import <Foundation/Foundation.h>
10#import "MPBooking.h"
11#import "MPBookableQuery.h"
12#import "MPBookingsQuery.h"
13
14
15NS_ASSUME_NONNULL_BEGIN
16
17
18@class MPLocation;
20
21typedef void (^mpBookingCompletion)( MPBooking* _Nullable booking, NSError* _Nullable error );
22typedef void (^mpBookingListCompletion)( NSArray<MPBooking*>* _Nullable bookings, NSError* _Nullable error );
23typedef void (^mpLocationListCompletion)( NSArray<MPLocation*>* _Nullable locations, NSError* _Nullable error );
24
25
35@interface MPBookingService : NSObject
36
37+ (instancetype) sharedInstance;
38
42@property (nonatomic, strong, nullable) MPBookingAuthConfig* authenticationConfig;
43
49- (void) getBookableLocationsUsingQuery:(MPBookableQuery*)q completion:(mpLocationListCompletion)completion;
50
56- (void) getLocationsConfiguredForBooking:(MPBookableQuery*)query completion:(mpLocationListCompletion)completion NS_SWIFT_NAME(getLocationsConfiguredForBooking(query:completion:));
57
64- (void) getBookingsUsingQuery:(MPBookingsQuery*)q completion:(mpBookingListCompletion)completion;
65
71- (void) performBooking:(MPBooking*)booking completion:(mpBookingCompletion)completion;
72
78- (void) cancelBooking:(MPBooking*)booking completion:(mpBookingCompletion)completion;
79
80@end
81
82
83NS_ASSUME_NONNULL_END
void(^ mpLocationListCompletion)(NSArray< MPLocation * > *_Nullable locations, NSError *_Nullable error)
Definition MPBookingService.h:23
void(^ mpBookingListCompletion)(NSArray< MPBooking * > *_Nullable bookings, NSError *_Nullable error)
Definition MPBookingService.h:22
void(^ mpBookingCompletion)(MPBooking *_Nullable booking, NSError *_Nullable error)
Definition MPBookingService.h:21
Definition MPBookableQuery.h:25
Booking authentication configuration model. This may be used if the MPBookingService should book on b...
Definition MPBookingAuthConfig.h:15
Definition MPBooking.h:22
Definition MPBookingService.h:36
instancetype sharedInstance()
MPBookingAuthConfig * authenticationConfig
Definition MPBookingService.h:42
Definition MPBookingsQuery.h:22
Definition MPLocation.h:38