コード例 #1
0
 internal SynchronisedElementScope(ElementFinder elementFinder,
                                   DriverScope outerScope,
                                   Options options)
     : base(elementFinder, outerScope)
 {
     this.options = options;
 }
コード例 #2
0
 internal FillInWith(Element element, Driver driver, RobustWrapper robustWrapper, DriverScope scope, Options options)
 {
     this.element       = element;
     this.driver        = driver;
     this.robustWrapper = robustWrapper;
     this.scope         = scope;
     this.options       = options;
 }
コード例 #3
0
 internal FillInWith(string locator, Driver driver, RobustWrapper robustWrapper, DriverScope scope, Options options)
 {
     this.locator       = locator;
     this.driver        = driver;
     this.robustWrapper = robustWrapper;
     this.scope         = scope;
     this.options       = options;
 }
コード例 #4
0
ファイル: SelectFrom.cs プロジェクト: gondar/coypu
 internal SelectFrom(string option, Driver driver, RobustWrapper robustWrapper, DriverScope scope, Options options)
 {
     this.option        = option;
     this.driver        = driver;
     this.robustWrapper = robustWrapper;
     this.scope         = scope;
     this.options       = options;
 }
コード例 #5
0
ファイル: SelectFrom.cs プロジェクト: hnhan/coypu
 internal SelectFrom(string option, Driver driver, TimingStrategy timingStrategy, DriverScope scope, Options options, DisambiguationStrategy disambiguationStrategy)
 {
     this.option                 = option;
     this.driver                 = driver;
     this.timingStrategy         = timingStrategy;
     this.scope                  = scope;
     this.options                = options;
     this.disambiguationStrategy = disambiguationStrategy;
 }
コード例 #6
0
 internal DriverScope(ElementFinder elementFinder, DriverScope outerScope)
 {
     if (outerScope != null)
     {
         SetScope(outerScope);
     }
     if (elementFinder != null)
     {
         SetFinder(elementFinder);
     }
 }
コード例 #7
0
ファイル: DriverScope.cs プロジェクト: bszypelow/coypu
 internal DriverScope(ElementFinder elementFinder, DriverScope outer)
 {
     this.elementFinder   = elementFinder;
     driver               = outer.driver;
     robustWrapper        = outer.robustWrapper;
     urlBuilder           = outer.urlBuilder;
     stateFinder          = outer.stateFinder;
     waiter               = outer.waiter;
     options              = outer.SessionConfiguration;
     SessionConfiguration = outer.SessionConfiguration;
 }
コード例 #8
0
 internal DriverScope(ElementFinder elementFinder, DriverScope outerScope)
 {
     this.elementFinder     = elementFinder;
     this.outerScope        = outerScope;
     driver                 = outerScope.driver;
     timingStrategy         = outerScope.timingStrategy;
     urlBuilder             = outerScope.urlBuilder;
     DisambiguationStrategy = outerScope.DisambiguationStrategy;
     stateFinder            = outerScope.stateFinder;
     waiter                 = outerScope.waiter;
     SessionConfiguration   = outerScope.SessionConfiguration;
 }
コード例 #9
0
ファイル: DriverScope.cs プロジェクト: rubicon-oss/Fork.coypu
 internal DriverScope(ElementFinder elementFinder,
                      DriverScope outerScope)
 {
     _driver                = outerScope._driver;
     _elementFinder         = elementFinder;
     DisambiguationStrategy = outerScope.DisambiguationStrategy;
     OuterScope             = outerScope;
     SessionConfiguration   = outerScope.SessionConfiguration;
     StateFinder            = outerScope.StateFinder;
     TimingStrategy         = outerScope.TimingStrategy;
     UrlBuilder             = outerScope.UrlBuilder;
     Waiter = outerScope.Waiter;
 }
