Class: Playwright::Execution

Inherits:
Object
  • Object
show all
Defined in:
lib/playwright.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(connection, playwright, browser = nil) ⇒ Execution

Returns a new instance of Execution.



39
40
41
42
43
# File 'lib/playwright.rb', line 39

def initialize(connection, playwright, browser = nil)
  @connection = connection
  @playwright = playwright
  @browser = browser
end

Instance Attribute Details

#browserObject (readonly)

Returns the value of attribute browser.



50
51
52
# File 'lib/playwright.rb', line 50

def browser
  @browser
end

#playwrightObject (readonly)

Returns the value of attribute playwright.



50
51
52
# File 'lib/playwright.rb', line 50

def playwright
  @playwright
end

Instance Method Details

#stopObject



45
46
47
48
# File 'lib/playwright.rb', line 45

def stop
  @browser&.close
  @connection.stop
end