Skip to content
This repository has been archived by the owner on Jun 17, 2020. It is now read-only.

List Tamadcoin (TMC) #50

Closed
wants to merge 12 commits into from
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1 @@
# bisq-core
# bisq-core (by tamadcoin)
28 changes: 28 additions & 0 deletions src/main/java/bisq/asset/coins/Tamadcoin.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
/*
* This file is part of Bisq.
*
* Bisq is free software: you can redistribute it and/or modify it
* under the terms of the GNU Affero General Public License as published by
* the Free Software Foundation, either version 3 of the License, or (at
* your option) any later version.
*
* Bisq is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public
* License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with Bisq. If not, see <http://www.gnu.org/licenses/>.
*/

package bisq.asset.coins;

import bisq.asset.Coin;
import bisq.asset.RegexAddressValidator;

public class Tamadcoin extends Coin {

public Tamadcoin() {
super("Tamadcoin", "TMC", new RegexAddressValidator("^ax[A-Z][0-9ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{1,97}$"));
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -306,6 +306,7 @@ private void printAllCurrencyStats() {
newlyAdded.add("GEO");
newlyAdded.add("GRANS");
newlyAdded.add("ICH");
newlyAdded.add("TMC");

coinsWithValidator.addAll(newlyAdded);

Expand Down
1 change: 1 addition & 0 deletions src/main/resources/META-INF/services/bisq.asset.Asset
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ bisq.asset.coins.SpeedCash
bisq.asset.coins.STEEM
bisq.asset.coins.Stellite
bisq.asset.coins.Strayacoin
bisq.asset.coins.Tamadcoin
bisq.asset.coins.Terracoin
bisq.asset.coins.Ubiq
bisq.asset.coins.Unobtanium
Expand Down
28 changes: 14 additions & 14 deletions src/main/resources/i18n/displayStrings.properties
Original file line number Diff line number Diff line change
Expand Up @@ -98,15 +98,15 @@ shared.faq=Visit FAQ web page
shared.yesCancel=Yes, cancel
shared.nextStep=Next step
shared.selectTradingAccount=Select trading account
shared.fundFromSavingsWalletButton=Transfer funds from Bisq wallet
shared.fundFromSavingsWalletButton=Transfer funds from BASX wallet
shared.fundFromExternalWalletButton=Open your external wallet for funding
shared.openDefaultWalletFailed=Opening a default bitcoin wallet application has failed. Perhaps you don't have one installed?
shared.distanceInPercent=Distance in % from market price
shared.belowInPercent=Below % from market price
shared.aboveInPercent=Above % from market price
shared.enterPercentageValue=Enter % value
shared.OR=OR
shared.notEnoughFunds=You don''t have enough funds in your Bisq wallet.\nYou need {0} but you have only {1} in your Bisq wallet.\n\nPlease fund that trade from an external Bitcoin wallet or fund your Bisq wallet at \"Funds/Receive funds\".
shared.notEnoughFunds=You don''t have enough funds in your BASX wallet.\nYou need {0} but you have only {1} in your BASX wallet.\n\nPlease fund that trade from an external Bitcoin wallet or fund your BASX wallet at \"Funds/Receive funds\".
shared.waitingForFunds=Waiting for funds...
shared.depositTransactionId=Deposit transaction ID
shared.TheBTCBuyer=The BTC buyer
Expand Down Expand Up @@ -220,9 +220,9 @@ mainView.menu.account=Account
mainView.menu.dao=DAO

mainView.marketPrice.provider=Market price provider:
mainView.marketPrice.bisqInternalPrice=Price of latest Bisq trade
mainView.marketPrice.bisqInternalPrice=Price of latest BASX trade
mainView.marketPrice.tooltip.bisqInternalPrice=There is no market price from external price feed providers available.\n\
The displayed price is the latest Bisq trade price for that currency.
The displayed price is the latest BASX trade price for that currency.
mainView.marketPrice.tooltip=Market price is provided by {0}{1}\nLast update: {2}\nProvider node URL: {3}
mainView.marketPrice.tooltip.altcoinExtra=If the altcoin is not available at Poloniex we use https://coinmarketcap.com
mainView.balance.available=Available balance
Expand Down Expand Up @@ -254,7 +254,7 @@ mainView.walletServiceErrorMsg.timeout=Connecting to the bitcoin network failed
mainView.walletServiceErrorMsg.connectionError=Connection to the bitcoin network failed because of an error: {0}

mainView.networkWarning.allConnectionsLost=You lost the connection to all {0} network peers.\nMaybe you lost your internet connection or your computer was in standby mode.
mainView.networkWarning.localhostBitcoinLost=You lost the connection to the localhost Bitcoin node.\nPlease restart the Bisq application to connect to other Bitcoin nodes or restart the localhost Bitcoin node.
mainView.networkWarning.localhostBitcoinLost=You lost the connection to the localhost Bitcoin node.\nPlease restart the BASX application to connect to other Bitcoin nodes or restart the localhost Bitcoin node.
mainView.version.update=(Update available)


Expand Down Expand Up @@ -383,18 +383,18 @@ createOffer.warning.buyAboveMarketPrice=You will always pay {0}% more than the c

# new entries
createOffer.placeOfferButton=Review: Place offer to {0} bitcoin
createOffer.alreadyFunded=You had already funded that offer.\nYour funds have been moved to your local Bisq wallet and are available for withdrawal in the \"Funds/Send funds\" screen.
createOffer.alreadyFunded=You had already funded that offer.\nYour funds have been moved to your local BASX wallet and are available for withdrawal in the \"Funds/Send funds\" screen.
createOffer.createOfferFundWalletInfo.headline=Fund your offer
# suppress inspection "TrailingSpacesInProperty"
createOffer.createOfferFundWalletInfo.tradeAmount=- Trade amount: {0} \n
createOffer.createOfferFundWalletInfo.msg=You need to deposit {0} to this offer.\n\nThose funds are reserved in your local wallet and will get locked into the Multisig deposit address once someone takes your offer.\n\nThe amount is the sum of:\n{1}- Your security deposit: {2}\n- Trading fee: {3}\n- Mining fee: {4}\n\nYou can choose between two options when funding your trade:\n- Use your Bisq wallet (convenient, but transactions may be linkable) OR\n- Transfer from an external wallet (potentially more private)\n\nYou will see all funding options and details after closing this popup.
createOffer.createOfferFundWalletInfo.msg=You need to deposit {0} to this offer.\n\nThose funds are reserved in your local wallet and will get locked into the Multisig deposit address once someone takes your offer.\n\nThe amount is the sum of:\n{1}- Your security deposit: {2}\n- Trading fee: {3}\n- Mining fee: {4}\n\nYou can choose between two options when funding your trade:\n- Use your BASX wallet (convenient, but transactions may be linkable) OR\n- Transfer from an external wallet (potentially more private)\n\nYou will see all funding options and details after closing this popup.

# only first part "An error occurred when placing the offer:" has been used before. We added now the rest (need update in existing translations!)
createOffer.amountPriceBox.error.message=An error occurred when placing the offer:\n\n{0}\n\n\
No funds have left your wallet yet.\n\
Please restart your application and check your network connection.
createOffer.setAmountPrice=Set amount and price
createOffer.warnCancelOffer=You have already funded that offer.\nIf you cancel now, your funds will be moved to your local Bisq wallet and are available for withdrawal in the \"Funds/Send funds\" screen.\nAre you sure you want to cancel?
createOffer.warnCancelOffer=You have already funded that offer.\nIf you cancel now, your funds will be moved to your local BASX wallet and are available for withdrawal in the \"Funds/Send funds\" screen.\nAre you sure you want to cancel?
createOffer.fixed=Fixed
createOffer.percentage=Percentage
createOffer.timeoutAtPublishing=A timeout occurred at publishing the offer.
Expand Down Expand Up @@ -442,15 +442,15 @@ takeOffer.error.message=An error occurred when taking the offer.\n\n{0}
# new entries
takeOffer.takeOfferButton=Review: Take offer to {0} bitcoin
takeOffer.noPriceFeedAvailable=You cannot take that offer as it uses a percentage price based on the market price but there is no price feed available.
takeOffer.alreadyFunded.movedFunds=You had already funded that offer.\nYour funds have been moved to your local Bisq wallet and are available for withdrawal in the \"Funds/Send funds\" screen.
takeOffer.alreadyFunded.movedFunds=You had already funded that offer.\nYour funds have been moved to your local BASX wallet and are available for withdrawal in the \"Funds/Send funds\" screen.
takeOffer.takeOfferFundWalletInfo.headline=Fund your trade
# suppress inspection "TrailingSpacesInProperty"
takeOffer.takeOfferFundWalletInfo.tradeAmount=- Trade amount: {0} \n
takeOffer.takeOfferFundWalletInfo.msg=You need to deposit {0} for taking this offer.\n\nThe amount is the sum of:\n{1}- Your security deposit: {2}\n- Trading fee: {3}\n- Total mining fees: {4}\n\nYou can choose between two options when funding your trade:\n- Use your Bisq wallet (convenient, but transactions may be linkable) OR\n- Transfer from an external wallet (potentially more private)\n\nYou will see all funding options and details after closing this popup.
takeOffer.takeOfferFundWalletInfo.msg=You need to deposit {0} for taking this offer.\n\nThe amount is the sum of:\n{1}- Your security deposit: {2}\n- Trading fee: {3}\n- Total mining fees: {4}\n\nYou can choose between two options when funding your trade:\n- Use your BASX wallet (convenient, but transactions may be linkable) OR\n- Transfer from an external wallet (potentially more private)\n\nYou will see all funding options and details after closing this popup.
takeOffer.alreadyPaidInFunds=If you have already paid in funds you can withdraw it in the \"Funds/Send funds\" screen.
takeOffer.paymentInfo=Payment info
takeOffer.setAmountPrice=Set amount
takeOffer.alreadyFunded.askCancel=You have already funded that offer.\nIf you cancel now, your funds will be moved to your local Bisq wallet and are available for withdrawal in the \"Funds/Send funds\" screen.\nAre you sure you want to cancel?
takeOffer.alreadyFunded.askCancel=You have already funded that offer.\nIf you cancel now, your funds will be moved to your local BASX wallet and are available for withdrawal in the \"Funds/Send funds\" screen.\nAre you sure you want to cancel?
takeOffer.failed.offerNotAvailable=Take offer request failed because the offer is not available anymore. Maybe another trader has taken the offer in the meantime.
takeOffer.failed.offerTaken=You cannot take that offer because the offer was already taken by another trader.
takeOffer.failed.offerRemoved=You cannot take that offer because the offer has been removed in the meantime.
Expand Down Expand Up @@ -748,7 +748,7 @@ support.buyerOfferer=BTC buyer/Maker
support.sellerOfferer=BTC seller/Maker
support.buyerTaker=BTC buyer/Taker
support.sellerTaker=BTC seller/Taker
support.backgroundInfo=Bisq is not a company and not operating any kind of customer support.\n\n\
support.backgroundInfo=BASX (or Bisq for Alabang Stock Exchange) is a fork from Bisq P2P, is provided by Hueburg Solutions for free and not operating any kind of customer support.\n\n\
If there are disputes in the trade process (e.g. one trader does not follow the trade protocol) \
the application will display a \"Open dispute\" button after the trade period is over \
for contacting the arbitrator.\n\
Expand Down Expand Up @@ -860,8 +860,8 @@ After the restart it can take a while for resyncing with the network and you wil
settings.net.reSyncSPVAfterRestart=The SPV chain file has been deleted. Please have patience, it can take a while when resyncing with the network.
settings.net.reSyncSPVAfterRestartCompleted=The resync is now completed. Please restart the application.
settings.net.reSyncSPVFailed=Could not delete SPV chain file.\nError: {0}
setting.about.aboutBisq=About Bisq
setting.about.about=Bisq is an open source project and a decentralized network of users who want to exchange Bitcoin with national currencies or alternative crypto currencies in a privacy protecting way. Learn more about Bisq on our project web page.
setting.about.aboutBisq=About BASX (Bisq for Alabang Stock Exchange)
setting.about.about=BASX (Bisq for Alabang Stock Exchange) is an open source project and a decentralized network of users who want to exchange Bitcoin with national currencies or alternative crypto currencies in a privacy protecting way. Learn more about Bisq on our project web page.
setting.about.web=Bisq web page
setting.about.code=Source code
setting.about.agpl=AGPL License
Expand Down
46 changes: 46 additions & 0 deletions src/test/java/bisq/asset/coins/TamadcoinTest.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
/*
* This file is part of Bisq.
*
* Bisq is free software: you can redistribute it and/or modify it
* under the terms of the GNU Affero General Public License as published by
* the Free Software Foundation, either version 3 of the License, or (at
* your option) any later version.
*
* Bisq is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public
* License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with Bisq. If not, see <http://www.gnu.org/licenses/>.
*/

package bisq.asset.coins;

import bisq.asset.AbstractAssetTest;

import org.junit.Test;

public class TamadcoinTest extends AbstractAssetTest {

public TamadcoinTest() {
super(new Tamadcoin());
}

@Test
public void testValidAddresses() {
assertValidAddress("axRehEfp5BjgHsZKXBECdDgLZPrgmCaXxKxy7P8Z6J3qDbJcQK5v9fDc3SBHoiuQCYa6aUoARJ3b7FyeGHKDJLoq2es58GXi4");
assertValidAddress("axRpWzdirPe7njtxevGCzhUoDZnsa3ncdHyiebYcDqGwXR6R5CyAa79c3SBHoiuQCYa6aUoARJ3b7FyeGHKDJLoq2es9JwJXd");
assertValidAddress("axR311K1J6GRmCXmFaegZdc7v4Nv5f3c5Hv6bK84txRMGqeNbuVrr15c3SBHoiuQCYa6aUoARJ3b7FyeGHKDJLoq2es5dqYJy");
assertValidAddress("axRSb2PovsKLS4JaVXEdH4gQfEhCLFcykYUnsRPtxa4Y89nZZrbRtYXc3SBHoiuQCYa6aUoARJ3b7FyeGHKDJLoq2es5s9k2F");
}

@Test
public void testInvalidAddresses() {
assertInvalidAddress("axrehEfp5BjgHsZKXBECdDgLZPrgmCaXxKxy7P8Z6J3qDbJcQK5v9fDc3SBHoiuQCYa6aUoARJ3b7Fye");
assertInvalidAddress("AxRpWzdirPe7njtxevGCzhUoDZnsa3ncdHyiebYcDqGwXR6");
assertInvalidAddress("axss311K1J6GRmCXmFaegZdc7v4Nv5f3c5Hv6bK84txRMGqeNbuVrr15c3SBHoiuQCYa6aUoARJ3b7FyeGHKDJLoq2es5dqYJy");
assertInvalidAddress("axaSb2PovsKLS4JaVXEdH4gQfEhCLFcykYUnsRPtxa4Y89nZZrbRtYXc3SBHoiuQCYa6aUoARJ3b7FyeGHKDJLoq2es5s9k2F");

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -988,6 +988,7 @@ public void testPHR() {
assertFalse(validator.validate("").isValid);
}


private void testDefaultValidator(String currencyCode) {
validator.setCurrencyCode(currencyCode);

Expand All @@ -1012,4 +1013,7 @@ private void testErc20Address(String currencyCode) {
assertFalse(validator.validate("2a65Aca4D5fC5B5C859090a6c34d16413539822g").isValid);
assertFalse(validator.validate("").isValid);
}



}