コード例 #1
0
 public IEnumerator <IValueMetaData> GetEnumerator()
 {
     for (uint i = 0; i < _object.getSize(); i++)
     {
         yield return(new ValueMetaData(_engine, _object.getByIndex(i)));
     }
 }
コード例 #2
0
        internal static IEnumerable <IValueMetaData> Select(
            this ValueMetaDataCollectionSwig source,
            Func <ValueMetaDataSwig, IValueMetaData> selector)
        {
            for (uint i = 0; i < source.getSize(); i++)
            {
#pragma warning disable CA2000 // Dispose objects before losing scope
                // The IValueMetaData instance that is created
                // will handle disposal
                yield return(selector(source.getByIndex(i)));

#pragma warning restore CA2000 // Dispose objects before losing scope
            }
        }