/*
(non-Javadoc)

@see eu.hydrologis.jgrass.libs.map.RasterData#setValueAt(int)
321823
public void setValueAt( int index, double value ) {

        int row = index / data[0].length;
        int col = index % data[0].length;

        data[row][col] = value;
    }
632834
public synchronized void setValue(String name, String value) {
        if (map == null) {
            map = new HashMap<String,String>();
        }
        map.put(name, value);
    }
1293047
private static void setValue(Map<String,String> map, String key, String value) {
		map.put(key,value);
	}
798283
public void setValue(int index, int value) throws IOException {
        if (index >= structure.valueSizes.size()) {
            throw new IOException("Index " + index + " is out of range.");
        }
        Bytes.putInt(this.value, structure.valueByteOffsets.get(index), value);
    }
923096
public void setValue(float angle, float x, float y, float z) {
        set(angle, x, y, z);
    }
739064
@Override
    public void setValue(final double VALUE) {
        if (isEnabled()) {
            super.setValue(VALUE);

            this.stepValue = 2 * ((int) (Math.abs(VALUE) * 10) % 10);
            if (stepValue > 10) {
                stepValue -= 20;
            }

            if (VALUE == 0) {
                this.visibleValue = 90;
            }

            if (VALUE > 0 && VALUE <= 90) {
                this.visibleValue = (90 - VALUE % 360);
            }

            if (VALUE > 90 && VALUE <= 180) {
                this.visibleValue = (VALUE - 90);
            }

            if (VALUE > 180 && VALUE <= 270) {
                this.visibleValue = (270 - VALUE);
            }

            if (VALUE > 270 && VALUE <= 360) {
                this.visibleValue = (VALUE - 270);
            }

            if (VALUE < 0 && VALUE >= -90) {
                this.visibleValue = (90 - Math.abs(VALUE));
            }

            if (VALUE < -90 && VALUE >= -180) {
                this.visibleValue = Math.abs(VALUE) - 90;
            }

            if (VALUE < -180 && VALUE >= -270) {
                this.visibleValue = 270 - Math.abs(VALUE);
            }

            if (VALUE < -270 && VALUE >= -360) {
                this.visibleValue = Math.abs(VALUE) - 270;
            }

            fireStateChanged();
            repaint();
        }
    }
1263102
protected void setValue(int newPosition, T1 valueSum, long valueN,
      boolean currentExisting) {
    if (valueN > 0) {
      if (currentExisting) {
        newBasicValueSumList[newPosition] = operations
            .add11(newBasicValueSumList[newPosition], valueSum);
        newBasicValueNList[newPosition] += valueN;
      } else {
        newBasicValueSumList[newPosition] = valueSum;
        newBasicValueNList[newPosition] = valueN;
      }
    }
  }
193590
public void setValue(Object value) {
        setDataModel(null);
        getStateHelper().put(PropertyKeys.value, value);

    }
905644
@Nonnull
  public TypeaheadRemote setDataType (@Nonnull @Nonempty final String sDataType)
  {
    m_sDataType = ValueEnforcer.notEmpty (sDataType, "DataType");
    return this;
  }
1015418
public void setValue(Map<String, Tag> value) {
        this.value = new LinkedHashMap<String, Tag>(value);
    }
1363103
protected void setValue(int newPosition, T1[] values, int number,
      boolean currentExisting) {
    if (number > 0) {
      if (currentExisting) {
        T1[] tmpList = operations
            .createVector1(newFullValueList[newPosition].length + number);
        System.arraycopy(newFullValueList[newPosition], 0, tmpList, 0,
            newFullValueList[newPosition].length);
        System.arraycopy(values, 0, tmpList,
            newFullValueList[newPosition].length, number);
        newFullValueList[newPosition] = tmpList;
      } else {
        if (number < values.length) {
          T1[] tmpList = operations.createVector1(number);
          System.arraycopy(values, 0, tmpList, 0, number);
          newFullValueList[newPosition] = tmpList;
        } else {
          newFullValueList[newPosition] = values;
        }
      }
    }
  }
539255
public Object setObjectValue(StringToObjectConverter pConverter, Object pInner, String pAttribute, Object pValue)
            throws IllegalAccessException, InvocationTargetException {
        throw new IllegalArgumentException("TabularData cannot be written to");
    }
1199777
public void setValues(PreparedStatement pstmt) throws SQLException {
		int i = 1;
		for (Class<?> type : this.type) {
			this.setValues(pstmt, i, type);
			i++;
		}
	}
542458
public void setValue (int index, String value)
    {
    if (index >= 0 && index < length) {
        data[index*5+4] = value;
    } else {
        badIndex(index);
    }
    }
1362549
@Override
    public void setValue(Object value) throws WidgetException {
        try {
            if (value instanceof String) {
                Select select = new Select(getByLocator());
                select.selectOption((String) value);
            } else {
                throw new WidgetRuntimeException("value must be a String type", getByLocator());
            }
        } catch (Exception e) {
            throw new WidgetException("Error while seleting option on drop down", getByLocator(), e);
        }
    }
705952
public void setValue(String constantValue)
    {
        this.fieldSource = SOURCE_VALUE;
        this.fieldRefName = null;
        this.returnedByProcedure = false;
        this.constantValue = constantValue;
    }
389040
@Override
    public void setValue(Object value) throws WidgetException {
        boolean set = false;
        try {
            if (value instanceof String) {
                if (((String) value).equalsIgnoreCase(UNCHECK)) {
                    doAction(true);
                } else if (((String) value).equalsIgnoreCase(CHECK)) {
                    doAction(false);
                }

                set = true;
            } else {
                throw new WidgetRuntimeException(
                        "value must be a String of either 'check' or 'uncheck'", getByLocator());
            }
        } catch (Exception e) {
            throw new WidgetException("Error while checking/unchecking", getByLocator(), e);
        }

        if (!set)
            throw new WidgetException(
                    "Invalid set value for checkbox. It must be either 'check' or 'uncheck'",
                    getByLocator());
    }