Version: Unity 6.7 Beta (6000.7)
LanguageEnglish
  • C#

Range

struct in Unity.Collections

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Submission failed

For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

Description

A range of allocated memory.

The name is perhaps misleading: only in combination with a Block does a Range have sufficient information to represent the number of bytes in an allocation. The reason Range is its own type that's separate from Block stems from some efficiency concerns in the implementation details. In most cases, a Range is only used in conjunction with an associated Block.

Properties

Property Description
Allocator The allocator function used for this range.
Items Number of items allocated in this range.
Pointer Pointer to the start of this range.

Public Methods

Method Description
Dispose Deallocates the memory represented by this range.