Initializes component with grid.

@param Grid $grid
@return null
358556
public function initialize(Grid $grid)
    {
        $this->grid = $grid;
        if (method_exists($this, 'initializeComponents')) {
            $this->initializeComponents($grid);
        }
    }
866632
private void init() {
        if (provider != null) {
            propertyGrid.setTarget(StringUtils.isEmpty(groupId) ? null : new Settings(groupId, provider));
        }
    }
115715
private function initialise()
    {
        for ($i = 0; $i < $this->size; $i++) {
            for ($j = 0; $j < $this->size; $j++) {
                $this->grid[$i][$j] = null;
            }

            $this->rowsAvailable[] = $i;
            $this->columnsAvailable[] = $i;
        }
    }
990006
def initialize(self, grid, num_of_paths, seed):
        
        for p in self.producers:
            p.initialize(grid, num_of_paths, seed)
        self.grid = grid
        self.num_of_paths = num_of_paths
        self.seed = seed
792708
private static function init()
    {
        if (!self::$data_initialized) {
            self::$data_initialized = true;

            $page_components_collection = new PageComponentEntityRepository();
            $page_components_collection->setWherePageId(PAGE_ID);
            $page_components_collection->addWhereFieldIsLike('component', 'select_plugin');
            if (Settings::isCacheEnabled()) {
                $page_components_collection->enableUsingCache();
            }

            self::$data = $page_components_collection->getPairs('data', 'component');
        }
    }
157604
public void init(BaseField field, GridScreenParent gridScreen, Record recGrid, boolean bCreateSortOrder)
    {
        m_recGrid = recGrid;
        m_bCreateSortOrder = bCreateSortOrder;
        super.init(field, gridScreen, null);
        m_iKeyAreaArray = new String[MAX_ARRAY_SIZE];
        for (int i = 0; i < MAX_ARRAY_SIZE; i++)
            m_iKeyAreaArray[i] = null;
        m_iNextArrayIndex = 0;
    }
439578
private void initialize() {
        GridBagConstraints gridBagConstraints2 = new GridBagConstraints();

        java.awt.GridBagConstraints gridBagConstraints1 = new GridBagConstraints();

        java.awt.GridBagConstraints gridBagConstraints11 = new GridBagConstraints();

        this.setLayout(new GridBagLayout());
	    if (Model.getSingleton().getOptionsParam().getViewParam().getWmUiHandlingOption() == 0) {
	    	this.setSize(375, 204);
	    }
	    this.setPreferredSize(new Dimension(375, 204));
        this.setName("categoryPanel");
        gridBagConstraints11.weightx = 1.0;
        gridBagConstraints11.weighty = 1.0;
        gridBagConstraints11.fill = java.awt.GridBagConstraints.BOTH;
        gridBagConstraints11.gridx = 0;
        gridBagConstraints11.gridy = 2;
        gridBagConstraints11.insets = new java.awt.Insets(0,0,0,0);
        gridBagConstraints11.anchor = java.awt.GridBagConstraints.NORTHWEST;
        gridBagConstraints11.gridwidth = 2;
        gridBagConstraints1.anchor = java.awt.GridBagConstraints.NORTHWEST;
        gridBagConstraints1.gridx = 0;
        gridBagConstraints1.gridy = 1;
        gridBagConstraints1.insets = new java.awt.Insets(2,2,2,2);
        gridBagConstraints2.gridx = 1;
        gridBagConstraints2.insets = new java.awt.Insets(2,2,2,2);
        gridBagConstraints2.gridy = 1;
        gridBagConstraints2.anchor = java.awt.GridBagConstraints.NORTHWEST;
        
        this.add(new JLabel(Constant.messages.getString("filter.warning")), LayoutHelper.getGBC(0, 0, 2, 1.0));
        this.add(getBtnEnableAll(), gridBagConstraints1);
        this.add(getBtnDisableAll(), gridBagConstraints2);
        this.add(getJScrollPane(), gridBagConstraints11);
		
	}
