From 838e7531648c2b3d86e24894c684c0657f544fc2 Mon Sep 17 00:00:00 2001 From: Shams Asari Date: Tue, 19 Sep 2017 17:36:26 +0100 Subject: [PATCH] Moved PhysicalLocationStructures into finance (#1557) --- docs/source/changelog.rst | 2 ++ .../net/corda/finance/utils}/PhysicalLocationStructures.kt | 2 +- .../src/main/resources/net/corda/finance/utils}/cities.txt | 0 .../kotlin/net/corda/finance/utils}/CityDatabaseTest.kt | 2 +- .../src/main/kotlin/net/corda/netmap/VisualiserViewModel.kt | 2 +- .../main/kotlin/net/corda/netmap/simulation/Simulation.kt | 4 ++-- .../src/main/kotlin/net/corda/testing/node/MockNode.kt | 2 +- .../src/main/kotlin/net/corda/demobench/model/NodeData.kt | 2 +- .../main/kotlin/net/corda/demobench/views/NodeTabView.kt | 4 ++-- .../src/main/kotlin/net/corda/explorer/views/Network.kt | 6 +++--- 10 files changed, 14 insertions(+), 12 deletions(-) rename {core/src/main/kotlin/net/corda/core/node => finance/src/main/kotlin/net/corda/finance/utils}/PhysicalLocationStructures.kt (99%) rename {core/src/main/resources/net/corda/core/node => finance/src/main/resources/net/corda/finance/utils}/cities.txt (100%) rename {core/src/test/kotlin/net/corda/core/node => finance/src/test/kotlin/net/corda/finance/utils}/CityDatabaseTest.kt (91%) diff --git a/docs/source/changelog.rst b/docs/source/changelog.rst index bc370af2b6..dab2a42814 100644 --- a/docs/source/changelog.rst +++ b/docs/source/changelog.rst @@ -152,6 +152,8 @@ UNRELEASED * ``X509CertificateHolder`` has been removed from the public API, replaced by ``java.security.X509Certificate``. +* Moved ``CityDatabase`` out of ``core`` and into ``finance`` + Milestone 14 ------------ diff --git a/core/src/main/kotlin/net/corda/core/node/PhysicalLocationStructures.kt b/finance/src/main/kotlin/net/corda/finance/utils/PhysicalLocationStructures.kt similarity index 99% rename from core/src/main/kotlin/net/corda/core/node/PhysicalLocationStructures.kt rename to finance/src/main/kotlin/net/corda/finance/utils/PhysicalLocationStructures.kt index 754fbbc44e..5277921bd1 100644 --- a/core/src/main/kotlin/net/corda/core/node/PhysicalLocationStructures.kt +++ b/finance/src/main/kotlin/net/corda/finance/utils/PhysicalLocationStructures.kt @@ -1,4 +1,4 @@ -package net.corda.core.node +package net.corda.finance.utils import net.corda.core.serialization.CordaSerializable import java.util.* diff --git a/core/src/main/resources/net/corda/core/node/cities.txt b/finance/src/main/resources/net/corda/finance/utils/cities.txt similarity index 100% rename from core/src/main/resources/net/corda/core/node/cities.txt rename to finance/src/main/resources/net/corda/finance/utils/cities.txt diff --git a/core/src/test/kotlin/net/corda/core/node/CityDatabaseTest.kt b/finance/src/test/kotlin/net/corda/finance/utils/CityDatabaseTest.kt similarity index 91% rename from core/src/test/kotlin/net/corda/core/node/CityDatabaseTest.kt rename to finance/src/test/kotlin/net/corda/finance/utils/CityDatabaseTest.kt index a9d3bcda6a..e0e5036146 100644 --- a/core/src/test/kotlin/net/corda/core/node/CityDatabaseTest.kt +++ b/finance/src/test/kotlin/net/corda/finance/utils/CityDatabaseTest.kt @@ -1,4 +1,4 @@ -package net.corda.core.node +package net.corda.finance.utils import org.junit.Assert.assertEquals import org.junit.Test diff --git a/samples/network-visualiser/src/main/kotlin/net/corda/netmap/VisualiserViewModel.kt b/samples/network-visualiser/src/main/kotlin/net/corda/netmap/VisualiserViewModel.kt index ec3aea5111..f9751e8d6c 100644 --- a/samples/network-visualiser/src/main/kotlin/net/corda/netmap/VisualiserViewModel.kt +++ b/samples/network-visualiser/src/main/kotlin/net/corda/netmap/VisualiserViewModel.kt @@ -8,8 +8,8 @@ import javafx.scene.shape.Circle import javafx.scene.shape.Line import javafx.util.Duration import net.corda.core.identity.CordaX500Name -import net.corda.core.node.ScreenCoordinate import net.corda.core.utilities.ProgressTracker +import net.corda.finance.utils.ScreenCoordinate import net.corda.netmap.simulation.IRSSimulation import net.corda.testing.chooseIdentity import net.corda.testing.node.MockNetwork diff --git a/samples/network-visualiser/src/main/kotlin/net/corda/netmap/simulation/Simulation.kt b/samples/network-visualiser/src/main/kotlin/net/corda/netmap/simulation/Simulation.kt index 89509aefa0..a466501651 100644 --- a/samples/network-visualiser/src/main/kotlin/net/corda/netmap/simulation/Simulation.kt +++ b/samples/network-visualiser/src/main/kotlin/net/corda/netmap/simulation/Simulation.kt @@ -2,10 +2,10 @@ package net.corda.netmap.simulation import net.corda.core.flows.FlowLogic import net.corda.core.identity.CordaX500Name +import net.corda.finance.utils.CityDatabase +import net.corda.finance.utils.WorldMapLocation import net.corda.core.internal.uncheckedCast import net.corda.core.messaging.SingleMessageRecipient -import net.corda.core.node.CityDatabase -import net.corda.core.node.WorldMapLocation import net.corda.core.node.services.ServiceInfo import net.corda.core.node.services.ServiceType import net.corda.core.utilities.ProgressTracker diff --git a/testing/node-driver/src/main/kotlin/net/corda/testing/node/MockNode.kt b/testing/node-driver/src/main/kotlin/net/corda/testing/node/MockNode.kt index 75b6b27a4d..0e79451095 100644 --- a/testing/node-driver/src/main/kotlin/net/corda/testing/node/MockNode.kt +++ b/testing/node-driver/src/main/kotlin/net/corda/testing/node/MockNode.kt @@ -17,11 +17,11 @@ import net.corda.core.messaging.RPCOps import net.corda.core.messaging.SingleMessageRecipient import net.corda.core.node.CordaPluginRegistry import net.corda.core.node.ServiceEntry -import net.corda.core.node.WorldMapLocation import net.corda.core.node.services.* import net.corda.core.utilities.NetworkHostAndPort import net.corda.core.utilities.getOrThrow import net.corda.core.utilities.loggerFor +import net.corda.finance.utils.WorldMapLocation import net.corda.node.internal.AbstractNode import net.corda.node.internal.StartedNode import net.corda.node.services.config.NodeConfiguration diff --git a/tools/demobench/src/main/kotlin/net/corda/demobench/model/NodeData.kt b/tools/demobench/src/main/kotlin/net/corda/demobench/model/NodeData.kt index e4f234fa10..90147c5b43 100644 --- a/tools/demobench/src/main/kotlin/net/corda/demobench/model/NodeData.kt +++ b/tools/demobench/src/main/kotlin/net/corda/demobench/model/NodeData.kt @@ -4,7 +4,7 @@ import javafx.beans.property.SimpleIntegerProperty import javafx.beans.property.SimpleListProperty import javafx.beans.property.SimpleObjectProperty import javafx.beans.property.SimpleStringProperty -import net.corda.core.node.CityDatabase +import net.corda.finance.utils.CityDatabase import tornadofx.* object SuggestedDetails { diff --git a/tools/demobench/src/main/kotlin/net/corda/demobench/views/NodeTabView.kt b/tools/demobench/src/main/kotlin/net/corda/demobench/views/NodeTabView.kt index 16fe779134..8f3ec2d19d 100644 --- a/tools/demobench/src/main/kotlin/net/corda/demobench/views/NodeTabView.kt +++ b/tools/demobench/src/main/kotlin/net/corda/demobench/views/NodeTabView.kt @@ -15,8 +15,8 @@ import javafx.scene.layout.Priority import javafx.stage.FileChooser import javafx.util.StringConverter import net.corda.core.internal.* -import net.corda.core.node.CityDatabase -import net.corda.core.node.WorldMapLocation +import net.corda.finance.utils.CityDatabase +import net.corda.finance.utils.WorldMapLocation import net.corda.demobench.model.* import net.corda.demobench.ui.CloseableTab import org.controlsfx.control.CheckListView diff --git a/tools/explorer/src/main/kotlin/net/corda/explorer/views/Network.kt b/tools/explorer/src/main/kotlin/net/corda/explorer/views/Network.kt index cada329cc1..c3bff3753e 100644 --- a/tools/explorer/src/main/kotlin/net/corda/explorer/views/Network.kt +++ b/tools/explorer/src/main/kotlin/net/corda/explorer/views/Network.kt @@ -28,13 +28,13 @@ import net.corda.client.jfx.model.* import net.corda.client.jfx.utils.* import net.corda.core.contracts.ContractState import net.corda.core.identity.Party -import net.corda.core.node.CityDatabase import net.corda.core.node.NodeInfo -import net.corda.core.node.ScreenCoordinate -import net.corda.core.node.WorldMapLocation import net.corda.core.utilities.toBase58String import net.corda.explorer.formatters.PartyNameFormatter import net.corda.explorer.model.CordaView +import net.corda.finance.utils.CityDatabase +import net.corda.finance.utils.ScreenCoordinate +import net.corda.finance.utils.WorldMapLocation import tornadofx.* class Network : CordaView() {