rippler 0.0.9 → 0.0.10

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -24,6 +24,8 @@ Rippler supports Ripple API commands (https://ripple.com/wiki/RPC_API). All para
24
24
 
25
25
  $ rippler account_tx account:evoorhees ledger_min:0 ledger_max:400000
26
26
 
27
+ $ rippler book_offers taker_pays:USD/bitstamp taker_gets:BTC/bitstamp
28
+
27
29
  $ rippler subscribe streams:[ledger]
28
30
 
29
31
  Ripple server replies are returned as JSON and printed to stdout. If you want to do some post-processing of the results, get the source from Github and modify bin/rippler script.
data/lib/rippler.rb CHANGED
@@ -84,6 +84,22 @@ module Rippler
84
84
  end
85
85
  end
86
86
 
87
+ ### These API commands need some pre/post-process wrappers
88
+
89
+ # book_offers needs to convert "taker_gets" & "taker_pays" params
90
+ # from "CUR/issuer" to { "currency": currency, "issuer" : address },
91
+ def self.book_offers params
92
+ taker_gets = Money("0/#{params['taker_gets']}")
93
+ taker_pays = Money("0/#{params['taker_pays']}")
94
+
95
+ reply = request( params.merge('command' => "book_offers",
96
+ 'taker_gets' => taker_gets.to_hash,
97
+ 'taker_pays' => taker_pays.to_hash))
98
+
99
+ # lines = reply["result"]["lines"]
100
+ end
101
+
102
+
87
103
  # Subscribe needs a streaming wrapper
88
104
  def self.subscribe params, &block
89
105
  em_request( true, {'command' => "subscribe", 'id' => 0, 'streams' => ['ledger']}.
@@ -139,6 +155,8 @@ module Rippler
139
155
  'sort_asc' => 1
140
156
  }.merge(params) ) #(optional)
141
157
  txs = reply["result"]["transactions"]
142
- txs.reverse.map {|t| Transaction.new(t).to_s}.push("Total transactions: #{txs.size}")
158
+ txs.map {|t| Transaction.new(t)}.map(&:to_s)
159
+ .push("Total transactions: #{txs.size}")
160
+
143
161
  end
144
162
  end
@@ -1,5 +1,89 @@
1
1
  module Rippler
