Class: Izokatu::Exporter Abstract
- Inherits:
-
Object
- Object
- Izokatu::Exporter
- Extended by:
- Callable
- Includes:
- Contracts, Helpers
- Defined in:
- lib/izokatu/exporter.rb
Overview
This class is abstract.
Subclasses are containing implementation of #perform
Abstract class for exporters
Direct Known Subclasses
Constant Summary
Constants included from Helpers
Helpers::EC_CIPHER, Helpers::KEY_SYMBOL, Helpers::RBNACL_KEY_CLASSES
Instance Attribute Summary collapse
-
#data ⇒ String
readonly
Data for export.
Instance Method Summary collapse
-
#initialize(data:, encode:) ⇒ Exporter
constructor
Initializing data for export.
-
#perform ⇒ Object
Performing export of initialized data.
Methods included from Callable
Methods included from Helpers
#decode_data, #encode_data, #export_data, #export_decrypted!, #export_encrypted!, #generate_ec_keypair, #generate_rbnacl_keypair, #generate_rsa_keypair, #import_data, #import_encrypted!, #import_encrypted_in_options!
Constructor Details
#initialize(data:, encode:) ⇒ Exporter
Initializing data for export
23 24 25 |
# File 'lib/izokatu/exporter.rb', line 23 def initialize(data:, encode:) @data = encode ? encode_data(data) : data end |
Instance Attribute Details
#data ⇒ String (readonly)
Returns data for export.
14 15 16 |
# File 'lib/izokatu/exporter.rb', line 14 def data @data end |
Instance Method Details
#perform ⇒ Object
Performing export of initialized data
32 33 34 |
# File 'lib/izokatu/exporter.rb', line 32 def perform raise 'Not implemented!' end |