WD
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
webdriver::WebDriverCommand Class Reference

#include <webdriver_command.h>

Inheritance diagram for webdriver::WebDriverCommand:
Collaboration diagram for webdriver::WebDriverCommand:

Public Member Functions

 WebDriverCommand (const std::vector< std::string > &path_segments, const base::DictionaryValue *const parameters)
 
virtual ~WebDriverCommand ()
 
virtual bool Init (Response *const response) OVERRIDE
 
virtual void Finish (Response *const response) OVERRIDE
 
virtual bool ShouldRunPreAndPostCommandHandlers ()
 
- Public Member Functions inherited from webdriver::Command
 Command (const std::vector< std::string > &path_segments, const DictionaryValue *const parameters)
 
 Command (const Command &other)
 
virtual ~Command ()
 
virtual bool DoesDelete () const
 
virtual bool DoesGet () const
 
virtual bool DoesPost () const
 
virtual void ExecuteDelete (Response *const response)
 
virtual void ExecuteGet (Response *const response)
 
virtual void ExecutePost (Response *const response)
 

Protected Member Functions

 DISALLOW_COPY_AND_ASSIGN (WebDriverCommand)
 
- Protected Member Functions inherited from webdriver::Command
std::string GetPathVariable (const size_t i) const
 
bool HasParameter (const std::string &key) const
 
bool IsNullParameter (const std::string &key) const
 
bool GetStringParameter (const std::string &key, string16 *out) const
 
bool GetStringParameter (const std::string &key, std::string *out) const
 
bool GetStringASCIIParameter (const std::string &key, std::string *out) const
 
bool GetBooleanParameter (const std::string &key, bool *out) const
 
bool GetIntegerParameter (const std::string &key, int *out) const
 
bool GetDoubleParameter (const std::string &key, double *out) const
 
bool GetDictionaryParameter (const std::string &key, const DictionaryValue **out) const
 
bool GetListParameter (const std::string &key, const ListValue **out) const
 

Protected Attributes

Sessionsession_
 
std::string session_id_
 
- Protected Attributes inherited from webdriver::Command
const std::vector< std::string > path_segments_
 
yasper::ptr< const
DictionaryValue > 
parameters_
 

Detailed Description

All URLs that are found in the document: http://code.google.com/p/selenium/wiki/JsonWireProtocol and are to be supported for all browsers and platforms should inhert this class. For cases which do not invlove interaction with the browser, such a transfering a file, inhert from the Command class directly.

Constructor & Destructor Documentation

webdriver::WebDriverCommand::WebDriverCommand ( const std::vector< std::string > &  path_segments,
const base::DictionaryValue *const  parameters 
)
virtual webdriver::WebDriverCommand::~WebDriverCommand ( )
virtual

Member Function Documentation

webdriver::WebDriverCommand::DISALLOW_COPY_AND_ASSIGN ( WebDriverCommand  )
protected
virtual void webdriver::WebDriverCommand::Finish ( Response *const  response)
virtual

Called after this command is executed. This is only called if Init() is successful and regardless of whether the execution results in a Error.

Parameters
responsepointer to response object

Reimplemented from webdriver::Command.

virtual bool webdriver::WebDriverCommand::Init ( Response *const  response)
virtual

Initializes this webdriver command by fetching the command session.

Reimplemented from webdriver::Command.

Reimplemented in webdriver::WheelCommand, webdriver::ClickCommand, webdriver::MoveToCommand, webdriver::ViewCommand, webdriver::NamedCookieCommand, and webdriver::ElementCommand.

virtual bool webdriver::WebDriverCommand::ShouldRunPreAndPostCommandHandlers ( )
virtual

Returns whether this command should run the session pre and post command handlers. These handlers include waiting for the page to load.

Reimplemented in webdriver::WindowCommand, and webdriver::SessionWithID.

Member Data Documentation

Session* webdriver::WebDriverCommand::session_
protected
std::string webdriver::WebDriverCommand::session_id_
protected

The documentation for this class was generated from the following file: