Esempio n. 1
0
            public void SetAssemblies(IEnumerable <Assembly> assemblies)
            {
                _Assemblies = assemblies
                              .ExceptNulls()
                              .Distinct()
                              .ToArray();

                _SettingsTypes = ContentObjectInfo.GetContentTypes(_Assemblies).ToArray();
                _PluginTypes   = ContentFilterInfo.GetContentTypes(_Assemblies).ToArray();
            }
Esempio n. 2
0
 /// <summary>
 /// Gets a specialised TypeInfo with extra information about a ContentFilter
 /// </summary>
 /// <param name="t">Any type, but designed for <code>SDK.ContentFilter</code> derived types</param>
 /// <returns>A <code>ContentFilterTypeInfo</code> instace for valid <code>SDK.ContentFilter</code>, and <code>UnknownTypeInfo</code> for everything else</returns>
 public static ContentBaseInfo GetContentInfo(this Type t)
 {
     if (t == null)
     {
         return(null);
     }
     if (typeof(SDK.ContentFilter).GetTypeInfo().IsAssignableFrom(t))
     {
         return(ContentFilterInfo.Create(t));
     }
     return(ContentObjectInfo.Create(t));
 }