Class: ActiveRecord::DataClassification::Configuration
- Inherits:
-
Object
- Object
- ActiveRecord::DataClassification::Configuration
- Defined in:
- lib/active_record/data_classification/configuration.rb
Instance Attribute Summary collapse
-
#confidential_class_names ⇒ Object
Returns the value of attribute confidential_class_names.
-
#default_classification ⇒ Object
Returns the value of attribute default_classification.
-
#excluded_table_patterns ⇒ Object
Returns the value of attribute excluded_table_patterns.
-
#ignored_tables ⇒ Object
Returns the value of attribute ignored_tables.
-
#load_models_block ⇒ Object
readonly
Returns the value of attribute load_models_block.
-
#table_name_transformer_block ⇒ Object
readonly
Returns the value of attribute table_name_transformer_block.
Instance Method Summary collapse
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
- #load_models(&block) ⇒ Object
- #transform_table_name(&block) ⇒ Object
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
16 17 18 19 20 21 22 23 24 25 26 |
# File 'lib/active_record/data_classification/configuration.rb', line 16 def initialize @default_classification = :Private @load_models_block = -> { } @table_name_transformer_block = ->(table_name) { table_name } @confidential_class_names = [] @excluded_table_patterns = [] @ignored_tables = [ "schema_migrations", "ar_internal_metadata", ] end |
Instance Attribute Details
#confidential_class_names ⇒ Object
Returns the value of attribute confidential_class_names.
8 9 10 |
# File 'lib/active_record/data_classification/configuration.rb', line 8 def confidential_class_names @confidential_class_names end |
#default_classification ⇒ Object
Returns the value of attribute default_classification.
8 9 10 |
# File 'lib/active_record/data_classification/configuration.rb', line 8 def default_classification @default_classification end |
#excluded_table_patterns ⇒ Object
Returns the value of attribute excluded_table_patterns.
8 9 10 |
# File 'lib/active_record/data_classification/configuration.rb', line 8 def excluded_table_patterns @excluded_table_patterns end |
#ignored_tables ⇒ Object
Returns the value of attribute ignored_tables.
8 9 10 |
# File 'lib/active_record/data_classification/configuration.rb', line 8 def ignored_tables @ignored_tables end |
#load_models_block ⇒ Object (readonly)
Returns the value of attribute load_models_block.
13 14 15 |
# File 'lib/active_record/data_classification/configuration.rb', line 13 def load_models_block @load_models_block end |
#table_name_transformer_block ⇒ Object (readonly)
Returns the value of attribute table_name_transformer_block.
13 14 15 |
# File 'lib/active_record/data_classification/configuration.rb', line 13 def table_name_transformer_block @table_name_transformer_block end |
Instance Method Details
#load_models(&block) ⇒ Object
28 29 30 |
# File 'lib/active_record/data_classification/configuration.rb', line 28 def load_models(&block) @load_models_block = block end |
#transform_table_name(&block) ⇒ Object
32 33 34 |
# File 'lib/active_record/data_classification/configuration.rb', line 32 def transform_table_name(&block) @table_name_transformer_block = block end |