Declare a class which contains credentials

This commit is contained in:
Sergey Abramchuk
2017-04-24 16:30:15 +03:00
parent 8d591ba2e9
commit b792c9ba51
5 changed files with 83 additions and 0 deletions
@@ -0,0 +1,19 @@
//
// OpenVPNCredentials+Internal.h
// OpenVPN Adapter
//
// Created by Sergey Abramchuk on 24.04.17.
//
//
#import <client/ovpncli.hpp>
#import "OpenVPNCredentials.h"
using namespace openvpn;
@interface OpenVPNCredentials (Internal)
@property (readonly) ClientAPI::ProvideCreds credentials;
@end
+13
View File
@@ -0,0 +1,13 @@
//
// OpenVPNCredentials.h
// OpenVPN Adapter
//
// Created by Sergey Abramchuk on 24.04.17.
//
//
#import <Foundation/Foundation.h>
@interface OpenVPNCredentials : NSObject
@end
+32
View File
@@ -0,0 +1,32 @@
//
// OpenVPNCredentials.m
// OpenVPN Adapter
//
// Created by Sergey Abramchuk on 24.04.17.
//
//
#import "OpenVPNCredentials.h"
#import "OpenVPNCredentials+Internal.h"
using namespace openvpn;
@interface OpenVPNCredentials () {
ClientAPI::ProvideCreds _credentials;
}
@end
@implementation OpenVPNCredentials (Internal)
- (ClientAPI::ProvideCreds)credentials {
return _credentials;
}
@end
@implementation OpenVPNCredentials
@end
+1
View File
@@ -19,5 +19,6 @@ FOUNDATION_EXPORT const unsigned char OpenVPNAdapterVersionString[];
#import <OpenVPNAdapter/OpenVPNError.h>
#import <OpenVPNAdapter/OpenVPNEvent.h>
#import <OpenVPNAdapter/OpenVPNConfiguration.h>
#import <OpenVPNAdapter/OpenVPNCredentials.h>
#import <OpenVPNAdapter/OpenVPNAdapter.h>
#import <OpenVPNAdapter/OpenVPNAdapter+Public.h>