Register a plugin

@param pluginType Plugin type
191111
public <T extends SimonConsolePlugin> void addPlugin(Class<T> pluginType) {
		try {
			SimonConsolePlugin plugin = pluginType.newInstance();
			addPlugin(plugin);
		} catch (InstantiationException | IllegalAccessException instantiationException) {
			throw new IllegalArgumentException("Invalid plugin type " + pluginType.getName(), instantiationException);
		}
	}
873843
def register(name, mod, options)
      elements[name] = plugin_type.new(mod, options)
    end
784218
public void addPlugin(ComponentPlugin plugin)
   {
      if (plugin instanceof AddActionsPlugin)
      {
         AddActionsPlugin cplugin = (AddActionsPlugin)plugin;
         for (ActionConfiguration ac : cplugin.getActions())
         {
            try
            {
               SessionEventMatcher matcher =
                  new SessionEventMatcher(getEventTypes(ac.getEventTypes()), getPaths(ac.getPath()), ac.isDeep(),
                     getWorkspaces(ac.getWorkspace()), getNames(ac.getNodeTypes()), typeDataManager);

               Action action =
                  ac.getAction() != null ? ac.getAction() : (Action)ClassLoading.forName(ac.getActionClassName(), this)
                     .newInstance();

               addAction(matcher, action);
            }
            catch (Exception e)
            {
               log.error(e.getLocalizedMessage(), e);
            }
         }
      }
   }
1188446
protected void registerColumnType(String columnType, int jdbcType) {
        columnTypeMatchers.add(new ColumnTypeMatcher(columnType));
        jdbcTypes.put(columnType, jdbcType);
    }
669008
public static synchronized void register(JSONObject type) {
    Class<? extends JSONObject> previous = registrations.put(type.getIdentifier(), type.getClass());
    if (previous != null && !previous.isInstance(type))
      throw new RuntimeException("Attempt to register conflicting classes for identifier: " + type.getIdentifier());
    if (previous == null)
      log.debug("Registered {} to {}", type.getIdentifier(), type.getClass());
  }
111708
public void addPluginClass(final String jobTypeName,
      final Class<? extends Job> jobTypeClass) {
    this.jobToClass.put(jobTypeName, jobTypeClass);
  }
1366093
public void register(FoxHttpInterceptorType interceptorType, FoxHttpInterceptor foxHttpInterceptor) throws FoxHttpException {
        FoxHttpInterceptorType.verifyInterceptor(interceptorType, foxHttpInterceptor);
        if (foxHttpInterceptors.containsKey(interceptorType)) {
            foxHttpInterceptors.get(interceptorType).add(foxHttpInterceptor);
        } else {
            foxHttpInterceptors.put(interceptorType, new ArrayList<>(Arrays.asList(foxHttpInterceptor)));
        }
    }
692096
private void attemptPluginLoad(GrailsPlugin plugin) {
        if (areDependenciesResolved(plugin) && areNoneToLoadBefore(plugin)) {
            registerPlugin(plugin);
        }
        else {
            delayedLoadPlugins.add(plugin);
        }
    }
821823
public void addPlugin(SimonConsolePlugin plugin) {
		SimonConsolePlugin existingPlugin = getPluginById(plugin.getId());
		if (existingPlugin != null) {
			throw new IllegalArgumentException("Plugin " + plugin.getId() + " already registered");
		}
		plugins.add(plugin);
	}
461473
public final void register(Class type, Serializer serializer) {
        if (type == null) {
            throw new IllegalArgumentException("Class type information is required!");
        }
        if (serializer.getTypeId() <= 0) {
            throw new IllegalArgumentException(
                    "Type ID must be positive! Current: " + serializer.getTypeId() + ", Serializer: " + serializer);
        }
        safeRegister(type, createSerializerAdapter(serializer, this));
    }
573984
public static void registerPluginAnalysisEngines(DetectorFactoryCollection detectorFactoryCollection,
            IAnalysisCache analysisCache) throws IOException {
        for (Iterator<Plugin> i = detectorFactoryCollection.pluginIterator(); i.hasNext();) {
            Plugin plugin = i.next();

            Class<? extends IAnalysisEngineRegistrar> engineRegistrarClass = plugin.getEngineRegistrarClass();
            if (engineRegistrarClass != null) {
                try {
                    IAnalysisEngineRegistrar engineRegistrar = engineRegistrarClass.newInstance();
                    engineRegistrar.registerAnalysisEngines(analysisCache);
                } catch (InstantiationException e) {
                    IOException ioe = new IOException("Could not create analysis engine registrar for plugin "
                            + plugin.getPluginId());
                    ioe.initCause(e);
                    throw ioe;
                } catch (IllegalAccessException e) {
                    IOException ioe = new IOException("Could not create analysis engine registrar for plugin "
                            + plugin.getPluginId());
                    ioe.initCause(e);
                    throw ioe;
                }
            }
        }
    }
694564
protected void registerJavaTimeDatatypes() {

    // prevent compile-time dependencies and GWT availability problems
    registerStandardDatatype("java.time.LocalTime");
    registerStandardDatatype("java.time.LocalDate");
    registerStandardDatatype("java.time.LocalDateTime");
    registerStandardDatatype("java.time.MonthDay");
    registerStandardDatatype("java.time.Year");
    registerStandardDatatype("java.time.YearMonth");
    registerStandardDatatype("java.time.Instant");
    registerStandardDatatype("java.time.Duration");
    registerStandardDatatype("java.time.Period");
    registerStandardDatatype("java.time.OffsetTime");
    registerStandardDatatype("java.time.OffsetDate");
    registerStandardDatatype("java.time.OffsetDateTime");
    registerStandardDatatype("java.time.ZoneId");
    registerStandardDatatype("java.time.ZonedDateTime");
    registerStandardDatatype("java.time.ZoneOffset");
    registerStandardDatatype("java.time.ZoneRegion");
  }
677158
public void registerTypeWithKryoSerializer(Class<?> type, Class<? extends Serializer<?>> serializerClass) {
		config.registerTypeWithKryoSerializer(type, serializerClass);
	}
585138
public static void register(String typeName, Class<? extends PropertyEditorBase<?>> editorClass) {
        register(typeName, null, editorClass);
    }
7795
function(plugins, pluginBase){
        var _this = this;
        
        if (typeof pluginBase === 'string') {
            _pluginBase = pluginBase;
        }
        plugins.forEach(function(plugin, index){
            var name;
            var path;
            if (typeof plugin === 'string'){
                name = plugin;
            } else {
                name = plugin.name;
                path = plugin.path;
            }
            _this.register(name, plugin);
        });
    }
643616
function registerTypeByName(type) {
    if (registryLogger.isDebugEnabled()) {
        registryLogger.debug('Register Type \'%s\' by name [%s]', type.id, type.typeName);
    }
    typeByName[type.typeName] = type;
    return type;
}
1139460
public <T> void register(Class<T> type, Converter<T> converter) {
        addConverter(type, converter);
    }