Arma Reforger Script API
Loading...
Searching...
No Matches
Public Member Functions | Protected Attributes | List of all members
SCR_ContainerBudgetManager< Class CONTAINER_TYPE, Class ITEM_TYPE > Interface Template Reference

Utility class that aids on budgeting or batching the processing of a specified container of CONTAINER_TYPE that holds items of ITEM_TYPE type. More...

Public Member Functions

CONTAINER_TYPE GetContainer ()
 
void SetContainer (CONTAINER_TYPE container)
 Sets the container instance.
 
array< ITEM_TYPE > ProcessNextBatch ()
 Processes the next batch based on the defined budget, and returns a new array with the batched items.
 
void SCR_ContainerBudgetManager (CONTAINER_TYPE container, int budgetSize)
 

Protected Attributes

CONTAINER_TYPE m_Container
 
int m_iBudgetSize
 
int m_iPivot
 

Detailed Description

Utility class that aids on budgeting or batching the processing of a specified container of CONTAINER_TYPE that holds items of ITEM_TYPE type.

Constructor & Destructor Documentation

◆ SCR_ContainerBudgetManager()

void SCR_ContainerBudgetManager< Class CONTAINER_TYPE, Class ITEM_TYPE >.SCR_ContainerBudgetManager ( CONTAINER_TYPE  container,
int  budgetSize 
)

Member Function Documentation

◆ GetContainer()

CONTAINER_TYPE SCR_ContainerBudgetManager< Class CONTAINER_TYPE, Class ITEM_TYPE >.GetContainer ( )
Returns
The container instance.

◆ ProcessNextBatch()

array< ITEM_TYPE > SCR_ContainerBudgetManager< Class CONTAINER_TYPE, Class ITEM_TYPE >.ProcessNextBatch ( )

Processes the next batch based on the defined budget, and returns a new array with the batched items.

Returns
The newly created batch or null if the container is null.

◆ SetContainer()

void SCR_ContainerBudgetManager< Class CONTAINER_TYPE, Class ITEM_TYPE >.SetContainer ( CONTAINER_TYPE  container)

Sets the container instance.

Parameters
containerThe container instance to set into the manager.

Member Data Documentation

◆ m_Container

CONTAINER_TYPE SCR_ContainerBudgetManager< Class CONTAINER_TYPE, Class ITEM_TYPE >.m_Container
protected

◆ m_iBudgetSize

int SCR_ContainerBudgetManager< Class CONTAINER_TYPE, Class ITEM_TYPE >.m_iBudgetSize
protected

◆ m_iPivot

int SCR_ContainerBudgetManager< Class CONTAINER_TYPE, Class ITEM_TYPE >.m_iPivot
protected

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