Skip to content

[πŸš€ Feature]: implement namespacing methods as propertiesΒ #14065

@titusfortner

Description

@titusfortner

Feature and motivation

.NET copied the Java approach of using methods for namespacing:

driver.Manage().Cookies().AddCookie(cookie)

When a more idiomatic way would be to use properties.
This came up when discussing adding the BiDi functionality. Rather than mixing them, or using the old way, I propose we add the properties and deprecate the methods.

Usage example

driver.Manage.Cookies.AddCookie(cookie)

Community Proposal

Cookies

driver.Cookies

IReadOnlyList<Cookie> GetAll();
Cookie? Get(string name);
void Add(Cookie cookie);
void Delete(Cookie cookie);
void Delete(string name);
void DeleteAll();

Logs

driver.Logs

IReadOnlyList<string> GetAvailableTypes();
IReadOnlyList<LogEntry> GetAll(string type);

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions