chromium/content/common/input/actions_parser.h

// Copyright 2016 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifndef CONTENT_COMMON_INPUT_ACTIONS_PARSER_H_
#define CONTENT_COMMON_INPUT_ACTIONS_PARSER_H_

#include <cstddef>
#include <set>
#include <string>

#include "base/values.h"
#include "content/common/content_export.h"
#include "content/common/input/synthetic_pointer_action_list_params.h"
#include "content/common/input/synthetic_smooth_scroll_gesture_params.h"

namespace content {

// This class takes the argument of JSON format from
// gpuBenchmarking.pointerActionSequence and testdriver Action API.
// gpuBenchmarking.pointerActionSequence is used in all the web tests, and
// testdriver Action API is used in the WPT tests. We will eventually
// transition to testdriver, so that the web tests and WPT tests will use
// a unified way to inject user inputs.
// Testdriver Action API is an implementation of Webdriver Action API
// https://www.w3.org/TR/webdriver/#processing-actions.
// TestDriver API input is a list of ActionSequences, each of which represents
// a single device. Each action sequence has device-properties and a list of
// ActionItems that define the action to take at each tick.
// ActionSequenceList = [
//   ActionSequence = {
//      type:
//      id:
//      parameters:
//      actions: [ ActionItem { type, duration, etc. }, * ]
//   }, *
// ]
// gpuBenchmarking.pointerActionSequence takes a different JSON format, an
// example can be found here in third_party/blink/web_tests/fast/events/
// pointerevents/multi-pointer-event-in-slop-region.html.
// This class parses the JSON string and warps it into a SyntehticGestureParams
// object that can be used to inject input into Chrome.
class CONTENT_EXPORT ActionsParser {};

}  // namespace content

#endif  // CONTENT_COMMON_INPUT_ACTIONS_PARSER_H_