C++/CLI Sample
Demonstrates how to create a C++/CLI library using the VideoXpert SDK
CPPCli::QuickLog Class Reference

The QuickLog class represents a quick system health log. More...

#include <QuickLog.h>

Public Types

enum  LogCreationStatus {
  LogCreationStatus::Unknown,
  LogCreationStatus::InProgress,
  LogCreationStatus::Failed,
  LogCreationStatus::Successful
}
 Values that represent status of creating a quick log. More...
 

Public Member Functions

 QuickLog (VxSdk::IVxQuickLog *vxQuickLog)
 Constructor. More...
 
virtual ~QuickLog ()
 Destructor. More...
 
 !QuickLog ()
 Finaliser. More...
 

Package Functions

System::String^ _GetQuickLogEndpoint ()
 
LogCreationStatus _GetStatus ()
 

Package Attributes

VxSdk::IVxQuickLog_log
 

Properties

System::String^  QuickLogEndpoint [get]
 Gets the URI to the download location of the quick log. The endpoint will only be available if the VideoXpert system has completed generating the log. More...
 
LogCreationStatus Status [get]
 Gets the current status of generating the quick log. More...
 

Detailed Description

The QuickLog class represents a quick system health log.

Definition at line 12 of file QuickLog.h.

Member Enumeration Documentation

Values that represent status of creating a quick log.

Enumerator
Unknown 

An error or unknown value was returned.

InProgress 

The log creation is in progress.

Failed 

The log failed to be created.

Successful 

The log has successfully been created.

Definition at line 18 of file QuickLog.h.

18  {
20  Unknown,
22  InProgress,
24  Failed,
26  Successful
27  };

Constructor & Destructor Documentation

CPPCli::QuickLog::QuickLog ( VxSdk::IVxQuickLog vxQuickLog)

Constructor.

Implements the quick log class.

Parameters
vxQuickLogThe vx quick log.

Definition at line 6 of file QuickLog.cpp.

6  {
7  _log = vxQuickLog;
8 }
VxSdk::IVxQuickLog * _log
Definition: QuickLog.h:67
virtual CPPCli::QuickLog::~QuickLog ( )
inlinevirtual

Destructor.

Definition at line 38 of file QuickLog.h.

38  {
39  this->!QuickLog();
40  }
QuickLog(VxSdk::IVxQuickLog *vxQuickLog)
Constructor.
Definition: QuickLog.cpp:6
CPPCli::QuickLog::!QuickLog ( )

Finaliser.

Definition at line 10 of file QuickLog.cpp.

10  {
11  _log->Delete();
12  _log = nullptr;
13 }
VxSdk::IVxQuickLog * _log
Definition: QuickLog.h:67
virtual VxResult::Value Delete() const =0

Member Function Documentation

System::String CPPCli::QuickLog::_GetQuickLogEndpoint ( )
package

Definition at line 15 of file QuickLog.cpp.

15  {
16  char* logEndpoint = nullptr;
17  int size = 0;
18 
19  // If the quick log endpoint is not available on the system the result will return VxSdk::VxResult::kActionUnavailable,
20  // otherwise VxSdk::VxResult::kInsufficientSize
21  VxSdk::VxResult::Value result = _log->GetQuickLogEndpoint(logEndpoint, size);
22  if (result == VxSdk::VxResult::kInsufficientSize) {
23  // Allocate enough space for logEndpoint
24  logEndpoint = new char[size];
25  // The result should now be kOK since we have allocated enough space
26  _log->GetQuickLogEndpoint(logEndpoint, size);
27  }
28  return gcnew System::String(logEndpoint);
29 }
VxSdk::IVxQuickLog * _log
Definition: QuickLog.h:67
virtual VxResult::Value GetQuickLogEndpoint(char *endpoint, int &size)=0
CPPCli::QuickLog::LogCreationStatus CPPCli::QuickLog::_GetStatus ( )
package

Definition at line 31 of file QuickLog.cpp.

31  {
32  // Get the status of the log
34  VxSdk::VxResult::Value result = _log->GetStatus(status);
35  // Return the status if GetStatus was successful
36  if (result == VxSdk::VxResult::kOK)
38 
40 }
VxSdk::IVxQuickLog * _log
Definition: QuickLog.h:67
An error or unknown value was returned.
LogCreationStatus
Values that represent status of creating a quick log.
Definition: QuickLog.h:18
virtual VxResult::Value GetStatus(VxLogCreationStatus::Value &status)=0

Member Data Documentation

VxSdk::IVxQuickLog* CPPCli::QuickLog::_log
package

Definition at line 67 of file QuickLog.h.

Property Documentation

System:: String^ CPPCli::QuickLog::QuickLogEndpoint
get

Gets the URI to the download location of the quick log. The endpoint will only be available if the VideoXpert system has completed generating the log.

Returns
The quick log endpoint, if available.

Definition at line 52 of file QuickLog.h.

LogCreationStatus CPPCli::QuickLog::Status
get

Gets the current status of generating the quick log.

The current quick log creation status.

Definition at line 61 of file QuickLog.h.


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