objc2_metal/generated/MTLAllocation.rs
1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use objc2::__framework_prelude::*;
4
5use crate::*;
6
7extern_protocol!(
8 /// Base class for Metal allocations.
9 ///
10 /// This protocol provides a common interface for adding Metal resources to ``MTLResidencySet`` instances. Call
11 /// ``MTLResidencySet/addAllocation:`` to add a Metal resource allocation to a residency set.
12 ///
13 /// <doc
14 /// :simplifying-gpu-resource-management-with-residency-sets.md>
15 ///
16 /// See also [Apple's documentation](https://developer.apple.com/documentation/metal/mtlallocation?language=objc)
17 pub unsafe trait MTLAllocation: NSObjectProtocol {
18 #[unsafe(method(allocatedSize))]
19 #[unsafe(method_family = none)]
20 fn allocatedSize(&self) -> NSUInteger;
21 }
22);