You.i Engine
CYIDeepLinkBridge Class Referenceabstract

Detailed Description

Class for accessing deep link urls which launched the app, and for launching other apps using urls.

#include <deeplinking/YiDeepLinkBridge.h>

Inheritance diagram for CYIDeepLinkBridge:

Public Types

typedef std::function< void(bool, const CYIUrl &)> OpenUrlCallback
 

Public Member Functions

virtual ~CYIDeepLinkBridge ()
 
void SetFirstLaunchUrl (const CYIUrl &url)
 
const CYIUrlGetFirstLaunchUrl () const
 
virtual bool CanOpenUrl (const CYIUrl &url) const =0
 
void OpenUrl (const CYIUrl &url)
 
void OpenUrl (const CYIUrl &url, OpenUrlCallback callback)
 
- Public Member Functions inherited from CYISignalHandler
 CYISignalHandler ()
 
 CYISignalHandler (const CYISignalHandler &rSignalHandler)
 
virtual ~CYISignalHandler ()
 
CYISignalHandleroperator= (const CYISignalHandler &rSignalHandler)
 
void MoveToThread (CYIThread *pThread)
 This function allows the user to override the default thread affinity to any CYIThread that may or may not be running. More...
 
CYIThreadHandle GetThreadAffinity () const
 
void SetThreadAffinity (const CYIThreadHandle &rThreadAffinity)
 
virtual bool IsConnected () const
 
virtual bool IsConnected (const CYISignalBase &rSignal) const
 
void Disconnect (CYISignalBase &rSignal)
 
void DisconnectFromAllSignals ()
 
- Public Member Functions inherited from CYIThread::Listener
 Listener ()
 
virtual ~Listener ()
 
virtual void OnThreadStarted (CYIThread *)
 
virtual void OnThreadTerminated (CYIThread *)
 
virtual void OnThreadFinished (CYIThread *)
 

Public Attributes

CYISignal< const CYIUrl & > IncomingUrlReceived
 
CYISignal< const CYIUrl & > OutgoingOpenUrlSucceeded
 
CYISignal< const CYIUrl & > OutgoingOpenUrlFailed
 

Protected Member Functions

virtual void OpenUrlImpl (const CYIUrl &url, OpenUrlCallback callback)=0
 

Member Typedef Documentation

typedef std::function<void(bool, const CYIUrl &)> CYIDeepLinkBridge::OpenUrlCallback

Constructor & Destructor Documentation

virtual CYIDeepLinkBridge::~CYIDeepLinkBridge ( )
inlinevirtual

Member Function Documentation

virtual bool CYIDeepLinkBridge::CanOpenUrl ( const CYIUrl url) const
pure virtual

Returns true if it is possible to launch another app with the provided deep link url, and false otherwise.

const CYIUrl& CYIDeepLinkBridge::GetFirstLaunchUrl ( ) const

Returns the url which first launched the app.

void CYIDeepLinkBridge::OpenUrl ( const CYIUrl url)

Attempts to open another app with the provided deep link url.

Note
If the attempt is successful, the signal OutgoingOpenUrlSucceeded will be emitted.
If the attempt is unsuccessful, the signal OutgoingOpenUrlFailed will be emitted.
void CYIDeepLinkBridge::OpenUrl ( const CYIUrl url,
OpenUrlCallback  callback 
)

Attempts to open another app with the provided deep link url.

Note
When the attempt is complete the callback will be called with parameters for whether the url was successfully opened, and the original url.
If the attempt is successful, the signal OutgoingOpenUrlSucceeded will be emitted.
If the attempt is unsuccessful, the signal OutgoingOpenUrlFailed will be emitted.
virtual void CYIDeepLinkBridge::OpenUrlImpl ( const CYIUrl url,
OpenUrlCallback  callback 
)
protectedpure virtual
void CYIDeepLinkBridge::SetFirstLaunchUrl ( const CYIUrl url)

Sets the deep link url which first launched the app.

Note
This method is accessed by platform specific engine code to route information to the app, and is not intended for use by app code.

Member Data Documentation

CYISignal<const CYIUrl &> CYIDeepLinkBridge::IncomingUrlReceived

Emitted when the app is either launched, or brought back from the background with a deep link.

CYISignal<const CYIUrl &> CYIDeepLinkBridge::OutgoingOpenUrlFailed

Emitted when an attempt to open another app with an outgoing deep link url is unsuccessful.

CYISignal<const CYIUrl &> CYIDeepLinkBridge::OutgoingOpenUrlSucceeded

Emitted when an attempt to open another app with an outgoing deep link url is successful.


The documentation for this class was generated from the following file: