SDK  2.1.4
CloudBackend Software Development Kit - SDK API for C++
cbe::ShareManager Class Reference

Managing Shares. More...

#include <ShareManager.h>

Public Types

using ListSharesDelegatePtr = delegate::ListSharesDelegatePtr
 
using ListSharesException = delegate::ListSharesDelegate::Exception
 
using ListSharesError = delegate::ListSharesDelegate::ErrorInfo
 
using ListMySharesException = delegate::ListSharesDelegate::Exception
 
using ListMySharesError = delegate::ListSharesDelegate::ErrorInfo
 

Public Member Functions

void listAvailableShares (ListSharesDelegatePtr delegate)
 Lists the shares exposed by other users to current user. This will give specific share information. More...
 
cbe::QueryResult listAvailableShares ()
 Synchronous [exception] Synchronous version of listAvailableShares(ListSharesDelegatePtr) , and throws an exception, ListSharesException, in case of a failed call.
See listAvailableShares(ListSharesDelegatePtr) More...
 
cbe::util::Optional< cbe::QueryResultlistAvailableShares (ListSharesError &error)
 Synchronous [non-throwing] Synchronous version of listAvailableShares(ListSharesDelegatePtr) , and throws no exception on error, instead the out/return parameter error is used to provide the error information in connection with a failed call.
See listAvailableShares(ListSharesDelegatePtr) More...
 
void listMyShares (ListSharesDelegatePtr delegate)
 Lists the shares exposed by current user. This will give specific share information. More...
 
delegate::ListSharesDelegate::Success listMyShares ()
 Synchronous [exception] Synchronous version of listMyShares(ListSharesDelegatePtr) , and throws an exception, ListMySharesException, in case of a failed call.
See listMyShares(ListSharesDelegatePtr) More...
 
cbe::util::Optional< delegate::ListSharesDelegate::SuccesslistMyShares (ListSharesError &error)
 Synchronous [non-throwing] Synchronous version of listMyShares(ListSharesDelegatePtr) , and throws no exception on error, instead the out/return parameter error is used to provide the error information in connection with a failed call.
See listMyShares(ListSharesDelegatePtr) More...
 
 ShareManager (cbe::DefaultCtor)
 Default constructor. More...
 
 operator bool () const
 Checks if the current instance is real. More...
 

Friends

class CloudBackend
 

Detailed Description

Managing Shares.

This class represents a list of Shares.

Member Typedef Documentation

◆ ListSharesDelegatePtr

◆ ListSharesException

Pointer to cbe::delegate::ListSharesDelegate that is passed into asynchronous version of method listAvailableShares() See delegate::object::ListSharesDelegate::Exception

◆ ListSharesError

Forms the type of the error return parameter for the synchronous version of method listAvailableShares()
See delegate::ListSharesDelegate::ErrorInfo

◆ ListMySharesException

Pointer to cbe::delegate::ListSharesDelegate that is passed into asynchronous version of method listMyShares() See delegate::object::ListSharesDelegate::Exception

◆ ListMySharesError

Forms the type of the error return parameter for the synchronous version of method listMyShares()
See delegate::ListSharesDelegate::ErrorInfo

Constructor & Destructor Documentation

◆ ShareManager()

cbe::ShareManager::ShareManager ( cbe::DefaultCtor  )

Default constructor.

Construct a new object with the DefaultCtor to enable the operator bool() test

Member Function Documentation

◆ listAvailableShares() [1/3]

void cbe::ShareManager::listAvailableShares ( ListSharesDelegatePtr  delegate)

Lists the shares exposed by other users to current user. This will give specific share information.

Parameters
delegatePointer to a delegate::ListSharesDelegate instance that is implemented by the user.

◆ listAvailableShares() [2/3]

cbe::QueryResult cbe::ShareManager::listAvailableShares ( )

Synchronous [exception] Synchronous version of listAvailableShares(ListSharesDelegatePtr) , and throws an exception, ListSharesException, in case of a failed call.
See listAvailableShares(ListSharesDelegatePtr)

Returns
Information about the listAvailableShares object — if the call was successful.
See cbe::delegate::ListSharesDelegate::Success
Exceptions
ListSharesException

◆ listAvailableShares() [3/3]

cbe::util::Optional<cbe::QueryResult> cbe::ShareManager::listAvailableShares ( ListSharesError error)

Synchronous [non-throwing] Synchronous version of listAvailableShares(ListSharesDelegatePtr) , and throws no exception on error, instead the out/return parameter error is used to provide the error information in connection with a failed call.
See listAvailableShares(ListSharesDelegatePtr)

Parameters
[out]errorReturn parameter containing the error information in case of a failed call.
An empty return value will indicate failure, and the ListSharesError object passed in will we be populated with the error information.
Returns
Empty — i.e., false — indicates a failed call, and the error information is passed out via the error out/return parameter.

◆ listMyShares() [1/3]

void cbe::ShareManager::listMyShares ( ListSharesDelegatePtr  delegate)

Lists the shares exposed by current user. This will give specific share information.

Parameters
delegatePointer to a delegate::ListSharesDelegate instance that is implemented by the user.

◆ listMyShares() [2/3]

delegate::ListSharesDelegate::Success cbe::ShareManager::listMyShares ( )

Synchronous [exception] Synchronous version of listMyShares(ListSharesDelegatePtr) , and throws an exception, ListMySharesException, in case of a failed call.
See listMyShares(ListSharesDelegatePtr)

Returns
Information about the listMyShares object — if the call was successful.
See cbe::delegate::ListSharesDelegate::Success
Exceptions
ListMySharesException

◆ listMyShares() [3/3]

cbe::util::Optional<delegate::ListSharesDelegate::Success> cbe::ShareManager::listMyShares ( ListSharesError error)

Synchronous [non-throwing] Synchronous version of listMyShares(ListSharesDelegatePtr) , and throws no exception on error, instead the out/return parameter error is used to provide the error information in connection with a failed call.
See listMyShares(ListSharesDelegatePtr)

Parameters
[out]errorReturn parameter containing the error information in case of a failed call.
An empty return value will indicate failure, and the ListMySharesError object passed in will we be populated with the error information.
Returns
Empty — i.e., false — indicates a failed call, and the error information is passed out via the error out/return parameter.

◆ operator bool()

cbe::ShareManager::operator bool ( ) const
explicit

Checks if the current instance is real.

An "unreal" instance implies typically a failed event.

Relies on the Default constructor ShareManager(cbe::DefaultCtor)

Returns
true : is real
false : unreal; got nullptr; if current instance is unbound/undefined. I.e., if it is only default constructed.

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