Initialize the common generators
961728
protected void initCommonGenerators() {
		commonGenerators.put(new PrefixedPathResolver(MESSAGE_BUNDLE_PREFIX), ResourceBundleMessagesGenerator.class);
		Class<?> classPathGeneratorClass = null;
		Class<?> webJarsGeneratorClass = null;

		boolean isWebJarsLocatorPresent = ClassLoaderResourceUtils.isClassPresent(WEBJARS_LOCATOR_CLASSNAME);

		if (resourceType.equals(JawrConstant.JS_TYPE)) {
			classPathGeneratorClass = ClasspathJSGenerator.class;
			if (isWebJarsLocatorPresent) {
				webJarsGeneratorClass = WebJarsLocatorJSGenerator.class;
			} else {
				webJarsGeneratorClass = WebJarsJSGenerator.class;
			}
		} else if (resourceType.equals(JawrConstant.CSS_TYPE)) {
			classPathGeneratorClass = ClassPathCSSGenerator.class;
			if (isWebJarsLocatorPresent) {
				webJarsGeneratorClass = WebJarsLocatorCssGenerator.class;
			} else {
				webJarsGeneratorClass = WebJarsCssGenerator.class;
			}
		} else {
			classPathGeneratorClass = ClassPathBinaryResourceGenerator.class;
			if (isWebJarsLocatorPresent) {
				webJarsGeneratorClass = WebJarsLocatorBinaryResourceGenerator.class;
			} else {
				webJarsGeneratorClass = WebJarsBinaryResourceGenerator.class;
			}
		}

		commonGenerators.put(new PrefixedPathResolver(CLASSPATH_RESOURCE_BUNDLE_PREFIX), classPathGeneratorClass);
		commonGenerators.put(new PrefixedPathResolver(WEBJARS_GENERATOR_PREFIX), webJarsGeneratorClass);

		if (resourceType.equals(JawrConstant.JS_TYPE)) {
			commonGenerators.put(new PrefixedPathResolver(COMMONS_VALIDATOR_PREFIX), CommonsValidatorGenerator.class);
			commonGenerators.put(new PrefixedPathResolver(SKIN_SWTICHER_GENERATOR_PREFIX),
					SkinSwitcherJsGenerator.class);
			commonGenerators.put(new SuffixedPathResolver(COFEESCRIPT_GENERATOR_SUFFIX), CoffeeScriptGenerator.class);
		}

		if (resourceType.equals(JawrConstant.CSS_TYPE)) {
			commonGenerators.put(new PrefixedPathResolver(IE_CSS_GENERATOR_PREFIX), IECssBundleGenerator.class);
			commonGenerators.put(new PrefixedPathResolver(SKIN_GENERATOR_PREFIX), CssSkinGenerator.class);
			commonGenerators.put(new SuffixedPathResolver(LESS_GENERATOR_SUFFIX), LessCssGenerator.class);

			String sassGenerator = config.getProperty(SASS_GENERATOR_TYPE, SASS_GENERATOR_VAADIN);
			if (!sassGenerator.equals(SASS_GENERATOR_VAADIN) && !sassGenerator.equals(SASS_GENERATOR_RUBY)) {
				throw new BundlingProcessException("The value '" + sassGenerator + "' is not allowed for property '"
						+ SASS_GENERATOR_TYPE + "'. Please check your configuration.");
			}
			if (sassGenerator.equals(SASS_GENERATOR_VAADIN)) {
				commonGenerators.put(new SuffixedPathResolver(SASS_GENERATOR_SUFFIX), SassVaadinGenerator.class);
			} else {
				commonGenerators.put(new SuffixedPathResolver(SASS_GENERATOR_SUFFIX), SassRubyGenerator.class);
			}

		}

		if ((resourceType.equals(JawrConstant.CSS_TYPE) || resourceType.equals(JawrConstant.BINARY_TYPE))) {
			commonGenerators.put(new PrefixedPathResolver(SPRITE_GENERATOR_PREFIX), SpriteGenerator.class);
		}

	}
