Ejemplo n.º 1
0
 /// <summary>
 /// Gets the list of missing dependencies from the current implementation.
 /// </summary>
 /// <param name="map">The implementation map.</param>
 /// <returns>A list of missing dependencies.</returns>
 public IEnumerable <IDependency> GetMissingDependencies(IDependencyContainer map)
 {
     foreach (var dependency in GetRequiredDependencies(map))
     {
         if (!map.Contains(dependency))
         {
             yield return(dependency);
         }
     }
 }
Ejemplo n.º 2
0
        /// <summary>
        /// Creates a new instance of the RootMain and returns it.
        /// </summary>
        public static new Root3D Create(IDependencyContainer dependency)
        {
            var root = new GameObject("Root3D").AddComponent <Root3D>();

            if (dependency != null)
            {
                dependency.Inject(root);

                if (!dependency.Contains <IRoot>())
                {
                    dependency.CacheAs <IRoot>(root);
                }
            }
            return(root);
        }
Ejemplo n.º 3
0
 /// <summary>
 /// Gets the list of missing dependencies from the current implementation.
 /// </summary>
 /// <param name="map">The implementation map.</param>
 /// <returns>A list of missing dependencies.</returns>
 public IEnumerable<IDependency> GetMissingDependencies(IDependencyContainer map)
 {
     foreach (var dependency in GetRequiredDependencies(map))
     {
         if (!map.Contains(dependency))
             yield return dependency;
     }
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Gets the list of missing dependencies from the current implementation.
 /// </summary>
 /// <param name="map">The implementation map.</param>
 /// <returns>A list of missing dependencies.</returns>
 public IEnumerable <IDependency> GetMissingDependencies(IDependencyContainer map)
 {
     return(GetRequiredDependencies(map).Where(dependency => !map.Contains(dependency)));
 }