IStatsPage

The public interface for a stats page.

Choose your operating system:

Windows

macOS

Linux

Inheritance Hierarchy

IStatsPage

FStatsPage

References

Module

StatsViewer

Header

/Engine/Source/Editor/StatsViewer/Public/IStatsPage.h

Include

#include "IStatsPage.h"

Syntax

class IStatsPage

Remarks

The public interface for a stats page.

The table does its best to display the relevant information.

Objects UCLASS metadata required are: DisplayName - The name displayed in the page selection dropdown. Tooltip - The tooltip displayed in the page selection dropdown. ObjectSetType - A text representation of the UENUM used for object set enumeration.

The object set UENUM also uses metadata to display certain information. UENUM metadata syntax differs from UCLASS metadata as it is specified via the UMETA() tag, rather than meta=() UPROPERTY subtags. DisplayName - The name displayed in the object set dropdown. ToolTip - The tooltip displayed over the object set dropdown.

The UI supports the following UPROPERTY metadata: ColumnWidth - Integer value. The (proportionally-based, not absolute) width of the properties column. ShowTotal - Either true or false. Whether the column header should attempt to show a total (provided in Generate() via the OutTotals map). SortMode - Either Ascending or Descending. If this is specified then the properties column will be sorted on table creation. Unit - Text value displayed next to table entries and totals

Functions

Name Description

Public function Virtual

void

 

AddEntry

(
    UObject* InEntry
)

Adds a stats entry to the page Not all pages have to override this - only ones that accept transient data output from processes that do not persist in the editor

Public function Virtual

void

 

Clear()

Clears any entries added via AddEntry() Not all pages have to override this - only ones that accept transient data output from processes that do not persist in the editor

Public function Const

void

 

Generate

(
    TArray< TWeakObjectPtr< UObject > >...
)

Fill the output array with statistic objects to be displayed

Public function Const

void

 

GenerateTotals

(
    const TArray< TWeakObjectPtr< UObje...,
    TMap< FString, FText >& OutTotals
)

Totals are displayed by mapping the CPP name of the columns property to the total string in the OutTotals map.

Public function Const

void

 

GetCustomColumns

(
    TArray< TSharedRef< class IProperty...
)

Get any column customizations that this page wants to use.

Public function

TSharedPtr< ...

 

GetCustomFilter

(
    TWeakPtr< class IStatsViewer > InPa...
)

Get custom filter to display in the top part of the stats viewer, can return nullptr

Public function

TSharedPtr< ...

 

GetCustomWidget

(
    TWeakPtr< class IStatsViewer > InPa...
)

Get custom widget to display in the top part of the stats viewer, can return nullptr

Public function Const

const FText

 

GetDisplayName()

Get the name of the entry type to be displayed in the page selection dropdown

Public function Const

UClass *

 

GetEntryClass()

Get the class of the entry we handle This is needed to display the search filter's combo button

Public function Const

FName

 

GetName()

Get the name of the entry type

Public function Const

int32

 

GetObjectSetCount()

Get the number of object sets this page supports

Public function Const

FString

 

GetObjectSetName

(
    int32 InObjectSetIndex
)

Get the name of the object set, to be displayed in the dropdown

Public function Const

FString

 

GetObjectSetToolTip

(
    int32 InObjectSetIndex
)

Get the tooltip of the object set, to be displayed over the object set the dropdown

Public function Const

int32

 

GetSelectedObjectSet()

Get the currently displayed object set

Public function Const

const FText

 

GetToolTip()

Get the tooltip to be displayed over the page selection dropdown

Public function Const

UWorld *

 

GetWorld()

Get the world used for page statistics.

Public function Const

bool

 

IsRefreshPending()

Check if this page wants to refresh itself

Public function Const

bool

 

IsShowPending()

Check if this page wants to show itself

Public function Virtual

void

 

OnHide()

Called back each time the page is hidden

Public function Virtual

void

 

OnShow

(
    TWeakPtr< class IStatsViewer > InPa...
)

Called back each time the page is shown

Public function

void

 

Refresh

(
    bool bRefresh
)

Sends a requests to the stats page to refresh itself the next chance it gets

Public function

void

 

SetSelectedObjectSet

(
    int32 InObjectSetIndex
)

Set the currently displayed object set

Public function

void

 

SetWorld

(
    UWorld& InWorld
)

Set a specific world to use for page statistics.

Public function

void

 

Show

(
    bool bShow
)

Tries to switch the currently displayed page to this one