563266
private void initComponents()//GEN-BEGIN:initComponents
    {
        java.awt.GridBagConstraints gridBagConstraints;

        lblJDBCDriver = new javax.swing.JLabel();
        cmbJDBCDriver = new javax.swing.JComboBox();
        lblJDBCURL = new javax.swing.JLabel();
        cmbJDBCURL = new javax.swing.JComboBox();
        lblUsername = new javax.swing.JLabel();
        tfUsername = new javax.swing.JTextField();
        lblPassword = new javax.swing.JLabel();
        tfPassword = new javax.swing.JPasswordField();
        lblResult = new javax.swing.JTextField();
        jPanel1 = new javax.swing.JPanel();
        pbCancel = new javax.swing.JButton();
        pbTest = new javax.swing.JButton();
        pbOpen = new javax.swing.JButton();

        getContentPane().setLayout(new java.awt.GridBagLayout());

        setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
        addWindowListener(new java.awt.event.WindowAdapter()
        {
            public void windowClosing(java.awt.event.WindowEvent evt)
            {
                closeDialog(evt);
            }
        });

        lblJDBCDriver.setText("JDBC Driver Class:");
        gridBagConstraints = new java.awt.GridBagConstraints();
        gridBagConstraints.gridx = 0;
        gridBagConstraints.gridy = 0;
        gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
        getContentPane().add(lblJDBCDriver, gridBagConstraints);

        cmbJDBCDriver.setFont(new java.awt.Font("Dialog", 0, 12));
        cmbJDBCDriver.setMinimumSize(new java.awt.Dimension(31, 20));
        cmbJDBCDriver.setPreferredSize(new java.awt.Dimension(31, 20));
        cmbJDBCDriver.addItemListener(new java.awt.event.ItemListener()
        {
            public void itemStateChanged(java.awt.event.ItemEvent evt)
            {
                cmbJDBCDriverItemStateChanged(evt);
            }
        });

        gridBagConstraints = new java.awt.GridBagConstraints();
        gridBagConstraints.gridx = 1;
        gridBagConstraints.gridy = 0;
        gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
        getContentPane().add(cmbJDBCDriver, gridBagConstraints);

        lblJDBCURL.setText("JDBC URL:");
        gridBagConstraints = new java.awt.GridBagConstraints();
        gridBagConstraints.gridx = 0;
        gridBagConstraints.gridy = 1;
        gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
        getContentPane().add(lblJDBCURL, gridBagConstraints);

        cmbJDBCURL.setFont(new java.awt.Font("Dialog", 0, 12));
        cmbJDBCURL.setMinimumSize(new java.awt.Dimension(31, 20));
        cmbJDBCURL.setPreferredSize(new java.awt.Dimension(31, 20));
        cmbJDBCURL.addItemListener(new java.awt.event.ItemListener()
        {
            public void itemStateChanged(java.awt.event.ItemEvent evt)
            {
                cmbJDBCURLItemStateChanged(evt);
            }
        });

        gridBagConstraints = new java.awt.GridBagConstraints();
        gridBagConstraints.gridx = 1;
        gridBagConstraints.gridy = 1;
        gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
        getContentPane().add(cmbJDBCURL, gridBagConstraints);

        lblUsername.setText("Username:");
        gridBagConstraints = new java.awt.GridBagConstraints();
        gridBagConstraints.gridx = 0;
        gridBagConstraints.gridy = 2;
        gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
        getContentPane().add(lblUsername, gridBagConstraints);

        tfUsername.setColumns(30);
        tfUsername.setText("jTextField3");
        gridBagConstraints = new java.awt.GridBagConstraints();
        gridBagConstraints.gridx = 1;
        gridBagConstraints.gridy = 2;
        gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
        gridBagConstraints.weightx = 1.0;
        getContentPane().add(tfUsername, gridBagConstraints);

        lblPassword.setText("Password:");
        gridBagConstraints = new java.awt.GridBagConstraints();
        gridBagConstraints.gridx = 0;
        gridBagConstraints.gridy = 3;
        gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST;
        getContentPane().add(lblPassword, gridBagConstraints);

        tfPassword.setColumns(30);
        gridBagConstraints = new java.awt.GridBagConstraints();
        gridBagConstraints.gridx = 1;
        gridBagConstraints.gridy = 3;
        gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
        gridBagConstraints.weightx = 1.0;
        getContentPane().add(tfPassword, gridBagConstraints);

        lblResult.setBackground((java.awt.Color) javax.swing.UIManager.getDefaults().get("Label.background"));
        lblResult.setEditable(false);
        lblResult.setText("jTextField1");
        lblResult.setBorder(null);
        gridBagConstraints = new java.awt.GridBagConstraints();
        gridBagConstraints.gridx = 0;
        gridBagConstraints.gridy = 4;
        gridBagConstraints.gridwidth = 2;
        gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
        getContentPane().add(lblResult, gridBagConstraints);

        pbCancel.setMnemonic('c');
        pbCancel.setText("Cancel");
        pbCancel.addActionListener(new java.awt.event.ActionListener()
        {
            public void actionPerformed(java.awt.event.ActionEvent evt)
            {
                pbCancelActionPerformed(evt);
            }
        });

        jPanel1.add(pbCancel);

        pbTest.setMnemonic('t');
        pbTest.setText("Test");
        pbTest.setEnabled(false);
        pbTest.addActionListener(new java.awt.event.ActionListener()
        {
            public void actionPerformed(java.awt.event.ActionEvent evt)
            {
                pbTestActionPerformed(evt);
            }
        });

        jPanel1.add(pbTest);

        pbOpen.setMnemonic('o');
        pbOpen.setText("Open");
        pbOpen.setEnabled(false);
        pbOpen.addActionListener(new java.awt.event.ActionListener()
        {
            public void actionPerformed(java.awt.event.ActionEvent evt)
            {
                pbOpenActionPerformed(evt);
            }
        });

        jPanel1.add(pbOpen);

        gridBagConstraints = new java.awt.GridBagConstraints();
        gridBagConstraints.gridx = 1;
        gridBagConstraints.gridy = 5;
        gridBagConstraints.anchor = java.awt.GridBagConstraints.EAST;
        getContentPane().add(jPanel1, gridBagConstraints);

        pack();
    }
914885
def initialize(self):
        
        Device.initialize(self)
        for child in iter(self.children.values()):
            child.initialize()
952494
public function init() {
		elgg_register_plugin_hook_handler('entity:icon:url', 'all', new Handlers\EntityIconUrlHook());

		elgg_register_plugin_hook_handler('graph:properties', 'all', new Handlers\PropertiesHook());

		elgg_register_plugin_hook_handler('graph:properties', 'user', new Handlers\UserPropertiesHook());
		elgg_register_plugin_hook_handler('graph:properties', 'group', new Handlers\GroupPropertiesHook());
		elgg_register_plugin_hook_handler('graph:properties', 'site', new Handlers\SitePropertiesHook());

		elgg_register_plugin_hook_handler('graph:properties', 'object', new Handlers\ObjectPropertiesHook());
		elgg_register_plugin_hook_handler('graph:properties', 'object:blog', new Handlers\BlogPropertiesHook());
		elgg_register_plugin_hook_handler('graph:properties', 'object:file', new Handlers\FilePropertiesHook());
		elgg_register_plugin_hook_handler('graph:properties', 'object:messages', new Handlers\MessagePropertiesHook());

		elgg_register_plugin_hook_handler('graph:properties', 'metadata', new Handlers\ExtenderPropertiesHook());
		elgg_register_plugin_hook_handler('graph:properties', 'annotation', new Handlers\ExtenderPropertiesHook());
		elgg_register_plugin_hook_handler('graph:properties', 'relationship', new Handlers\RelationshipPropertiesHook());
		elgg_register_plugin_hook_handler('graph:properties', 'river:item', new Handlers\RiverPropertiesHook());

	}
979656
private void init(Configuration pConfig) {
        // Central objects
        converters = new Converters();
        initLimits(pConfig);

        // Create and remember request dispatchers
        localDispatcher = new LocalRequestDispatcher(converters,
                                                     restrictor,
                                                     pConfig,
                                                     logHandler);
        ServerHandle serverHandle = localDispatcher.getServerHandle();
        requestDispatchers = createRequestDispatchers(pConfig, converters,serverHandle,restrictor);
        requestDispatchers.add(localDispatcher);

        // Backendstore for remembering agent state
        initMBeans(pConfig);

        agentDetails.setServerInfo(serverHandle.getVendor(),serverHandle.getProduct(),serverHandle.getVersion());
    }
175697
def connect_generators(self, debug=False):
        

        self._graph = lv_connect.lv_connect_generators(self.grid_district, self._graph, debug)
866632
private void init() {
        if (provider != null) {
            propertyGrid.setTarget(StringUtils.isEmpty(groupId) ? null : new Settings(groupId, provider));
        }
    }
231404
def add_new_init_method(cls):
    

    orig_init = cls.__init__

    def new_init(self, *args, **kwargs):
        self._dependent_generators = []
        orig_init(self, *args, **kwargs)

    cls.__init__ = new_init
