コード例 #1
0
 public static ArrayTuple Create <T>(List <T> elements, Func <T, PostgresTuple> converter)
 {
     if (elements != null)
     {
         var tuples = new PostgresTuple[elements.Count];
         for (int i = 0; i < elements.Count; i++)
         {
             tuples[i] = converter(elements[i]);
         }
         return(new ArrayTuple(tuples));
     }
     return(null);
 }
コード例 #2
0
 public static ArrayTuple Create <T>(IEnumerable <T> elements, Func <T, PostgresTuple> converter)
 {
     if (elements != null)
     {
         var tuples = new PostgresTuple[elements.Count()];
         var i      = 0;
         foreach (var el in elements)
         {
             tuples[i++] = converter(el);
         }
         return(new ArrayTuple(tuples));
     }
     return(null);
 }
コード例 #3
0
ファイル: RecordTuple.cs プロジェクト: nutrija/revenj
 public RecordTuple(PostgresTuple[] properties)
 {
     this.Properties = properties;
 }