public static IntegerWrapper month(Stella_Object thing) {
    { Surrogate testValue000 = Stella_Object.safePrimaryType(thing);

      if (Surrogate.subtypeOfStringP(testValue000)) {
        { StringWrapper thing000 = ((StringWrapper)(thing));

          { int monthNumber = ((StringToIntegerHashTable)(Stella.$MONTH_STRINGS$.get())).lookup(thing000.wrapperValue);

            if (monthNumber != Stella.NULL_INTEGER) {
              return (IntegerWrapper.wrapInteger(monthNumber));
            }
            else {
              return (null);
            }
          }
        }
      }
      else if (Surrogate.subtypeOfIntegerP(testValue000)) {
        { IntegerWrapper thing000 = ((IntegerWrapper)(thing));

          if ((1 <= thing000.wrapperValue) &&
              (thing000.wrapperValue <= 12)) {
            return (thing000);
          }
          else {
            return (null);
          }
        }
      }
      else {
        return (null);
      }
    }
  }