594371
def gant(ctx, conf, basedir, basetag, maintag, prefix, verbose):
    
    ctx.obj.initConf(basetag, maintag, basedir, prefix, verbose)
    ctx.obj.gd.setConf(ctx.obj.conf)
115973
private void initComponents() {//GEN-BEGIN:initComponents
        java.awt.GridBagConstraints gridBagConstraints;

        jToolBar1 = new javax.swing.JToolBar();
        jButton1 = new javax.swing.JButton();
        jButton2 = new javax.swing.JButton();
        jButton3 = new javax.swing.JButton();
        jButton4 = new javax.swing.JButton();
        jButton5 = new javax.swing.JButton();
        jButton6 = new javax.swing.JButton();
        jSplitPane1 = new javax.swing.JSplitPane();
        jScrollPane1 = new javax.swing.JScrollPane();
        jTree1 = new javax.swing.JTree();
        jScrollPane2 = new javax.swing.JScrollPane();
        jPanel1 = new javax.swing.JPanel();
        menuBar = new javax.swing.JMenuBar();
        fileMenu = new javax.swing.JMenu();
        mnuFileConnect = new javax.swing.JMenuItem();
        mnuFileReadSchema = new javax.swing.JMenuItem();
        exitMenuItem = new javax.swing.JMenuItem();

        getContentPane().setLayout(new java.awt.GridBagLayout());

        setTitle("OJB Scheme Generator");
        addWindowListener(new java.awt.event.WindowAdapter() {
            public void windowClosing(java.awt.event.WindowEvent evt) {
                exitForm(evt);
            }
        });

        jButton1.setAction(new DBConnPropertiesAction(this));
        jToolBar1.add(jButton1);

        jButton2.setText("Read");
        jButton2.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButton2ActionPerformed(evt);
            }
        });

        jToolBar1.add(jButton2);

        jButton3.setText("Save XML");
        jButton3.setAction(new SaveXMLAction(this));
        jToolBar1.add(jButton3);

        jButton4.setAction(new GenerateJavaClassesAction(this));
        jToolBar1.add(jButton4);

        jButton5.setAction(new SetPackageAction(this));
        jToolBar1.add(jButton5);

        jButton6.setAction(new DisableClassesWithRegexAction(this));
        jToolBar1.add(jButton6);

        gridBagConstraints = new java.awt.GridBagConstraints();
        gridBagConstraints.gridx = 0;
        gridBagConstraints.gridy = 0;
        gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
        gridBagConstraints.weightx = 1.0;
        getContentPane().add(jToolBar1, gridBagConstraints);

        jSplitPane1.setDividerLocation(100);
        jTree1.setModel(null);
        jTree1.addTreeSelectionListener(new javax.swing.event.TreeSelectionListener() {
            public void valueChanged(javax.swing.event.TreeSelectionEvent evt) {
                jTree1ValueChanged(evt);
            }
        });

        jScrollPane1.setViewportView(jTree1);

        jSplitPane1.setLeftComponent(jScrollPane1);

        jScrollPane2.setViewportView(jPanel1);

        jSplitPane1.setRightComponent(jScrollPane2);

        gridBagConstraints = new java.awt.GridBagConstraints();
        gridBagConstraints.gridx = 0;
        gridBagConstraints.gridy = 1;
        gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;
        gridBagConstraints.weightx = 1.0;
        gridBagConstraints.weighty = 1.0;
        getContentPane().add(jSplitPane1, gridBagConstraints);

        fileMenu.setText("File");
        fileMenu.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                fileMenuActionPerformed(evt);
            }
        });

        mnuFileConnect.setAction(new DBConnPropertiesAction(this));
        mnuFileConnect.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mnuFileConnectActionPerformed(evt);
            }
        });

        fileMenu.add(mnuFileConnect);

        mnuFileReadSchema.setText("Read Schema");
        mnuFileReadSchema.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                mnuFileReadSchemaActionPerformed(evt);
            }
        });

        fileMenu.add(mnuFileReadSchema);

        exitMenuItem.setText("Exit");
        exitMenuItem.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                exitMenuItemActionPerformed(evt);
            }
        });

        fileMenu.add(exitMenuItem);

        menuBar.add(fileMenu);

        setJMenuBar(menuBar);

        pack();
    }
600622
def init
      generator = Fudge::Generator.new(Dir.pwd)
      msg = generator.write_fudgefile
      shell.say msg
    end
