Class: Uniword::Batch::Operation::Task

Inherits:
Object
  • Object
show all
Defined in:
lib/uniword/batch/operation/task.rb

Overview

Abstract base class for one batchable operation on one file. Subclasses implement run(path) -> FileResult.

Direct Known Subclasses

RepairTask, VerifyTask

Instance Method Summary collapse

Instance Method Details

#nameSymbol

Returns task name shown in reports.

Returns:

  • (Symbol)

    task name shown in reports

Raises:

  • (NotImplementedError)


10
11
12
# File 'lib/uniword/batch/operation/task.rb', line 10

def name
  raise NotImplementedError
end

#run(path) ⇒ FileResult

Run the operation on one file. Returns a FileResult.

Parameters:

  • path (String)

    input file path

Returns:

Raises:

  • (NotImplementedError)


18
19
20
# File 'lib/uniword/batch/operation/task.rb', line 18

def run(path)
  raise NotImplementedError
end