Skip to content

Commit

Permalink
Adding String2DArray message type in array.proto (#77)
Browse files Browse the repository at this point in the history
* Add support for 2D arrays of strings in array.proto

* Update documentation for 2D array definition in array.proto

---------

Co-authored-by: Avi Goel <[email protected]>
  • Loading branch information
Blahpapto1 and Avi Goel authored Jan 27, 2025
1 parent d90843b commit a629df2
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions ni/protobuf/types/array.proto
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,12 @@ option php_namespace = "NI\\PROTOBUF\\TYPES";
option ruby_package = "NI::Protobuf::Types";

//---------------------------------------------------------------------
// Defines a 2D array of double values. The 2D array is stored as
// a repeated double, a 1D array. It is stored in row major order.
// Defines a 2D array of values. The 2D array is stored as a repeated field of
// the appropriate element type, a 1D array. It is stored in row major order.
//
// Example:
// Repeated Double: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
//
// rows: 2
// columns: 5
//
Expand All @@ -44,4 +45,11 @@ message Double2DArray
int32 rows = 1;
int32 columns = 2;
repeated double data = 3;
}

message String2DArray
{
int32 rows = 1;
int32 columns = 2;
repeated string data = 3;
}

0 comments on commit a629df2

Please sign in to comment.