2
- Contacts = Hash[ *%W[
2
+
3
+ # X.*** signifies anonymous account that is active in Ripple
4
+ Contacts = Hash[ *%W[
5
+ X.FortKnox.1 rhWnKQ79moM7wkk2b9RpufDzhbHw7YLc6d
6
+ X.FortKnox.2 r9PbKbYisKN1DSwaZ7jp6ZsKmfk1yCFAAi
7
+ X.FortKnox.3 rJipRKjL3CNAvWWMNrbXW9sCvk66PBdyMv
8
+ X.FortKnox.4 rDyLzAzyniahxpPLkNsLDSPZki6HZk6wV5
9
+ X.FortKnox.5 rhXSetHpayrrnjVAzVgtP4EVmpqMpMFUBt
10
+ X.FortKnox.6 rn4o6i8BrwhwmyjLntKsW4DZnk76dZXocS
11
+ X.FortKnox.7 rNAbBQAd8zgfdRoUFvjeu582Nu7uQjsuhz
12
+ X.FortKnox.8 rNGWsgk1MGdW12SWQ67hRhnvGfZ1M3cMxB
13
+ X.FortKnox.9 rp7gaQch2fiNQHDPrnPk9pG65e9cnv7g6X
14
+ X.FortKnox.a rstKSeB2Qx7zrwSkyc7X9Xm5nYTJqtL3iM
15
+ X.FortKnox.b rJYMACXJd1eejwzZA53VncYmiK2kZSBxyD
16
+ X.FortKnox.c r9ycgvDgXjeiaYmoz4F8sKBNXgHHx1wVFM
17
+ X.Distributor.1 r8TR1AeB1RDQFabM6i8UoFsRF5basqoHJ
18
+ X.Veirou rhq5LEZSWHWY6H3raiC2KGe8TVeirou4BS
19
+ X.Wow rHD7Bs8Zk1oQeUhLjPrsFStFcRE2NWoWpe
20
+ X.Reya rEyAJhMMi5WNzgdkY67vN7ivfiQnh3itXY
21
+ X.sron rnXht74MxLVfmhi52wDDKYNKL9moPs7Y5T
22
+ X.77millions rB5TihdPbKgMrkFqrqUC3yLdE8hhv4BdeY
23
+ X.10millions rHrSTVSjMsZKeZMenkpeLgHGvY5svPkRvR
24
+ X.Founder.1 rfbKLd1VLB3o6fpkhCJexckArjoMmBm2wG
25
+ X.Tester.1 rLgXwzqSSCnQjA83tWP1j8D1Kf4zX9gMVj
26
+ X.Tester.2 rHByiWNHuu4P4n9TuJBjkpbbZiptdywzd9
27
+ X.Trader rnT9PFSfAnWyj2fd7D5TCoCyCYbK4n356A
28
+ X.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b2LRHvyouHMF9WoWMJ29mdDTUgEdiA5
78
+ X.51 rGJDijoiue2HmjuiEBQKAWY7XdKb2poWka
79
+ X.52 rnxyvrF2mUhK6HubgPxUfWExERAwZXMhVL
80
+ X.54 rMZKeAt1vMjhuNCWDiB4SdzJRiymdpERw4
81
+ X.55 rhPWDU6pPZpVpDr7PjkeMHwB5DskmV4jDe
82
+ X.56 rDZ8QghKF4C11pmbVAkqumPTehiF8mfHt3
83
+ X.57 rDGd76GCnZYGhjiAngV3xrPV4Qkfx79qqp
84
+ X.58 r9Y4Mdhs339CxpCFxgdBVRcuM5i4rMRbu
85
+ X.59 rPcu8U9dSsK6nHtqgpeSvjuFTmNGq3arPh
86
+
3
87
  ADDRESS_ONE rrrrrrrrrrrrrrrrrrrrBZbvji
4
88
  OpenCoin rJR7gjNe3DpJ7kpB4CHBxjDKfwVMpTKPpj
5
89
  OpenCoin.1 r3kmLJN5D28dHuH8vZNUZpMC43pEHpaocV
@@ -19,105 +103,6 @@ module Rippler
19
103
  ChrisFromZed rPA9PquwamoriknybdishCdWp6N1m2iEF8
20
104
  SecondBankOfZed rnqQ7YEStMBBqn6qBP4AYsyGhy1RKfUeRR
21
105
 
22
- arvicco rnZoUopPFXRSVGdeDkgbqdft8SbXfJxKYh
23
- paysafecardbitcoin rN4kvobWCZVSzgLmo27B4kMjakAL31pMSr
24
- Lethn r4DpNXFTohg1hgBKxrYv8YBtahKNAALjeH
25
- nikkus rUhcZuPQBrykExj1VSfLnaeLdu2hJmVe9e
26
- filharvey rJRFxWe3KxmhMfW7am5hFE9pkciAJHefeD
27
- ablewasiereisawelba rPtTbUkhLZ9e2a7H3TCHcHmSa35jTnQHoa
28
- luffy r3mjrPe1S4vHe2g6CTCeb6ezcPfpDywQAs
29
- thepwnorbpwnd rLQ1WWeCVuM523iMRC9PCLpyFU8YkWqDdR
30
- lightlord raAw68E3T6Eh4h5Qfb1ZxsWzyHkY8BZJRN
31
- Wolf0 rwcpov2ZZmPpo6sjeg4n2oZx94uAYBQ21o
32
- thepickingpair rht576qwyKXZ26JEGHYpC3N3atjNS8oM5j
33
- Luceo rGZL3cCV6Er5Tiag9tStGhseF4NDBxbxQr
34
- Luceo.1 rJpuugf8o4NfvorsTGwGyyy11Hi3j9514H
35
- 21after2 rwuoJnBP4kyfR6Bry8ruLNyxubuk37w6gi
36
- t.o.m. r4b5wQJL9qfqGZA6WQksE9spuYi4fmgDde
37
- octopus r33dwR8VbfDvHptF2AYzp9JHjR7iVetqM
38
- MichaelBliss rB2VLRRZejCMpDCyvGNn4nEHRLycwY7H8z
39
- nckfor rD2yesqWXxgEztU6khSjts7tx8CF6VN3k3
40
- FirewallXIII rEvYxDNoz8aFSRRWH6JoKBhBAqx6xDMN3G
41
- 00null rhr3wb58NyicoBBXGfPQtctXxk1X8ZhwcM
42
- Isamaru rGsfVSM9etepbYoa52AScPRd2eSdv86ZDf
43
- ragmondo rHm9QPX7v2xz9JMozrYnJynfgEhnQ6Aaeo
44
- trippp rL4px896Gf2r5PDru38jsJt3qTN9NmpgEd
45
- TheRenix rMPJ77FoY86cLLzhQ3ETnvNdAvy6A4UMqR
46
- simonk83 r3U8PomU1pw4T48cmXVahUNuUerNVcbwto
47
- rme rJeuPjq9XBZkuxk51hmXSsFmANy7JbBCRC
48
- Ecks rJaBUL6npe6yvoJU7e5nuRgAaMoa3njnQ8
49
- NABiT rLorFPMtVzutmcZBDGpAeQLfVyCL19p1qK
50
- JesterOfTortuga rDGLPeQTbd7ntNRNdwAtgAjnUPf7YwDHGz
51
- ryanbrownstar rvTZGvDaKza8Zuhm4E7vnLtTuMU2MgwX3
52
- mmkiwi rJpG5GJrpKBabbqGphfijjdZe2bkyPewL7
53
- camolist rBzu6o32DoHtHUvRYUKwcHMsgz1BTSTyek
54
- cambda rfxAqtZA9Knb8mb1Gij4Y6rFfTfp6FWSTZ
55
- cambda.1 rBBSghHNdpbBuT5kiGruX5TjofWLF2fi74
56
- TheInventor r7a3uqQREUU6tEYnsCTFWh31DeVHWNp2G
57
- rizzla rLnhMYFwqUkc2D8ojJmhQkNuytaBsyzVG3
58
- Moshi r9fupyMm63XMvbAozvzjLyHdJHCtLEKveE
59
- bachus rKQLwGTe6NX16iSEuS88bi3FEqZnbwF7EB
60
- helloworld rwDo98FnbCp3qUN5CkwDcK4rFfbyW3Kzqq
61
- Cyberdyne ragN8YEhHjXbgeGrNGLw9wuxQeq1d8qHk
62
- cardinalG rQr973QcHXx1NCfXpQdLPpnGmMrkDjwRXB
63
- dalek r3HpcvyJUhpGzJGa7KBZcvo35EiDqLtU1V
64
- Slackware1995 rLHacQyTzfRjHMp7yFzXu18cbt6KteSXBP
65
- WalterRothbard rwaaH5CCdWe8V7kBbXQonpFyKbRDePF9Vc
66
- spndr7 rUusFTWNUDYqKnAg4tiZLTAyRdUMaVFVUG
67
- kakobrekla rHrkFodY9f3DxQnSsHiu6R1j4JvTYfFnRS
68
- ny2cafuse rBh3KyjpANw5GXbt9AmCiFB2MbYGxWSCWa
69
- chris200x9 r9MmCAquMciDwGRqKUXvayK2LAayPSvYuz
70
- Prospero rB8N1ohjVKtMiZVivSY3H6Y3ABcAMJce36
71
- Atruk rp3uz9jcb8LkMpMvwsfFTaCpkEgAGxNnKj
72
- Isokivi rUjVzMqFpFYLQ8PoKb46psWuKhkxgZFTnx
73
- Anormalname rp9DmXB6uxkooTeGpdtjaj8eT8V3ENaads
74
- Luno rDcW2mqMKGHZ4iFKkTSyHyBT4AtLNBwge
75
- weex@bitcointalk rEjC6w3m7ENkmD9SAyFyfKgRgeNz7HbkbW
76
- gbl08ma rsgg1U8UpYodp1GM3NDaYfMrZge97Gpvc9
77
- tosku rBs43YZMn5QsYY9jZYcG4C3egEebUfGWh3
78
- BitcoinG r3CxMDQFX1Atq1vQN5sqVsjm3rawGSwd32
79
- Gzarcov rEg8hTqY7jhSkeFirfE5Fm7BF72WaaCnrB
80
- milly6 rQaxmmRMasgt1edq8pfJKCfbkEiSp5FqXJ
81
- crazyearner rBcrMMTUKAQJd5tMEsy1zyTGRiy79gY9K3
82
- elelegzet rBKnNboJeGxTwQM1agrXp28WcVWKtPPQah
83
- Myrddindc rp2ewp8uH4zi35T2oWkfpETT3rQ4qBBZzt
84
- Ivica ra6FCgRD4Ye4PNcTRhmiXaSzpJKo1PQEzh
85
- DrG rQrnuAtfePuz2fsSDTakuDZn594fi9x7dP
86
- DrG.1 rJEZjBv27ZHCPAoDtTBJb9r82VnUdkRd77
87
- DrG.2 rQNFxWVBxnjeF5gaFKwoj5nr3WansCtR19
88
- UnitClick rLKojeESeKi9mdBuPLkiQhCxs4wh8iKy2W
89
- saddambitcoin rMSEYpzcRtkiA5kkxYEWZtvLr8u3jnn385
90
- helloworld111 rwGAnUvzT5yrDz6dXxm6MWVhpV9abm39W3
91
- dykast rQfwn3GVHVEfTpjqU2Y3BoMGAGHrw43XnT
92
- BurbolGii rDYwnqGbUazEuMfebQwLprCQQXWbYgXTMa
93
- BC12345 rNy61KXKUYPMFf5fMV6ojo3u98dc5WhiVu
94
- Eegnylot rPKwrbDS6GC61QF1NuyTCohK926ns2vEG3
95
- CurbsideProphet rBgpempF56xEyJA9WV55NKZ9VZPJfwMQuZ
96
- whitehawk501 r3qXCX9hdoFmTdPo7JvjQsbFUfE7UHUBhb
97
- whitehawk501.1 r3bbiYhxHxseufw9UY5bqN1yCEdHVNKgM3
98
- reefless r3sAGjHpBW1VN7zerJLxpHj86p9eyrBTqs
99
- candoo rPSRiivLymK5n7bge9veb4u2bbMPUdRm71
100
- xenon481 rVY72tekygu4AToFjQsDtL6TDfNXtbCeQ
101
- gogxmagog rMSaUrYFtNAjV4aGmNEBnEshuYYtttbMkB
102
- Lanzer rfs635NxEE9FnenYCksy2qx9QHbosemKQD
103
- Badonkadonk rnorpbuYVYk1u5r2cmEqzaDXdZ93FGjH4o
104
- Jaques rLVMPwKBxungSYQgiN7HmTa9ndiXSbgzhV
105
- Geraintjdotcom rNiS1vbeca2p7WxRwA1oS4WtnxXLB9MHsU
106
- icey rDACCWyQyqfuvt9WxCWBZyqgBEMijLseZm
107
- thatbluedude rLnCJbgbivWYavZXCdaJ7asHPP31RyXPdk
108
- montana rUMub4tmRpNRfognEeTcwW5rEbXwrgZLwd
109
- montana.1 r3t5JvXF6rChFs4kCFe44a3h4eQdxmPo9a
110
- Cookie_Monster raww2VncvFyPvPCY8xnmb1AoqRxUWb6VdN
111
- CarlosL rE9hpRfFFqWGxpGYA8bC6GkroRCr4mLLcq
112
- greendave rPGpKXPSSxwvkpNXM5BtRRFWYjLP1ibH9D
113
- Darkneo rfQdhMCnjWRP1fd1amNQwe49sMmXgR3uYq
114
- veteranBtc rUvpjNBcnt4DLKEVA2XyvJi1YGCfp2EPtk
115
- templeofshadows rJCCwPsVANVfEgQEB2bsEiaTF86cr9fdw4
116
- manrus rwM8yMFctE9Ffom1AUjr8epViNwXHPC9aP
117
- shivansps rMxpLTxf7ocTcBdLHbUEeeuF76Vj3VjYvN
118
- majinx rMeXvtHE3ZeKAdhMfiFdQC5FJvaNDHzjoK
119
- vite rwRbCNfQa4gnELgttMfCWFXjUo37BigQbz
120
-
121
106
  molecular rpH3zuMch2GrrYX724xGWwbMGwiQ5RbSAU
122
107
  Ente rNEtVs4kNeESF5HbWCDZMYcWwKZ5iKwUEr
123
108
  herzmeister rUdPvX9YN1NwyniwiJeSW6y3YKZL84gsB6
@@ -455,90 +440,148 @@ module Rippler
455
440
  levino.1 rpgKc15YqRMKfr517BcKJRC8YrtQs8iuVE
456
441
  levino.2 rPFWpTWmMn3BiRkGpBBa1GhKQtw82bwks7
457
442
 
458
-
459
- X.FortKnox.1 rhWnKQ79moM7wkk2b9RpufDzhbHw7YLc6d
460
- X.FortKnox.2 r9PbKbYisKN1DSwaZ7jp6ZsKmfk1yCFAAi
461
- X.FortKnox.3 rJipRKjL3CNAvWWMNrbXW9sCvk66PBdyMv
462
- X.FortKnox.4 rDyLzAzyniahxpPLkNsLDSPZki6HZk6wV5
463
- X.FortKnox.5 rhXSetHpayrrnjVAzVgtP4EVmpqMpMFUBt
464
- X.FortKnox.6 rn4o6i8BrwhwmyjLntKsW4DZnk76dZXocS
465
- X.FortKnox.7 rNAbBQAd8zgfdRoUFvjeu582Nu7uQjsuhz
466
- X.FortKnox.8 rNGWsgk1MGdW12SWQ67hRhnvGfZ1M3cMxB
467
- X.FortKnox.9 rp7gaQch2fiNQHDPrnPk9pG65e9cnv7g6X
468
- X.FortKnox.a rstKSeB2Qx7zrwSkyc7X9Xm5nYTJqtL3iM
469
- X.FortKnox.b rJYMACXJd1eejwzZA53VncYmiK2kZSBxyD
470
- X.FortKnox.c r9ycgvDgXjeiaYmoz4F8sKBNXgHHx1wVFM
471
- X.Distributor.1 r8TR1AeB1RDQFabM6i8UoFsRF5basqoHJ
472
- X.Veirou rhq5LEZSWHWY6H3raiC2KGe8TVeirou4BS
473
- X.Wow rHD7Bs8Zk1oQeUhLjPrsFStFcRE2NWoWpe
474
- X.Reya rEyAJhMMi5WNzgdkY67vN7ivfiQnh3itXY
475
- X.sron rnXht74MxLVfmhi52wDDKYNKL9moPs7Y5T
476
- X.77millions rB5TihdPbKgMrkFqrqUC3yLdE8hhv4BdeY
477
- X.10millions rHrSTVSjMsZKeZMenkpeLgHGvY5svPkRvR
478
- X.Founder.1 rfbKLd1VLB3o6fpkhCJexckArjoMmBm2wG
479
- X.Tester.1 rLgXwzqSSCnQjA83tWP1j8D1Kf4zX9gMVj
480
- X.Tester.2 rHByiWNHuu4P4n9TuJBjkpbbZiptdywzd9
481
- X.Trader rnT9PFSfAnWyj2fd7D5TCoCyCYbK4n356A
482
- X.1 rKdtD8YQXCJAnXoXQfmn645FybiaFWVghs
483
- X.2 ramJoEsBUHc299vFuMvn8NgLrF3Qrt3XV4
484
- X.3 r9tGqzZgKxVFvzKFdUqXAqTzazWBUia8Qr
485
- X.4 rftLQPpLaUGfHRLAo9WRRXq7AyTaFR8gZJ
486
- X.5 rszhA4GDntuFkTw6Eu7K9q5qGd31gcD9pP
487
- X.6 rKRcetrtqMXJS8TSHsnCSvwZxVf2CMvKX1
488
- X.7 r4FbZZ5VYdp9FaVPeFdAHA6ogysHrPu3rr
489
- X.8 r3yJUumMvWez4PCGxv8ENdCfXaRKHKFNTp
490
- X.9 rLp9pST1aAndXTeUYFkpLtkmtZVNcMs2Hc
491
- X.10 rhJgDbDWs4iEzvT3qUTQZ2S1T2Qu6KCQQk
492
- X.11 rshceBo6ftSVYo8h5uNPzRWbdqk4W6g9va
493
- X.12 rwCYkXihZPm7dWuPCXoS3WXap7vbnZ8uzB
494
- X.13 rwHpLXGBMxUUqenPBaPugBfoVtgQy19nRE
495
- X.14 rpMwfz4c8FRxjqQhxLxbKzqkXdgkenFg8B
496
- X.15 rEWDpTUVU9fZZtzrywAUE6D6UcFzu6hFdE
497
- X.16 rUGNvasUuxLiPL5RXvfZXW8HjBtSHZgqgz
498
- X.17 rPyuHFYDwYMGJ5xhMbzfYeikx7ARV3ExvF
499
- X.18 r4MZrGMPEHfxGNQHR92BJo5hU9BiqMsTej
500
- X.19 r3ADD8kXSUKHd6zTCKfnKT3zV9EZHjzp1S
501
- X.20 rnW7DHtmZGJk4uhGTSU2BW3iPCPWb2xegg
502
- X.21 rUrdFHbrEKWNQQ444zcTLrThjcnHCw2FPu
503
- X.22 r49nVgaYSDuU7GEQh4mF1nyjsXSVRcUHsr
504
- X.23 rf8kg7r5Fc8cCszGdD2jeUZt2FrgQd76BS
505
- X.24 r9aRw8p1jHtR9XhDAE22TjtM7PdupNXhkx
506
- X.25 rwdLV79WzXmFuzP2cBwTG6mtXcfSnCjtoF
507
- X.26 r3ZXkbKVkCcwtSRbX5Rqz9VveyZDuXSs5G
508
- X.27 rakv2tqjdLLuPu5g5j4F5JW21Q4LNLc6Vn
509
- X.28 rnwRcxX4JpHnPjTJpaDH8YZzRPTphvsHbE
510
- X.29 rKWFsTLRPrgC8KDC7fCqQRzDsvajgcM1Tp
511
- X.30 r4mscDrVMQz2on2px31aV5e5ouHeRPn8oy
512
- X.31 rHnxRmkRdL4NsAoxqN1xwKDuW49uosM3HL
513
- X.32 r3o9bK8Re9XZpFwZC6jXGwKBuhoLss9Mhc
514
- X.33 rKuuVUKA14roSPTuquQTo7nmWZN8EsfxpT
515
- X.34 r9dshc2F8SqBdqXSmQHjsSoPN42PLB37ud
516
- X.35 rnxnLRYWt6yiHC413MWwUeXJ4AZpQKShUg
517
- X.36 rNJRm1VQZZuczrVHjgUSB9Y6kpMopLdADo
518
- X.37 r3iLZXAAmuRQnt4hYQUcoXiSkrSAmHjcKW
519
- X.38 raXgrRqLeDFRjFbXXJd3vQgjymoLkbzic5
520
- X.39 r9VUjVRKEFyBNmFRKPCjHbjYUv8QvJ5xyu
521
- X.40 rs5Kyt6CoYsYx5E6HVpcKGQjVa6trzrBa4
522
- X.41 r9LVrQDxq9R4mSN2XezNDAXbAeUtRwBrvu
523
- X.42 rMPNPj8nwiKsBNTRRMGtgRnAdXK17Wvuep
524
- X.43 rh9uD31E8B3nWbPCGNVNkTE1QzA2486Yom
525
- X.44 rHrck4S1n9kmyWyFPJHAegLKtRFNmwC2ic
526
- X.45 rjcDqW25DCTpAUnKi9T8aiMe32vEy8JHt
527
- X.46 rh5PSrnbYZ31ZVRWNgcEZDNhTmV61rshVK
528
- X.47 rhBKQBvsyDnSnLgU5D1DcbNKq34To6G2Mr
529
- X.48 r3RVftuvnhuWyTykK2R2XaD6vepwyfnCYs
530
- X.49 rLDwkvrMVbbJ9WLaXpNaPM9k9AinJwNPSg
531
- X.50 rhMb2LRHvyouHMF9WoWMJ29mdDTUgEdiA5
532
- X.51 rGJDijoiue2HmjuiEBQKAWY7XdKb2poWka
533
- X.52 rnxyvrF2mUhK6HubgPxUfWExERAwZXMhVL
534
- X.53 rBiYVjzHRQxMDMdC5ynKsejqoy1qJMQ8zR
535
- X.54 rMZKeAt1vMjhuNCWDiB4SdzJRiymdpERw4
536
- X.55 rhPWDU6pPZpVpDr7PjkeMHwB5DskmV4jDe
537
- X.56 rDZ8QghKF4C11pmbVAkqumPTehiF8mfHt3
538
- X.57 rDGd76GCnZYGhjiAngV3xrPV4Qkfx79qqp
539
- X.58 r9Y4Mdhs339CxpCFxgdBVRcuM5i4rMRbu
540
- X.59 rPcu8U9dSsK6nHtqgpeSvjuFTmNGq3arPh
541
- ]] # X.*** signifies anonymous account that is active in Ripple
443
+ arvicco rnZoUopPFXRSVGdeDkgbqdft8SbXfJxKYh
444
+ paysafecardbitcoin rN4kvobWCZVSzgLmo27B4kMjakAL31pMSr
445
+ Lethn r4DpNXFTohg1hgBKxrYv8YBtahKNAALjeH
446
+ nikkus rUhcZuPQBrykExj1VSfLnaeLdu2hJmVe9e
447
+ filharvey rJRFxWe3KxmhMfW7am5hFE9pkciAJHefeD
448
+ ablewasiereisawelba rPtTbUkhLZ9e2a7H3TCHcHmSa35jTnQHoa
449
+ luffy r3mjrPe1S4vHe2g6CTCeb6ezcPfpDywQAs
450
+ thepwnorbpwnd rLQ1WWeCVuM523iMRC9PCLpyFU8YkWqDdR
451
+ lightlord raAw68E3T6Eh4h5Qfb1ZxsWzyHkY8BZJRN
452
+ Wolf0 rwcpov2ZZmPpo6sjeg4n2oZx94uAYBQ21o
453
+ thepickingpair rht576qwyKXZ26JEGHYpC3N3atjNS8oM5j
454
+ Luceo rGZL3cCV6Er5Tiag9tStGhseF4NDBxbxQr
455
+ Luceo.1 rJpuugf8o4NfvorsTGwGyyy11Hi3j9514H
456
+ 21after2 rwuoJnBP4kyfR6Bry8ruLNyxubuk37w6gi
457
+ t.o.m. r4b5wQJL9qfqGZA6WQksE9spuYi4fmgDde
458
+ octopus r33dwR8VbfDvHptF2AYzp9JHjR7iVetqM
459
+ MichaelBliss rB2VLRRZejCMpDCyvGNn4nEHRLycwY7H8z
460
+ nckfor rD2yesqWXxgEztU6khSjts7tx8CF6VN3k3
461
+ FirewallXIII rEvYxDNoz8aFSRRWH6JoKBhBAqx6xDMN3G
462
+ 00null rhr3wb58NyicoBBXGfPQtctXxk1X8ZhwcM
463
+ Isamaru rGsfVSM9etepbYoa52AScPRd2eSdv86ZDf
464
+ ragmondo rHm9QPX7v2xz9JMozrYnJynfgEhnQ6Aaeo
465
+ trippp rL4px896Gf2r5PDru38jsJt3qTN9NmpgEd
466
+ TheRenix rMPJ77FoY86cLLzhQ3ETnvNdAvy6A4UMqR
467
+ simonk83 r3U8PomU1pw4T48cmXVahUNuUerNVcbwto
468
+ rme rJeuPjq9XBZkuxk51hmXSsFmANy7JbBCRC
469
+ Ecks rJaBUL6npe6yvoJU7e5nuRgAaMoa3njnQ8
470
+ NABiT rLorFPMtVzutmcZBDGpAeQLfVyCL19p1qK
471
+ JesterOfTortuga rDGLPeQTbd7ntNRNdwAtgAjnUPf7YwDHGz
472
+ ryanbrownstar rvTZGvDaKza8Zuhm4E7vnLtTuMU2MgwX3
473
+ mmkiwi rJpG5GJrpKBabbqGphfijjdZe2bkyPewL7
474
+ camolist rBzu6o32DoHtHUvRYUKwcHMsgz1BTSTyek
475
+ cambda rfxAqtZA9Knb8mb1Gij4Y6rFfTfp6FWSTZ
476
+ cambda.1 rBBSghHNdpbBuT5kiGruX5TjofWLF2fi74
477
+ TheInventor r7a3uqQREUU6tEYnsCTFWh31DeVHWNp2G
478
+ rizzla rLnhMYFwqUkc2D8ojJmhQkNuytaBsyzVG3
479
+ Moshi r9fupyMm63XMvbAozvzjLyHdJHCtLEKveE
480
+ bachus rKQLwGTe6NX16iSEuS88bi3FEqZnbwF7EB
481
+ helloworld rwDo98FnbCp3qUN5CkwDcK4rFfbyW3Kzqq
482
+ Cyberdyne ragN8YEhHjXbgeGrNGLw9wuxQeq1d8qHk
483
+ cardinalG rQr973QcHXx1NCfXpQdLPpnGmMrkDjwRXB
484
+ dalek r3HpcvyJUhpGzJGa7KBZcvo35EiDqLtU1V
485
+ Slackware1995 rLHacQyTzfRjHMp7yFzXu18cbt6KteSXBP
486
+ WalterRothbard rwaaH5CCdWe8V7kBbXQonpFyKbRDePF9Vc
487
+ spndr7 rUusFTWNUDYqKnAg4tiZLTAyRdUMaVFVUG
488
+ kakobrekla rHrkFodY9f3DxQnSsHiu6R1j4JvTYfFnRS
489
+ ny2cafuse rBh3KyjpANw5GXbt9AmCiFB2MbYGxWSCWa
490
+ chris200x9 r9MmCAquMciDwGRqKUXvayK2LAayPSvYuz
491
+ Prospero rB8N1ohjVKtMiZVivSY3H6Y3ABcAMJce36
492
+ Atruk rp3uz9jcb8LkMpMvwsfFTaCpkEgAGxNnKj
493
+ Isokivi rUjVzMqFpFYLQ8PoKb46psWuKhkxgZFTnx
494
+ Anormalname rp9DmXB6uxkooTeGpdtjaj8eT8V3ENaads
495
+ Luno rDcW2mqMKGHZ4iFKkTSyHyBT4AtLNBwge
496
+ weex@bitcointalk rEjC6w3m7ENkmD9SAyFyfKgRgeNz7HbkbW
497
+ gbl08ma rsgg1U8UpYodp1GM3NDaYfMrZge97Gpvc9
498
+ tosku rBs43YZMn5QsYY9jZYcG4C3egEebUfGWh3
499
+ BitcoinG r3CxMDQFX1Atq1vQN5sqVsjm3rawGSwd32
500
+ Gzarcov rEg8hTqY7jhSkeFirfE5Fm7BF72WaaCnrB
501
+ milly6 rQaxmmRMasgt1edq8pfJKCfbkEiSp5FqXJ
502
+ crazyearner rBcrMMTUKAQJd5tMEsy1zyTGRiy79gY9K3
503
+ elelegzet rBKnNboJeGxTwQM1agrXp28WcVWKtPPQah
504
+ Myrddindc rp2ewp8uH4zi35T2oWkfpETT3rQ4qBBZzt
505
+ Ivica ra6FCgRD4Ye4PNcTRhmiXaSzpJKo1PQEzh
506
+ DrG rQrnuAtfePuz2fsSDTakuDZn594fi9x7dP
507
+ DrG.1 rJEZjBv27ZHCPAoDtTBJb9r82VnUdkRd77
508
+ DrG.2 rQNFxWVBxnjeF5gaFKwoj5nr3WansCtR19
509
+ UnitClick rLKojeESeKi9mdBuPLkiQhCxs4wh8iKy2W
510
+ saddambitcoin rMSEYpzcRtkiA5kkxYEWZtvLr8u3jnn385
511
+ helloworld111 rwGAnUvzT5yrDz6dXxm6MWVhpV9abm39W3
512
+ dykast rQfwn3GVHVEfTpjqU2Y3BoMGAGHrw43XnT
513
+ BurbolGii rDYwnqGbUazEuMfebQwLprCQQXWbYgXTMa
514
+ BC12345 rNy61KXKUYPMFf5fMV6ojo3u98dc5WhiVu
515
+ Eegnylot rPKwrbDS6GC61QF1NuyTCohK926ns2vEG3
516
+ CurbsideProphet rBgpempF56xEyJA9WV55NKZ9VZPJfwMQuZ
517
+ whitehawk501 r3qXCX9hdoFmTdPo7JvjQsbFUfE7UHUBhb
518
+ whitehawk501.1 r3bbiYhxHxseufw9UY5bqN1yCEdHVNKgM3
519
+ reefless r3sAGjHpBW1VN7zerJLxpHj86p9eyrBTqs
520
+ candoo rPSRiivLymK5n7bge9veb4u2bbMPUdRm71
521
+ xenon481 rVY72tekygu4AToFjQsDtL6TDfNXtbCeQ
522
+ gogxmagog rMSaUrYFtNAjV4aGmNEBnEshuYYtttbMkB
523
+ Lanzer rfs635NxEE9FnenYCksy2qx9QHbosemKQD
524
+ Badonkadonk rnorpbuYVYk1u5r2cmEqzaDXdZ93FGjH4o
525
+ Jaques rLVMPwKBxungSYQgiN7HmTa9ndiXSbgzhV
526
+ Geraintjdotcom rNiS1vbeca2p7WxRwA1oS4WtnxXLB9MHsU
527
+ icey rDACCWyQyqfuvt9WxCWBZyqgBEMijLseZm
528
+ thatbluedude rLnCJbgbivWYavZXCdaJ7asHPP31RyXPdk
529
+ montana rUMub4tmRpNRfognEeTcwW5rEbXwrgZLwd
530
+ montana.1 r3t5JvXF6rChFs4kCFe44a3h4eQdxmPo9a
531
+ Cookie_Monster raww2VncvFyPvPCY8xnmb1AoqRxUWb6VdN
532
+ CarlosL rE9hpRfFFqWGxpGYA8bC6GkroRCr4mLLcq
533
+ greendave rPGpKXPSSxwvkpNXM5BtRRFWYjLP1ibH9D
534
+ Darkneo rfQdhMCnjWRP1fd1amNQwe49sMmXgR3uYq
535
+ veteranBtc rUvpjNBcnt4DLKEVA2XyvJi1YGCfp2EPtk
536
+ templeofshadows rJCCwPsVANVfEgQEB2bsEiaTF86cr9fdw4
537
+ manrus rwM8yMFctE9Ffom1AUjr8epViNwXHPC9aP
538
+ shivansps rMxpLTxf7ocTcBdLHbUEeeuF76Vj3VjYvN
539
+ majinx rMeXvtHE3ZeKAdhMfiFdQC5FJvaNDHzjoK
540
+ vite rwRbCNfQa4gnELgttMfCWFXjUo37BigQbz
541
+ WikileaksDude rE7QqUJQWFGu7JZU6E9byysF6Qu5UQjQkP
542
+ supersquish rskbH7JpBCwDfGZdR5o3uuWPhEmZyN4K4Y
543
+ whiskers75 r9mX12CP8eecs2bF4huWNXKEsKYZvheRm4
544
+ rgzen rtYef2QyZRAbaZ5bZGscmMLZd2NpkkVPW
545
+ zerokwel rfEfNCwYy7HbFX5yydvdkkbphMrg1Zk9Hr
546
+ subSTRATA r9YVNp7R1jw7YJPw9gB377C3gd2GTNtuDH
547
+ GrimDeath r4jyYoevUDeAwuncTQfdfWwtXAhWVkL23J
548
+ altoz rsHExT3gM41hbMBp1r1F4ExRH3nvE6XpDS
549
+ bushstar r3irRDtWz7TkatFsxqLpVceai8g1k13GBY
550
+ techsavver rLCxVqJYpAEsoQBymLxk5wTv4Za5HngWXX
551
+ rickowens69 rNpNmErtsWZ7ZMtyPWva4KBJF8hm3nqRUU
552
+ fbastage rLDFWJBHkNLRRDZ7QMUMWokRrLNdto3i2J
553
+ 1541 r994Qbks4PBVz8y75AbWLprW38neUr378N
554
+ wingsuit rhA4ffry3dxHznRLxnjm1LxmDhVepNDpsU
555
+ rpietila r4Qp8oPwXZAdD6XUo19iLvmf5nXR63EBYf
556
+ BlackLilac r3CyBXBprmmXbGNbaJvuof5j279zvMMpFb
557
+ c0ikws rrhB7ScPQkX53iFsdpGccomkq3s13he8pC
558
+ shaitand rBScs5VCwwzPgwYA63aH6WxCUxGQuvhJ7t
559
+ kais3r rNFNE9UMtMAxFqmv5qXFTgPuD17NXsu8Cd
560
+ BitTech r4V9vvqLXPetsnqrr6DuTK5k1wvzfeREgM
561
+ bjornnl rJQvRYhBfZnoMeSR87P9ofeb1Rke2zrsQe
562
+ grue rarcFpWzotLwaouszCRLsqFyJmAsxypwtq
563
+ respcelasa r9Eupo97W5HayeDG5qryDehqauTDtxQAzW
564
+ Mical2xrpbtcxchangr rPDBT1T2KkPGPYsL5QwGuFp9V2RprnpmuN
565
+ fbassett rhZCUSQWcmXjx1jU7HaBUGTvrSfdUccRkJ
566
+ tilt rGmC57N1ocPiQJpBxFWY5KkSMpsjeZWdqF
567
+ wtfvanity rh5WUav67rTmkd7omDyNULa3S3voG2wPRC
568
+ acceptance2 rKho5pU4mg7odtzxk6wUhuNBoHNmFLWFiN
569
+ yokosan rUk91ETJEFtiQsbvDp3zArhT1kG265WmrV
570
+ luicon rp35zKY7ZYgdbxkRLzVSAhY9h5VHU1iQWL
571
+ bomboclat77 rK2h4wqDhKjP33NwBdETpd8HipGrmVVwc8
572
+ UNOE227 rhdRTq54ZBBmH5cNRk1jTcxBBAZzHNk9up
573
+ rcocchiararo rscBj9VNKrw11WfdAcXe4GnHtjF6uUqRqf
574
+ TheJuiceBox rKLWvxDRMiNENqCQPe1qpEeXgBhYUwgryQ
575
+ stepkrav rnSQonMs6KPeVoYUqesYFfY5DSDxUikcLd
576
+ notserp rPPTofqEgidtfpEkEkrtQdQ83kMnn1fiZa
577
+ v7znay rGNNQZo3KXaeC8i33FmbddUk43iRELPkKk
578
+ wannabitcoin rLubad3VQxaeT6qk43jEGPJX7ADkMBkwTM
579
+ webr3 rnW7DHtmZGJk4uhGTSU2BW3iPCPWb2xegg
580
+ WikileaksDude rE7QqUJQWFGu7JZU6E9byysF6Qu5UQjQkP
581
+ LoweryCBS rBiYVjzHRQxMDMdC5ynKsejqoy1qJMQ8zR
582
+ ScratAcorns rEwNm7FWSy4whunsNRCebPbDktjeoGhdbS
583
+ Dreamweaver rnt5BahXixR8PeBwsYXynN6Ew8MCn87GUn
584
+ ]]
542
585
 