コード例 #10
0
 internal SelectFrom(string option,
                     IDriver driver,
                     TimingStrategy timingStrategy,
                     DriverScope scope,
                     Options options,
                     DisambiguationStrategy disambiguationStrategy)
 {
     _option                 = option;
     _driver                 = driver;
     _timingStrategy         = timingStrategy;
     _scope                  = scope;
     _options                = options;
     _disambiguationStrategy = disambiguationStrategy;
 }
コード例 #11
0
        public void Init(string xpath, DriverScope outerScope, Options options)
        {
            if (xpath == null)
            {
                xpath = defaultLocator;
            }

            init         = true;
            this.options = Merge(options);
            SetScope(outerScope);
            SetFinder(new XPathFinder(driver, xpath, outerScope, this.options));

            UpdateChildrenScope(this);
        }
コード例 #12
0
        protected void UpdateChildrenScope(DriverScope scope)
        {
            var fields = GetType().GetFields(BindingFlags.Public | BindingFlags.NonPublic | BindingFlags.Instance);

            foreach (var f in fields)
            {
                if (typeof(IHaveScope).IsAssignableFrom(f.FieldType))
                {
                    var e = (IHaveScope)f.GetValue(this);
                    if (e != null)
                    {
                        e.SetScope(scope);
                    }
                }
            }
        }
コード例 #13
0
        public virtual void SetScope(DriverScope scope)
        {
            outerScope             = scope;
            driver                 = outerScope.driver;
            timingStrategy         = outerScope.timingStrategy;
            urlBuilder             = outerScope.urlBuilder;
            DisambiguationStrategy = outerScope.DisambiguationStrategy;
            stateFinder            = outerScope.stateFinder;
            waiter                 = outerScope.waiter;
            SessionConfiguration   = outerScope.SessionConfiguration;
            outerScope             = scope;

            if (elementFinder != null)
            {
                elementFinder.SetDriver(driver);
                elementFinder.ChangeScope(scope);
            }
        }
コード例 #14
0
 public void SetScope(DriverScope s)
 {
     scope = s;
 }
コード例 #15
0
 internal BrowserWindow(ElementFinder elementFinder,
                        DriverScope outerScope) : base(elementFinder, outerScope)
 {
 }
コード例 #16
0
 internal ElementScope(ElementFinder elementFinder, DriverScope outerScope)
     : base(elementFinder, outerScope)
 {
 }
コード例 #17
0
 public TableScope(DriverScope b, bool header, params string[] locators)
 {
     SetScope(b);
     this.isHeader = header;
     this.locators = locators;
 }
コード例 #18
0
 internal SnapshotElementScope(Element element, DriverScope scope, Options options)
     : base(null, scope)
 {
     this.element = element;
     this.options = options;
 }
コード例 #19
0
ファイル: RobustElementScope.cs プロジェクト: gondar/coypu
 internal RobustElementScope(ElementFinder elementFinder, DriverScope outerScope, Options options)
     : base(elementFinder, outerScope)
 {
     this.options = options;
 }
コード例 #20
0
 public static IEnumerable <SnapshotElementScope> AsSnapshotElementScopes(this IEnumerable <Element> elements, DriverScope driverScope, Options options)
 {
     return(elements.Select(elementFound => new SnapshotElementScope(elementFound, driverScope, options)));
 }
コード例 #21
0
ファイル: FillInWith.cs プロジェクト: AidenMontgomery/coypu
 internal FillInWith(ElementScope element, Driver driver, RobustWrapper robustWrapper, DriverScope scope, Options options)
     : this(element.Now(), driver, robustWrapper, scope, options)
 {
 }
コード例 #22
0
 internal SnapshotElementScope(ElementFound elementFound, DriverScope scope) : base(null, scope)
 {
     _elementFound = elementFound;
 }
コード例 #23
0
 public TableScope(DriverScope b, params string[] locators)
 {
     SetScope(b);
     this.locators = locators;
 }
コード例 #24
0
ファイル: ElementScope.cs プロジェクト: gondar/coypu
 internal DeferredElementScope(ElementFinder elementFinder, DriverScope outer)
     : base(elementFinder, outer)
 {
 }