Class: OLE_QA::Framework::Line_Object

Inherits:
Data_Object show all
Defined in:
lib/common/line_object.rb

Overview

A Data Object in OLE that represents a single line in a given area. A line object can usually be added or deleted, and may or may not have its own line objects beneath it in the page-object hierarchy.

Direct Known Subclasses

OLEFS::Line_Object, OLELS::Line_Object

Instance Attribute Summary collapse

Attributes inherited from Common_Object

#elements, #functions, #ole

Instance Method Summary collapse

Methods inherited from Common_Object

#set_functions

Methods included from Helpers

#browser, #load_yml, #set_element, #set_function

Constructor Details

#initialize(ole_session, line_number = 1) ⇒ Line_Object

Returns a new instance of Line_Object.

Parameters:

  • ole_session (Object)

    The OLE_QA::Framework::Session session to pass to the Data Object.

  • line_number (Fixnum) (defaults to: 1)

    The number this line object will use for element definitions.



29
30
31
32
33
# File 'lib/common/line_object.rb', line 29

def initialize(ole_session, line_number = 1)
  @line_number = line_number
  @line_id = line_number - 1
  super(ole_session)
end

Instance Attribute Details

#line_idObject (readonly)

Returns the value of attribute line_id.



25
26
27
# File 'lib/common/line_object.rb', line 25

def line_id
  @line_id
end

#line_numberObject (readonly)

The line number that this object will have on the screen.

  • Used for line identifier replacement.



24
25
26
# File 'lib/common/line_object.rb', line 24

def line_number
  @line_number
end

Instance Method Details

#set_elementsObject

Note:

Use @line_number or @line_id in an element definition to specify either the textual, human-readable (1-based) line number of the line object, or the coded, application-readable (0-based) line identifier number of the line object.

Set element definitions, if any.



39
40
# File 'lib/common/line_object.rb', line 39

def set_elements
end