543
586
  Addresses = Contacts.invert
544
587
  end
@@ -4,7 +4,7 @@ module Rippler
4
4
  include Rippler::Utils
5
5
 
6
6
  def to_s
7
- "#{Time(self.ledger_time, :unix).strftime("%Y-%m-%d %H:%M:%S")} " +
7
+ "#{Time(self.ledger_time).strftime("%Y-%m-%d %H:%M:%S")} " +
8
8
  "Ledger ##{self.ledger_index}, txn: #{self.txn_count}"
9
9
  end
10
10
  end
data/lib/rippler/money.rb CHANGED
@@ -8,6 +8,8 @@ module Rippler
8
8
  # Hash: {'value' => xx, 'currency' => 'XXX', 'issuer' => 'ZZZZZZZ'}
9
9
  # String: 'value/currency(/issuer)'
10
10
  # Int in a String: XRP amount in drops (x1,000,000)
11
+ # ? Also, generic currency id without value:
12
+ # ? XRP or USD/bitstamp
11
13
  def initialize data
12
14
  case data
13
15
  when Hash
@@ -28,6 +30,7 @@ module Rippler
28
30
  end
29
31
 
30
32
  @value = @value.to_i if @value.to_i == @value
33
+ @issuer = Account(@issuer) if @issuer
31
34
  end