315316
function initGridCompColumn() {
    var oThis = this;
    this.initGridCompColumnVar();
    if (this.options.columns) {
        $.each(this.options.columns, function (i) {
            oThis.initGridCompColumnFun(this);
        });
    }
    this.initGridCompColumnLoacl();
    this.initGridHiddenLevelColumn();
    this.initGridCompFixedColumn();
    this.columnsVisibleFun();
}
732385
public function adapt(Grid &$grid)
    {
        $this->grid   = $grid;
        $customfields = app('customfields')->get();
        if (empty($customfields)) {
            return;
        }
        foreach ($customfields as $classname => $customfield) {

            if (is_array($grid->row)) {
                continue;
            }
            if (get_class($grid->row) !== $classname) {
                continue;
            }
            if (!is_array($customfield)) {
                $customfield = [$customfield];
            }

            foreach ($customfield as $instance) {
                if (!is_object($instance)) {
                    continue;
                }

                $this->addToForm($instance);
            }
        }



        if (extension_active('customfields')) {
            $map   = config('antares/customfields::map', []);
            $types = [];
            foreach ($map as $type => $classnames) {
                foreach ($classnames as $classname) {

                    if (is_array($this->grid->row)) {
                        continue;
                    }
                    if (get_class($this->grid->row) !== $classname) {
                        continue;
                    }
                    array_push($types, $type);
                }
            }
            if (!empty($types)) {
                $this->getFields($types);
            }
        }
    }
565906
private void initGridLabels() {
        int dim = base.getDimension();
        double[] offset = new double[dim];
        for (int j = 0; j < dim; j++) {
            if (j != index) {
                offset[j] = -(base.getUpperBounds()[j] - base.getLowerBounds()[j]) / 100;
            }
        }

        int decimal = 0;
        String label;

        gridLabels = new Label[labelsSlicing.length];

        for (int i = 0; i < gridLabels.length; i++) {

            double[] labelCoord = new double[base.getDimension()];
            System.arraycopy(base.getCoordinateSpace()[index + 1], 0, labelCoord, 0, base.getDimension());
            labelCoord[index] = labelsSlicing[i];

            if (dim == 3) {
                if (index == 0) {
                    labelCoord[2] = base.getUpperBounds()[2] - 2 * offset[2];
                } else if (index == 1) {
                    labelCoord[0] = base.getUpperBounds()[0] - 2 * offset[0];
                } else if (index == 2) {
                    labelCoord[1] = base.getUpperBounds()[1] - 2 * offset[1];
                }
            }

            decimal = base.getPrecisionDigits()[index];

            if (gridLabelStrings != null) {
                label = gridLabelStrings[i % gridLabelStrings.length];
            } else {
                String format = "%.0f";
                if (decimal < 0) {
                    format = String.format("%%.%df", -decimal);
                }
                label = String.format(format, labelsSlicing[i]);
            }

            for (int j = 0; j < dim; j++) {
                labelCoord[j] += offset[j];
            }

            if (base.getDimension() == 2) {
                if (index == 0) {
                    if (rotation == 0.0) {
                        gridLabels[i] = new Label(label, 0.5, 1.0, labelCoord);
                    } else {
                        gridLabels[i] = new Label(label, 1.0, 0.5, rotation, labelCoord);
                    }
                } else {
                    gridLabels[i] = new Label(label, 1.0, 0.5, labelCoord);
                }
            } else {
                if (index == 0) {
                    gridLabels[i] = new Label(label, 0.5, -0.5, labelCoord);
                } else if (index == 1) {
                    gridLabels[i] = new Label(label, 0.5, 1.0, labelCoord);
                } else if (index == 2) {
                    gridLabels[i] = new Label(label, 0.0, 0.5, labelCoord);
                }
            }

            gridLabels[i].setFont(gridLabelFont);
        }

        gridLabelStrings = null;
    }
1257763
protected function initColumns()
    {
        parent::initColumns();
        if ($this->responsiveTable) {
            $this->attachBehavior('ywresponsive', array('class' => 'yiiwheels.widgets.grid.behaviors.WhResponsive'));
            $this->writeResponsiveCss($this->columns, $this->id);
        }
    }
381045
function init(grid) {
      options = $.extend(true, {}, _defaults, options);
      _grid = grid;
      if (options.enableForCells) _grid.onMouseEnter.subscribe(handleMouseEnter);
      if (options.enableForHeaderCells) _grid.onHeaderMouseEnter.subscribe(handleHeaderMouseEnter);
    }
363497
def initialize(self, grid, num_of_paths, seed):
        
        self.grid = grid
        self.num_of_paths = num_of_paths
        self.seed = seed
        if self.initial_state.date is None:
            self.initial_state.date = grid[0]
