Question: <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents

private void initComponents() {
    java.awt.GridBagConstraints gridBagConstraints;

    jScrollPane1 = new javax.swing.JScrollPane();
    jPanel6 = new javax.swing.JPanel();
    jPanel3 = new javax.swing.JPanel();
    jLabel2 = new javax.swing.JLabel();
    spinnerConnectorWidth = new javax.swing.JSpinner();
    jLabel5 = new javax.swing.JLabel();
    spinnerCollapsatorSize = new javax.swing.JSpinner();
    jLabel6 = new javax.swing.JLabel();
    spinnerCollapsatorWidth = new javax.swing.JSpinner();
    jLabel7 = new javax.swing.JLabel();
    spinnerJumpLinkWidth = new javax.swing.JSpinner();
    jPanel10 = new javax.swing.JPanel();
    colorChooserCollapsatorBackground = new com.igormaznitsa.nbmindmap.nb.swing.ColorChooserButton();
    colorChooserJumpLink = new com.igormaznitsa.nbmindmap.nb.swing.ColorChooserButton();
    colorChooserCollapsatorBorder = new com.igormaznitsa.nbmindmap.nb.swing.ColorChooserButton();
    colorChooserConnectorColor = new com.igormaznitsa.nbmindmap.nb.swing.ColorChooserButton();
    jPanel4 = new javax.swing.JPanel();
    colorChooserPaperColor = new com.igormaznitsa.nbmindmap.nb.swing.ColorChooserButton();
    checkBoxShowGrid = new javax.swing.JCheckBox();
    colorChooserGridColor = new com.igormaznitsa.nbmindmap.nb.swing.ColorChooserButton();
    spinnerGridStep = new javax.swing.JSpinner();
    jLabel1 = new javax.swing.JLabel();
    jPanel13 = new javax.swing.JPanel();
    comboBoxRenderQuality = new javax.swing.JComboBox();
    jPanel2 = new javax.swing.JPanel();
    checkBoxDropShadow = new javax.swing.JCheckBox();
    jPanel7 = new javax.swing.JPanel();
    buttonFont = new javax.swing.JButton();
    jPanel8 = new javax.swing.JPanel();
    buttonOpenShortcutEditor = new javax.swing.JButton();
    panelScalingModifiers = new javax.swing.JPanel();
    checkBoxScalingCTRL = new javax.swing.JCheckBox();
    checkBoxScalingALT = new javax.swing.JCheckBox();
    checkBoxScalingSHIFT = new javax.swing.JCheckBox();
    checkBoxScalingMETA = new javax.swing.JCheckBox();
    jPanel11 = new javax.swing.JPanel();
    colorChooserRootText = new com.igormaznitsa.nbmindmap.nb.swing.ColorChooserButton();
    colorChooserRootBackground = new com.igormaznitsa.nbmindmap.nb.swing.ColorChooserButton();
    colorChooser1stBackground = new com.igormaznitsa.nbmindmap.nb.swing.ColorChooserButton();
    colorChooser2ndBackground = new com.igormaznitsa.nbmindmap.nb.swing.ColorChooserButton();
    colorChooser1stText = new com.igormaznitsa.nbmindmap.nb.swing.ColorChooserButton();
    colorChooser2ndText = new com.igormaznitsa.nbmindmap.nb.swing.ColorChooserButton();
    jPanel12 = new javax.swing.JPanel();
    labelBorderWidth = new javax.swing.JLabel();
    spinnerElementBorderWidth = new javax.swing.JSpinner();
    jPanel14 = new javax.swing.JPanel();
    slider1stLevelHorzGap = new javax.swing.JSlider();
    jPanel15 = new javax.swing.JPanel();
    slider1stLevelVertGap = new javax.swing.JSlider();
    jPanel16 = new javax.swing.JPanel();
    slider2ndLevelHorzGap = new javax.swing.JSlider();
    jPanel17 = new javax.swing.JPanel();
    slider2ndLevelVertGap = new javax.swing.JSlider();
    jPanel1 = new javax.swing.JPanel();
    checkboxUseInsideBrowser = new javax.swing.JCheckBox();
    checkboxRelativePathsForFilesInTheProject = new javax.swing.JCheckBox();
    checkBoxUnfoldCollapsedTarget = new javax.swing.JCheckBox();
    checkBoxCopyColorInfoToNewAllowed = new javax.swing.JCheckBox();
    checkBoxKnowledgeFolderAutogenerationAllowed = new javax.swing.JCheckBox();
    checkBoxWatchFileRefactoring = new javax.swing.JCheckBox();
    checkBoxIgnoreWhereUsedRequests = new javax.swing.JCheckBox();
    labelMiscNeedsReloading = new javax.swing.JLabel();
    checkboxTrimTopicText = new javax.swing.JCheckBox();
    jPanel5 = new javax.swing.JPanel();
    colorChooserSelectLine = new com.igormaznitsa.nbmindmap.nb.swing.ColorChooserButton();
    jLabel3 = new javax.swing.JLabel();
    spinnerSelectLineWidth = new javax.swing.JSpinner();
    jLabel4 = new javax.swing.JLabel();
    spinnerSelectLineGap = new javax.swing.JSpinner();
    jPanel9 = new javax.swing.JPanel();
    buttonAbout = new javax.swing.JButton();
    donateButton1 = new com.igormaznitsa.nbmindmap.nb.swing.DonateButton();
    buttonResetSettings = new javax.swing.JButton();
    buttonExportSettings = new javax.swing.JButton();
    buttonImportSettings = new javax.swing.JButton();
    filler4 = new javax.swing.Box.Filler(new java.awt.Dimension(0, 16), new java.awt.Dimension(0, 16), new java.awt.Dimension(32767, 16));
    filler5 = new javax.swing.Box.Filler(new java.awt.Dimension(0, 0), new java.awt.Dimension(0, 0), new java.awt.Dimension(0, 32767));
    filler2 = new javax.swing.Box.Filler(new java.awt.Dimension(0, 0), new java.awt.Dimension(0, 0), new java.awt.Dimension(0, 32767));
    filler6 = new javax.swing.Box.Filler(new java.awt.Dimension(0, 0), new java.awt.Dimension(0, 0), new java.awt.Dimension(0, 32767));
    filler7 = new javax.swing.Box.Filler(new java.awt.Dimension(0, 16), new java.awt.Dimension(0, 16), new java.awt.Dimension(32767, 16));
    filler1 = new javax.swing.Box.Filler(new java.awt.Dimension(0, 0), new java.awt.Dimension(0, 0), new java.awt.Dimension(32767, 0));
    filler3 = new javax.swing.Box.Filler(new java.awt.Dimension(0, 0), new java.awt.Dimension(0, 0), new java.awt.Dimension(0, 32767));

    setLayout(new java.awt.BorderLayout());

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

    java.util.ResourceBundle bundle = java.util.ResourceBundle.getBundle("com/igormaznitsa/nbmindmap/i18n/Bundle"); // NOI18N
    jPanel3.setBorder(javax.swing.BorderFactory.createTitledBorder(bundle.getString("MMDCfgPanel.jPanel3.border.title"))); // NOI18N
    jPanel3.setLayout(new java.awt.GridBagLayout());

    jLabel2.setText(bundle.getString("MMDCfgPanel.jLabel2.text")); // NOI18N
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 0;
    gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHEAST;
    jPanel3.add(jLabel2, gridBagConstraints);

    spinnerConnectorWidth.setModel(new javax.swing.SpinnerNumberModel(Float.valueOf(0.1f), Float.valueOf(0.05f), Float.valueOf(20.0f), Float.valueOf(0.01f)));
    spinnerConnectorWidth.addChangeListener(new javax.swing.event.ChangeListener() {
      public void stateChanged(javax.swing.event.ChangeEvent evt) {
        spinnerConnectorWidthStateChanged(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 0;
    gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;
    gridBagConstraints.ipadx = 82;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.weightx = 1000.0;
    jPanel3.add(spinnerConnectorWidth, gridBagConstraints);

    jLabel5.setText(bundle.getString("MMDCfgPanel.jLabel5.text")); // NOI18N
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 2;
    gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHEAST;
    jPanel3.add(jLabel5, gridBagConstraints);

    spinnerCollapsatorSize.setModel(new javax.swing.SpinnerNumberModel(5, 3, 500, 1));
    spinnerCollapsatorSize.addChangeListener(new javax.swing.event.ChangeListener() {
      public void stateChanged(javax.swing.event.ChangeEvent evt) {
        spinnerCollapsatorSizeStateChanged(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 2;
    gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;
    gridBagConstraints.ipadx = 93;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.weightx = 1000.0;
    jPanel3.add(spinnerCollapsatorSize, gridBagConstraints);

    jLabel6.setText(bundle.getString("MMDCfgPanel.jLabel6.text")); // NOI18N
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 3;
    gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHEAST;
    jPanel3.add(jLabel6, gridBagConstraints);

    spinnerCollapsatorWidth.setModel(new javax.swing.SpinnerNumberModel(Float.valueOf(1.0f), Float.valueOf(0.01f), Float.valueOf(100.0f), Float.valueOf(0.1f)));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 3;
    gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;
    gridBagConstraints.ipadx = 82;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.weightx = 1000.0;
    jPanel3.add(spinnerCollapsatorWidth, gridBagConstraints);

    jLabel7.setText(bundle.getString("MMDCfgPanel.jLabel7.text")); // NOI18N
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 1;
    gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHEAST;
    jPanel3.add(jLabel7, gridBagConstraints);

    spinnerJumpLinkWidth.setModel(new javax.swing.SpinnerNumberModel(Float.valueOf(0.1f), Float.valueOf(0.05f), Float.valueOf(20.0f), Float.valueOf(0.01f)));
    spinnerJumpLinkWidth.addChangeListener(new javax.swing.event.ChangeListener() {
      public void stateChanged(javax.swing.event.ChangeEvent evt) {
        spinnerJumpLinkWidthStateChanged(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 1;
    gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;
    gridBagConstraints.ipadx = 82;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.weightx = 1000.0;
    jPanel3.add(spinnerJumpLinkWidth, gridBagConstraints);

    jPanel10.setBorder(null);
    jPanel10.setLayout(new java.awt.GridLayout(2, 2));

    colorChooserCollapsatorBackground.setText(bundle.getString("MMDCfgPanel.colorChooserCollapsatorBackground.text")); // NOI18N
    colorChooserCollapsatorBackground.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
    colorChooserCollapsatorBackground.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        colorChooserCollapsatorBackgroundActionPerformed(evt);
      }
    });
    jPanel10.add(colorChooserCollapsatorBackground);

    colorChooserJumpLink.setText(bundle.getString("MMDCfgPanel.colorChooserJumpLink.text")); // NOI18N
    colorChooserJumpLink.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
    colorChooserJumpLink.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        colorChooserJumpLinkActionPerformed(evt);
      }
    });
    jPanel10.add(colorChooserJumpLink);

    colorChooserCollapsatorBorder.setText(bundle.getString("MMDCfgPanel.colorChooserCollapsatorBorder.text")); // NOI18N
    colorChooserCollapsatorBorder.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
    colorChooserCollapsatorBorder.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        colorChooserCollapsatorBorderActionPerformed(evt);
      }
    });
    jPanel10.add(colorChooserCollapsatorBorder);

    colorChooserConnectorColor.setText(bundle.getString("MMDCfgPanel.colorChooserConnectorColor.text")); // NOI18N
    colorChooserConnectorColor.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
    colorChooserConnectorColor.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        colorChooserConnectorColorActionPerformed(evt);
      }
    });
    jPanel10.add(colorChooserConnectorColor);

    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 4;
    gridBagConstraints.gridwidth = 2;
    gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;
    jPanel3.add(jPanel10, gridBagConstraints);

    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 1;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel6.add(jPanel3, gridBagConstraints);

    jPanel4.setBorder(javax.swing.BorderFactory.createTitledBorder(bundle.getString("MMDCfgPanel.jPanel4.border.title"))); // NOI18N
    jPanel4.setLayout(new java.awt.GridBagLayout());

    colorChooserPaperColor.setText(bundle.getString("MMDCfgPanel.colorChooserPaperColor.text")); // NOI18N
    colorChooserPaperColor.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
    colorChooserPaperColor.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        colorChooserPaperColorActionPerformed(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 2;
    gridBagConstraints.gridy = 1;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel4.add(colorChooserPaperColor, gridBagConstraints);

    checkBoxShowGrid.setText(bundle.getString("MMDCfgPanel.checkBoxShowGrid.text")); // NOI18N
    checkBoxShowGrid.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        checkBoxShowGridActionPerformed(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 1;
    gridBagConstraints.gridwidth = 2;
    gridBagConstraints.ipady = 10;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel4.add(checkBoxShowGrid, gridBagConstraints);

    colorChooserGridColor.setText(bundle.getString("MMDCfgPanel.colorChooserGridColor.text")); // NOI18N
    colorChooserGridColor.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
    colorChooserGridColor.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        colorChooserGridColorActionPerformed(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 2;
    gridBagConstraints.gridy = 0;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel4.add(colorChooserGridColor, gridBagConstraints);

    spinnerGridStep.setModel(new javax.swing.SpinnerNumberModel(15, 2, 500, 1));
    spinnerGridStep.addChangeListener(new javax.swing.event.ChangeListener() {
      public void stateChanged(javax.swing.event.ChangeEvent evt) {
        spinnerGridStepStateChanged(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 0;
    gridBagConstraints.ipadx = 31;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel4.add(spinnerGridStep, gridBagConstraints);

    jLabel1.setText(bundle.getString("MMDCfgPanel.jLabel1.text")); // NOI18N
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 0;
    gridBagConstraints.ipady = 11;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel4.add(jLabel1, gridBagConstraints);

    jPanel13.setBorder(javax.swing.BorderFactory.createTitledBorder(bundle.getString("MMDCfgPanel.RenderQuality.border.title"))); // NOI18N
    jPanel13.setLayout(new java.awt.GridLayout(1, 0));

    comboBoxRenderQuality.setModel(new DefaultComboBoxModel<RenderQuality>(RenderQuality.values()));
    comboBoxRenderQuality.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        comboBoxRenderQualityActionPerformed(evt);
      }
    });
    jPanel13.add(comboBoxRenderQuality);

    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 2;
    gridBagConstraints.gridwidth = 3;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    jPanel4.add(jPanel13, gridBagConstraints);

    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 0;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel6.add(jPanel4, gridBagConstraints);

    jPanel2.setBorder(javax.swing.BorderFactory.createTitledBorder(bundle.getString("MMDCfgPanel.jPanel2.border.title"))); // NOI18N
    jPanel2.setLayout(new java.awt.GridBagLayout());

    checkBoxDropShadow.setText(bundle.getString("MMDCfgPanel.checkBoxDropShadow.text")); // NOI18N
    checkBoxDropShadow.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        checkBoxDropShadowActionPerformed(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 0;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel2.add(checkBoxDropShadow, gridBagConstraints);

    jPanel7.setBorder(javax.swing.BorderFactory.createTitledBorder(bundle.getString("MMDCfgPanel.jPanel7.border.title"))); // NOI18N

    buttonFont.setText("..."); // NOI18N
    buttonFont.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        buttonFontActionPerformed(evt);
      }
    });

    javax.swing.GroupLayout jPanel7Layout = new javax.swing.GroupLayout(jPanel7);
    jPanel7.setLayout(jPanel7Layout);
    jPanel7Layout.setHorizontalGroup(
      jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
      .addGroup(jPanel7Layout.createSequentialGroup()
        .addContainerGap()
        .addComponent(buttonFont, javax.swing.GroupLayout.DEFAULT_SIZE, 263, Short.MAX_VALUE)
        .addContainerGap())
    );
    jPanel7Layout.setVerticalGroup(
      jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
      .addGroup(jPanel7Layout.createSequentialGroup()
        .addComponent(buttonFont)
        .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
    );

    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 7;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel2.add(jPanel7, gridBagConstraints);

    jPanel8.setBorder(javax.swing.BorderFactory.createTitledBorder(bundle.getString("MMDCfgPanel.ShortCutsTitle"))); // NOI18N

    buttonOpenShortcutEditor.setText(bundle.getString("MMDCfgPanel.ShortCutsButtonText")); // NOI18N
    buttonOpenShortcutEditor.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        buttonOpenShortcutEditorActionPerformed(evt);
      }
    });

    panelScalingModifiers.setBorder(javax.swing.BorderFactory.createTitledBorder(bundle.getString("MMDCfgPanel.panelScalingModifiers.border.title"))); // NOI18N

    checkBoxScalingCTRL.setText("CTRL"); // NOI18N
    checkBoxScalingCTRL.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        checkBoxScalingCTRLActionPerformed(evt);
      }
    });

    checkBoxScalingALT.setText("ALT"); // NOI18N
    checkBoxScalingALT.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        checkBoxScalingALTActionPerformed(evt);
      }
    });

    checkBoxScalingSHIFT.setText("SHIFT"); // NOI18N
    checkBoxScalingSHIFT.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        checkBoxScalingSHIFTActionPerformed(evt);
      }
    });

    checkBoxScalingMETA.setText("META"); // NOI18N
    checkBoxScalingMETA.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        checkBoxScalingMETAActionPerformed(evt);
      }
    });

    javax.swing.GroupLayout panelScalingModifiersLayout = new javax.swing.GroupLayout(panelScalingModifiers);
    panelScalingModifiers.setLayout(panelScalingModifiersLayout);
    panelScalingModifiersLayout.setHorizontalGroup(
      panelScalingModifiersLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
      .addGroup(panelScalingModifiersLayout.createSequentialGroup()
        .addContainerGap()
        .addComponent(checkBoxScalingCTRL)
        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
        .addComponent(checkBoxScalingALT)
        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
        .addComponent(checkBoxScalingSHIFT)
        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
        .addComponent(checkBoxScalingMETA)
        .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
    );
    panelScalingModifiersLayout.setVerticalGroup(
      panelScalingModifiersLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
      .addGroup(panelScalingModifiersLayout.createSequentialGroup()
        .addContainerGap()
        .addGroup(panelScalingModifiersLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
          .addComponent(checkBoxScalingCTRL)
          .addComponent(checkBoxScalingALT)
          .addComponent(checkBoxScalingSHIFT)
          .addComponent(checkBoxScalingMETA))
        .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
    );

    javax.swing.GroupLayout jPanel8Layout = new javax.swing.GroupLayout(jPanel8);
    jPanel8.setLayout(jPanel8Layout);
    jPanel8Layout.setHorizontalGroup(
      jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
      .addGroup(jPanel8Layout.createSequentialGroup()
        .addContainerGap()
        .addGroup(jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
          .addComponent(buttonOpenShortcutEditor, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
          .addComponent(panelScalingModifiers, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        .addContainerGap())
    );
    jPanel8Layout.setVerticalGroup(
      jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
      .addGroup(jPanel8Layout.createSequentialGroup()
        .addContainerGap()
        .addComponent(buttonOpenShortcutEditor)
        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
        .addComponent(panelScalingModifiers, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
        .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
    );

    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 8;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel2.add(jPanel8, gridBagConstraints);

    jPanel11.setLayout(new java.awt.GridLayout(3, 2));

    colorChooserRootText.setText(bundle.getString("MMDCfgPanel.colorChooserRootText.text")); // NOI18N
    colorChooserRootText.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
    colorChooserRootText.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        colorChooserRootTextActionPerformed(evt);
      }
    });
    jPanel11.add(colorChooserRootText);

    colorChooserRootBackground.setText(bundle.getString("MMDCfgPanel.colorChooserRootBackground.text")); // NOI18N
    colorChooserRootBackground.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
    colorChooserRootBackground.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        colorChooserRootBackgroundActionPerformed(evt);
      }
    });
    jPanel11.add(colorChooserRootBackground);

    colorChooser1stBackground.setText(bundle.getString("MMDCfgPanel.colorChooser1stBackground.text")); // NOI18N
    colorChooser1stBackground.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
    colorChooser1stBackground.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        colorChooser1stBackgroundActionPerformed(evt);
      }
    });
    jPanel11.add(colorChooser1stBackground);

    colorChooser2ndBackground.setText(bundle.getString("MMDCfgPanel.colorChooser2ndBackground.text")); // NOI18N
    colorChooser2ndBackground.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
    colorChooser2ndBackground.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        colorChooser2ndBackgroundActionPerformed(evt);
      }
    });
    jPanel11.add(colorChooser2ndBackground);

    colorChooser1stText.setText(bundle.getString("MMDCfgPanel.colorChooser1stText.text")); // NOI18N
    colorChooser1stText.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
    colorChooser1stText.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        colorChooser1stTextActionPerformed(evt);
      }
    });
    jPanel11.add(colorChooser1stText);

    colorChooser2ndText.setText(bundle.getString("MMDCfgPanel.colorChooser2ndText.text")); // NOI18N
    colorChooser2ndText.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
    colorChooser2ndText.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        colorChooser2ndTextActionPerformed(evt);
      }
    });
    jPanel11.add(colorChooser2ndText);

    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 2;
    gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;
    jPanel2.add(jPanel11, gridBagConstraints);

    labelBorderWidth.setText(bundle.getString("MMDCfgPanel.labelBorderWidth.text")); // NOI18N
    jPanel12.add(labelBorderWidth);

    spinnerElementBorderWidth.setModel(new javax.swing.SpinnerNumberModel(Float.valueOf(0.5f), Float.valueOf(0.05f), Float.valueOf(50.0f), Float.valueOf(0.1f)));
    spinnerElementBorderWidth.addChangeListener(new javax.swing.event.ChangeListener() {
      public void stateChanged(javax.swing.event.ChangeEvent evt) {
        spinnerElementBorderWidthStateChanged(evt);
      }
    });
    jPanel12.add(spinnerElementBorderWidth);

    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 1;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel2.add(jPanel12, gridBagConstraints);

    jPanel14.setBorder(javax.swing.BorderFactory.createTitledBorder(bundle.getString("MMDCfgPanel.panel1stLevelHorzGap.border.title"))); // NOI18N
    jPanel14.setLayout(new java.awt.BorderLayout());

    slider1stLevelHorzGap.setMajorTickSpacing(30);
    slider1stLevelHorzGap.setMaximum(250);
    slider1stLevelHorzGap.setMinimum(10);
    slider1stLevelHorzGap.setPaintLabels(true);
    slider1stLevelHorzGap.setPaintTicks(true);
    slider1stLevelHorzGap.addChangeListener(new javax.swing.event.ChangeListener() {
      public void stateChanged(javax.swing.event.ChangeEvent evt) {
        slider1stLevelHorzGapStateChanged(evt);
      }
    });
    jPanel14.add(slider1stLevelHorzGap, java.awt.BorderLayout.CENTER);

    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 3;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    jPanel2.add(jPanel14, gridBagConstraints);

    jPanel15.setBorder(javax.swing.BorderFactory.createTitledBorder(bundle.getString("MMDCfgPanel.panel1stLevelVertGap.border.title"))); // NOI18N
    jPanel15.setLayout(new java.awt.BorderLayout());

    slider1stLevelVertGap.setMajorTickSpacing(30);
    slider1stLevelVertGap.setMaximum(250);
    slider1stLevelVertGap.setMinimum(10);
    slider1stLevelVertGap.setPaintLabels(true);
    slider1stLevelVertGap.setPaintTicks(true);
    slider1stLevelVertGap.addChangeListener(new javax.swing.event.ChangeListener() {
      public void stateChanged(javax.swing.event.ChangeEvent evt) {
        slider1stLevelVertGapStateChanged(evt);
      }
    });
    jPanel15.add(slider1stLevelVertGap, java.awt.BorderLayout.CENTER);

    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 4;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    jPanel2.add(jPanel15, gridBagConstraints);

    jPanel16.setBorder(javax.swing.BorderFactory.createTitledBorder(bundle.getString("MMDCfgPanel.panel2ndLevelHorzGap.border.title"))); // NOI18N
    jPanel16.setLayout(new java.awt.BorderLayout());

    slider2ndLevelHorzGap.setMajorTickSpacing(30);
    slider2ndLevelHorzGap.setMaximum(250);
    slider2ndLevelHorzGap.setMinimum(10);
    slider2ndLevelHorzGap.setPaintLabels(true);
    slider2ndLevelHorzGap.setPaintTicks(true);
    slider2ndLevelHorzGap.addChangeListener(new javax.swing.event.ChangeListener() {
      public void stateChanged(javax.swing.event.ChangeEvent evt) {
        slider2ndLevelHorzGapStateChanged(evt);
      }
    });
    jPanel16.add(slider2ndLevelHorzGap, java.awt.BorderLayout.CENTER);

    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 5;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    jPanel2.add(jPanel16, gridBagConstraints);

    jPanel17.setBorder(javax.swing.BorderFactory.createTitledBorder(bundle.getString("MMDCfgPanel.panel2ndLevelVertGap.border.title"))); // NOI18N
    jPanel17.setLayout(new java.awt.BorderLayout());

    slider2ndLevelVertGap.setMajorTickSpacing(30);
    slider2ndLevelVertGap.setMaximum(250);
    slider2ndLevelVertGap.setMinimum(10);
    slider2ndLevelVertGap.setPaintLabels(true);
    slider2ndLevelVertGap.setPaintTicks(true);
    slider2ndLevelVertGap.addChangeListener(new javax.swing.event.ChangeListener() {
      public void stateChanged(javax.swing.event.ChangeEvent evt) {
        slider2ndLevelVertGapStateChanged(evt);
      }
    });
    jPanel17.add(slider2ndLevelVertGap, java.awt.BorderLayout.CENTER);

    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 6;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    jPanel2.add(jPanel17, gridBagConstraints);

    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 0;
    gridBagConstraints.gridheight = 4;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel6.add(jPanel2, gridBagConstraints);

    jPanel1.setBorder(javax.swing.BorderFactory.createTitledBorder(bundle.getString("MMDCfgPanel.jPanel1.border.title"))); // NOI18N
    jPanel1.setLayout(new java.awt.GridBagLayout());

    checkboxUseInsideBrowser.setText(bundle.getString("MMDCfgPanel.checkboxUseInsideBrowser.text")); // NOI18N
    checkboxUseInsideBrowser.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        checkboxUseInsideBrowserActionPerformed(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 1;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel1.add(checkboxUseInsideBrowser, gridBagConstraints);

    checkboxRelativePathsForFilesInTheProject.setText(bundle.getString("MMDCfgPanel.checkboxRelativePathsForFilesInTheProject.text")); // NOI18N
    checkboxRelativePathsForFilesInTheProject.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        checkboxRelativePathsForFilesInTheProjectActionPerformed(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 2;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel1.add(checkboxRelativePathsForFilesInTheProject, gridBagConstraints);

    checkBoxUnfoldCollapsedTarget.setText(bundle.getString("MMDCfgPanel.checkBoxUnfoldCollapsedTarget.text")); // NOI18N
    checkBoxUnfoldCollapsedTarget.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        checkBoxUnfoldCollapsedTargetActionPerformed(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 3;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel1.add(checkBoxUnfoldCollapsedTarget, gridBagConstraints);

    checkBoxCopyColorInfoToNewAllowed.setText(bundle.getString("MMDCfgPanel.checkBoxCopyColorInfoToNewAllowed.text")); // NOI18N
    checkBoxCopyColorInfoToNewAllowed.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        checkBoxCopyColorInfoToNewAllowedActionPerformed(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 4;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel1.add(checkBoxCopyColorInfoToNewAllowed, gridBagConstraints);

    checkBoxKnowledgeFolderAutogenerationAllowed.setText(bundle.getString("MMDCfgPanel.checkBoxKnowledgeFolderAutogenerationAllowed.text")); // NOI18N
    checkBoxKnowledgeFolderAutogenerationAllowed.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        checkBoxKnowledgeFolderAutogenerationAllowedActionPerformed(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 5;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel1.add(checkBoxKnowledgeFolderAutogenerationAllowed, gridBagConstraints);

    checkBoxWatchFileRefactoring.setText("Watch file refactoring (Experimental)"); // NOI18N
    checkBoxWatchFileRefactoring.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        checkBoxWatchFileRefactoringActionPerformed(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 6;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel1.add(checkBoxWatchFileRefactoring, gridBagConstraints);

    checkBoxIgnoreWhereUsedRequests.setText("Turn off processing of \"Where used\" refactoring"); // NOI18N
    checkBoxIgnoreWhereUsedRequests.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        checkBoxIgnoreWhereUsedRequestsActionPerformed(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 7;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel1.add(checkBoxIgnoreWhereUsedRequests, gridBagConstraints);

    labelMiscNeedsReloading.setForeground(java.awt.Color.red);
    labelMiscNeedsReloading.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
    labelMiscNeedsReloading.setText("IDE should be reloaded for effect"); // NOI18N
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 8;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel1.add(labelMiscNeedsReloading, gridBagConstraints);

    checkboxTrimTopicText.setText(bundle.getString("MMDCfgPanel.checkboxTrimTopicText.text")); // NOI18N
    checkboxTrimTopicText.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        checkboxTrimTopicTextActionPerformed(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 0;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel1.add(checkboxTrimTopicText, gridBagConstraints);

    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 2;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel6.add(jPanel1, gridBagConstraints);

    jPanel5.setBorder(javax.swing.BorderFactory.createTitledBorder(bundle.getString("MMDCfgPanel.jPanel5.border.title"))); // NOI18N
    jPanel5.setLayout(new java.awt.GridBagLayout());

    colorChooserSelectLine.setText(bundle.getString("MMDCfgPanel.colorChooserSelectLine.text")); // NOI18N
    colorChooserSelectLine.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
    colorChooserSelectLine.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        colorChooserSelectLineActionPerformed(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 0;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.weightx = 1000.0;
    jPanel5.add(colorChooserSelectLine, gridBagConstraints);

    jLabel3.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
    jLabel3.setText(bundle.getString("MMDCfgPanel.jLabel3.text")); // NOI18N
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 1;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.ipady = 11;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.weightx = 1000.0;
    jPanel5.add(jLabel3, gridBagConstraints);

    spinnerSelectLineWidth.setModel(new javax.swing.SpinnerNumberModel(Float.valueOf(1.0f), Float.valueOf(0.02f), Float.valueOf(100.0f), Float.valueOf(0.1f)));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 1;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.ipadx = 86;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.weightx = 1000.0;
    jPanel5.add(spinnerSelectLineWidth, gridBagConstraints);

    jLabel4.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
    jLabel4.setText(bundle.getString("MMDCfgPanel.jLabel4.text")); // NOI18N
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 2;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.ipady = 11;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel5.add(jLabel4, gridBagConstraints);

    spinnerSelectLineGap.setModel(new javax.swing.SpinnerNumberModel(1, 1, 500, 1));
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 1;
    gridBagConstraints.gridy = 2;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.ipadx = 97;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    gridBagConstraints.weightx = 1000.0;
    jPanel5.add(spinnerSelectLineGap, gridBagConstraints);

    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 3;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
    jPanel6.add(jPanel5, gridBagConstraints);

    jPanel9.setBorder(null);
    jPanel9.setLayout(new java.awt.GridBagLayout());

    buttonAbout.setIcon(new javax.swing.ImageIcon(getClass().getResource("/com/igormaznitsa/nbmindmap/icons/info16.png"))); // NOI18N
    buttonAbout.setText(bundle.getString("MMDCfgPanel.buttonAbout.Text")); // NOI18N
    buttonAbout.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        buttonAboutActionPerformed(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 1;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    jPanel9.add(buttonAbout, gridBagConstraints);
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 2;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    jPanel9.add(donateButton1, gridBagConstraints);

    buttonResetSettings.setIcon(new javax.swing.ImageIcon(getClass().getResource("/com/igormaznitsa/nbmindmap/icons/stop16.png"))); // NOI18N
    buttonResetSettings.setText(bundle.getString("MMDCfgPanel.buttonResetSettings.text"));
    buttonResetSettings.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        buttonResetSettingsActionPerformed(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 6;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    jPanel9.add(buttonResetSettings, gridBagConstraints);

    buttonExportSettings.setIcon(new javax.swing.ImageIcon(getClass().getResource("/com/igormaznitsa/nbmindmap/icons/document_export16.png"))); // NOI18N
    buttonExportSettings.setText(bundle.getString("MMDCfgPanel.buttonExportSettings.text"));
    buttonExportSettings.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        buttonExportSettingsActionPerformed(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 4;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    jPanel9.add(buttonExportSettings, gridBagConstraints);

    buttonImportSettings.setIcon(new javax.swing.ImageIcon(getClass().getResource("/com/igormaznitsa/nbmindmap/icons/document_import16.png"))); // NOI18N
    buttonImportSettings.setText(bundle.getString("MMDCfgPanel.buttonImportSettings.text"));
    buttonImportSettings.addActionListener(new java.awt.event.ActionListener() {
      public void actionPerformed(java.awt.event.ActionEvent evt) {
        buttonImportSettingsActionPerformed(evt);
      }
    });
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 5;
    gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
    jPanel9.add(buttonImportSettings, gridBagConstraints);
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 3;
    jPanel9.add(filler4, gridBagConstraints);
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 7;
    gridBagConstraints.weighty = 1000.0;
    jPanel9.add(filler5, gridBagConstraints);
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 0;
    jPanel9.add(filler2, gridBagConstraints);
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 0;
    jPanel9.add(filler6, gridBagConstraints);
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 0;
    jPanel9.add(filler7, gridBagConstraints);

    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 2;
    gridBagConstraints.gridy = 0;
    gridBagConstraints.gridheight = 4;
    gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;
    jPanel6.add(jPanel9, gridBagConstraints);
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 3;
    gridBagConstraints.gridy = 0;
    gridBagConstraints.weightx = 1000.0;
    jPanel6.add(filler1, gridBagConstraints);
    gridBagConstraints = new java.awt.GridBagConstraints();
    gridBagConstraints.gridx = 0;
    gridBagConstraints.gridy = 4;
    gridBagConstraints.weighty = 1000.0;
    jPanel6.add(filler3, gridBagConstraints);

    jScrollPane1.setViewportView(jPanel6);

    add(jScrollPane1, java.awt.BorderLayout.CENTER);
  }

def components(self):
        '''

        '''
        with self._mutex:
            if not self._components:
                self._components = [c for c in self.children if c.is_component]
        return self._components

Instruction: Given a code description, retrieve the corresponding code.


Question:
Serialize value to TCL

        :return: tuple (serialized value, serialized evaluated value of value, value is constant flag)

def serialzeValueToTCL(self, val, do_eval=False) -> Tuple[str, str, bool]:

        return str(val), str(val), True

def write_tmp_i3status_config(self, tmpfile):

        # order += ...
        for module in self.py3_config["i3s_modules"]:
            self.write_in_tmpfile('order += "%s"\n' % module, tmpfile)
        self.write_in_tmpfile("\n", tmpfile)
        # config params for general section and each module
        for section_name in ["general"] + self.py3_config["i3s_modules"]:
            section = self.py3_config[section_name]
            self.write_in_tmpfile("%s {\n" % section_name, tmpfile)
            for key, value in section.items():
                # don't include color values except in the general section
                if key.startswith("color"):
                    if (
                        section_name.split(" ")[0] not in I3S_COLOR_MODULES
                        or key not in I3S_ALLOWED_COLORS
                    ):
                        continue
                # Set known fixed format for time and tztime so we can work
                # out the timezone
                if section_name.split()[0] in TIME_MODULES:
                    if key == "format":
                        value = TZTIME_FORMAT
                    if key == "format_time":
                        continue
                if isinstance(value, bool):
                    value = "{}".format(value).lower()
                self.write_in_tmpfile('    %s = "%s"\n' % (key, value), tmpfile)
            self.write_in_tmpfile("}\n\n", tmpfile)
        tmpfile.flush()

Instruction: Given a code description, retrieve the corresponding code.


Question:
/*
(non-Javadoc)
@see javax.validation.ConstraintValidator#isValid(java.lang.Object, javax.validation.ConstraintValidatorContext)

@Override
	public boolean isValid(String value, ConstraintValidatorContext constraintContext) {

		// Si l'objet est null : false
		if(value == null) return false;

		// Si l'objet n'est pas une chaine : false
		if(!(value instanceof String)) return false;

		// On caste
		String stringValue = (String) value;

		// Si la chaine est vide : false
		if(stringValue == null || stringValue.length() == 0) return false;

		// Obtention du tableau de valeurs
		String[] parts = stringValue.split("\\.");

		// Si la tableau n'a pas une taille de 4
		if(parts == null || parts.length < 4) return false;

		// Pattern Numerique
		Pattern pattern = Pattern.compile("\\d+");

		// Parcours du tableau
		for (String part : parts) {

			// Si ce n'est pas un Numerique
			if(!pattern.matcher(part).matches()) return false;
		}

		// On retourne true
		return true;
	}

public function set($id, $value)
    {
        $id = (string) $id;

        $this->validateSet($id);

        if ($type = $this->isDefined($id)) {
            if ($type[0] == ':') {
                $type = substr($type, 1);
                $actualType = $this->getType($value);
                if ($actualType != $type) {
                    throw new WrongTypeException(sprintf('Value for item "%s" in %s container must be of type %s, but %s given.', $id, $this->name, $type, $actualType));
                }
            } else {
                if (!$value instanceof $type) {
                    throw new WrongTypeException(sprintf('Value for item "%s" in %s container must be an instance of %s class, but %s given.', $id, $this->name, $type, $this->getType($value)));
                }
            }
        }

        $this->items[$id] = $value;
    }

Instruction: Given a code description, retrieve the corresponding code.


Question: Read and parse the on-disk file associated with this object

def read
      text = @filetype.read
      if text.nil?
        raise IniParseError, _("Cannot read nonexistent file %{file}") % { file: @file.inspect }
      end
      parse(text)
    end

def _prep_genome(out_dir, data):

    genome_name = utils.splitext_plus(os.path.basename(dd.get_ref_file(data)))[0]
    out_dir = utils.safe_makedir(os.path.join(out_dir, genome_name))
    ref_file = dd.get_ref_file(data)
    utils.symlink_plus(ref_file, os.path.join(out_dir, os.path.basename(ref_file)))
    with open(os.path.join(out_dir, "GenomeSize.xml"), "w") as out_handle:
        out_handle.write('<sequenceSizes genomeName="%s">' % genome_name)
        for c in pysam.AlignmentFile("%s.dict" % utils.splitext_plus(ref_file)[0]).header["SQ"]:
            cur_ploidy = ploidy.get_ploidy([data], region=[c["SN"]])
            out_handle.write('<chromosome fileName="%s" contigName="%s" totalBases="%s" knownBases="%s" '
                             'isCircular="false" ploidy="%s" md5="%s"/>' %
                             (os.path.basename(ref_file), c["SN"], c["LN"], c["LN"], cur_ploidy, c["M5"]))
        out_handle.write('</sequenceSizes>')
    return out_dir

Instruction: Given a code description, retrieve the corresponding code.


Question: // Register a service node. Additionally supply options such as TTL.

func Register(s *Service, opts ...RegisterOption) error {
	return DefaultRegistry.Register(s, opts...)
}

func (c *TCP) Subscribe(tags []string) error {

	if len(tags) == 0 {
		return fmt.Errorf("Unable to subscribe - missing tags")
	}

	return c.encoder.Encode(&mist.Message{Command: "subscribe", Tags: tags})
}

Instruction: Given a code description, retrieve the corresponding code.


Question:
检测服务节点的一些信息

@param providerGroup 服务列表分组

protected void checkProviderInfo(ProviderGroup providerGroup) {
        List<ProviderInfo> providerInfos = providerGroup == null ? null : providerGroup.getProviderInfos();
        if (CommonUtils.isEmpty(providerInfos)) {
            return;
        }
        Iterator<ProviderInfo> iterator = providerInfos.iterator();
        while (iterator.hasNext()) {
            ProviderInfo providerInfo = iterator.next();
            if (!StringUtils.equals(providerInfo.getProtocolType(), consumerConfig.getProtocol())) {
                if (LOGGER.isWarnEnabled(consumerConfig.getAppName())) {
                    LOGGER.warnWithApp(consumerConfig.getAppName(),
                        "Unmatched protocol between consumer [{}] and provider [{}].",
                        consumerConfig.getProtocol(), providerInfo.getProtocolType());
                }
            }
        }
    }

static ElementAttributes createElementAttributes(String tag) {
        // Parsing strings
        // <!--$includetemplate$aggregated2$templatewithparams.jsp$-->
        // or
        // <!--$includeblock$aggregated2$$(block)$myblock$-->
        // in order to retrieve driver, page and name attributes
        Pattern pattern = Pattern.compile("(?<=\\$)(?:[^\\$]|\\$\\()*(?=\\$)");
        Matcher matcher = pattern.matcher(tag);
        List<String> listparameters = new ArrayList<>();
        while (matcher.find()) {
            listparameters.add(matcher.group());
        }

        String[] parameters = listparameters.toArray(new String[listparameters.size()]);

        Driver driver;
        String page = "";
        String name = null;

        if (parameters.length > 1) {
            driver = DriverFactory.getInstance(parameters[1]);
        } else {
            driver = DriverFactory.getInstance();
        }

        if (parameters.length > 2) {
            page = parameters[2];
        }

        if (parameters.length > 3) {
            name = parameters[3];
        }
        return new ElementAttributes(driver, page, name);

    }

Instruction: Given a code description, retrieve the corresponding code.


Question:
Show ``count`` most-recently modified files by mtime

        Yields:
            tuple: (strftime-formatted mtime, self.fpath-relative file path)

def lately(self, count=15):

        excludes = '|'.join(('*.pyc', '*.swp', '*.bak', '*~'))
        cmd = ('''find . -printf "%%T@ %%p\\n" '''
               '''| egrep -v '%s' '''
               '''| sort -n '''
               '''| tail -n %d''') % (excludes, count)
        op = self.sh(cmd, shell=True)
        for l in op.split('\n'):
            l = l.strip()
            if not l:
                continue
            mtime, fname = l.split(' ', 1)
            mtime = datetime.datetime.fromtimestamp(float(mtime))
            mtimestr = dtformat(mtime)
            yield mtimestr, fname

def _cutadapt_trim(fastq_files, quality_format, adapters, out_files, log_file, data):

    if all([utils.file_exists(x) for x in out_files]):
        return out_files
    cmd = _cutadapt_trim_cmd(fastq_files, quality_format, adapters, out_files, data)
    if len(fastq_files) == 1:
        of = [out_files[0], log_file]
        message = "Trimming %s in single end mode with cutadapt." % (fastq_files[0])
        with file_transaction(data, of) as of_tx:
            of1_tx, log_tx = of_tx
            do.run(cmd.format(**locals()), message)
    else:
        of = out_files + [log_file]
        with file_transaction(data, of) as tx_out_files:
            of1_tx, of2_tx, log_tx = tx_out_files
            tmp_fq1 = utils.append_stem(of1_tx, ".tmp")
            tmp_fq2 = utils.append_stem(of2_tx, ".tmp")
            singles_file = of1_tx + ".single"
            message = "Trimming %s and %s in paired end mode with cutadapt." % (fastq_files[0],
                                                                                fastq_files[1])
            do.run(cmd.format(**locals()), message)
    return out_files

Instruction: Given a code description, retrieve the corresponding code.


Question: // SetSilentPush sets the SilentPush field's value.

func (s *APNSMessage) SetSilentPush(v bool) *APNSMessage {
	s.SilentPush = &v
	return s
}

protected function notify($title, $message, $icon = null)
    {
        $icon = is_string($icon) ? $icon : $this->icon;

        $this->execute("notify-send -t 2000 -i {$icon} '{$title}' '$message'");
    }

Instruction: Given a code description, retrieve the corresponding code.


Question: multitouch gesture, could be a drag, swipe, pinch and rotate, with 2 or more points

function multitouch(position, element, done) {
                var points = config.randomizer.integer({ min: 2, max: config.maxTouches});
                var gesture = {
                    scale:     config.randomizer.floating({ min: 0, max: 2 }),
                    rotation:  config.randomizer.natural({ min: -100, max: 100 }),
                    radius:    config.randomizer.integer({ min: 50, max: 200 }),
                    distanceX: config.randomizer.integer({ min: -20, max: 20 }),
                    distanceY: config.randomizer.integer({ min: -20, max: 20 }),
                    duration:  config.randomizer.integer({ min: 100, max: 1500 })
                };
                var touches = getTouches(position, points, gesture.radius);

                triggerGesture(element, position, touches, gesture, function(touches) {
                    done(touches, gesture);
                });
            }

function _addExplicitLayerEvent($canvas, data, layer, eventName) {
	_addLayerEvent($canvas, data, layer, eventName);
	if (eventName === 'mouseover' || eventName === 'mouseout' || eventName === 'mousemove') {
		data.redrawOnMousemove = true;
	}
}

Instruction: Given a code description, retrieve the corresponding code.


Question:
// IsUserAllowedByGroup returns true if the user is allowed access
// by belonging to the appropriate group

func (o *Ownership) IsUserAllowedByGroup(
	user *auth.UserInfo,
	accessType Ownership_AccessType,
) bool {

	// Allow if it is the admin user for any group
	if o.IsAdminByUser(user) {
		return true
	}

	ownergroups := o.GetGroups()
	if len(ownergroups) == 0 {
		return false
	}

	// Check each of the groups from the user
	for _, group := range user.Claims.Groups {
		// Check if the user group has permission
		if a, ok := ownergroups[group]; ok {
			return a.isAccessPermitted(accessType)
		}
	}

	// Check if any group is allowed
	if a, ok := ownergroups["*"]; ok {
		return a.isAccessPermitted(accessType)
	}

	return false
}

public function sqlQueryCheck($q)
    {
        if (\stripos($q, 'union') !== false) {
            dump('UNION usage is limited.');
        }

        if (\stripos($q, ' like \'%\'') !== false) {
            dump('LIKE \'%\' usage is limited.');
        }

        if (\strpos($q, '/*') !== false || \strpos($q, '--') !== false) {
            dump('Comments like \* or -- usage is limited. Query: ' . $q);
        }
    }

Instruction: Given a code description, retrieve the corresponding code.


Question: // Image returns the docker image name for the specified component

func Image(component string, clusterSpec *kops.ClusterSpec, assetsBuilder *assets.AssetBuilder) (string, error) {
	if assetsBuilder == nil {
		return "", fmt.Errorf("unable to parse assets as assetBuilder is not defined")
	}
	// TODO remove this, as it is an addon now
	if component == "kube-dns" {
		// TODO: Once we are shipping different versions, start to use them
		return "k8s.gcr.io/kubedns-amd64:1.3", nil
	}

	kubernetesVersion, err := k8sversion.Parse(clusterSpec.KubernetesVersion)
	if err != nil {
		return "", err
	}

	if !IsBaseURL(clusterSpec.KubernetesVersion) {
		image := "k8s.gcr.io/" + component + ":" + "v" + kubernetesVersion.String()

		image, err := assetsBuilder.RemapImage(image)
		if err != nil {
			return "", fmt.Errorf("unable to remap container %q: %v", image, err)
		}
		return image, nil
	}

	baseURL := clusterSpec.KubernetesVersion
	baseURL = strings.TrimSuffix(baseURL, "/")

	// TODO path.Join here?
	tagURL := baseURL + "/bin/linux/amd64/" + component + ".docker_tag"
	glog.V(2).Infof("Downloading docker tag for %s from: %s", component, tagURL)

	b, err := vfs.Context.ReadFile(tagURL)
	if err != nil {
		return "", fmt.Errorf("error reading tag file %q: %v", tagURL, err)
	}
	tag := strings.TrimSpace(string(b))
	glog.V(2).Infof("Found tag %q for %q", tag, component)

	image := "k8s.gcr.io/" + component + ":" + tag

	// When we're using a docker load-ed image, we are likely a CI build.
	// But the k8s.gcr.io prefix is an alias, and we only double-tagged from 1.10 onwards.
	// For versions prior to 1.10, remap k8s.gcr.io to the old name.
	// This also means that we won't start using the aliased names on existing clusters,
	// which could otherwise be surprising to users.
	if !kubernetesVersion.IsGTE("1.10") {
		image = "gcr.io/google_containers/" + strings.TrimPrefix(image, "k8s.gcr.io/")
	}

	return image, nil
}

def as_name(value)
      case true
      when value.tag?
        element(value).name
      when value.dicom_name?
        @methods_from_names.has_key?(value) ? value.to_s : nil
      when value.dicom_method?
        @names_from_methods[value.to_sym]
      else
        nil
      end
    end

Instruction: Given a code description, retrieve the corresponding code.


Question:
// CreateEndpoint creates a TCP endpoint for the connection request, performing
// the 3-way handshake in the process.

func (r *ForwarderRequest) CreateEndpoint(queue *waiter.Queue) (tcpip.Endpoint, *tcpip.Error) {
	r.mu.Lock()
	defer r.mu.Unlock()

	if r.segment == nil {
		return nil, tcpip.ErrInvalidEndpointState
	}

	f := r.forwarder
	ep, err := f.listen.createEndpointAndPerformHandshake(r.segment, &header.TCPSynOptions{
		MSS:           r.synOptions.MSS,
		WS:            r.synOptions.WS,
		TS:            r.synOptions.TS,
		TSVal:         r.synOptions.TSVal,
		TSEcr:         r.synOptions.TSEcr,
		SACKPermitted: r.synOptions.SACKPermitted,
	})
	if err != nil {
		return nil, err
	}

	// Start the protocol goroutine.
	ep.startAcceptedLoop(queue)

	return ep, nil
}

public void configureHttpPipeline(ChannelPipeline pipeline, TargetHandler targetHandler) {
        pipeline.addLast(Constants.HTTP_CLIENT_CODEC, new HttpClientCodec());
        addCommonHandlers(pipeline);
        pipeline.addLast(Constants.BACK_PRESSURE_HANDLER, new BackPressureHandler());
        pipeline.addLast(Constants.TARGET_HANDLER, targetHandler);
    }

Instruction: Given a code description, retrieve the corresponding code.


Question:
@param array $args

@return Collection|\Polyether\Support\EtherError

public function query($args = [])
    {
        $defaults = [
            'orderby'       => 'id',
            'order'         => 'DESC',
            'paginate'      => Option::get('default_posts_paginate', 20),
            'cat_in'        => [], //ids
            'cat_not_in'    => [], //ids
            'tag_in'        => [], //ids
            'tag_not_in'    => [], //ids
            'parent_in'     => [], //ids
            'parent_not_in' => [],
            'meta_query'    => [], // Array Of Arrays

        ];

        $args = array_merge($defaults, $args);

        $current_page = Request::get('page', 1);
        $cache_key = 'posts_' . md5(http_build_query($args) . '_' . $current_page);
        if (Cache::tags('posts')->has($cache_key)) {
            $posts = Cache::tags('posts')->get($cache_key);
        } else {
            $posts = $this->postRepository->queryPosts($args);

            if ( ! count($posts) > 0) {
                return new EtherError('No Posts were found');
            }

            Cache::tags('posts')->put($cache_key, $posts, \Option::get('posts_cache_expires', 60));

        }

        return $posts;
    }

func GetUsers() []User {
	var userPagesResponse struct {
		NextURL   *string `json:"next_url"`
		Resources []struct {
			Metadata struct {
				GUID      string    `json:"guid"`
				CreatedAt time.Time `json:"created_at"`
			} `json:"metadata"`
			Entity struct {
				Username string `json:"username"`
			} `json:"entity"`
		} `json:"resources"`
	}

	var allUsers []User
	nextURL := "/v2/users?results-per-page=50"

	for {
		session := CF("curl", nextURL)
		Eventually(session).Should(Exit(0))

		err := json.Unmarshal(session.Out.Contents(), &userPagesResponse)
		Expect(err).NotTo(HaveOccurred())
		for _, resource := range userPagesResponse.Resources {
			allUsers = append(allUsers, User{
				GUID:      resource.Metadata.GUID,
				CreatedAt: resource.Metadata.CreatedAt,
				Username:  resource.Entity.Username,
			})
		}

		if userPagesResponse.NextURL == nil {
			break
		}
		nextURL = *userPagesResponse.NextURL
	}

	return allUsers
}

Instruction: Given a code description, retrieve the corresponding code.


Question:
get all of the data urls for a specified endpoint_type, currently supported types
    are:

     * http-import: for importing data points
     * juttle: for running juttle programs

def get_data_urls(deployment_name,
                  endpoint_type='juttle',
                  token_manager=None,
                  app_url=defaults.APP_URL):

    deployment_details = deployments.get_deployment_details(deployment_name,
                                                            token_manager=token_manager,
                                                            app_url=app_url)

    # use a random juttle endpoint
    data_urls = []
    for endpoint in deployment_details['endpoints']:
        if endpoint_type in endpoint['type']:
            data_urls.append(endpoint['uri'])

    if len(data_urls) == 0:
        raise JutException('No data engine currently configured for '
                           'deployment "%s"' % deployment_name)

    return data_urls

public void start() throws Exception {
		synchronized (this.lock) {
			if (this.nephele == null) {

				// create the embedded runtime
				this.nephele = new NepheleMiniCluster();

				// configure it, if values were changed. otherwise the embedded runtime uses the internal defaults
				if (jobManagerRpcPort > 0) {
					nephele.setJobManagerRpcPort(jobManagerRpcPort);
				}
				if (taskManagerRpcPort > 0) {
					nephele.setTaskManagerRpcPort(jobManagerRpcPort);
				}
				if (taskManagerDataPort > 0) {
					nephele.setTaskManagerDataPort(taskManagerDataPort);
				}
				if (configDir != null) {
					nephele.setConfigDir(configDir);
				}
				if (hdfsConfigFile != null) {
					nephele.setHdfsConfigFile(hdfsConfigFile);
				}
				nephele.setDefaultOverwriteFiles(defaultOverwriteFiles);
				nephele.setDefaultAlwaysCreateDirectory(defaultAlwaysCreateDirectory);

				// start it up
				this.nephele.start();
			} else {
				throw new IllegalStateException("The local executor was already started.");
			}
		}
	}

Instruction: Given a code description, retrieve the corresponding code.


Question:
Builds a new vector by applying given {@code function} to each element
of this vector.

@param function the vector function

@return the transformed vector

public Vector transform(VectorFunction function) {
        VectorIterator it = iterator();
        Vector result = blank();

        while (it.hasNext()) {
            double x = it.next();
            int i = it.index();
            result.set(i, function.evaluate(i, x));
        }

        return result;
    }

func setBlendFunc(cmp pixel.ComposeMethod) {
	switch cmp {
	case pixel.ComposeOver:
		glhf.BlendFunc(glhf.One, glhf.OneMinusSrcAlpha)
	case pixel.ComposeIn:
		glhf.BlendFunc(glhf.DstAlpha, glhf.Zero)
	case pixel.ComposeOut:
		glhf.BlendFunc(glhf.OneMinusDstAlpha, glhf.Zero)
	case pixel.ComposeAtop:
		glhf.BlendFunc(glhf.DstAlpha, glhf.OneMinusSrcAlpha)
	case pixel.ComposeRover:
		glhf.BlendFunc(glhf.OneMinusDstAlpha, glhf.One)
	case pixel.ComposeRin:
		glhf.BlendFunc(glhf.Zero, glhf.SrcAlpha)
	case pixel.ComposeRout:
		glhf.BlendFunc(glhf.Zero, glhf.OneMinusSrcAlpha)
	case pixel.ComposeRatop:
		glhf.BlendFunc(glhf.OneMinusDstAlpha, glhf.SrcAlpha)
	case pixel.ComposeXor:
		glhf.BlendFunc(glhf.OneMinusDstAlpha, glhf.OneMinusSrcAlpha)
	case pixel.ComposePlus:
		glhf.BlendFunc(glhf.One, glhf.One)
	case pixel.ComposeCopy:
		glhf.BlendFunc(glhf.One, glhf.Zero)
	default:
		panic(errors.New("Canvas: invalid compose method"))
	}
}

Instruction: Given a code description, retrieve the corresponding code.


Question: ### setFromString() Sets a property from a string.  t.setFromString('scale', '2,4'); // Same as set('scale', '2', '4');

function(prop, val) {
      var args =
        (typeof val === 'string')  ? val.split(',') :
        (val.constructor === Array) ? val :
        [ val ];

      args.unshift(prop);

      Transform.prototype.set.apply(this, args);
    }

function assignKey(key, scope, method){
    var keys, mods, i, mi;
    if (method === undefined) {
      method = scope;
      scope = 'all';
    }
    key = key.replace(/\s/g,'');
    keys = key.split(',');

    if((keys[keys.length-1])=='')
      keys[keys.length-2] += ',';
    // for each shortcut
    for (i = 0; i < keys.length; i++) {
      // set modifier keys if any
      mods = [];
      key = keys[i].split('+');
      if(key.length > 1){
        mods = key.slice(0,key.length-1);
        for (mi = 0; mi < mods.length; mi++)
          mods[mi] = _MODIFIERS[mods[mi]];
        key = [key[key.length-1]];
      }
      // convert to keycode and...
      key = key[0]
      key = _MAP[key] || key.toUpperCase().charCodeAt(0);
      // ...store handler
      if (!(key in _handlers)) _handlers[key] = [];
      _handlers[key].push({ shortcut: keys[i], scope: scope, method: method, key: keys[i], mods: mods });
    }
  }

Instruction: Given a code description, retrieve the corresponding code.


Question: get a connection by node

def get_connection_by_node(self, node):

        self._checkpid()
        self.nodes.set_node_name(node)

        try:
            # Try to get connection from existing pool
            connection = self._available_connections.get(node["name"], []).pop()
        except IndexError:
            connection = self.make_connection(node)

        self._in_use_connections.setdefault(node["name"], set()).add(connection)

        return connection

func (s *DescribeNodeAssociationStatusInput) SetServerName(v string) *DescribeNodeAssociationStatusInput {
	s.ServerName = &v
	return s
}

Instruction: Given a code description, retrieve the corresponding code.


Question:
Sets the minimum number of active connections to be maintained.

@param minConnections the minConnections to set
@return a reference to this RiakNode
@see Builder#withMinConnections(int)

public RiakNode setMinConnections(int minConnections)
    {
        stateCheck(State.CREATED, State.RUNNING, State.HEALTH_CHECKING);
        if (minConnections <= getMaxConnections())
        {
            this.minConnections = minConnections;
        }
        else
        {
            throw new IllegalArgumentException("Min connections greater than max connections");
        }
        // TODO: Start / reap delta?
        return this;
    }

def create_node(**kwargs):
    '''

    '''
    name = kwargs['name']
    size = kwargs['size']
    image = kwargs['image']
    location = kwargs['location']
    networks = kwargs.get('networks')
    tag = kwargs.get('tag')
    locality = kwargs.get('locality')
    metadata = kwargs.get('metadata')
    firewall_enabled = kwargs.get('firewall_enabled')

    create_data = {
        'name': name,
        'package': size['name'],
        'image': image['name'],
    }
    if networks is not None:
        create_data['networks'] = networks

    if locality is not None:
        create_data['locality'] = locality

    if metadata is not None:
        for key, value in six.iteritems(metadata):
            create_data['metadata.{0}'.format(key)] = value

    if tag is not None:
        for key, value in six.iteritems(tag):
            create_data['tag.{0}'.format(key)] = value

    if firewall_enabled is not None:
        create_data['firewall_enabled'] = firewall_enabled

    data = salt.utils.json.dumps(create_data)

    ret = query(command='my/machines', data=data, method='POST',
                location=location)
    if ret[0] in VALID_RESPONSE_CODES:
        return ret[1]
    else:
        log.error('Failed to create node %s: %s', name, ret[1])

    return {}

Instruction: Given a code description, retrieve the corresponding code.


Question:
Defines a relationship via a custom accessor.

@param callable $getter
@param callable $setter

@return RelationUsingDefiner
@throws InvalidArgumentException

public function accessorRelation(callable $getter, callable $setter): RelationUsingDefiner
    {
        return $this->defineRelationVia(new CustomAccessor($getter, $setter), function () {
            $this->verifyAllPropertiesMapped = false;
        });
    }

public function translate(callable $f)
    {
        list($this->x, $this->y, $this->value) = $f($this->x, $this->y, $this->value);
    }

Instruction: Given a code description, retrieve the corresponding code.


Question: Pre-formats the multipart HTTP request to transmit the directory.

def _prepare(self):
        """"""
        names = []

        added_directories = set()

        def add_directory(short_path):
            # Do not continue if this directory has already been added
            if short_path in added_directories:
                return

            # Scan for first super-directory that has already been added
            dir_base  = short_path
            dir_parts = []
            while dir_base:
                dir_base, dir_name = os.path.split(dir_base)
                dir_parts.append(dir_name)
                if dir_base in added_directories:
                    break

            # Add missing intermediate directory nodes in the right order
            while dir_parts:
                dir_base = os.path.join(dir_base, dir_parts.pop())

                # Create an empty, fake file to represent the directory
                mock_file = io.StringIO()
                mock_file.write(u'')
                # Add this directory to those that will be sent
                names.append(('files',
                             (dir_base.replace(os.sep, '/'), mock_file, 'application/x-directory')))
                # Remember that this directory has already been sent
                added_directories.add(dir_base)

        def add_file(short_path, full_path):
            try:
                # Always add files in wildcard directories
                names.append(('files', (short_name.replace(os.sep, '/'),
                                        open(full_path, 'rb'),
                                        'application/octet-stream')))
            except OSError:
                # File might have disappeared between `os.walk()` and `open()`
                pass

        def match_short_path(short_path):
            # Remove initial path component so that all files are based in
            # the target directory itself (not one level above)
            if os.sep in short_path:
                path = short_path.split(os.sep, 1)[1]
            else:
                return False

            # Convert all path seperators to POSIX style
            path = path.replace(os.sep, '/')

            # Do the matching and the simplified path
            for pattern in self.patterns:
                if pattern.match(path):
                    return True
            return False

        # Identify the unecessary portion of the relative path
        truncate = os.path.dirname(self.directory)
        # Traverse the filesystem downward from the target directory's uri
        # Errors: `os.walk()` will simply return an empty generator if the
        #         target directory does not exist.
        wildcard_directories = set()
        for curr_dir, _, files in os.walk(self.directory):
            # find the path relative to the directory being added
            if len(truncate) > 0:
                _, _, short_path = curr_dir.partition(truncate)
            else:
                short_path = curr_dir
            # remove leading / or \ if it is present
            if short_path.startswith(os.sep):
                short_path = short_path[1:]

            wildcard_directory = False
            if os.path.split(short_path)[0] in wildcard_directories:
                # Parent directory has matched a pattern, all sub-nodes should
                # be added too
                wildcard_directories.add(short_path)
                wildcard_directory = True
            else:
                # Check if directory path matches one of the patterns
                if match_short_path(short_path):
                    # Directory matched pattern and it should therefor
                    # be added along with all of its contents
                    wildcard_directories.add(short_path)
                    wildcard_directory = True

            # Always add directories within wildcard directories - even if they
            # are empty
            if wildcard_directory:
                add_directory(short_path)

            # Iterate across the files in the current directory
            for filename in files:
                # Find the filename relative to the directory being added
                short_name = os.path.join(short_path, filename)
                filepath = os.path.join(curr_dir, filename)

                if wildcard_directory:
                    # Always add files in wildcard directories
                    add_file(short_name, filepath)
                else:
                    # Add file (and all missing intermediary directories)
                    # if it matches one of the patterns
                    if match_short_path(short_name):
                        add_directory(short_path)
                        add_file(short_name, filepath)
        # Send the request and present the response body to the user
        req = requests.Request("POST", 'http://localhost', files=names)
        prep = req.prepare()
        return prep

def do_drag_data_received(self, drag_context, x, y, data, info, time):
        '''
        '''
        if not self.app.profile:
            return
        if info == TargetInfo.URI_LIST:
            uris = data.get_uris()
            source_paths = util.uris_to_paths(uris)
            if source_paths:
                self.app.upload_page.upload_files(source_paths, self.path)

Instruction: Given a code description, retrieve the corresponding code.


Question: // IsNotFound returns true if err is not nil and represents a missing resource.

func IsNotFound(err error) bool {
	switch {
	case err == nil:
		return false
	case strings.Contains(err.Error(), "does not exist"):
		return true
	case strings.Contains(err.Error(), "not found"):
		return true
	default:
		return false
	}
}

def render_file_set_status
      @file_set_status ||=
        if relevant_log_records.empty?
          "Fixity checks have not yet been run on this object"
        elsif failing_checks.empty?
          content_tag("span", "passed", class: "label label-success") + ' ' + render_existing_check_summary
        else
          content_tag("span", "FAIL", class: "label label-danger") + ' ' + render_existing_check_summary + render_failed_compact
        end
    end

Instruction: Given a code description, retrieve the corresponding code.


Question:
// whitespace returns all whitespace (i.e. ' ' and '\t') runes in a sequence,
// or an error if there is a problem reading the next runes.

func (l *lexer) whitespace() ([]rune, Error) {
	// read until we hit the first non-whitespace rune
	_ws := make([]rune, 0, 1)

	// loop until there's nothing more to do
	for {
		_next, _err := l.read()
		if _err != nil {
			return _ws, _err
		}

		// what is this next rune?
		switch _next {
		// space or tab is consumed
		case _SPACE:
			fallthrough
		case _TAB:
			break

		// non-whitespace rune
		default:
			// return the rune to the buffer and we're done
			l.unread(_next)
			return _ws, nil
		}

		// add this rune to the whitespace
		_ws = append(_ws, _next)
	}
}

function unexpectedTokenError(token, message) {
        var value, msg = message || Messages.UnexpectedToken;

        if (token) {
            if (!message) {
                msg = (token.type === Token.EOF) ? Messages.UnexpectedEOS :
                    (token.type === Token.Identifier) ? Messages.UnexpectedIdentifier :
                    (token.type === Token.NumericLiteral) ? Messages.UnexpectedNumber :
                    (token.type === Token.StringLiteral) ? Messages.UnexpectedString :
                    (token.type === Token.Template) ? Messages.UnexpectedTemplate :
                    Messages.UnexpectedToken;

                if (token.type === Token.Keyword) {
                    if (isFutureReservedWord(token.value)) {
                        msg = Messages.UnexpectedReserved;
                    } else if (strict && isStrictModeReservedWord(token.value)) {
                        msg = Messages.StrictReservedWord;
                    }
                }
            }

            value = (token.type === Token.Template) ? token.value.raw : token.value;
        } else {
            value = 'ILLEGAL';
        }

        msg = msg.replace('%0', value);

        return (token && typeof token.lineNumber === 'number') ?
            createError(token.lineNumber, token.start, msg) :
            createError(scanning ? lineNumber : lastLineNumber, scanning ? index : lastIndex, msg);
    }

Instruction: Given a code description, retrieve the corresponding code.


Question: // Dead mocks base method

func (m *MockBaseWatcher) Dead() <-chan struct{} {
	ret := m.ctrl.Call(m, "Dead")
	ret0, _ := ret[0].(<-chan struct{})
	return ret0
}

public function dispatch(
        MetaboxModel $metabox,
        MetaboxFactory $factory,
        HookFactory $hook
    ) {
        $this->metabox = $metabox;
        $this->factory = $factory;
        $this->hook = $hook;
    }

Instruction: Given a code description, retrieve the corresponding code.


Question:
Get debug info of current metadata file.
@return array

public function debugInfo()
    {
        return [
            'exists' => $this->exists(),
            'isFile' => $this->isFile(),
            'isImage' => $this->isImage(),
            'path' => $this->path,
            'lastModified' => $this->lastModified,
            'name' => $this->name,
            'dir' => $this->dir,
            'mimeType' => $this->mimeType,
            'extension' => $this->extension,
            'size' => $this->size,
            'type' => $this->type,
            'getFullName' => $this->getFullName()
        ];
    }

public function storeMeta($key, $value)
    {
        $value = json_encode($value);
        Factory::getStore('Build')->setMeta($this->getProjectId(), $this->getId(), $key, $value);
    }

Instruction: Given a code description, retrieve the corresponding code.


Question:
Get the tree header.

@return a content tree for the tree header

protected HtmlTree getTreeHeader() {
        String title = configuration.getText("doclet.Window_Class_Hierarchy");
        HtmlTree bodyTree = getBody(true, getWindowTitle(title));
        HtmlTree htmlTree = (configuration.allowTag(HtmlTag.HEADER))
                ? HtmlTree.HEADER()
                : bodyTree;
        addTop(htmlTree);
        addNavLinks(true, htmlTree);
        if (configuration.allowTag(HtmlTag.HEADER)) {
            bodyTree.addContent(htmlTree);
        }
        return bodyTree;
    }

def leaveEvent( self, event ):

        hitem = self.hoveredItem()
        hcol  = self.hoveredColumn()

        if ( hitem != None ):
            self._hoveredItem   = None
            self._hoveredColumn = -1

            rect = self.visualItemRect(hitem)
            rect.setWidth(self.viewport().width())
            self.viewport().update(rect)

        super(XTreeWidget, self).leaveEvent(event)

Instruction: Given a code description, retrieve the corresponding code.


Question:
Set request

@param RequestInterface $request
@return self

public function setRequest(RequestInterface $request)
    {
        $this->setParam('request', $request);
        $this->request = $request;

        return $this;
    }

func newOpClientRequest(reqType opClientRequestType, args interface{}) opClientRequest {
	return opClientRequest{
		op:       reqType,
		args:     args,
		response: make(chan interface{}),
	}
}

Instruction: Given a code description, retrieve the corresponding code.


Question:
Хелпер для фактического вызова метода модели и обработки результата
@param {ns.View~UpdateTree} updateTree вид, инициирующий вызов
@param {String} methodName имя метода модели
@param {...*} args
@returns {*}

function nsViewCallHelper(updateTree, methodName, p1, p2, p3, p4, p5) {
        var tree = yr.nodeset2data(updateTree);
        var view = tree.bosphorus;

        var result = view[methodName](p1, p2, p3, p4, p5);
        return result2nodeset(result);
    }

async function resolve (ant, resolveArgs, fieldArgs, currentValue, model) {
  let field = null;
  if (model) {
    field = model.field;
  }
  if (ant && resolveArgs && resolveArgs.to) {
    const antFunction =  ant.functionController.getFunction(resolveArgs.to);
    if (!antFunction) {
      logger.error(new AntError(
        `Could not find "${resolveArgs.to}" function`
      ));
      return null;
    }
    try {
      currentValue = antFunction.run(
        currentValue !== undefined ? currentValue : fieldArgs
      );
      if (currentValue instanceof Observable) {
        if (
          field &&
          field.astNode &&
          field.astNode.type &&
          field.astNode.type.kind === 'ListType'
        ) {
          return await currentValue.pipe(
            flatMap(data => data instanceof Array ? data : [ data ]),
            toArray()
          ).toPromise();
        } else {
          return await currentValue.toPromise();
        }
      } else {
        return currentValue;
      }
    } catch (e) {
      logger.error(new AntError(
        `Could not run "${resolveArgs.to}" function`,
        e
      ));
    }
  }
  return null;
}

Instruction: Given a code description, retrieve the corresponding code.


Question: // SetTextTransformation sets the TextTransformation field's value.

func (s *ByteMatchTuple) SetTextTransformation(v string) *ByteMatchTuple {
	s.TextTransformation = &v
	return s
}

public BaseFontParameters getBaseFontParameters(String name) {
        String alias = (String)aliases.get(name);
        if (alias == null)
            return (BaseFontParameters)mapper.get(name);
        BaseFontParameters p = (BaseFontParameters)mapper.get(alias);
        if (p == null)
            return (BaseFontParameters)mapper.get(name);
        else
            return p;
    }

Instruction: Given a code description, retrieve the corresponding code.


Question:
// synSentStateOutbound is the state handler for outbound segments when the
// connection is in SYN-SENT state.

func synSentStateOutbound(t *TCB, tcp header.TCP) Result {
	// Drop outbound segments that aren't retransmits of the original one.
	if tcp.Flags() != header.TCPFlagSyn ||
		tcp.SequenceNumber() != uint32(t.outbound.una) {
		return ResultDrop
	}

	// Update the receive window. We only remember the largest value seen.
	if wnd := seqnum.Value(tcp.WindowSize()); wnd > t.inbound.end {
		t.inbound.end = wnd
	}

	return ResultConnecting
}

func reorderChunks(name string, respCh <-chan *chunkResp, chunkRespc chan<- *chunkResp, eofCh chan<- struct{}, closedc <-chan struct{}) {
	pending := make(map[int64]*chunkResp)
	var off int64
	for resp := range respCh {
		glog.V(2).Infof("Received chunk (off=%d chunk=<%d bytes> err=%v", resp.off, len(resp.chunk), resp.err)
		pending[resp.off] = resp
		if resp.err != nil && eofCh != nil {
			close(eofCh)
			eofCh = nil
		}
		for {
			resp, ok := pending[off]
			if !ok {
				break
			}
			if resp.err != nil && resp.err != io.EOF {
				glog.Errorf("readahead %s: about to report an error %v", name, resp.err)
			}
			glog.V(2).Infof("Returning chunk (off=%d chunk=<%d bytes> err=%v", resp.off, len(resp.chunk), resp.err)
			select {
			case chunkRespc <- resp:
			case <-closedc:
				// N.B. We are aborting here before draining respCh; the other
				// goroutines will abort asynchronously on closedc as well.
				return
			}
			delete(pending, off)
			off += int64(len(resp.chunk))
		}
	}
}

Instruction: Given a code description, retrieve the corresponding code.


Question:
Get the instance of the claim when passing the name and value.

@param  string  $name
@param  mixed   $value
@return \Lia\Addons\JWTAuth\Claims\Claim

public function get($name, $value)
    {
        if ($this->has($name)) {
            return new self::$classMap[$name]($value);
        }

        return new Custom($name, $value);
    }

func (c *FakePersistentVolumeClaims) Create(persistentVolumeClaim *corev1.PersistentVolumeClaim) (result *corev1.PersistentVolumeClaim, err error) {
	obj, err := c.Fake.
		Invokes(testing.NewCreateAction(persistentvolumeclaimsResource, c.ns, persistentVolumeClaim), &corev1.PersistentVolumeClaim{})

	if obj == nil {
		return nil, err
	}
	return obj.(*corev1.PersistentVolumeClaim), err
}

Instruction: Given a code description, retrieve the corresponding code.


Question: Returns list of all :class:`~plexapi.client.PlexClient` objects connected to server.

def clients(self):

        items = []
        ports = None
        for elem in self.query('/clients'):
            port = elem.attrib.get('port')
            if not port:
                log.warning('%s did not advertise a port, checking plex.tv.', elem.attrib.get('name'))
                ports = self._myPlexClientPorts() if ports is None else ports
                port = ports.get(elem.attrib.get('machineIdentifier'))
            baseurl = 'http://%s:%s' % (elem.attrib['host'], port)
            items.append(PlexClient(baseurl=baseurl, server=self,
                                    token=self._token, data=elem, connect=False))

        return items

def search(query, team=None):

    if team is None:
        team = _find_logged_in_team()

    if team is not None:
        session = _get_session(team)
        response = session.get("%s/api/search/" % get_registry_url(team), params=dict(q=query))
        print("* Packages in team %s" % team)
        packages = response.json()['packages']
        for pkg in packages:
            print(("%s:" % team) + ("%(owner)s/%(name)s" % pkg))
        if len(packages) == 0:
            print("(No results)")
        print("* Packages in public cloud")

    public_session = _get_session(None)
    response = public_session.get("%s/api/search/" % get_registry_url(None), params=dict(q=query))
    packages = response.json()['packages']
    for pkg in packages:
        print("%(owner)s/%(name)s" % pkg)
    if len(packages) == 0:
        print("(No results)")

Instruction: Given a code description, retrieve the corresponding code.


Question:
Set the time at which the resource was last modified.

@param lastModified the lastModified value to set
@return the TaskGetHeaders object itself.

public TaskGetHeaders withLastModified(DateTime lastModified) {
        if (lastModified == null) {
            this.lastModified = null;
        } else {
            this.lastModified = new DateTimeRfc1123(lastModified);
        }
        return this;
    }

public function httpOptions(RequestInterface $request, ResponseInterface $response)
    {
        $methods = $this->server->getAllowedMethods($request->getPath());

        $response->setHeader('Allow', strtoupper(implode(', ', $methods)));
        $features = ['1', '3', 'extended-mkcol'];

        foreach ($this->server->getPlugins() as $plugin) {
            $features = array_merge($features, $plugin->getFeatures());
        }

        $response->setHeader('DAV', implode(', ', $features));
        $response->setHeader('MS-Author-Via', 'DAV');
        $response->setHeader('Accept-Ranges', 'bytes');
        $response->setHeader('Content-Length', '0');
        $response->setStatus(200);

        // Sending back false will interrupt the event chain and tell the server
        // we've handled this method.
        return false;
    }

Instruction: Given a code description, retrieve the corresponding code.


Question:
Creates a new model.
If creation is successful, the browser will be redirected to the 'view' page.

public function actionGeneral()
	{
		if(Yii::app()->user->level != 1)
			throw new CHttpException(404, Yii::t('phrase', 'The requested page does not exist.'));

		$model = OmmuSettings::model()->findByPk(1);
		if($model == null)
			$model=new OmmuSettings;

		// Uncomment the following line if AJAX validation is needed
		$this->performAjaxValidation($model);

		if(isset($_POST['OmmuSettings'])) {
			$model->attributes=$_POST['OmmuSettings'];
			$model->scenario = 'general';

			$jsonError = CActiveForm::validate($model);
			if(strlen($jsonError) > 2) {
				$errors = $model->getErrors();
				$summary['msg'] = "
".Yii::t('phrase', 'Please fix the following input errors:')."";
				$summary['msg'] .= "
";
				foreach($errors as $key => $value) {
					$summary['msg'] .= "
{$value[0]}
";
				}
				$summary['msg'] .= "

";

				$message = json_decode($jsonError, true);
				$merge = array_merge_recursive($summary, $message);
				$encode = json_encode($merge);
				echo $encode;

			} else {
				if(Yii::app()->getRequest()->getParam('enablesave') == 1) {
					if($model->save()) {
						echo CJSON::encode(array(
							'type' => 0,
							'msg' => '
'.Yii::t('phrase', 'General settings success updated.').'
',
						));
					} else {
						print_r($model->getErrors());
					}
				}
			}
			Yii::app()->end();
		}

		$this->pageTitle = Yii::t('phrase', 'General Settings');
		$this->pageDescription = Yii::t('phrase', 'This page contains general settings that affect your entire social network.');
		$this->pageMeta = '';
		$this->render('admin_general', array(
			'model'=>$model,
		));
	}

def add_to_gui(self, content):

        if not self.rewrite_config:
            raise DirectoryException("Error! Directory was not intialized w/ rewrite_config.")
        if not self.gui_file:
            self.gui_path, self.gui_file = self.__get_gui_handle(self.root_dir)
        self.gui_file.write(content + '\n')

Instruction: Given a code description, retrieve the corresponding code.


Question:
Add new condition to decorator

@param string $name
@param array $options
@return $this|null

public function addCondition($name, $options)
    {
        if ($this instanceof DataAccessInterface) {
            $condition = ConditionFactory::factory($name, $options);
            $condition->setDecorator($this);
            $this->attachCondition($condition);
            return $this;
        }
    }

public function formatOutput(Route $route, Output $output, $type = self::STYLE_DETAIL)
    {
        switch ($type) {
            case self::STYLE_DETAIL:
                $output->write('Route [');
                $output->write('<success>"' . $route->getName() . '"</success>');
                $output->writeln(']');
                $output->writeln("Path:\t\t" . str_replace('//', '/', $route->getPath()));
                $output->writeln("Method:\t\t" . $route->getMethod());
                $output->writeln("Format:\t\t" . implode(', ', $route->getFormats()));
                $output->writeln("Callback:\t" . (is_callable($route->getCallback()) ? 'Closure' : $route->getCallback()));
                $output->writeln("Defaults:\t" . implode(', ', $route->getDefaults()));
                $output->writeln("Requirements:\t" . implode(', ', $route->getRequirements()));
                $output->writeln("Path-Regex:\t" . $route->getPathRegex());
                $output->writeln('');
                break;
            case self::STYLE_LIST:
            default:
                $name = $route->getName();
                $method = $route->getMethod();
                $schema = $route->getScheme() ?? 'http';
                $path = $route->getPath();
                $output->write($name . str_repeat(' ', 25 - strlen($name)));
                $output->write($method . str_repeat(' ', 15 - strlen($method)));
                $output->write($schema . str_repeat(' ', 15 - strlen($schema)));
                $output->writeln($path);
        }

        return;
    }

Instruction: Given a code description, retrieve the corresponding code.


Question: Returns the size of the :attr:`data` object in bytes (read-only).

def data_size(self):

        # Container
        if is_container(self._data):
            byte_length, bit_length = self._data.container_size()
            return byte_length + math.ceil(bit_length / 8)
        # Field
        elif is_field(self._data):
            return math.ceil(self._data.bit_size / 8)
        else:
            return 0

public static void printMountInfo(Map<String, MountPointInfo> mountTable) {
    for (Map.Entry<String, MountPointInfo> entry : mountTable.entrySet()) {
      String mMountPoint = entry.getKey();
      MountPointInfo mountPointInfo = entry.getValue();

      long capacityBytes = mountPointInfo.getUfsCapacityBytes();
      long usedBytes = mountPointInfo.getUfsUsedBytes();

      String usedPercentageInfo = "";
      if (capacityBytes > 0) {
        int usedPercentage = (int) (100L * usedBytes / capacityBytes);
        usedPercentageInfo = String.format("(%s%%)", usedPercentage);
      }

      String leftAlignFormat = getAlignFormat(mountTable);

      System.out.format(leftAlignFormat, mountPointInfo.getUfsUri(), mMountPoint,
          mountPointInfo.getUfsType(), FormatUtils.getSizeFromBytes(capacityBytes),
          FormatUtils.getSizeFromBytes(usedBytes) + usedPercentageInfo,
          mountPointInfo.getReadOnly() ? "" : "not ",
          mountPointInfo.getShared() ? "" : "not ");
      System.out.println("properties=" + mountPointInfo.getProperties() + ")");
    }
  }

Instruction: Given a code description, retrieve the corresponding code.


Question:
Revokes a permission from the RBAC system.

@param string $permission
@return bool

public function revokePermission($permission)
    {
        if ($this->hasPermission($permission)) {
            unset($this->permissions[$permission]);
            return true;
        } else {
            return false;
        }
    }

public function truncateLaratrustTables()
    {
        DB::statement('SET FOREIGN_KEY_CHECKS = 0');
        DB::table('permission_role')->truncate();
        DB::table('permission_user')->truncate();
        DB::table('role_user')->truncate();
        \App\User::truncate();
        \Simoja\Laramin\Models\Role::truncate();
        \Simoja\Laramin\Models\Permission::truncate();
        DB::statement('SET FOREIGN_KEY_CHECKS = 1');
    }

Instruction: Given a code description, retrieve the corresponding code.