Module: ValidatesXmlOf
- Defined in:
- lib/validates_xml_of.rb,
lib/validates_xml_of/railtie.rb,
lib/validates_xml_of/version.rb,
lib/validates_xml_of/validator.rb,
lib/validates_xml_of/matchers/validate_xml_of.rb
Defined Under Namespace
Modules: Matchers
Classes: Railtie, Validator
Constant Summary
collapse
- DEFAULT_MESSAGE =
'does not appear to be a valid xml'
- DEFAULT_SCHEMA_MESSAGE =
'does not appear to be a valid xml based on schema informed'
- ERROR_MESSAGE_I18N_KEY =
:invalid_xml
- ERROR_SCHEMA_MESSAGE_I18N_KEY =
:invalid_xml_based_on_schema
- VERSION =
"0.1.0"
Class Attribute Summary collapse
Class Method Summary
collapse
Class Attribute Details
.schema_paths ⇒ Object
Returns the value of attribute schema_paths.
7
8
9
|
# File 'lib/validates_xml_of.rb', line 7
def schema_paths
@schema_paths
end
|
Class Method Details
.default_message ⇒ Object
.default_schema_message ⇒ Object
.load_i18n_locales ⇒ Object
9
10
11
12
|
# File 'lib/validates_xml_of.rb', line 9
def load_i18n_locales
require 'i18n'
I18n.load_path += Dir.glob(File.expand_path(File.join(File.dirname(__FILE__), '..', 'config', 'locales', '*.yml')))
end
|
.setup {|_self| ... } ⇒ Object
36
37
38
|
# File 'lib/validates_xml_of.rb', line 36
def self.setup
yield self
end
|