Ejemplo n.º 1
0
        /// <summary>
        /// Get configuration info for all services of a given service type
        /// </summary>
        /// <typeparam name="SI">Service info type you're looking for</typeparam>
        /// <param name="config">Configuration to search</param>
        /// <returns>List of service infos</returns>
        public static List <SI> GetServiceInfos <SI>(this IConfiguration config)
            where SI : class
        {
            CloudFoundryServiceInfoCreator factory = CloudFoundryServiceInfoCreator.Instance(config);

            return(factory.GetServiceInfos <SI>());
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Get configuration info for all services of a given service type
        /// </summary>
        /// <param name="config">Configuration to search</param>
        /// <param name="infoType">Type to search for</param>
        /// <returns>A list of relevant <see cref="IServiceInfo"/></returns>
        public static List <IServiceInfo> GetServiceInfos(this IConfiguration config, Type infoType)
        {
            CloudFoundryServiceInfoCreator factory = CloudFoundryServiceInfoCreator.Instance(config);

            return(factory.GetServiceInfos(infoType));
        }