32
35
 
33
36
  # Uniform currency rate presentation
@@ -57,14 +60,18 @@ module Rippler
57
60
 
58
61
  def to_s
59
62
  if @issuer
60
- "#{@value}/#{@currency}/#{Account(@issuer)}"
63
+ "#{@value}/#{@currency}/#{@issuer.name}"
61
64
  else
62
65
  "#{@value}/#{@currency}"
63
66
  end
64
67
  end
65
68
 
66
69
  def to_hash
67
- {'value' => @value.to_s, 'currency' => @currency, 'issuer' => @issuer}
70
+ if @issuer
71
+ {'value' => @value.to_s, 'currency' => @currency, 'issuer' => @issuer.address}
72
+ else
73
+ {'value' => @value.to_s, 'currency' => @currency}
74
+ end
68
75
  end
69
76
  end
70
77
  end
@@ -2,15 +2,26 @@ module Rippler
2
2
  # Represents a single Ripple transaction
3
3
  class Transaction
4
4
  include Rippler::Utils
5
+ include Comparable
5
6
 
6
7
  def initialize data # data Hash
7
8
  @data = data
8
9
  end
9
10
 
11
+ # Pure transaction data, without metadata
12
+ def tx
13
+ @data['tx'] || @data['transaction']
14
+ end
15
+
16
+ def timestring
17
+ if tx
18
+ "#{Time(tx['date']).strftime("%Y-%m-%d %H:%M:%S")} "
19
+ end
20
+ end
21
+
10
22
  def to_s
