Class: Athena::Formats
- Inherits:
-
Object
- Object
- Athena::Formats
- Defined in:
- lib/athena/formats.rb,
lib/athena/formats/dbm.rb,
lib/athena/formats/xml.rb,
lib/athena/formats/lingo.rb,
lib/athena/formats/sisis.rb,
lib/athena/formats/ferret.rb
Overview
–
#
A component of athena, the database file converter. #
#
Copyright © 2007-2008 University of Cologne, #
Albertus-Magnus-Platz, #
50932 Cologne, Germany #
#
Authors: #
Jens Wille <[email protected]> #
#
athena is free software; you can redistribute it and/or modify it under the # terms of the GNU General Public License as published by the Free Software # Foundation; either version 3 of the License, or (at your option) any later # version. #
#
athena is distributed in the hope that it will be useful, but WITHOUT ANY # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS # FOR A PARTICULAR PURPOSE. See the GNU General Public License for more # details. #
#
You should have received a copy of the GNU General Public License along # with athena. If not, see <www.gnu.org/licenses/>. #
#
++
Direct Known Subclasses
DBM, Ferret, Lingo::Base, Sisis, XML
Defined Under Namespace
Modules: Lingo Classes: DBM, DuplicateFormatDefinitionError, Ferret, FormatArgumentError, Sisis, XML
Class Method Summary collapse
- .[](direction, format) ⇒ Object
- .convert(*args) ⇒ Object
- .deferred? ⇒ Boolean
- .formats ⇒ Object
- .valid_format?(direction, format) ⇒ Boolean
Instance Method Summary collapse
Class Method Details
.[](direction, format) ⇒ Object
39 40 41 |
# File 'lib/athena/formats.rb', line 39 def [](direction, format) formats[direction][format] end |
.convert(*args) ⇒ Object
51 52 53 |
# File 'lib/athena/formats.rb', line 51 def convert(*args) raise NotImplementedError, 'must be defined by sub-class' end |
.deferred? ⇒ Boolean
47 48 49 |
# File 'lib/athena/formats.rb', line 47 def deferred? false end |
.formats ⇒ Object
35 36 37 |
# File 'lib/athena/formats.rb', line 35 def formats Athena::Formats.instance_variable_get(:@formats) end |
.valid_format?(direction, format) ⇒ Boolean
43 44 45 |
# File 'lib/athena/formats.rb', line 43 def valid_format?(direction, format) formats[direction].has_key?(format) end |
Instance Method Details
#parse(*args) ⇒ Object
74 75 76 |
# File 'lib/athena/formats.rb', line 74 def parse(*args) raise NotImplementedError, 'must be defined by sub-class' end |