Example #1
0
  /**
   * Sets the value of <code>number</code>.
   *
   * <p>If the new value is the same as the old value, this method has no effect, i.e. if you
   * specify a new value, than {@see isNumberChanged()} will return true. If you specify the same
   * value as the old value isNumberChanged() will return the same as it did before calling <code>
   * setNumber(...)</code>.
   *
   * @throws IllegalArgumentException if the value is <code>null</code> (since <code>number</code>
   *     is not nullable)
   * @since Iteration2
   */
  public Room setNumber(String value) {
    if (manager.isNull(value)) {
      throw new java.lang.IllegalArgumentException("number is not nullable, null given");
    }

    if (de.fu.weave.orm.GenericRelationManager.compareValues(_number, value) == 0) return this;
    changed_number = true;
    _number = value;
    return this;
  }
Example #2
0
  /**
   * Sets the value of <code>required</code>.
   *
   * <p>If the new value is the same as the old value, this method has no effect, i.e. if you
   * specify a new value, than {@see isRequiredChanged()} will return true. If you specify the same
   * value as the old value isRequiredChanged() will return the same as it did before calling <code>
   * setRequired(...)</code>.
   *
   * @throws IllegalArgumentException if the value is <code>null</code> (since <code>required</code>
   *     is not nullable)
   * @since Iteration2
   */
  public CourseElement setRequired(boolean value) {
    if (manager.isNull(value)) {
      throw new java.lang.IllegalArgumentException("required is not nullable, null given");
    }

    if (de.fu.weave.orm.GenericRelationManager.compareValues(_required, value) == 0) return this;
    changed_required = true;
    _required = value;
    return this;
  }
Example #3
0
  /**
   * Sets the value of <code>duration</code>.
   *
   * <p>If the new value is the same as the old value, this method has no effect, i.e. if you
   * specify a new value, than {@see isDurationChanged()} will return true. If you specify the same
   * value as the old value isDurationChanged() will return the same as it did before calling <code>
   * setDuration(...)</code>.
   *
   * @throws IllegalArgumentException if the value is <code>null</code> (since <code>duration</code>
   *     is not nullable)
   * @since Iteration2
   */
  public CourseElement setDuration(int value) {
    if (manager.isNull(value)) {
      throw new java.lang.IllegalArgumentException("duration is not nullable, null given");
    }

    if (de.fu.weave.orm.GenericRelationManager.compareValues(_duration, value) == 0) return this;
    changed_duration = true;
    _duration = value;
    return this;
  }
Example #4
0
  /**
   * Sets the value of <code>name</code>. You may specify null as value.
   *
   * <p>If the new value is the same as the old value, this method has no effect, i.e. if you
   * specify a new value, than {@see isNameChanged()} will return true. If you specify the same
   * value as the old value isNameChanged() will return the same as it did before calling <code>
   * setName(...)</code>.
   *
   * @since Iteration2
   */
  public Room setName(String value) {

    if (value == null) {
      clearName();
      return this;
    }
    if (de.fu.weave.orm.GenericRelationManager.compareValues(_name, value) == 0) return this;
    changed_name = true;
    _name = value;
    return this;
  }
Example #5
0
 public int compareTo(CourseElement entity) {
   if (!exists) {
     if (this == entity) return 0;
     if (this.hashCode() <= entity.hashCode()) return -7;
     return 7;
   }
   if (entity == null) return -4711;
   if (equals(entity)) {
     return 0;
   }
   return de.fu.weave.orm.GenericRelationManager.compareValues(id(), entity.id());
 }
Example #6
0
  /**
   * Sets the value of <code>building</code>.
   *
   * <p>If the new value is the same as the old value, this method has no effect, i.e. if you
   * specify a new value, than {@see isBuildingChanged()} will return true. If you specify the same
   * value as the old value isBuildingChanged() will return the same as it did before calling <code>
   * setBuilding(...)</code>.
   *
   * @throws IllegalArgumentException if the value is <code>null</code> (since <code>building</code>
   *     is not nullable)
   * @since Iteration2
   */
  public Room setBuilding(Building value) {
    if (manager.isNull(value)) {
      throw new java.lang.IllegalArgumentException("building is not nullable, null given");
    }

    if (de.fu.weave.orm.GenericRelationManager.compareValues(ref_building, value._id) == 0)
      return this;
    changed_building = true;
    ref_building = value._id;
    fetched_building = true;
    _building = value;
    return this;
  }
Example #7
0
  /**
   * Sets the value of <code>type</code>. You may specify null as value.
   *
   * <p>If the new value is the same as the old value, this method has no effect, i.e. if you
   * specify a new value, than {@see isTypeChanged()} will return true. If you specify the same
   * value as the old value isTypeChanged() will return the same as it did before calling <code>
   * setType(...)</code>.
   *
   * @since Iteration2
   */
  public CourseElement setType(CourseElementType value) {

    if (value == null) {
      clearType();
      return this;
    }
    if (de.fu.weave.orm.GenericRelationManager.compareValues(ref_type, value._id) == 0) return this;
    changed_type = true;
    ref_type = value._id;
    fetched_type = true;
    _type = value;
    return this;
  }
Example #8
0
  /**
   * Sets the value of <code>partOf</code>.
   *
   * <p>If the new value is the same as the old value, this method has no effect, i.e. if you
   * specify a new value, than {@see isPartOfChanged()} will return true. If you specify the same
   * value as the old value isPartOfChanged() will return the same as it did before calling <code>
   * setPartOf(...)</code>.
   *
   * @throws IllegalArgumentException if the value is <code>null</code> (since <code>partOf</code>
   *     is not nullable)
   * @since Iteration2
   */
  public CourseElement setPartOf(Course value) {
    if (manager.isNull(value)) {
      throw new java.lang.IllegalArgumentException("partOf is not nullable, null given");
    }

    if (de.fu.weave.orm.GenericRelationManager.compareValues(ref_partOf, value._id) == 0)
      return this;
    changed_partOf = true;
    ref_partOf = value._id;
    fetched_partOf = true;
    _partOf = value;
    return this;
  }
Example #9
0
 public boolean isValidTimekey(java.sql.Timestamp key) {
   return de.fu.weave.orm.GenericRelationManager.compareValues(_timekey, key) == 0;
 }