Esempio n. 1
0
        public override string GetWktContent()
        {
            if (InnerRings.Any())
            {
                return(string.Format("(({0}),({1}))", OuterRing.ToWktSyntax(), InnerRings.Select(x => x.ToWktSyntax()).Join("),(")));
            }

            return(string.Format("(({0}))", OuterRing.ToWktSyntax()));
        }
Esempio n. 2
0
        public override int GetHashCode()
        {
            unchecked
            {
                int hashCode = Data.GetHashCode();

                hashCode = (hashCode * 397) ^ OuterRing.GetHashCode();

                foreach (MacroStabilityInwardsSoilLayer2D nestedLayer in NestedLayers)
                {
                    hashCode = (hashCode * 397) ^ nestedLayer.GetHashCode();
                }

                return(hashCode);
            }
        }
Esempio n. 3
0
 private bool Equals(MacroStabilityInwardsSoilLayer2D other)
 {
     return(Data.Equals(other.Data) &&
            OuterRing.Equals(other.OuterRing) &&
            NestedLayers.SequenceEqual(other.NestedLayers));
 }