Esempio n. 1
0
        private string GetLink()
        {
            if (OSMData.IsParent())
            {
                return($"https://wiki.openstreetmap.org/wiki/Key:{this.OSMData.Value}");
            }

            return($"https://wiki.openstreetmap.org/wiki/Tag:{this.OSMData.Key}={this.OSMData.Value}");
        }
        public void TestKeyValueParsingA() // E.g. defined subfeatures without a primary feature
        {
            var miscA = new OSMTag("capacity=charging");

            Assert.AreEqual(miscA.ToString(), "capacity=charging");
            Assert.AreEqual(miscA.IsParent(), false);

            Assert.AreEqual(miscA.Key.ToString(), "capacity=*");
            Assert.AreEqual(miscA.Key.IsParent(), true);
        }