QuantLib: a free/open-source library for quantitative finance
fully annotated source code - version 1.38
Loading...
Searching...
No Matches
crypto.cpp
Go to the documentation of this file.
1/* -*- mode: c++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2
3/*
4 Copyright (C) 2004, 2005 StatPro Italia srl
5
6 This file is part of QuantLib, a free-software/open-source library
7 for financial quantitative analysts and developers - http://quantlib.org/
8
9 QuantLib is free software: you can redistribute it and/or modify it
10 under the terms of the QuantLib license. You should have received a
11 copy of the license along with this program; if not, please email
12 <quantlib-dev@lists.sf.net>. The license is also available online at
13 <http://quantlib.org/license.shtml>.
14
15 This program is distributed in the hope that it will be useful, but WITHOUT
16 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
17 FOR A PARTICULAR PURPOSE. See the license for more details.
18*/
19
20/*
21 Data from http://fx.sauder.ubc.ca/currency_table.html
22 and http://www.thefinancials.com/vortex/CurrencyFormats.html
23*/
24
26
27namespace QuantLib {
28
29 // Bitcoin
30 /* https://bitcoin.org/
31 */
33 static auto btcData = ext::make_shared<Data>("Bitcoin", "BTC", 10000, "BTC", "", 100000, Rounding());
34 data_ = btcData;
35 }
36
37 //! Ethereum
38 /*! https://www.ethereum.org/
39 */
41 static auto ethData = ext::make_shared<Data>("Ethereum", "ETH", 10001, "ETH", "", 100000, Rounding());
42 data_ = ethData;
43 }
44
45 //! Ethereum Classic
46 /*! https://ethereumclassic.github.io/
47 */
49 static auto etcData = ext::make_shared<Data>("Ethereum Classic", "ETC", 10002, "ETC", "", 100000, Rounding());
50 data_ = etcData;
51 }
52
53 //! Bitcoin Cash
54 /*! https://www.bitcoincash.org/
55 */
57 static auto bchData = ext::make_shared<Data>("Bitcoin Cash", "BCH", 10003, "BCH", "", 100000, Rounding());
58 data_ = bchData;
59 }
60
61 //! Ripple
62 /*! https://ripple.com/
63 */
65 static auto xrpData = ext::make_shared<Data>("Ripple", "XRP", 10004, "XRP", "", 100000, Rounding());
66 data_ = xrpData;
67 }
68
69 //! Litecoin
70 /*! https://litecoin.com/
71 */
73 static auto ltcData = ext::make_shared<Data>("Litecoin", "LTC", 10005, "LTC", "", 100000, Rounding());
74 data_ = ltcData;
75 }
76
77 //! Dash coin
78 /*! https://www.dash.org/
79 */
81 static auto dashData = ext::make_shared<Data>("Dash coin", "DASH", 10006, "DASH", "", 100000, Rounding());
82 data_ = dashData;
83 }
84
85 //! Zcash
86 /*! https://z.cash/
87 */
89 static auto zecData = ext::make_shared<Data>("Zcash", "ZEC", 10007, "ZEC", "", 100000, Rounding());
90 data_ = zecData;
91 }
92
93}
94
BCHCurrency()
Bitcoin Cash.
Definition: crypto.cpp:56
ext::shared_ptr< Data > data_
Definition: currency.hpp:85
DASHCurrency()
Dash coin.
Definition: crypto.cpp:80
ETCCurrency()
Ethereum Classic.
Definition: crypto.cpp:48
ETHCurrency()
Ethereum.
Definition: crypto.cpp:40
LTCCurrency()
Litecoin.
Definition: crypto.cpp:72
basic rounding class
Definition: rounding.hpp:35
XRPCurrency()
Ripple.
Definition: crypto.cpp:64
crypto currencies
Definition: any.hpp:37