Class: ActiveSnapshot::Config

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfig

Returns a new instance of Config.



5
6
7
# File 'lib/active_snapshot/config.rb', line 5

def initialize
  @storage_method = 'serialized_json'
end

Instance Attribute Details

#storage_methodObject

Returns the value of attribute storage_method.



3
4
5
# File 'lib/active_snapshot/config.rb', line 3

def storage_method
  @storage_method
end

Instance Method Details

#storage_method_json?Boolean

Returns:

  • (Boolean)


23
24
25
# File 'lib/active_snapshot/config.rb', line 23

def storage_method_json?
  @storage_method == 'serialized_json'
end

#storage_method_native_json?Boolean

Returns:

  • (Boolean)


27
28
29
# File 'lib/active_snapshot/config.rb', line 27

def storage_method_native_json?
  @storage_method == 'native_json'
end

#storage_method_yaml?Boolean

Returns:

  • (Boolean)


19
20
21
# File 'lib/active_snapshot/config.rb', line 19

def storage_method_yaml?
  @storage_method == 'serialized_yaml'
end