From owner-freebsd-arch@FreeBSD.ORG Thu Jul 31 02:09:45 2014 Return-Path: Delivered-To: arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 067F9CDE for ; Thu, 31 Jul 2014 02:09:45 +0000 (UTC) Received: from mail-pd0-f171.google.com (mail-pd0-f171.google.com [209.85.192.171]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id CC1692400 for ; Thu, 31 Jul 2014 02:09:44 +0000 (UTC) Received: by mail-pd0-f171.google.com with SMTP id z10so2505029pdj.16 for ; Wed, 30 Jul 2014 19:09:43 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:content-type:mime-version:subject:from :in-reply-to:date:cc:content-transfer-encoding:message-id:references :to; bh=ilwxu2yw3dznfn2iIsCE19Zpa5Az4gQ/gL9GZUHSUUc=; b=NztCEfCF7jHA2Hjza28xD/njQiYCgyGlh3XxV1TX2/3tjGhzn4o3eay7yXUn3RGYBL vBzL1gQkoJdi+Z5skMExJ1E97Oez5sl5c5hRpb+Ezvsh+PVji4VxAKWnTd/d58V6QbUx RX6E1XfPXF8D0QTYzyDJqMX2JLjxnubTyg+mz2vCIKt0rcz6jZQyhD5bPbQXc9Ux89DJ brTq6qYRLYKvV2GZRZbQykz8Tp0FlM+VbEJ3rDyUMw2AvWT9N4Nbi4+xH+2L5MAd4asr 1KpW5ZKjTx4DSBLjIiPrPMx8G6oYuJ33MO6aCT3ypvtLzQ9bxbJxj6TOCz88KMPOik2S uteQ== X-Gm-Message-State: ALoCoQmpN4WFopwgWEE5MKMnVyDpq0s7xP67W5q4WXi60gmqpcYo3piy5+7voAoHpoGcdTRnlBhA X-Received: by 10.68.93.65 with SMTP id cs1mr916227pbb.52.1406772583483; Wed, 30 Jul 2014 19:09:43 -0700 (PDT) Received: from [192.168.1.100] (c-24-6-220-224.hsd1.ca.comcast.net. [24.6.220.224]) by mx.google.com with ESMTPSA id vz7sm150285pbc.95.2014.07.30.19.09.41 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 30 Jul 2014 19:09:42 -0700 (PDT) Content-Type: text/plain; charset=windows-1252 Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\)) Subject: Re: XML Output: libxo - provide single API to output TXT, XML, JSON and HTML From: Tim Kientzle In-Reply-To: Date: Wed, 30 Jul 2014 19:09:40 -0700 Content-Transfer-Encoding: quoted-printable Message-Id: References: <20140725044921.9F0D3580A2@chaos.jnpr.net> <82CFA67F-BA93-44EE-BD4B-9105F89AD157@rpi.edu> To: Garance A Drosehn X-Mailer: Apple Mail (2.1878.6) Cc: sjg@freebsd.org, arch@freebsd.org, marcel@freebsd.org, phil@juniper.net, Simon Gerraty X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 31 Jul 2014 02:09:45 -0000 On Jul 30, 2014, at 6:45 PM, Garance A Drosehn wrote: > On 30 Jul 2014, at 21:37, Garance A Drosehn wrote: >>=20 >> [...] if you're going for machine-readable output then >> you'd want that in some format which was much more specific and >> *standard* (as opposed to arbitrary pretty-printed strings). >> Something like the ISO 8601 format used in obscure parts of lpd: >>=20 >> #define LPD_TIMESTAMP_PATTERN "%Y-%m-%dT%T%z %a" >=20 >> Or you could follow the example of EDN, and use rfc-3339-format >> (see '#inst' at https://github.com/edn-format/edn). The nice >> thing about standards is that there are so many to choose from. >=20 > I should note that these two formats are very similar, and in fact > may be exactly the same. Essentially, ISO8601 is the same as RFC3339 except that ISO8601 also has a bunch of additional notations for partial date/time, durations, and repeat intervals. Trivia: * RFC3339 claims to be a =93profile of ISO8601=94 * RFC3339 requires a timezone specifier * Both allow fractional seconds (period followed by one or more digits) * RFC3339 allows a timezone of =91-00:00=92; ISO8601 requires a =91+=92 = for a zero offset > I kept meaning to see if there was any > difference between them. I just noticed that the rfc has the 'Z' > suffix as an option for a timezone, and I don't think that the ISO > one does. Both allow =91Z=92.=20 = http://stackoverflow.com/questions/522251/whats-the-difference-between-iso= -8601-and-rfc-3339-date-formats Tim