[gin] Add Arguments::GetAll()

Desktop / Chromium - rdevlin.cronin [chromium.org] - 18 April 2017 12:06 EDT

Add an Arguments::GetAll() function that returns all arguments as a std::vector>. This is more clear, concise, and slightly more performant than the alternative of using Arguments::GetRemaining() since it doesn't require trying to convert and avoids unnecessary calls.

Add a test for the new method.

BUG=None

Review-Url: https://codereview.chromium.org/2824883002 Cr-Commit-Position: refs/heads/master@{#465253}

3853b0b [gin] Add Arguments::GetAll()
extensions/renderer/event_emitter.cc | 6 +---
gin/arguments.cc | 13 ++++++++
gin/arguments.h | 5 +++
gin/arguments_unittest.cc | 63 ++++++++++++++++++++++++++++++++++++
4 files changed, 82 insertions(+), 5 deletions(-)

Upstream: git.chromium.org


  • Share