public static void InitUiElements(object page, IUiElementLocator locator, IPageObjectDecorator decorator) { if (page == null) { throw new ArgumentNullException(nameof(page), "page cannot be null"); } if (locator == null) { throw new ArgumentNullException(nameof(locator), "locator cannot be null"); } if (decorator == null) { throw new ArgumentNullException(nameof(decorator), "decorator cannot be null"); } decorator.Decorate(locator, page); }
public static void InitUiElements(IUiElementFinder finder, object page, IPageObjectDecorator decorator) => InitUiElements(page, new DefaultUiElementLocator(finder), decorator);