开发者

Naming a method that converts raw data into an object

Say you have data in the format:

name=john;age=33;gender=male

What would you call a 开发者_如何学Cmethod that converts data like that into an an object / associative array?

I've been thinking about:

- unserialize_variables

- parse_variables


DeserialisePerson


Person.Unserialize?


PersonReader. Works if you change how you persist the person data in the future too.


In two steps:

ContainerType person = data.parse();

Employee employee( person["name"], person["age"], person["gender"] );
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