기술 자료

Unity Engine

Unity Engine

GetMetadatas<T>()

Enumerates every metadata item of the given type.
읽는 시간 1분최근 업데이트: 한 달 전

Definition

  • Type: Method
  • Namespace: Unity.Localization
  • Assembly: UnityEngine.LocalizationRuntimeModule
public IEnumerable<T> GetMetadatas<T>() where T : class, IMetadata

Returns

Type

Description

IEnumerable<T>A sequence of the items assignable to
T
.

Remarks

Items are returned in the order they were added. Use MetadataCollection.GetMetadata when you only need the first match.
Iterate every comment attached to a collection.

Examples

using System.Collections.Generic;using Unity.Localization;namespace Unity.Localization.Samples{ public class MetadataCollectionGetMetadatasExample { public IEnumerable<Comment> Run(MetadataCollection metadata) => metadata.GetMetadatas<Comment>(); }}