103468
public function handle(GridContract $grid)
    {
        $runtime = Memory::make('runtime')->get('control');
        if (is_null($runtime)) {
            return false;
        }
        $name      = array_get($runtime, 'component');
        $fieldsets = $grid->fieldsets;
        $controls  = [];
        $formName  = null;
        foreach ($fieldsets as $fieldset) {
            $formName = is_null($formName) ? $fieldset->name : $formName;
            foreach ($fieldset->controls as $control) {
                if($control instanceof AbstractType) {
                    continue;
                }
                $controls[] = $this->attributes($control);
            }
        }
        $action = Action::select(['id', 'component_id', 'name'])->where('name', array_get($runtime, 'action'))->whereHas('extension', function($query) use($name) {
                    $query->where('name', $name);
                })->first();
        $configuration = array_merge(['cid' => $action->component_id, 'aid' => $action->id, 'name' => $formName, 'component' => $name, 'controls' => $controls], array_only($runtime, ['controller', 'action', 'method', 'namespace']));
        if (!is_string($formName)) {
            return;
        }
        $key = implode('::', [$name, array_get($runtime, 'action'), array_get($runtime, 'method'), str_slug($formName)]);
        $this->memory->push($key, $configuration);
        $this->memory->finish();
    }
795954
private void initComponents() {// GEN-BEGIN:initComponents
        java.awt.GridBagConstraints gridBagConstraints;

        aboutTabPane = new javax.swing.JTabbedPane();
        aboutScrollPane = new javax.swing.JScrollPane();
        aboutEditorPane = new javax.swing.JEditorPane();
        licenseScrollPane = new javax.swing.JScrollPane();
        licenseEditorPane = new javax.swing.JEditorPane();
        acknowledgmentsScrollPane = new javax.swing.JScrollPane();
        acknowldgementsEditorPane = new javax.swing.JEditorPane();
        jSeparator1 = new javax.swing.JSeparator();
        okButton = new javax.swing.JButton();

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

        addWindowListener(new java.awt.event.WindowAdapter() {
            @Override
            public void windowClosing(java.awt.event.WindowEvent evt) {
                closeDialog(evt);
            }
        });

        aboutEditorPane.setEditable(false);
        aboutEditorPane.addHyperlinkListener(evt -> editorPaneHyperlinkUpdate(evt));

        aboutScrollPane.setViewportView(aboutEditorPane);

        aboutTabPane.addTab("About", aboutScrollPane);

        licenseEditorPane.setEditable(false);
        licenseEditorPane.addHyperlinkListener(evt -> editorPaneHyperlinkUpdate(evt));

        licenseScrollPane.setViewportView(licenseEditorPane);

        aboutTabPane.addTab("License", licenseScrollPane);

        acknowldgementsEditorPane.setEditable(false);
        acknowldgementsEditorPane.addHyperlinkListener(evt -> editorPaneHyperlinkUpdate(evt));

        acknowledgmentsScrollPane.setViewportView(acknowldgementsEditorPane);

        aboutTabPane.addTab("Acknowledgments", acknowledgmentsScrollPane);

        gridBagConstraints = new java.awt.GridBagConstraints();
        gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;
        gridBagConstraints.weightx = 1.0;
        gridBagConstraints.weighty = 1.0;
        getContentPane().add(aboutTabPane, gridBagConstraints);

        {
            aboutTabPane.setTitleAt(0, edu.umd.cs.findbugs.L10N.getLocalString("dlg.about_tab", "About"));
            aboutTabPane.setTitleAt(1, edu.umd.cs.findbugs.L10N.getLocalString("dlg.license_tab", "License"));
            aboutTabPane.setTitleAt(2, edu.umd.cs.findbugs.L10N.getLocalString("dlg.acknowledgements_tab", "Acknowledgements"));
        }
        gridBagConstraints = new java.awt.GridBagConstraints();
        gridBagConstraints.gridx = 0;
        gridBagConstraints.gridy = 1;
        gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
        getContentPane().add(jSeparator1, gridBagConstraints);

        okButton.setMnemonic('O');
        okButton.setText(edu.umd.cs.findbugs.L10N.getLocalString("dlg.ok_btn", "OK"));
        okButton.addActionListener(evt -> okButtonActionPerformed(evt));

        gridBagConstraints = new java.awt.GridBagConstraints();
        gridBagConstraints.gridx = 0;
        gridBagConstraints.gridy = 2;
        gridBagConstraints.insets = new java.awt.Insets(3, 0, 3, 0);
        getContentPane().add(okButton, gridBagConstraints);

        pack();
    }
939371
public function createGrid($gridClassName)
    {
        $gridClass = new \ReflectionClass($gridClassName);

        /* @var \PedroTeixeira\Bundle\GridBundle\Grid\GridAbstract $grid */
        $grid = $gridClass->newInstance($this->container);
        $grid->setupGrid();

        return $grid;
    }
850979
@Override
    protected void init(Object target, PropertyInfo propInfo, PropertyGrid propGrid) {
        super.init(target, propInfo, propGrid);

        Iterable<?> iter = (Iterable<?>) propInfo.getPropertyType().getSerializer();

        for (Object value : iter) {
            appendItem(value.toString(), value);
        }

    }