voice_text_api 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/voice_text_api/version.rb +1 -1
- data/lib/voice_text_api.rb +3 -3
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2d759193020ab3e74c2e8f7daeaf823c1cdc3b20
|
4
|
+
data.tar.gz: ccea6021ad9bd415146da8eed15b7595c3b7af1d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 839345584673a5485bf8fedc2d85d057b40d24a25d29d6da43910776d760f876f25ae43a3ce018fde947aba9dcf0828ba4ba4373c77ed3bcbf0cb8216458ae1f
|
7
|
+
data.tar.gz: bdd4e0a968619c10602f0f0801074c62cdc9dca831d0d2e3d93444a9d5c816407abd3cbc5344abd4d3878c6b565225ab55f3e7d6dd2b45b5927208a5ecbfbe72
|
data/lib/voice_text_api.rb
CHANGED
@@ -44,12 +44,12 @@ class VoiceTextAPI
|
|
44
44
|
private
|
45
45
|
def validate_parameters(speaker, emotion, emotion_level, pitch, speed, volume)
|
46
46
|
raise ArgumentError.new("wrong speaker: #{speaker}" ) unless SPEAKERS.index(speaker.to_s)
|
47
|
-
|
48
|
-
|
47
|
+
if speaker != :show && emotion != nil
|
48
|
+
raise ArgumentError.new("wrong emotion: #{emotion}" ) unless EMOTIONS.index(emotion.to_s)
|
49
49
|
end
|
50
50
|
raise ArgumentError.new("wrong emotion_level: #{emotion_level}" ) unless (1..2).include?(emotion_level)
|
51
51
|
raise ArgumentError.new("wrong pitch: #{pitch}" ) unless (50..200).include?(pitch)
|
52
|
-
raise ArgumentError.new("wrong speed: #{speed}" ) unless (50..
|
52
|
+
raise ArgumentError.new("wrong speed: #{speed}" ) unless (50..400).include?(speed)
|
53
53
|
raise ArgumentError.new("wrong volume: #{volume}" ) unless (50..200).include?(volume)
|
54
54
|
end
|
55
55
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: voice_text_api
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- TADA Tadashi
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-07-
|
11
|
+
date: 2014-07-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|