Return-Path: X-Original-To: apmail-incubator-deltacloud-dev-archive@minotaur.apache.org Delivered-To: apmail-incubator-deltacloud-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 114FF91FB for ; Thu, 10 Nov 2011 18:55:45 +0000 (UTC) Received: (qmail 45589 invoked by uid 500); 10 Nov 2011 18:55:45 -0000 Delivered-To: apmail-incubator-deltacloud-dev-archive@incubator.apache.org Received: (qmail 45574 invoked by uid 500); 10 Nov 2011 18:55:44 -0000 Mailing-List: contact deltacloud-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: deltacloud-dev@incubator.apache.org Delivered-To: mailing list deltacloud-dev@incubator.apache.org Received: (qmail 45566 invoked by uid 99); 10 Nov 2011 18:55:44 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 10 Nov 2011 18:55:44 +0000 X-ASF-Spam-Status: No, hits=-5.0 required=5.0 tests=RCVD_IN_DNSWL_HI,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of lutter@redhat.com designates 209.132.183.28 as permitted sender) Received: from [209.132.183.28] (HELO mx1.redhat.com) (209.132.183.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 10 Nov 2011 18:55:37 +0000 Received: from int-mx12.intmail.prod.int.phx2.redhat.com (int-mx12.intmail.prod.int.phx2.redhat.com [10.5.11.25]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id pAAItE9u007896 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Thu, 10 Nov 2011 13:55:15 -0500 Received: from [10.3.112.24] (ovpn-112-24.phx2.redhat.com [10.3.112.24]) by int-mx12.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id pAAItERX013349 for ; Thu, 10 Nov 2011 13:55:14 -0500 Subject: Re: Model layer for CIMI From: David Lutterkort To: deltacloud-dev@incubator.apache.org Date: Thu, 10 Nov 2011 10:55:13 -0800 In-Reply-To: References: <1320873504-27543-1-git-send-email-lutter@redhat.com> Organization: Red Hat Inc Content-Type: text/plain; charset="ISO-8859-15" Content-Transfer-Encoding: 7bit Message-ID: <1320951314.29766.3.camel@melon.watzmann.net> Mime-Version: 1.0 X-Scanned-By: MIMEDefang 2.68 on 10.5.11.25 X-Virus-Checked: Checked by ClamAV on apache.org On Thu, 2011-11-10 at 08:36 -0500, Tong Li wrote: > I do not think DMTF cimi spec strongly suggested the sequence of the > elements. At least it did not say in the spec. although most of the samples > do show a patten of the elements. That's one of the implicit rules of XML: order matters, DOM's are ordered trees etc. > When I used XmlSimple (), it actually > keeps the right order with the xml it reads in. The difficulty is when you > have a hash (produced by XmlSimple from an XML doc), you most likely will > add or remove things off of the hash, that is where it sequence really get > messed up, I do not consider it has anything to do with the XmlSimple, it > is just when hash get serialized to xml or json, probably the serializer > does not know how to deal with the sequence since the hash certainly does > not have the sequence information of its members. Either way, we'll have to write our own XML serialization to make sure element order is correct; the schema that is declared with the DSL has the element order (the order in which attributes are declared) David