Beispiel #1
0
        public async Task <IPlanet> CreateAsync(string name)
        {
            var planet = await Task.Run(() => _inner.Create(name));

            NewPlanetEvent?.Invoke(this, new NewPlanetEventArgs(planet));
            return(planet);
        }
Beispiel #2
0
        public IPlanet Create(string name)
        {
            var planet = _inner.Create(name);

            NewPlanetEvent?.Invoke(this, new NewPlanetEventArgs(planet));
            return(planet);
        }