001/* ----------------------------------------------------------------------------
002 * This file was automatically generated by SWIG (https://www.swig.org).
003 * Version 4.1.1
004 *
005 * Do not make changes to this file unless you know what you are doing - modify
006 * the SWIG interface file instead.
007 * ----------------------------------------------------------------------------- */
008
009package org.quantlib;
010
011public final class Weekday {
012  public final static Weekday Sunday = new Weekday("Sunday", 1);
013  public final static Weekday Monday = new Weekday("Monday", 2);
014  public final static Weekday Tuesday = new Weekday("Tuesday", 3);
015  public final static Weekday Wednesday = new Weekday("Wednesday", 4);
016  public final static Weekday Thursday = new Weekday("Thursday", 5);
017  public final static Weekday Friday = new Weekday("Friday", 6);
018  public final static Weekday Saturday = new Weekday("Saturday", 7);
019
020  public final int swigValue() {
021    return swigValue;
022  }
023
024  public String toString() {
025    return swigName;
026  }
027
028  public static Weekday swigToEnum(int swigValue) {
029    if (swigValue < swigValues.length && swigValue >= 0 && swigValues[swigValue].swigValue == swigValue)
030      return swigValues[swigValue];
031    for (int i = 0; i < swigValues.length; i++)
032      if (swigValues[i].swigValue == swigValue)
033        return swigValues[i];
034    throw new IllegalArgumentException("No enum " + Weekday.class + " with value " + swigValue);
035  }
036
037  private Weekday(String swigName) {
038    this.swigName = swigName;
039    this.swigValue = swigNext++;
040  }
041
042  private Weekday(String swigName, int swigValue) {
043    this.swigName = swigName;
044    this.swigValue = swigValue;
045    swigNext = swigValue+1;
046  }
047
048  private Weekday(String swigName, Weekday swigEnum) {
049    this.swigName = swigName;
050    this.swigValue = swigEnum.swigValue;
051    swigNext = this.swigValue+1;
052  }
053
054  private static Weekday[] swigValues = { Sunday, Monday, Tuesday, Wednesday, Thursday, Friday, Saturday };
055  private static int swigNext = 0;
056  private final int swigValue;
057  private final String swigName;
058}
059