예제 #1
0
  // --------------------------------------------------------------------------
  public DataPoint setMetricRef(Metric table) {
    // We add the record to the transaction if one of the key values change
    if (m_metricId.setValue(table.getId())) {
      if ((m_dirtyFlags.isEmpty()) && (GenOrmDataSource.getGenOrmConnection() != null))
        GenOrmDataSource.getGenOrmConnection().addToTransaction(this);

      m_dirtyFlags.set(METRIC_ID_FIELD_META.getDirtyFlag());
    }

    return ((DataPoint) this);
  }
예제 #2
0
  public DataPoint setDoubleValueNull() {
    boolean changed = m_doubleValue.setNull();

    if (changed) {
      if (m_dirtyFlags.isEmpty()) GenOrmDataSource.getGenOrmConnection().addToTransaction(this);

      m_dirtyFlags.set(DOUBLE_VALUE_FIELD_META.getDirtyFlag());
    }

    return ((DataPoint) this);
  }
예제 #3
0
  public DataPoint setTimestampNull() {
    boolean changed = m_timestamp.setNull();

    if (changed) {
      if (m_dirtyFlags.isEmpty()) GenOrmDataSource.getGenOrmConnection().addToTransaction(this);

      m_dirtyFlags.set(TIMESTAMP_FIELD_META.getDirtyFlag());
    }

    return ((DataPoint) this);
  }
예제 #4
0
  public DataPoint setMetricIdNull() {
    boolean changed = m_metricId.setNull();

    if (changed) {
      if (m_dirtyFlags.isEmpty()) GenOrmDataSource.getGenOrmConnection().addToTransaction(this);

      m_dirtyFlags.set(METRIC_ID_FIELD_META.getDirtyFlag());
    }

    return ((DataPoint) this);
  }
예제 #5
0
  public DataPoint setDoubleValue(double data) {
    boolean changed = m_doubleValue.setValue(data);

    // Add the now dirty record to the transaction only if it is not previously dirty
    if (changed) {
      if (m_dirtyFlags.isEmpty()) GenOrmDataSource.getGenOrmConnection().addToTransaction(this);

      m_dirtyFlags.set(DOUBLE_VALUE_FIELD_META.getDirtyFlag());

      if (m_isNewRecord) // Force set the prev value
      m_doubleValue.setPrevValue(data);
    }

    return ((DataPoint) this);
  }
예제 #6
0
  public DataPoint setTimestamp(java.sql.Timestamp data) {
    boolean changed = m_timestamp.setValue(data);

    // Add the now dirty record to the transaction only if it is not previously dirty
    if (changed) {
      if (m_dirtyFlags.isEmpty()) GenOrmDataSource.getGenOrmConnection().addToTransaction(this);

      m_dirtyFlags.set(TIMESTAMP_FIELD_META.getDirtyFlag());

      if (m_isNewRecord) // Force set the prev value
      m_timestamp.setPrevValue(data);
    }

    return ((DataPoint) this);
  }