You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@thrift.apache.org by Apache Wiki <wi...@apache.org> on 2011/04/13 00:35:46 UTC

[Thrift Wiki] Update of "ThriftTypes" by JakeFarrell

Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Thrift Wiki" for change notification.

The "ThriftTypes" page has been changed by JakeFarrell.
http://wiki.apache.org/thrift/ThriftTypes?action=diff&rev1=11&rev2=12

--------------------------------------------------

  There are three container types:
  
   * '''{{{list<}}}''type''{{{>}}}''': An ordered list of elements. Translates to an STL {{{vector}}}, Java {{{ArrayList}}}, native arrays in scripting languages, etc.
-  * '''{{{set<}}}''type''{{{>}}}''': An unordered set of unique elements. Translates to an STL {{{set}}}, Java {{{HashSet}}}, {{{set}}} in Python, etc. This type is not supported in PHP! Use lists instead.
+  * '''{{{set<}}}''type''{{{>}}}''': An unordered set of unique elements. Translates to an STL {{{set}}}, Java {{{HashSet}}}, {{{set}}} in Python, etc. Note: PHP does not support sets, so it is treated similar to a List
   * '''{{{map<}}}''type1''{{{,}}}''type2''{{{>}}}''': A map of strictly unique keys to values. Translates to an STL {{{map}}}, Java {{{HashMap}}}, PHP associative array, Python/Ruby dictionary, etc.
  
  While defaults are provided, the type mappings are not explicitly fixed. Custom code generator directives have been added to allow substitution of custom types in various destination languages.