Diagnostics
Summary
| Members | Descriptions |
|---|---|
public DECLARE_DELEGATE_RetVal(TSharedPtr< FJsonObject >,FGetCustomDiagnosticMetadata) | Bindable delegate to get custom metadata to add to diagnostic reports. Can be used by a project to add data to the Metadata section. |
public DECLARE_DELEGATE_OneParam(FRH_OnDiagnosticReportComplete,const TSharedRef< const FRH_DiagnosticReportGenerator > &) | Bindable delegate to notify that a report generation is complete |
class FRH_DiagnosticReportGenerator | Report generator worker, which is responsible for collecting information from various locations, organizing the report, and then writing it to a destination. |
class URH_Diagnostics | Class to handle initializing and running a diagnostic (blueprint compatible). Tracks and stores local state from the running engine for tracking previous errors. |
struct FRH_DiagnosticReportOptions | Options for generating a diagnostic report. |
Members
public DECLARE_DELEGATE_RetVal(TSharedPtr< FJsonObject >,FGetCustomDiagnosticMetadata)
Bindable delegate to get custom metadata to add to diagnostic reports. Can be used by a project to add data to the Metadata section.
public DECLARE_DELEGATE_OneParam(FRH_OnDiagnosticReportComplete,const TSharedRef< const FRH_DiagnosticReportGenerator > &)
Bindable delegate to notify that a report generation is complete
class FRH_DiagnosticReportGenerator
class FRH_DiagnosticReportGenerator
: public FRH_AsyncTaskHelper
Report generator worker, which is responsible for collecting information from various locations, organizing the report, and then writing it to a destination.
Summary
| Members | Descriptions |
|---|---|
public TSharedPtr< FJsonObject > Metadata | Metadata JSON generated by the report |
public TSharedPtr< FJsonObject > WebRequests | Web Request JSON generated by the report |
public TSharedPtr< FJsonObject > FinalReport | Final combined report |
public FString ReportFilename | Filename the report was written to (if requested) |
public bool bCloudWriteSuccesful | Whether the cloud write was successful (if requested) |
public inline FRH_DiagnosticReportGenerator() | Default constructor |
public inline virtual bool CanStart() const | Check if report generation can start based on the current stage. |
public inline virtual void Start(const FRH_DiagnosticReportOptions & InOptions) | Start generating a report with the given options |
protected FRH_DiagnosticReportOptions Options | Options for generating the report |
protected ReportGenerationStage Stage | Current stage of report generation |
protected inline void StageComplete() | Called when a stage is complete, increments the stage and calls the appropriate function to start the next stage |
protected void GenerateMetadata() | generates the Metadata object |
protected void GenerateWebRequests() | Generates the WebRequests object. |
protected void GenerateFinalReport() | Generates a final report in JSON format, stores in Report, and then triggers a delegate. |
protected void WriteToFile() | Writes the current Report value to the filename specified in options (or a default filename if none is specified) |
protected void WriteToCloud() | Writes the current Report value to the cloud (based on the RallyHere integration settings) |
protected inline virtual FString GetName() const | Gets the name of this object for reporting and debugging. |
protected inline virtual void ExecuteCallback(bool bSuccess) const | Execute completion callback. |
enum ReportGenerationStage | Generation stage for report generation |
Members
public TSharedPtr< FJsonObject > Metadata
Metadata JSON generated by the report
public TSharedPtr< FJsonObject > WebRequests
Web Request JSON generated by the report
public TSharedPtr< FJsonObject > FinalReport
Final combined report
public FString ReportFilename
Filename the report was written to (if requested)
public bool bCloudWriteSuccesful
Whether the cloud write was successful (if requested)
public inline FRH_DiagnosticReportGenerator()
Default constructor
public inline virtual bool CanStart() const
Check if report generation can start based on the current stage.
public inline virtual void Start(const FRH_DiagnosticReportOptions & InOptions)
Start generating a report with the given options
protected FRH_DiagnosticReportOptions Options
Options for generating the report
protected ReportGenerationStage Stage
Current stage of report generation
protected inline void StageComplete()
Called when a stage is complete, increments the stage and calls the appropriate function to start the next stage
protected void GenerateMetadata()
generates the Metadata object
protected void GenerateWebRequests()
Generates the WebRequests object.
protected void GenerateFinalReport()
Generates a final report in JSON format, stores in Report, and then triggers a delegate.
protected void WriteToFile()
Writes the current Report value to the filename specified in options (or a default filename if none is specified)
protected void WriteToCloud()
Writes the current Report value to the cloud (based on the RallyHere integration settings)
protected inline virtual FString GetName() const
Gets the name of this object for reporting and debugging.
protected inline virtual void ExecuteCallback(bool bSuccess) const
Execute completion callback.
enum ReportGenerationStage
| Values | Descriptions |
|---|---|
| Unstarted | |
| Metadata | |
| WebRequests | |
| FinalReport | |
| WriteToFile | |
| WriteToCloud | |
| Complete |
Generation stage for report generation
class URH_Diagnostics
class URH_Diagnostics
: public UObject
Class to handle initializing and running a diagnostic (blueprint compatible). Tracks and stores local state from the running engine for tracking previous errors.
Summary
| Members | Descriptions |
|---|---|
public FGetCustomDiagnosticMetadata CustomDiagnosticMetadataDelegate | Delegate to bind to to add extra custom data to the diagnostic report. |
public void Initialize() | Initialize the system. |
public void Uninitialize() | Safely tears down the system. |
public inline void ClearCache() | Clears the diagnostics cache. |
public void GenerateReport(const FRH_DiagnosticReportOptions & Options) const | Generates a report in JSON format. |
Members
public FGetCustomDiagnosticMetadata CustomDiagnosticMetadataDelegate
Delegate to bind to to add extra custom data to the diagnostic report.
public void Initialize()
Initialize the system.
public void Uninitialize()
Safely tears down the system.
public inline void ClearCache()
Clears the diagnostics cache.
public void GenerateReport(const FRH_DiagnosticReportOptions & Options) const
Generates a report in JSON format.
Parameters
-
WorldThe context world object. -
OptionsOptions for the generated report.
Returns
The generated object
struct FRH_DiagnosticReportOptions
Options for generating a diagnostic report.
Summary
| Members | Descriptions |
|---|---|
public bool bIncludeMetadata | Whether to include metadata in the report |
public bool bIncludeWebRequests | Whether to include web request data in the report |
public bool bWriteToFile | Whether to write to a file when the report is complete |
public FString OutputFilename | Optional filename to write the report to if bWiteToFile is set (otherwise, generates a name) |
public bool bWriteToCloud | Whether to write to cloud when the report is complete |
public TWeakObjectPtr< UWorld > World | World to use to acquire RH subsystems and information |
public FRH_OnDiagnosticReportComplete OnReportComplete | Delegate fired when report is complete |
public inline FRH_DiagnosticReportOptions() | Default constructor, defaults to everything enabled |
public inline FRH_DiagnosticReportOptions(DiagnosticReportPreset Preset) | Preset constructor, for ease of use |
enum DiagnosticReportPreset | Preset for enabling/disabling various diagnostic report options |
Members
public bool bIncludeMetadata
Whether to include metadata in the report
public bool bIncludeWebRequests
Whether to include web request data in the report
public bool bWriteToFile
Whether to write to a file when the report is complete
public FString OutputFilename
Optional filename to write the report to if bWiteToFile is set (otherwise, generates a name)
public bool bWriteToCloud
Whether to write to cloud when the report is complete
public TWeakObjectPtr< UWorld > World
World to use to acquire RH subsystems and information
public FRH_OnDiagnosticReportComplete OnReportComplete
Delegate fired when report is complete
public inline FRH_DiagnosticReportOptions()
Default constructor, defaults to everything enabled
public inline FRH_DiagnosticReportOptions(DiagnosticReportPreset Preset)
Preset constructor, for ease of use
enum DiagnosticReportPreset
| Values | Descriptions |
|---|---|
| AllEnabled | Enable all options |
| AllDisabled | Disable all options |
Preset for enabling/disabling various diagnostic report options