RE: Draft JSON specification for CIF
- Subject: RE: Draft JSON specification for CIF
- From: "Bollinger, John C" <John.Bollinger@xxxxxxxxxx>
- Date: Fri, 14 Apr 2017 13:04:06 +0000
- Accept-Language: en-US
- authentication-results: iucr.org; dkim=none (message not signed)header.d=none;iucr.org; dmarc=none action=none header.from=STJUDE.ORG;
- DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=SJCRH.onmicrosoft.com; s=selector1-stjude-org;h=From:Date:Subject:Message-ID:Content-Type:MIME-Version;bh=InWYqJsXzBSsyRaxy31CkJrQy5hUuS3goplBvlXee4k=;b=IDmTpdY0L2hRVjiZ8nGlejn3bj6gyatWO2rUQJSPFz/Zh1KYoibhR0lxli7m+bpznpL7SoipEBjN2OKLKOlXElsZi2CA9N3vAjZ6yRPNJDH4KqF7LwHBYU6DNvqRec+C3vqdNYZLi3Y0G651boJwbZ0nZwb9Ke0ZwWrwJmXu9e8=
- In-Reply-To: <CAF_YUvUnTmdCzXcC1LwGOnU3WpwTWa-9VnW4XYKp+kn2ob+FkQ@mail.gmail.com>
- References: <CAM+dB2fszww=4A_w6evqg=5O9KKLnujajmg_SPSX=hCRQiBPtg@mail.gmail.com><CAF_YUvWgON8Z3JS1TePu3K=SRErN4TBhNTP1Q3GfdJeoLnymMw@mail.gmail.com><CACaHzQU+25tZQXe1EKUFi4y+UJfa+rA6z7F7Y2EvWhX=Jg6P8g@mail.gmail.com><CAF_YUvUnTmdCzXcC1LwGOnU3WpwTWa-9VnW4XYKp+kn2ob+FkQ@mail.gmail.com>
- spamdiagnosticmetadata: NSPM
- spamdiagnosticoutput: 1:99
It’s not just CIF2 that can express a string value consisting of a single dot or a single question mark. CIF1 has always been able to do the same. This is one of the areas where it matters whether the value is expressed in quoted form.
I considered suggesting "\u0000" as one of the null representations, but held back because although it is well-defined, it has the potential to be difficult to handle. For example, in C, the UTF-8 or UTF-16 encoding of that string will be treated the same as an empty string by the standard library’s string functions. This certainly *can* be handled, but why lay traps?
As for other possible null representations, U+FFFF has an advantage over U+FFFD, in that the former cannot appear in CIF2’s native serialization (the spec does not allow it), whereas the latter can do.
From: cif-developers [mailto:firstname.lastname@example.org]
On Behalf Of Robert Hanson
You mean because in CIF2 you can put "." in, with quotes to mean an actual dot, or without quotes to mean NULL, is that the issue? I do like \u0000 (unicode NULL) for CIF ".' NULL. How about
U+FFFD for "?" ? Here's what they look like on my machine:
On Thu, Apr 13, 2017 at 10:13 AM, Marcin Wojdyr <email@example.com> wrote:
Robert M. Hanson
Email Disclaimer: www.stjude.org/emaildisclaimer
Consultation Disclaimer: www.stjude.org/consultationdisclaimer
_______________________________________________ cif-developers mailing list firstname.lastname@example.org http://mailman.iucr.org/cgi-bin/mailman/listinfo/cif-developers
Reply to: [list | sender only]