All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.squarespace.cldrengine.api.DateRawFormatOptions Maven / Gradle / Ivy

The newest version!
package com.squarespace.cldrengine.api;

import lombok.Generated;
import lombok.EqualsAndHashCode;

@Generated
@EqualsAndHashCode
public class DateRawFormatOptions {

  public final Option pattern = Option.option();
  public final Option calendar = Option.option();
  public final Option numberSystem = Option.option();
  public final Option context = Option.option();
  public final Option alt = Option.option();

  public DateRawFormatOptions() {
  }

  public DateRawFormatOptions(DateRawFormatOptions arg) {
    this.pattern.set(arg.pattern);
    this.calendar.set(arg.calendar);
    this.numberSystem.set(arg.numberSystem);
    this.context.set(arg.context);
    this.alt.set(arg.alt);
  }

  public DateRawFormatOptions pattern(String arg) {
    this.pattern.set(arg);
    return this;
  }

  public DateRawFormatOptions pattern(Option arg) {
    this.pattern.set(arg);
    return this;
  }

  public DateRawFormatOptions calendar(CalendarType arg) {
    this.calendar.set(arg);
    return this;
  }

  public DateRawFormatOptions calendar(Option arg) {
    this.calendar.set(arg);
    return this;
  }

  public DateRawFormatOptions numberSystem(String arg) {
    this.numberSystem.set(arg);
    return this;
  }

  public DateRawFormatOptions numberSystem(Option arg) {
    this.numberSystem.set(arg);
    return this;
  }

  public DateRawFormatOptions context(ContextType arg) {
    this.context.set(arg);
    return this;
  }

  public DateRawFormatOptions context(Option arg) {
    this.context.set(arg);
    return this;
  }

  public DateRawFormatOptions alt(DateFormatAltOptions arg) {
    this.alt.set(arg);
    return this;
  }

  public DateRawFormatOptions alt(Option arg) {
    this.alt.set(arg);
    return this;
  }

  public static DateRawFormatOptions build() {
    return new DateRawFormatOptions();
  }

  public DateRawFormatOptions copy() {
    return new DateRawFormatOptions(this);
  }

  public DateRawFormatOptions mergeIf(DateRawFormatOptions ...args) {
    DateRawFormatOptions o = new DateRawFormatOptions(this);
    for (DateRawFormatOptions arg : args) {
      o._mergeIf(arg);
    }
    return o;
  }

  protected void _mergeIf(DateRawFormatOptions o) {
    this.pattern.setIf(o.pattern);
    this.calendar.setIf(o.calendar);
    this.numberSystem.setIf(o.numberSystem);
    this.context.setIf(o.context);
    this.alt.setIf(o.alt);
  }

  public DateRawFormatOptions merge(DateRawFormatOptions ...args) {
    DateRawFormatOptions o = new DateRawFormatOptions(this);
    for (DateRawFormatOptions arg : args) {
      o._merge(arg);
    }
    return o;
  }

  protected void _merge(DateRawFormatOptions o) {
    this.pattern.set(o.pattern);
    this.calendar.set(o.calendar);
    this.numberSystem.set(o.numberSystem);
    this.context.set(o.context);
    this.alt.set(o.alt);
  }


  @Override
  public String toString() {
    StringBuilder buf = new StringBuilder("DateRawFormatOptions( ");
    this._tostring(buf);
    return buf.append(')').toString();
  }

  protected void _tostring(StringBuilder buf) {
    if (pattern.ok()) {
      buf.append("pattern=").append(pattern).append(' ');
    }
    if (calendar.ok()) {
      buf.append("calendar=").append(calendar).append(' ');
    }
    if (numberSystem.ok()) {
      buf.append("numberSystem=").append(numberSystem).append(' ');
    }
    if (context.ok()) {
      buf.append("context=").append(context).append(' ');
    }
    if (alt.ok()) {
      buf.append("alt=").append(alt).append(' ');
    }
  }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy