soar_auditor_api 0.0.8 → 0.0.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/soar_auditor_api.rb +1 -1
- data/lib/soar_auditor_api/serializable.rb +18 -0
- data/lib/soar_auditor_api/version.rb +1 -1
- data/sanity/Gemfile +1 -0
- data/sanity/sanity.rb +0 -2
- metadata +2 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c350e5d094080196dc7869897c05ae704eee30a5
|
4
|
+
data.tar.gz: 27e92d4b5df9feb1c3794f5c0832f87ee4b12bbd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 28a2a5c16f1f9e0042b2b9a23ded0a0f4095703cf2376022e0fd7915cade23614beeb0281039f25230474e128827bb12262505ce65eecf8ccc2cb56cd8755144
|
7
|
+
data.tar.gz: f7f97ebd0a60a08f42553a0b5a19feedfe3e97f05559127374f75eb7667162dcc8f0c674107cc710224b82393fe5590094a5420570599f66301d3bb3c7d62dc5
|
data/lib/soar_auditor_api.rb
CHANGED
@@ -0,0 +1,18 @@
|
|
1
|
+
module SoarAuditorApi
|
2
|
+
class Serializable
|
3
|
+
def initialize (data)
|
4
|
+
@data = data
|
5
|
+
end
|
6
|
+
|
7
|
+
def serialize
|
8
|
+
require "base64"
|
9
|
+
utf8_data = @data.to_s.encode(Encoding::UTF_8)
|
10
|
+
urlsafe_base64_data = Base64.urlsafe_encode64(utf8_data)
|
11
|
+
"[serialized:#{urlsafe_base64_data}]"
|
12
|
+
end
|
13
|
+
|
14
|
+
def to_s
|
15
|
+
raise NotImplementedError, "Class must implement to_s method when extending Serializable"
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
data/sanity/Gemfile
CHANGED
data/sanity/sanity.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: soar_auditor_api
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.9
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Barney de Villiers
|
@@ -86,6 +86,7 @@ files:
|
|
86
86
|
- bin/setup
|
87
87
|
- lib/soar_auditor_api.rb
|
88
88
|
- lib/soar_auditor_api/auditor_api.rb
|
89
|
+
- lib/soar_auditor_api/serializable.rb
|
89
90
|
- lib/soar_auditor_api/version.rb
|
90
91
|
- sanity/.ruby-gemset
|
91
92
|
- sanity/.ruby-version
|