Prepare for RapidJSON FindMember() API change.

Currently, ConstMemberIterator is implemented as a pointer and
FindMember() returns NULL to signal not found. But ConstMemberIterator
is going to be changed to a non-pointer type and the return value for
not found will then be changed to MemberEnd().

To make this code work for both cases, the return value is first
compared to a newly created empty ConstMemberIterator (ie. NULL, when
ConstMemberIterator is implemented as a pointer) and then compared to
MemberEnd().
1 file changed
tree: 755146d8c2d4485e9a92a91025589ab81f978e32
  1. cpp/
  2. externals/
  3. java/
  4. testdata/
  5. .gitignore
  6. .gitmodules
  7. AUTHORS
  8. CONTRIBUTORS
  9. README.md
README.md

libaddressinput

The libaddressinput project consists of two different libraries (one implemented in C++, one implemented in Java for Android) that use address metadata from Google's I18n Services Address Data Service to assist application developers in collecting and handling postal addresses from all over the world.

These libraries can provide information about what input fields are required for a correct address input form for any country in the world and can validate an address to highlight input errors like missing required fields or invalid values.

C++

The C++ library (in very portable C++03) of libaddressinput is the backend for requestAutocomplete() in Chromium. The source code for that is a good example of how to use this library to implement a complex feature in a real application:

https://src.chromium.org/viewvc/chrome/trunk/src/third_party/libaddressinput/ https://chromium.googlesource.com/chromium/src/+/master/third_party/libaddressinput/

Video: Easy International Checkout with Chrome

Java

The Java library of libaddressinput is written for use in Android and includes an Android UI address input widget ready for use, but only the UI parts are tied to Android (all the non-UI unit tests can be readily run in Java SE, ant junit) and the rest of the library could easily be adapted to run in any Java environment.

Mailing List

Using and developing libaddressinput is discussed on this mailing list:

https://groups.google.com/forum/#!forum/libaddressinput-discuss