Ejemplo n.º 1
0
        public bool TryGetVolSurface(string name, out IVolSurface volSurface)
        {
            if (VolSurfaces.TryGetValue(name, out volSurface))
            {
                return(true);
            }

            if (TryGetInverseSurface(name, out volSurface))
            {
                return(true);
            }

            volSurface = null;
            return(false);
        }
Ejemplo n.º 2
0
 public IVolSurface GetVolSurface(string name) => VolSurfaces.TryGetValue(name, out var curve) ? curve : throw new Exception($"Surface named {name} not found");
Ejemplo n.º 3
0
        private bool TryGetInverseSurface(string name, out IVolSurface volSurface)
        {
            var inverseName = name.Substring(name.Length - 3, 3) + "/" + name.Substring(0, 3);

            return(VolSurfaces.TryGetValue(inverseName, out volSurface));
        }