Initializes the corresponding attribute of the hsp
 with respect to the column name of the tabular blast output
 Params:
 +column+: String with column name.
 +value+: Value of the column
765859
def init_tabular_attribute(hash)
      @match_query_from    = hash['qstart'].to_i if hash['qstart']
      @match_query_to      = hash['qend'].to_i if hash['qend']
      @query_reading_frame = hash['qframe'].to_i if hash['qframe']
      @hit_from            = hash['sstart'].to_i if hash['sstart']
      @hit_to              = hash['send'].to_i if hash['send']
      @query_alignment     = hash['qseq'] if hash['qseq']
      @hit_alignment       = hash['sseq'] if hash['sseq']
      @align_len           = hash['length'].to_i if hash['length']
      @pidentity           = hash['pident'].to_f if hash['pident']
      @identity            = hash['nident'].to_f if hash['nident']
      @hsp_evalue          = hash['evalue'].to_f if hash['evalue']
      assert_seq_type(@query_alignment) if hash['sseq']
      assert_seq_type(@hit_alignment) if hash['sseq']
    end
1112381
private void initNewListBasic() {
    newAdvancedValueSumList = operations.createVector1(newSize);
    newAdvancedValueSumOfLogsList = operations.createVector2(newSize);
    newAdvancedValueSumOfSquaresList = operations.createVector1(newSize);
    newAdvancedValueMinList = operations.createVector1(newSize);
    newAdvancedValueMaxList = operations.createVector1(newSize);
    newAdvancedValueNList = new long[newSize];
  }
1108209
public void newCell(final int row,
            final int column,
            final String value,
            final int mergedColStart) {
        if ( emptyCellValue( value ) ) {
            return;
        }
        final Integer rowInt = new Integer( row );
        if ( this._rowProperties.containsKey( rowInt ) ) {
            final String[] keyValue = (String[]) this._rowProperties.get( rowInt );
            if ( PropertiesSheetListener.EMPTY_STRING.equals( keyValue[1] ) ) {
                keyValue[1] = value;
                keyValue[2] = RuleSheetParserUtil.rc2name(row, column);
            }
        } else {
            final String trimmedValue = value.trim();
            final String[] keyValue = {trimmedValue, PropertiesSheetListener.EMPTY_STRING, RuleSheetParserUtil.rc2name(row, column+1) };
            this._rowProperties.put( rowInt, keyValue );
        }
    }
199518
@Override
    public void setValueAt(Object value, int row, int column) {
        switch (column) {
        case 0:
            String expr = value.toString();
            expressions.set(row, expr);
            String result = "";
            if (expr.length() > 0) {
                result = debugGui.dim.eval(expr);
                if (result == null) result = "";
            }
            values.set(row, result);
            updateModel();
            if (row + 1 == expressions.size()) {
                expressions.add("");
                values.add("");
                fireTableRowsInserted(row + 1, row + 1);
            }
            break;
        case 1:
            // just reset column 2; ignore edits
            fireTableDataChanged();
        }
    }
1348723
def add_column(self, name, *, index=0, values=None):
        
        if name is None:
            return None

        params = {
            'name': name,
            'index': index
        }
        if values is not None:
            params['values'] = values

        url = self.build_url(self._endpoints.get('add_column'))
        response = self.session.post(url, data=params)
        if not response:
            return None

        data = response.json()

        return self.column_constructor(parent=self, **{self._cloud_data_key: data})
977035
def init_daru_vector(data, options)
      options[:using] ||= get_daru_columns(data, 2)
      options[:title] ||= data.name
      init_default(data, options)
    end
1214679
def AddRow(self, values):
    
    if self._number_of_columns and len(values) != self._number_of_columns:
      raise ValueError('Number of values is out of bounds.')

    if not self._column_sizes and self._columns:
      self._column_sizes = [len(column) for column in self._columns]

    value_strings = []
    for value_index, value_string in enumerate(values):
      if not isinstance(value_string, py2to3.UNICODE_TYPE):
        value_string = '{0!s}'.format(value_string)
      value_strings.append(value_string)

      self._column_sizes[value_index] = max(
          self._column_sizes[value_index], len(value_string))

    self._rows.append(value_strings)

    if not self._number_of_columns:
      self._number_of_columns = len(value_strings)
20261
def bind_inum(column, enum_class, options = {})
      options = { prefix: column }.merge(options)
      options[:prefix] = options[:prefix] ? "#{options[:prefix]}_" : ''

      self.class_eval do
        define_method(column) do
          enum_class.parse(read_attribute(column))
        end

        define_method("#{column}=") do |value|
          enum_class.parse(value).tap do |enum|
            if enum
              write_attribute(column, enum.to_i)
            else
              write_attribute(column, nil)
            end
          end
        end

        enum_class.each do |enum|
          define_method("#{options[:prefix]}#{enum.to_s.underscore}?") do
            enum.eql?(read_attribute(column))
          end
        end
      end
    end
555767
protected function initColumns()
    {
        foreach ($this->columns as $i => $column) {
            if (is_array($column) && !isset($column['class'])) {
                $this->columns[$i]['class'] = '\TbDataColumn';
            }
        }
        parent::initColumns();
    }