11
- tx = @data['tx'] || @data['transaction']
12
23
  if tx
13
- "#{Time(tx['date']).strftime("%Y-%m-%d %H:%M:%S")} " +
24
+ timestring +
14
25
  case tx["TransactionType"]
15
26
  when "Payment"
16
27
  "PAY #{Money(tx['Amount'])} #{Account(tx['Account'])} > #{Account(tx['Destination'])}"
@@ -31,4 +42,9 @@ module Rippler
31
42
  end
32
43
  end
33
44
  end
45
+
46
+ # Sort transactions by their timestamps
47
+ def <=> other
48
+ timestring <=> other.timestring
49
+ end
34
50
  end
data/lib/rippler/utils.rb CHANGED
@@ -4,9 +4,8 @@ module Rippler
4
4
  module Utils
5
5
  RIPPLE_TIME_OFFSET = 946684800 # Time.utc(2000,1,1,0,0,0).to_i
6
6
 
7
- def Time(seconds, epoch=:ripple)
8
- seconds = epoch == :ripple ? RIPPLE_TIME_OFFSET + seconds.to_i : seconds.to_i
9
- Time.at(seconds)
7
+ def Time(seconds)
8
+ Time.at(RIPPLE_TIME_OFFSET + seconds.to_i)
10
9
  end
11
10
 
12
11
  def Money(data)
@@ -1,3 +1,3 @@
1
1
  module Rippler
2
- VERSION = "0.0.9"
2
+ VERSION = "0.0.10"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rippler
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.9
4
+ version: 0.0.10
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-03-17 00:00:00.000000000 Z
12
+ date: 2013-03-26 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: faye-websocket