Support collections of types without having to explicitly define it
-------------------------------------------------------------------
Key: THRIFT-519
URL: https://issues.apache.org/jira/browse/THRIFT-519
Project: Thrift
Issue Type: New Feature
Reporter: Nathan Marz
I frequently find myself needing to be able to serialize/deserialize
collections of objects across languages. Every time I need one of these
collections, I have to explicitly define it in a thrift file. Some examples are:
struct FriendSet {
1: set<binary> friend_ids;
}
struct StringList {
1: list<string> strings;
}
struct FooList {
1: list<Foo> foos; // foo is a thrift struct
}
It would be convenient if Thrift supported collections of objects directly.
Perhaps serialize/deserialize can support taking a list or set, such as:
TDeserializer des = new TDeserializer();
List<Foo> myList = new ArrayList<Foo>();
des.deserialize(myList, record);
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.