Class: DataObjects::Command

### Home Classes Methods

### In Files

- lib/data_objects/command.rb

### Parent

Object

### Methods

- ::new
- #execute_non_query
- #execute_reader
- #set_types
- #to_s

### Class/Module Index

Quicksearch

- DataObjects
- DataObjects::Command
- DataObjects::Connection
- DataObjects::ConnectionError
- DataObjects::DataError
- DataObjects::Error
- DataObjects::Extension
- DataObjects::IntegrityError
- DataObjects::Logger
- DataObjects::Logging
- DataObjects::Pooling
- DataObjects::Pooling::InvalidResourceError
- DataObjects::Pooling::Pool
- DataObjects::Quoting
- DataObjects::Reader
- DataObjects::Result
- DataObjects::SQLError
- DataObjects::SavePoint
- DataObjects::Spec
- DataObjects::Spec::PendingHelpers
- DataObjects::SyntaxError
- DataObjects::Transaction
- DataObjects::TransactionError
- DataObjects::URI
- Extlib
- Extlib::ByteArray
- CustomTextType
- MyString
- Object
- SSLHelpers

No matching classes.

# DataObjects::Command

Abstract base class for adapter-specific Command subclasses

### Attributes

connection[R]

The Connection on which the command will be run

### Public Class Methods

new(connection, text) click to toggle source

Create a new Command object on the specified connection

    # File lib/data_objects/command.rb, line 9
    def initialize(connection, text)
      raise ArgumentError.new("+connection+ must be a DataObjects::Connection") unless DataObjects::Connection === connection
      @connection, @text = connection, text
    end

### Public Instance Methods

execute_non_query(*args) click to toggle source

Execute this command and return no dataset

    # File lib/data_objects/command.rb, line 15
    def execute_non_query(*args)
      raise NotImplementedError.new
    end

execute_reader(*args) click to toggle source

Execute this command and return a DataObjects::Reader for a dataset

    # File lib/data_objects/command.rb, line 20
    def execute_reader(*args)
      raise NotImplementedError.new
    end

set_types(column_types) click to toggle source

Assign an array of types for the columns to be returned by this command

    # File lib/data_objects/command.rb, line 25
    def set_types(column_types)
      raise NotImplementedError.new
    end

to_s() click to toggle source

Display the command text

    # File lib/data_objects/command.rb, line 30
    def to_s
      @text
    end

[Validate]

Generated with the Darkfish Rdoc Generator 2.