Class: Format

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

Overview

The Format class is provided as a base class for all publishing formats that are included in the Item class. Examples of format implementations include JsonObjectFormat and HttpStreamFormat.

Instance Method Summary collapse

Instance Method Details

#exportObject

The export method which should return a format-specific hash containing the required format-specific data.

Raises:

  • (NotImplementedError)


21
22
23
# File 'lib/format.rb', line 21

def export
  raise NotImplementedError
end

#nameObject

The name of the format which should return a string. Examples include ‘json-object’ and ‘http-response’

Raises:

  • (NotImplementedError)


15
16
17
# File 'lib/format.rb', line 15

def name
  raise NotImplementedError
end