40458
def load_generators(app = self)
      require "rails/generators"
      run_generators_blocks(app)
      Rails::Generators.configure!(app.config.generators)
      self
    end
189828
private void initializePresets() {
    if (gobblinPresets == null) {
      synchronized (GobblinHadoopJob.class) {
        if (gobblinPresets == null) {
          gobblinPresets = Maps.newHashMap();
          String gobblinPresetDirName = getSysProps()
              .getString(GobblinConstants.GOBBLIN_PRESET_DIR_KEY);
          File gobblinPresetDir = new File(gobblinPresetDirName);
          File[] presetFiles = gobblinPresetDir.listFiles();
          if (presetFiles == null) {
            return;
          }

          File commonPropertiesFile = new File(gobblinPresetDir,
              GOBBLIN_PRESET_COMMON_PROPERTIES_FILE_NAME);
          if (!commonPropertiesFile.exists()) {
            throw new IllegalStateException("Gobbline preset common properties file is missing "
                + commonPropertiesFile.getAbsolutePath());
          }

          for (File f : presetFiles) {
            if (GOBBLIN_PRESET_COMMON_PROPERTIES_FILE_NAME
                .equals(f.getName())) { //Don't load common one itself.
              continue;
            }

            if (f.isFile()) {
              Properties prop = new Properties();
              try (InputStream commonIs = new BufferedInputStream(
                  new FileInputStream(commonPropertiesFile));
                  InputStream presetIs = new BufferedInputStream(new FileInputStream(f))) {
                prop.load(commonIs);
                prop.load(presetIs);

                String presetName = f.getName().substring(0,
                    f.getName().lastIndexOf('.')); //remove extension from the file name
                gobblinPresets.put(GobblinPresets.fromName(presetName), prop);
              } catch (IOException e) {
                throw new RuntimeException(e);
              }
            }
          }
        }
      }
    }
  }
871016
public void initialize ()
  {
    m_aLoadHelpers = new CommonsArrayList <> ();
    m_aLoadHelpers.add (new LoadingLoaderClassLoadHelper ());
    m_aLoadHelpers.add (new SimpleClassLoadHelper ());
    m_aLoadHelpers.add (new ThreadContextClassLoadHelper ());
    m_aLoadHelpers.add (new InitThreadContextClassLoadHelper ());

    for (final IClassLoadHelper aLoadHelper : m_aLoadHelpers)
      aLoadHelper.initialize ();
  }
126459
void initInputsByIdMap() {
    inputsById.clear();
    for (CompilerInput input : externs) {
      InputId id = input.getInputId();
      CompilerInput previous = putCompilerInput(id, input);
      if (previous != null) {
        report(JSError.make(DUPLICATE_EXTERN_INPUT, input.getName()));
      }
    }
    for (CompilerInput input : moduleGraph.getAllInputs()) {
      InputId id = input.getInputId();
      CompilerInput previous = putCompilerInput(id, input);
      if (previous != null) {
        report(JSError.make(DUPLICATE_INPUT, input.getName()));
      }
    }
  }
1137325
private void initializeGeneratorProperties(ResourceGenerator generator) {
		// Initialize the generator
		if (generator instanceof InitializingResourceGenerator) {
			if (generator instanceof ConfigurationAwareResourceGenerator) {
				((ConfigurationAwareResourceGenerator) generator).setConfig(config);
			}
			if (generator instanceof TypeAwareResourceGenerator) {
				((TypeAwareResourceGenerator) generator).setResourceType(resourceType);
			}
			if (generator instanceof ResourceReaderHandlerAwareResourceGenerator) {
				((ResourceReaderHandlerAwareResourceGenerator) generator).setResourceReaderHandler(rsHandler);
			}
			if (generator instanceof WorkingDirectoryLocationAware) {
				((WorkingDirectoryLocationAware) generator).setWorkingDirectory(rsHandler.getWorkingDirectory());
			}
			if (generator instanceof PostInitializationAwareResourceGenerator) {
				((PostInitializationAwareResourceGenerator) generator).afterPropertiesSet();
			}
		}
	}
92780
def common_start(*args):
    
    def _iter():
        for s in zip(*args):
            if len(set(s)) < len(args):
                yield s[0]
            else:
                return

    out = "".join(_iter()).strip()
    result = [s for s in args if not s.startswith(out)]
    result.insert(0, out)
    return ', '.join(result)