collection_utils 2.0.0 → 2.0.1
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1750992aa6525c66d2dbc0ef51b388fe87ef86b3
|
4
|
+
data.tar.gz: 1600f263b54e8b0e17ed902612d65957501af1e2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ece6900793ce45e5c8263cffcb77ab9c976d46468495fa9e3b532c9d80a1a33b94a0b212cc667b64f3f8191bfd2f83b160705d26ff304b1b95d89368cc3ebe17
|
7
|
+
data.tar.gz: 04beb356f165acc2aa7388b20c91799d27e4cbf6cbb4dcbc9a7078930c25d991f97dd3543fd2ce7ddcd784c3c847dd38c6b09d67cdff3913cb80a7a7105a1002
|
data/collection_utils.gemspec
CHANGED
@@ -11,7 +11,10 @@ Gem::Specification.new do |spec|
|
|
11
11
|
|
12
12
|
spec.summary = ""
|
13
13
|
spec.description = "CollectionUtils provide with basic collection templates
|
14
|
-
like stack, queues
|
14
|
+
like stack(push, pop, peek), queues(enqueue, dequeue), heaps/tree(MinHeap, MaxHeap, BST)
|
15
|
+
and HashDeserializedObject(Converts a hash into object for easy access.
|
16
|
+
All the keys will become attributes of the object).
|
17
|
+
Check out the wiki at https://github.com/deeshugupta/collection_utils/wiki"
|
15
18
|
spec.homepage = "https://github.com/deeshugupta/collection_utils"
|
16
19
|
spec.license = "MIT"
|
17
20
|
|
@@ -93,6 +93,15 @@ module CollectionUtils
|
|
93
93
|
return remove_instance_variable("@#{name.to_s}")
|
94
94
|
end
|
95
95
|
|
96
|
+
# @return [Boolean] returns whether the HashDeserializedObject is empty or not
|
97
|
+
# @example check whether the object is empty or not
|
98
|
+
# => obj = CollectionUtils::HashDeserializedObject.new()
|
99
|
+
# => obj.empty? #true
|
100
|
+
# => obj.nil? #false
|
101
|
+
def empty?
|
102
|
+
return @original.empty?
|
103
|
+
end
|
104
|
+
|
96
105
|
# Get original Hash used to build the object. It will grow as we insert more
|
97
106
|
# values in the object
|
98
107
|
# @return [Hash] original hash used to build the object
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: collection_utils
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- deeshugupta
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-07-
|
11
|
+
date: 2017-07-31 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -52,9 +52,10 @@ dependencies:
|
|
52
52
|
- - ~>
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '3.0'
|
55
|
-
description:
|
56
|
-
|
57
|
-
|
55
|
+
description: "CollectionUtils provide with basic collection templates\n like stack(push,
|
56
|
+
pop, peek), queues(enqueue, dequeue), heaps/tree(MinHeap, MaxHeap, BST)\n and HashDeserializedObject(Converts
|
57
|
+
a hash into object for easy access.\n All the keys will become attributes of the
|
58
|
+
object). \n Check out the wiki at https://github.com/deeshugupta/collection_utils/wiki"
|
58
59
|
email:
|
59
60
|
- gupta.deeshu@gmail.com
|
60
61
|
executables: []
|