Age | Commit message (Collapse) | Author |
|
This patch removes the libaddressinput_dir variable and renames:
libaddressinput_[test_]sources -> libaddressinput_[test_]files
String values contained within lists associated with keys ending in
"_files" suffix are treated as pathnames relative to the file in which
they are defined.
https://code.google.com/p/gyp/wiki/InputFormatReference#Pathname_Relativization
R=roubert@google.com
Review URL: https://codereview.appspot.com/93410044
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@216 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This patch moves -fPIC flag from target defaults (for all targets) to
the library target, because the unit test executable does not require
it. The move is possible due to the automatic variable "_type", which
contains the value of the "type" configuration for the target.
https://code.google.com/p/gyp/wiki/InputFormatReference#Variables
R=roubert@google.com
Review URL: https://codereview.appspot.com/91470044
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@215 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This patch prevents duplication of source and test file lists in
Chromium's gyp files.
R=roubert@google.com
Review URL: https://codereview.appspot.com/92370043
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@213 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This patch changes BuildComponents() function to read the UI language
tag and determine the language tag that should be stored with the
address data. The function also chooses between the default and the
Latin order of UI components in the address form.
A language tag is a sequence of one of more subtags separated by
hyphen ("-"). All characters are in ASCII and case-insensitive. The
first subtag is the base language, for example "zh". The first
four-character subtag is the script, for example "Hans".
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@208 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
Specifically the utility functions IsFieldRequired() and IsFieldUsed()
that answers the questions of whether a particular field is a required
field or a field that is used, respectively, for a particular region.
This is implemented through the class AddressValidator, which provides
the public interface, and the class MetadataQueryTask which encapsulates
the information necessary to perform the checking for an Is*() method
that answers a yes/no question and call a callback when that has been
done.
The interface is asynchronous, allowing it to be used with a Downloader
implementation that waits for several pending requests simultaneously.
By virtue of being part of the class AddressValidator, this shares the
metadata cache with address validation. (The future might show this to
be a not so good design decision, but with the actual implementation
isolated in class MetadataQueryTask it should be straightforward to move
things around then.)
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@203 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This is implemented through the class AddressValidator, which provides
the public interface, and the class ValidationTask which encapsulates
the information necessary to perform validation of one particular
address and call a callback when that has been done.
The interface is asynchronous, allowing it to be used with a Downloader
implementation that waits for several pending requests simultaneously.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@202 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This class contains regular expressions to match post office boxes, and
a function to get the appropriate list of these to use for a particular
country.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@201 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
A MetadataLoader object owns a Retriever object, through which it loads
address metadata as needed, creating Rule objects and caching these.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@200 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
A LookupKey maps between an AddressData struct and the key string used
to request address data from an address data server.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@195 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@194 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@193 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
The operator is moved out into the root namespace (where it belongs) and
the implementation is updated to use a lookup table instead of a switch
statement, and to output more information when encountering an invalid
enum value.
AddressFieldTest is added to ensure that the overloaded operator<< works
as expected.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@191 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
It is not always desirable to cache libaddressinput data. Sometimes it
might give better performance characteristics to not cache. (Typically
in tests or when running the data server locally.) This implementation
of the Storage interface therefore doesn't actually store anything.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@189 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This patch adds the re2 dependency to libaddressinput. The dependency will
be used to validate postal code format of addresses. The addresses are
provided by the user. The format regular expressions are from:
https://i18napis.appspot.com/ssl-address
For example, the US postal code has the following regular expression:
\\d{5}([ \\-]\\d{4})?
BUG=327046
Review URL: https://codereview.chromium.org/98543010
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@180 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This patch removes unnecessary functions and dependencies from SplitString
and includes it in the build of libaddressinput.
BUG=327046
Review URL: https://codereview.chromium.org/113493002
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@179 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This patch adds a RuleRetriever. It retrieves a rule object based on its
key.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@175 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This patch adds a ValidatingStorage object, which wraps any implementation
of Storage by adding checksum and timestamp when saving data. When reading
data, the object verifies the timestamp freshness and checksum validity.
If these checks fail, then ValidatingStorage behaves as if there's no data
in storage. This behavior would force a Retriever object to re-download
validation rules from the server.
A data timestamp is fresh if it's within a month of the current time.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@174 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This patch strips the StringPiece dependency from MD5 implementation and
builds it as part of libaddressinput.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@173 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This patch adds an object to download data from a Downloader and caches
the results in Storage.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@171 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
These are functions for working with lookup keys. A lookup key is a string
that identifies a serialized validation rule.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@170 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This is a fake storage implementation to be used in tests. Instead of
storing the serialized validation data on disk, it keeps them in memory
for the duration of its lifetime.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@169 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This is a fake downloader implementation to be used in tests. Instead of
downloading serialized validation rules from the server, it reads them
from a local test data file.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@168 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This patch is part of a series of patches that enable showing an address
input form. This patch adds a function to build a list of
AddressUiComponents for a region code.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@163 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@162 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This patch is part of a series of patches that enable showing an address
input form. This patch adds a Localization object, which can be used to
switch between message languages or specify a custom message getter.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@160 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This patch is part of a series of patches that enable showing an address
input form. This patch adds a rule data structure that stores rules parsed
from RegionDataConstants.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@158 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This patch is part of a series of patches that enable showing an address
input form. This patch adds an AddressField enum and functions to parse it
from a format string.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@157 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This patch is part of a series of patches that enable showing an address
input form. This patch adds a GRIT dependency and messages. The messages
come from:
https://code.google.com/p/libaddressinput/source/browse/trunk/java/res/values/address_strings.xml?r=124
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@156 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This patch is part of a series of patches that enable showing an address
input form. This patch adds a rapidjson dependency and a wrapper.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@155 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This patch is part of a series of patches that enable showing an address
input form. This patch adds RegionDataConstants. The data comes from:
https://code.google.com/p/libaddressinput/source/browse/trunk/java/src/com/android/i18n/addressinput/RegionDataConstants.java?r=137
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@152 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
To make it possible to execute the unit tests directly from the build
directory, without having to first set DYLD_LIBRARY_PATH or install the
library, install_name_tool is executed in a postbuilds step to set the
path to the library to be relative to the unit test executable (so that
also the library will be loaded directly from the build directory).
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@151 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
This is the boilerplate of the C++ port of the library. The configuration file
is able to build an empty unit test binary. There're 3 dependencies:
GYP: Generates the build files.
Ninja: Executes the build files.
GTest: Used for unit tests.
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@146 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@145 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@144 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@143 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@141 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@140 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@139 38ededc0-08b8-5190-f2ac-b31f878777ad
|
|
git-svn-id: http://libaddressinput.googlecode.com/svn/trunk@138 38ededc0-08b8-5190-f2ac-b31f878777ad
|