468949
def initializeColumns(self):
        
        tableType = self.tableType()
        if not tableType:
            return
        elif self._columnsInitialized or self.columnOf(0) != '1':
            self.assignOrderNames()
            return
        
        # set the table header information
        tschema = tableType.schema()
        columns = tschema.columns()
        
        names = [col.displayName() for col in columns if not col.isPrivate()]
        self.setColumns(sorted(names))
        self.assignOrderNames()
        self.resizeToContents()
1221907
public void setValueAt(Object value, int row, int col) {
        if (log.isLoggable(Level.FINE)) {
            log.fine(
                "Setting value at " + row + "," + col + " to " + value + " (an instance of " + value.getClass() + ")");
        }

        if (data[0][col] instanceof Integer && !(value instanceof Integer)) {
            //With JFC/Swing 1.1 and JDK 1.2, we need to create    
            //an Integer from the value; otherwise, the column     
            //switches to contain Strings.  Starting with v 1.3,   
            //the table automatically converts value to an Integer,
            //so you only need the code in the 'else' part of this 
            //'if' block.                                          
            //XXX: See TableEditDemo.java for a better solution!!!
            try {
                data[row][col] = Integer.valueOf(value.toString());
                fireTableCellUpdated(row, col);
            }
            catch (NumberFormatException e) {
                log.log(Level.SEVERE, "The \"" + getColumnName(col) + "\" column accepts only integer values.");
            }
        }
        else {
            data[row][col] = value;
            fireTableCellUpdated(row, col);
        }
    }
878276
def build(self, columns):
        
        self.columns = columns
        default = dict(elements.default("default_"),
                       **_safe_get(self.init_style, "default_", {}))
        self.style = elements.adopt({c: default for c in columns},
                                    self.init_style)

        # Store special keys in _style so that they can be validated.
        self.style["default_"] = default
        self.style["header_"] = self._compose("header_", {"align", "width"})
        self.style["aggregate_"] = self._compose("aggregate_",
                                                 {"align", "width"})
        self.style["separator_"] = _safe_get(self.init_style, "separator_",
                                             elements.default("separator_"))
        lgr.debug("Validating style %r", self.style)
        self.style["width_"] = _safe_get(self.init_style, "width_",
                                         elements.default("width_"))
        elements.validate(self.style)
        self._setup_fields()

        ngaps = len(self.columns) - 1
        self.width_separtor = len(self.style["separator_"]) * ngaps
        lgr.debug("Calculated separator width as %d", self.width_separtor)
1251904
def column_label(col_or_sym)
      col_name =
          case col_or_sym
          when String, Symbol
            col_or_sym
          else
            col_or_sym.name
          end
      @controller_model ||= controller.send(:model)
      I18n.t(col_name,
          scope:    "view.#{controller_path}.#{@controller_model.name.underscore}",
          default:  @controller_model.human_attribute_name(col_name))
    end
408433
private static void addValue(CBuilder builder, ColumnDefinition def, ByteBuffer value) throws InvalidRequestException
    {
        if (value == null)
            throw new InvalidRequestException(String.format("Invalid null value in condition for column %s", def.name));
        builder.add(value);
    }
1024291
def add_column(name, column_properties = {})
      validate_column_absence(name)
      create_column_properties(name, column_properties)
      @data_rows.each{|x|
        x << (yield Row.new(@column_indexes, x))
      }
      @column_indexes[name] = @column_indexes.size
      self # enable chaining
    end
1158541
def putcolslice(self, columnname, value, blc, trc, inc=[],
                    startrow=0, nrow=-1, rowincr=1):
        
        self._putcolslice(columnname, value, blc, trc, inc,
                          startrow, nrow, rowincr)
744733
function setColumnValue($column_name, $value, $column_type = null) {
		if (null === $column_type) {
			$column_type = static::getColumnType($column_name);
		}

		static $true = array(true, 1, '1', 'on', 'true');
		static $false = array(false, 0, '0', 'off', 'false');

		if ($column_type === self::COLUMN_TYPE_BOOLEAN) {
			if (is_string($value)) {
				$value = strtolower($value);
			}
			if (in_array($value, $true, true)) {
				$value = 1;
			} elseif (in_array($value, $false, true)) {
				$value = 0;
			} elseif ($value === '' || $value === null) {
				$value = null;
			} else {
				throw new InvalidArgumentException($value . ' is not a valid boolean value');
			}
		} else {
			$temporal = static::isTemporalType($column_type);
			$numeric = static::isNumericType($column_type);

			if ($numeric || $temporal) {
				if (is_string($value)) {
					$value = trim($value);
				}
				if ('' === $value) {
					$value = null;
				} elseif (null !== $value) {
					if ($temporal) {
						$value = static::coerceTemporalValue($value, $column_type, static::getConnection());
					} elseif ($numeric) {
						if (is_bool($value)) {
							$value = $value ? 1 : 0;
						} elseif (static::isIntegerType($column_type)) {
							// validate and cast
							if (!is_int($value)) {
								$int_val = intval($value);
								if ((string) $int_val != (string) $value) {
									throw new InvalidArgumentException($value . ' is not a valid integer or it is too large');
								}
								$value = $int_val;
							}
						} else {
							// only validates, doesn't cast...yet
							$float_val = floatval($value);
							if ((string) $float_val != (string) $value) {
								throw new InvalidArgumentException($value . ' is not a valid float or it is too large');
							}
						}
					}
				}
			}
		}

		if ($this->$column_name !== $value) {
			$this->_modifiedColumns[$column_name] = $column_name;
			$this->$column_name = $value;
		}
		return $this;
	}