The asmapper data parsing tool completes the first step to implement vo and XML and mutual conversion.

Source: Internet
Author: User

Asmapper is a data parsing framework written by myself in ActionScript. It can convert Vo/po/pojo and XML to facilitate interaction with the server. If you have never used the VO mode development, you can ignore this tool.

XML and VO conversion tools have long been written, but never thought of a faster way. Recently I used xscream in Java and found that it was so convenient to bind VO to the framework and then perform one-time parsing. So I began to split my utils XML tool into a separate lib project. There are so many things to consider when a small parsing tool was originally implemented. For example, object a references object B, and object B references object a again. In this case, an endless loop is generated, resulting in errors. At the beginning, my practice was to generate only five times when such a reference was encountered, and if it was exceeded, it would be null. After writing it, we can see that the original scream is associated with the syntax of generating.../../AA/BB with a special attribute reference. Khan, rewrite it again. After rewriting, we found that the hash object of Java is different from that of ActionScript, So we added a new dedicated tool for parsing Java and xscream. It took me about a week to design, rewrite, and lazy. I never thought that a parsing tool would be so cool.

Now xmlmapper and javaxmlmapper are completed, that is, XML Conversion and Java Special Part conversion. Only one method for converting objects to VO is written in JSON, because Adobe's official JSON class library is not fully considered, for example, I just mentioned the issue of mutual reference, but the official claim that fp11 supports JSON native, so I will not wait for the moment. Currently, JSON characters are converted to objects and then to VO. Fill in jsonmapper and dotnetmapper in time. And help documentation.

A project was opened, and a source was opened after several days without any bugs.
Http://code.google.com/p/as-mapper/

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.