Class: Avm::Scms::AutoCommit::Rules::Base
- Inherits:
-
Object
- Object
- Avm::Scms::AutoCommit::Rules::Base
show all
- Defined in:
- lib/avm/scms/auto_commit/rules/base.rb
Defined Under Namespace
Classes: WithFile
Class Method Summary
collapse
Instance Method Summary
collapse
Class Method Details
.keys ⇒ Object
12
13
14
|
# File 'lib/avm/scms/auto_commit/rules/base.rb', line 12
def keys
[long_key, short_key]
end
|
.long_key ⇒ Object
16
17
18
|
# File 'lib/avm/scms/auto_commit/rules/base.rb', line 16
def long_key
name.demodulize.variableize
end
|
.short_key ⇒ Object
20
21
22
|
# File 'lib/avm/scms/auto_commit/rules/base.rb', line 20
def short_key
long_key[0, 1]
end
|
Instance Method Details
#with_file(file) ⇒ Object
25
26
27
|
# File 'lib/avm/scms/auto_commit/rules/base.rb', line 25
def with_file(file)
self.class.const_get('WithFile').new(self, file)
end
|