Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Primitive lists #4

Open
wants to merge 16 commits into
base: master
Choose a base branch
from
Open

Conversation

roguenet
Copy link
Contributor

Primitive list implementation complete for JSON and XML. The XML format is shown in the last commit from this PR. This one depends on the JSON support PR, so once that one is in, there should be fewer commits showing up here. Unfortunately, the "Ignore compiled python bytecode" commit was on my master branch and I don't think I can get rid of it, so that one and its reversion are included here, which I don't think I can avoid, unless I want to exclude it from every branch I ever make for PRs.

I've since realized that the way to develop in this environment is to do all dev on a branch, issue the PR, then only put on master once the PR has been responded to, which is how I'll operate going forward.

roguenet and others added 16 commits June 19, 2013 16:53
This allows ListMarshaller to set true for the new isList parameter to addChild, a feature required
for the forthcoming JSON implementation. This was also needed (I think) to support lists of
primitives, but I haven't verified this... I just didn't see how it could be done based on the
ListMarshaller writeObject() code.
There are some peculiar differences from the XML implementation because the name of an element is
not included within that element, but rather on the parent object. The main visible difference is
that JsonUtil's method parameters are a bit different from XmlUtil's.
I do notice though that this doesn't test writing, and I don't actually have any use for JSON
writing at the moment, so I haven't tested that yet.
List children are formated as <list><value>42</value></list>. As with complex lists, the child
element name is inconsequential, value is simply the default used when writing out a primitive list.
@roguenet
Copy link
Contributor Author

Oh, the list example is no longer in the last commit. 0a11542 is the one you want.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants