LinphoneCoreFactory.h 1.41 KB
Newer Older
1 2
#pragma once

3
#include "ApiLock.h"
4
#include "LinphoneCoreListener.h"
5 6 7

namespace Linphone
{
8
	namespace Core
9
	{
10
		ref class Globals;
11
		ref class LinphoneCore;
12 13
		ref class LinphoneAuthInfo;
		ref class LinphoneAddress;
14

15 16 17
		public ref class LinphoneCoreFactory sealed
		{
		public:
18
			property LinphoneCore^ LinphoneCore
19
            {
20
                Linphone::Core::LinphoneCore^ get();
21
            }
22 23

			void SetDebugMode(Platform::Boolean enable, Platform::String^ tag);
24
			
25 26 27 28 29 30
			void CreateLinphoneCore(LinphoneCoreListener^ listener, Platform::String^ userConfig, Platform::String^ factoryConfig, Platform::Object^ userData);
			void CreateLinphoneCore(LinphoneCoreListener^ listener);

			LinphoneAuthInfo^ CreateAuthInfo(Platform::String^ username, Platform::String^ password, Platform::String^ realm);

			LinphoneAddress^ CreateLinphoneAddress(Platform::String^ username, Platform::String^ domain, Platform::String^ displayName);
31 32 33 34 35

			/// <summary>
			/// Constructs a LinphoneAddress object by parsing the user supplied address, given as a string.
			/// </summary>
			/// <param name="address">address, should be like "sip:joe@sip.linphone.org"</param>
36
			LinphoneAddress^ CreateLinphoneAddress(Platform::String^ address);
37 38

		private:
39
			friend ref class Linphone::Core::Globals;
40

41
			Linphone::Core::LinphoneCore^ linphoneCore;
42

43
			LinphoneCoreFactory();
44 45 46 47
			~LinphoneCoreFactory();
		};
	}
}