Get() public method

Returns the listener config for a specified listener type.
public Get ( Type listenerType ) : EventListenerConfig
listenerType System.Type the type to look for
return EventListenerConfig
Esempio n. 1
0
 private static void ProcessEventListenerAssemblyAttributes(EventListenerContributor contributor, IEnumerable <EventListenerAssemblyAttribute> attributes)
 {
     foreach (var attribute in attributes)
     {
         if (attribute.Assembly != null)
         {
             foreach (var type in GetExportedTypesFromAssembly(attribute.Assembly))
             {
                 if (EventListenerContributor.GetEventTypes(type).Length > 0)
                 {
                     var config = contributor.Get(type) ?? contributor.Add(new EventListenerConfig(type));
                     ConfigureEventListener(attribute, config);
                 }
             }
         }
         if (attribute.Type != null)
         {
             var config = contributor.Get(attribute.Type) ?? contributor.Add(new EventListenerConfig(attribute.Type));
             ConfigureEventListener(attribute, config);
         }
     }
 }