add

add(keys={}) Instance Public methods

add_reference

add_reference(table_name, ref_name, options = {}) Instance Public methods Adds a reference. Optionally adds a type column, if :polymorphic option is provided. add_reference and add_belongs_to are acceptable. Create a user_id column add_reference(:products, :user) Create a supplier_id and supplier_type columns add_belongs_to(:products, :supplier, polymorphic: true) Create a supplier_id, supplier_type columns and appropriate index add_reference(:products, :supplier, polymorphic: tr

length

length() Instance Public methods

<=

obj Instance Public methods Compares two objects based on the receiver's <=> method, returning true if it returns -1 or 0.

unwrap

unwrap() Class Public methods

login

login(options, password = nil) Instance Public methods Login to the host with a given username and password. The username and password can either be provided as two string arguments in that order, or as a hash with keys âNameâ and âPasswordâ. This method looks for the strings âloginâ and âPasswordâ from the host to determine when to send the username and password. If the login sequence does not follow this pattern (for instance, you are connecting to a service other than telnet),

execute

execute() Instance Public methods

_set_global_var

_set_global_var(p1, p2) Instance Public methods

new

new() Class Public methods Create a new scanner

reset

reset() Instance Public methods Unloads the association. Returns self. class Person < ActiveRecord::Base has_many :pets end person.pets # fetches pets from the database # => [#<Pet id: 1, name: "Snoop", group: "dogs", person_id: 1>] person.pets # uses the pets cache # => [#<Pet id: 1, name: "Snoop", group: "dogs", person_id: 1>] person.pets.reset # clears the pets cache person.pets # fetches pets from the database # => [#<Pet id: 1, name: "Snoop",