randomness 0.1.2 → 0.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/lib/changelog.txt +4 -3
  3. data/lib/main.rb +9 -1
  4. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 4ff8779f4b4f6505a3fdc5386b0f127a547309f7
4
- data.tar.gz: 829ac1952c112b538d7909fe56f6be1c80a58e67
3
+ metadata.gz: 950a3d274337a60abef8777a47ec598a0e7d0208
4
+ data.tar.gz: 34e4fb4ec9670f31189e1f0ec4f7655290be333b
5
5
  SHA512:
6
- metadata.gz: 443491e8426ac5660db3cf76e7fc9477b30200894d7b1ca896dceb85475f4846e297533809b98c876e9a6851e78d671e5a1f8549a9d0e92d530a1f762843f844
7
- data.tar.gz: 3f4b06fd9841b189f9fb8004b64e5f274f1d8222c1b577b9b04e2743e4fee088355143f7bc718491aba82dd8c18b78fcb4522a690260827f6523ba27ac19e072
6
+ metadata.gz: b35d2ede06cf56e4d3fb9da1e7dd6bf515d536c72d19afdd9f3c228aa6ca9bea04f33b598f0b89c01983d6a6063465296532b87b05720198cd9ed886276767fc
7
+ data.tar.gz: 992ba47b3a3ce07144c819c55b60c96de6257c4b8bae50cbe7c42acf59dbc74e99fb3f01f272938c7e8afe9d2a44a1ff7c1a003d8eea743995acf76fa58be5e4
data/lib/changelog.txt CHANGED
@@ -1,3 +1,4 @@
1
- · Added methods:
2
- shufflearray
3
- shufflehash
1
+ · Slightly changed randomizeseed method.
2
+ · Added UNIMPLEMENTED methods:
3
+ randomletter
4
+ randomletters
data/lib/main.rb CHANGED
@@ -3,7 +3,7 @@ module Randomness
3
3
  #Sets the random seed to a value based on the current time.
4
4
  def randomizeseed()
5
5
  time = Time.now()
6
- srand(time.yday * (time.usec - time.sec))
6
+ srand(time.yday * time.usec * time.sec)
7
7
  end
8
8
  #Returns a random number between min and max(inclusive of both end points).
9
9
  def randint(min, max)
@@ -52,6 +52,14 @@ module Randomness
52
52
  def randchars(string, amount)
53
53
  return randchoices(string.split(''), amount)
54
54
  end
55
+ #THIS METHOD IS NOT YET IMPLEMENTED AND SHOULD NOT BE USED. Returns a random ascii letter.
56
+ def randletter(uppercase=true, lowercase=true, numbers_included=false)
57
+ raise NotImplementedError.new("Method randletter in module Randomness not yet implemented.")
58
+ end
59
+ #THIS METHOD IS NOT YET IMPLEMENTED AND SHOULD NOT BE USED. Returns the specified amount of random ascii letters.
60
+ def randletters(amount, uppercase=true, lowercase=true, numbers_included=false)
61
+ raise NotImplementedError.new("Method randletters in module Randomness not yet implemented.")
62
+ end
55
63
  #Returns a random boolean value.
56
64
  def randbool()
57
65
  return true if randint(1, 2) == 1
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: randomness
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - SugarRush
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-10-05 00:00:00.000000000 Z
11
+ date: 2018-10-06 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: A gem containing a module that generates random values of many different
14
14
  types.