class_attribute 0.1.3 → 0.1.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 32cb6cedf26550592353164f0d128e393205891a
4
- data.tar.gz: 8f20bdc950fe5ddaa0b63b57269110e45a77a6b1
3
+ metadata.gz: 66a02e69a422172ca4afaadaae114e9aaf5bbb03
4
+ data.tar.gz: 1f8d902717ce2b22ea65af3ab7e9f8269179804c
5
5
  SHA512:
6
- metadata.gz: 443d51e999ceaa91a7f83800a645458aa3bcdf1681a6ebded15d4dc2ba2cd61fd7063d7e94d5acf68b4563c086169addf0e05c9a3659ebb4b69a3c67602e39f1
7
- data.tar.gz: 52bc8b39c746a250995647066477e41122f0fcaa1970a5488ab078e4d9cbbb29bdbd2677bf3bdeff6f3f4c4e5f2ed7e8f2237997d4b05fa4687d45414f00d4ab
6
+ metadata.gz: cbafc1c0788f4e0711d6cc3d9ac0951d42ca4ca3e3054ab960ba585ac67d0e404f7994e7293c0094b7e95b7b367e26eac311eba4bf15a6920e67caa00f1bc8ab
7
+ data.tar.gz: a3ffdb588bab4c1444f7abd9d886705745eae157b7376afa193ebcce0ae3fcb6b0cbe1cf26ce7d234b50d5b1bb4c4550c8511301c2f29a07e63c275eb15207a3
data/.travis.yml CHANGED
@@ -2,7 +2,7 @@ language: ruby
2
2
  script: 'bundle exec rake test:coverage --trace'
3
3
  rvm:
4
4
  - 2.2.0
5
- - 2.2.2
5
+ - 2.2.3
6
6
  - rbx-2
7
7
  - jruby-9000
8
8
 
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # ClassAttribute
2
2
 
3
- Inheritable class level variable accessors
3
+ Inheritable class level variable accessors. Originally extracted from the Lotus project.
4
4
 
5
5
  ## Status
6
6
  [![Coverage Status](https://coveralls.io/repos/sandelius/class_attribute/badge.svg?branch=master)](https://coveralls.io/r/sandelius/class_attribute?branch=master)
@@ -1,3 +1,3 @@
1
1
  module ClassAttribute
2
- VERSION = '0.1.3'.freeze
2
+ VERSION = '0.1.4'.freeze
3
3
  end
@@ -1,14 +1,17 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'set'
2
4
 
3
5
  require_relative 'class_attribute/version'
4
6
 
5
7
  # Inheritable class level variable accessors.
6
8
  #
9
+ # @author Luca Guidi
7
10
  # @author Tobias Sandelius <tobias@sandeli.us>
8
11
  #
9
12
  # @see ClassAttribute::ClassMethods#class_attribute
10
13
  module ClassAttribute
11
- # @api private
14
+ # @private
12
15
  # @see http://www.ruby-doc.org/core/Module.html#method-i-included
13
16
  def self.included(base)
14
17
  base.extend ClassMethods
@@ -55,7 +58,7 @@ module ClassAttribute
55
58
  # @return [void]
56
59
  def class_attribute(*attrs)
57
60
  singleton_class.class_eval do
58
- attr_accessor *attrs
61
+ attr_accessor(*attrs)
59
62
  end
60
63
 
61
64
  class_attributes.merge(attrs)
@@ -64,7 +67,7 @@ module ClassAttribute
64
67
  protected
65
68
 
66
69
  # @private
67
- # @see Class#inherited
70
+ # @see http://ruby-doc.org/core/Class.html#method-i-inherited
68
71
  def inherited(subclass)
69
72
  class_attributes.each do |attr|
70
73
  value = send(attr)
@@ -78,8 +81,7 @@ module ClassAttribute
78
81
 
79
82
  private
80
83
 
81
- # @api private
82
- # @see http://ruby-doc.org/core-2.2.2/Class.html#method-i-inherited
84
+ # @private
83
85
  def class_attributes
84
86
  @class_attributes ||= ::Set.new
85
87
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: class_attribute
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tobias Sandelius
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-06-02 00:00:00.000000000 Z
11
+ date: 2016-06-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -119,10 +119,11 @@ required_rubygems_version: !ruby/object:Gem::Requirement
119
119
  version: '0'
120
120
  requirements: []
121
121
  rubyforge_project:
122
- rubygems_version: 2.4.7
122
+ rubygems_version: 2.5.1
123
123
  signing_key:
124
124
  specification_version: 4
125
125
  summary: Inheritable class level variable accessors
126
126
  test_files:
127
127
  - test/test_helper.rb
128
128
  - test/unit/class_attribute_test.rb
129
+ has_rdoc: