io.qt.core.QCalendar Maven / Gradle / Ivy
package io.qt.core;
/**
* Describes calendar systems
* Java wrapper for Qt class QCalendar
*/
public class QCalendar extends io.qt.QtObject
implements java.lang.Cloneable
{
static {
QtJambi_LibraryUtilities.initialize();
}
/**
* This variable stores the meta-object for the class.
*/
public static final io.qt.core.QMetaObject staticMetaObject = io.qt.core.QMetaObject.forType(QCalendar.class);
/**
* Java wrapper for Qt enum QCalendar::System
*/
@io.qt.QtRejectedEntries({"Last"})
public enum System implements io.qt.QtEnumerator {
Gregorian(0),
Julian(8),
Milankovic(9),
Jalali(10),
IslamicCivil(11),
Last(11),
User(-1);
private System(int value) {
this.value = value;
}
/**
* {@inheritDoc}
*/
public int value() {
return value;
}
/**
* Returns the corresponding enum entry for the given value.
* @param value
* @return enum entry
*/
public static System resolve(int value) {
switch (value) {
case 0: return Gregorian;
case 8: return Julian;
case 9: return Milankovic;
case 10: return Jalali;
case 11: return IslamicCivil;
case -1: return User;
default: throw new io.qt.QNoSuchEnumValueException(value);
}
}
private final int value;
}
/**
* Java wrapper for Qt class QCalendar::YearMonthDay
*/
public static class YearMonthDay extends io.qt.QtObject
implements java.lang.Cloneable
{
static {
QtJambi_LibraryUtilities.initialize();
}
public YearMonthDay(){
super((QPrivateConstructor)null);
initialize_native(this);
}
private native static void initialize_native(YearMonthDay instance);
/**
* Overloaded constructor for {@link #YearMonthDay(int, int, int)}
* with d = 1
.
*/
public YearMonthDay(int y, int m) {
this(y, m, (int)1);
}
/**
* Overloaded constructor for {@link #YearMonthDay(int, int, int)}
* with:
* m = 1
* d = 1
*
*/
public YearMonthDay(int y) {
this(y, (int)1, (int)1);
}
public YearMonthDay(int y, int m, int d){
super((QPrivateConstructor)null);
initialize_native(this, y, m, d);
}
private native static void initialize_native(YearMonthDay instance, int y, int m, int d);
@io.qt.QtUninvokable
public final boolean isValid(){
return isValid_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@io.qt.QtUninvokable
private native boolean isValid_native_constfct(long __this__nativeId);
@io.qt.QtUninvokable
private final boolean operator_equal(io.qt.core.QCalendar.YearMonthDay value2){
return operator_equal_native_cref_QCalendar_YearMonthDay(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(value2));
}
@io.qt.QtUninvokable
private native boolean operator_equal_native_cref_QCalendar_YearMonthDay(long __this__nativeId, long value2);
@io.qt.QtUninvokable
public final void setDay(int day){
setDay_native_int(QtJambi_LibraryUtilities.internal.nativeId(this), day);
}
@io.qt.QtUninvokable
private native void setDay_native_int(long __this__nativeId, int day);
@io.qt.QtUninvokable
public final int day(){
return day_native(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@io.qt.QtUninvokable
private native int day_native(long __this__nativeId);
@io.qt.QtUninvokable
public final void setMonth(int month){
setMonth_native_int(QtJambi_LibraryUtilities.internal.nativeId(this), month);
}
@io.qt.QtUninvokable
private native void setMonth_native_int(long __this__nativeId, int month);
@io.qt.QtUninvokable
public final int month(){
return month_native(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@io.qt.QtUninvokable
private native int month_native(long __this__nativeId);
@io.qt.QtUninvokable
public final void setYear(int year){
setYear_native_int(QtJambi_LibraryUtilities.internal.nativeId(this), year);
}
@io.qt.QtUninvokable
private native void setYear_native_int(long __this__nativeId, int year);
@io.qt.QtUninvokable
public final int year(){
return year_native(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@io.qt.QtUninvokable
private native int year_native(long __this__nativeId);
/**
* Constructor for internal use only.
* @param p expected to be null
.
*/
@io.qt.NativeAccess
protected YearMonthDay(QPrivateConstructor p) { super(p); }
@Override
@io.qt.QtUninvokable
public boolean equals(Object other) {
if (other instanceof io.qt.core.QCalendar.YearMonthDay) {
return operator_equal((io.qt.core.QCalendar.YearMonthDay) other);
}
return false;
}
@io.qt.QtUninvokable
@Override
public int hashCode() {
return hashCode_native(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@io.qt.QtUninvokable
private native static int hashCode_native(long __this_nativeId);
@Override
public YearMonthDay clone() {
return clone_native(QtJambi_LibraryUtilities.internal.nativeId(this));
}
private native YearMonthDay clone_native(long __this_nativeId);
}
/**
*
*/
public QCalendar(){
super((QPrivateConstructor)null);
initialize_native(this);
}
private native static void initialize_native(QCalendar instance);
/**
* See QCalendar::QCalendar(QCalendar::System)
*/
public QCalendar(io.qt.core.QCalendar.System system){
super((QPrivateConstructor)null);
initialize_native(this, system);
}
private native static void initialize_native(QCalendar instance, io.qt.core.QCalendar.System system);
/**
* See QCalendar::QCalendar(QStringView)
*/
public QCalendar(java.lang.String name){
super((QPrivateConstructor)null);
initialize_native(this, name);
}
private native static void initialize_native(QCalendar instance, java.lang.String name);
/**
* See QCalendar::dateFromParts(QCalendar::YearMonthDay)const
*/
@io.qt.QtUninvokable
public final io.qt.core.QDate dateFromParts(io.qt.core.QCalendar.YearMonthDay parts){
return dateFromParts_native_cref_QCalendar_YearMonthDay_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(parts));
}
@io.qt.QtUninvokable
private native io.qt.core.QDate dateFromParts_native_cref_QCalendar_YearMonthDay_constfct(long __this__nativeId, long parts);
/**
* See QCalendar::dateFromParts(int,int,int)const
*/
@io.qt.QtUninvokable
public final io.qt.core.QDate dateFromParts(int year, int month, int day){
return dateFromParts_native_int_int_int_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), year, month, day);
}
@io.qt.QtUninvokable
private native io.qt.core.QDate dateFromParts_native_int_int_int_constfct(long __this__nativeId, int year, int month, int day);
/**
* See QCalendar::dateTimeToString(QStringView,QDateTime,QDate,QTime,QLocale)const
*/
@io.qt.QtUninvokable
public final java.lang.String dateTimeToString(java.lang.String format, io.qt.core.QDateTime datetime, io.qt.core.QDate dateOnly, io.qt.core.QTime timeOnly, io.qt.core.QLocale locale){
return dateTimeToString_native_QStringView_cref_QDateTime_QDate_QTime_cref_QLocale_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), format, QtJambi_LibraryUtilities.internal.checkedNativeId(datetime), QtJambi_LibraryUtilities.internal.checkedNativeId(dateOnly), QtJambi_LibraryUtilities.internal.checkedNativeId(timeOnly), QtJambi_LibraryUtilities.internal.checkedNativeId(locale));
}
@io.qt.QtUninvokable
private native java.lang.String dateTimeToString_native_QStringView_cref_QDateTime_QDate_QTime_cref_QLocale_constfct(long __this__nativeId, java.lang.String format, long datetime, long dateOnly, long timeOnly, long locale);
/**
* See QCalendar::dayOfWeek(QDate)const
*/
@io.qt.QtUninvokable
public final int dayOfWeek(io.qt.core.QDate date){
return dayOfWeek_native_QDate_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(date));
}
@io.qt.QtUninvokable
private native int dayOfWeek_native_QDate_constfct(long __this__nativeId, long date);
/**
* Overloaded function for {@link #daysInMonth(int, int)}
* with year = Unspecified
.
*/
@io.qt.QtUninvokable
public final int daysInMonth(int month) {
return daysInMonth(month, (int)Unspecified);
}
/**
* See QCalendar::daysInMonth(int,int)const
*/
@io.qt.QtUninvokable
public final int daysInMonth(int month, int year){
return daysInMonth_native_int_int_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), month, year);
}
@io.qt.QtUninvokable
private native int daysInMonth_native_int_int_constfct(long __this__nativeId, int month, int year);
/**
* See QCalendar::daysInYear(int)const
*/
@io.qt.QtUninvokable
public final int daysInYear(int year){
return daysInYear_native_int_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), year);
}
@io.qt.QtUninvokable
private native int daysInYear_native_int_constfct(long __this__nativeId, int year);
/**
* See QCalendar::hasYearZero()const
*/
@io.qt.QtUninvokable
public final boolean hasYearZero(){
return hasYearZero_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@io.qt.QtUninvokable
private native boolean hasYearZero_native_constfct(long __this__nativeId);
/**
* See QCalendar::isDateValid(int,int,int)const
*/
@io.qt.QtUninvokable
public final boolean isDateValid(int year, int month, int day){
return isDateValid_native_int_int_int_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), year, month, day);
}
@io.qt.QtUninvokable
private native boolean isDateValid_native_int_int_int_constfct(long __this__nativeId, int year, int month, int day);
/**
* See QCalendar::isGregorian()const
*/
@io.qt.QtUninvokable
public final boolean isGregorian(){
return isGregorian_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@io.qt.QtUninvokable
private native boolean isGregorian_native_constfct(long __this__nativeId);
/**
* See QCalendar::isLeapYear(int)const
*/
@io.qt.QtUninvokable
public final boolean isLeapYear(int year){
return isLeapYear_native_int_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), year);
}
@io.qt.QtUninvokable
private native boolean isLeapYear_native_int_constfct(long __this__nativeId, int year);
/**
*
*/
@io.qt.QtUninvokable
public final boolean isLunar(){
return isLunar_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@io.qt.QtUninvokable
private native boolean isLunar_native_constfct(long __this__nativeId);
/**
* See QCalendar::isLuniSolar()const
*/
@io.qt.QtUninvokable
public final boolean isLuniSolar(){
return isLuniSolar_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@io.qt.QtUninvokable
private native boolean isLuniSolar_native_constfct(long __this__nativeId);
/**
* See QCalendar::isProleptic()const
*/
@io.qt.QtUninvokable
public final boolean isProleptic(){
return isProleptic_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@io.qt.QtUninvokable
private native boolean isProleptic_native_constfct(long __this__nativeId);
/**
*
*/
@io.qt.QtUninvokable
public final boolean isSolar(){
return isSolar_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@io.qt.QtUninvokable
private native boolean isSolar_native_constfct(long __this__nativeId);
/**
*
*/
@io.qt.QtUninvokable
public final boolean isValid(){
return isValid_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@io.qt.QtUninvokable
private native boolean isValid_native_constfct(long __this__nativeId);
/**
* See QCalendar::maximumDaysInMonth()const
*/
@io.qt.QtUninvokable
public final int maximumDaysInMonth(){
return maximumDaysInMonth_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@io.qt.QtUninvokable
private native int maximumDaysInMonth_native_constfct(long __this__nativeId);
/**
* See QCalendar::maximumMonthsInYear()const
*/
@io.qt.QtUninvokable
public final int maximumMonthsInYear(){
return maximumMonthsInYear_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@io.qt.QtUninvokable
private native int maximumMonthsInYear_native_constfct(long __this__nativeId);
/**
* See QCalendar::minimumDaysInMonth()const
*/
@io.qt.QtUninvokable
public final int minimumDaysInMonth(){
return minimumDaysInMonth_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@io.qt.QtUninvokable
private native int minimumDaysInMonth_native_constfct(long __this__nativeId);
/**
* Overloaded function for {@link #monthName(io.qt.core.QLocale, int, int, io.qt.core.QLocale.FormatType)}
* with format = io.qt.core.QLocale.FormatType.LongFormat
.
*/
@io.qt.QtUninvokable
public final java.lang.String monthName(io.qt.core.QLocale locale, int month, int year) {
return monthName(locale, month, year, io.qt.core.QLocale.FormatType.LongFormat);
}
/**
* Overloaded function for {@link #monthName(io.qt.core.QLocale, int, int, io.qt.core.QLocale.FormatType)}
* with:
* year = Unspecified
* format = io.qt.core.QLocale.FormatType.LongFormat
*
*/
@io.qt.QtUninvokable
public final java.lang.String monthName(io.qt.core.QLocale locale, int month) {
return monthName(locale, month, (int)Unspecified, io.qt.core.QLocale.FormatType.LongFormat);
}
/**
* See QCalendar::monthName(QLocale,int,int,QLocale::FormatType)const
*/
@io.qt.QtUninvokable
public final java.lang.String monthName(io.qt.core.QLocale locale, int month, int year, io.qt.core.QLocale.FormatType format){
return monthName_native_cref_QLocale_int_int_QLocale_FormatType_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(locale), month, year, format.value());
}
@io.qt.QtUninvokable
private native java.lang.String monthName_native_cref_QLocale_int_int_QLocale_FormatType_constfct(long __this__nativeId, long locale, int month, int year, int format);
/**
* See QCalendar::monthsInYear(int)const
*/
@io.qt.QtUninvokable
public final int monthsInYear(int year){
return monthsInYear_native_int_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), year);
}
@io.qt.QtUninvokable
private native int monthsInYear_native_int_constfct(long __this__nativeId, int year);
/**
*
*/
@io.qt.QtUninvokable
public final java.lang.String name(){
return name_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@io.qt.QtUninvokable
private native java.lang.String name_native_constfct(long __this__nativeId);
@io.qt.QtUninvokable
private final boolean operator_equal(io.qt.core.QCalendar value2){
return operator_equal_native_cref_QCalendar(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(value2));
}
@io.qt.QtUninvokable
private native boolean operator_equal_native_cref_QCalendar(long __this__nativeId, long value2);
/**
* See QCalendar::partsFromDate(QDate)const
*/
@io.qt.QtUninvokable
public final io.qt.core.QCalendar.YearMonthDay partsFromDate(io.qt.core.QDate date){
return partsFromDate_native_QDate_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(date));
}
@io.qt.QtUninvokable
private native io.qt.core.QCalendar.YearMonthDay partsFromDate_native_QDate_constfct(long __this__nativeId, long date);
/**
* Overloaded function for {@link #standaloneMonthName(io.qt.core.QLocale, int, int, io.qt.core.QLocale.FormatType)}
* with format = io.qt.core.QLocale.FormatType.LongFormat
.
*/
@io.qt.QtUninvokable
public final java.lang.String standaloneMonthName(io.qt.core.QLocale locale, int month, int year) {
return standaloneMonthName(locale, month, year, io.qt.core.QLocale.FormatType.LongFormat);
}
/**
* Overloaded function for {@link #standaloneMonthName(io.qt.core.QLocale, int, int, io.qt.core.QLocale.FormatType)}
* with:
* year = Unspecified
* format = io.qt.core.QLocale.FormatType.LongFormat
*
*/
@io.qt.QtUninvokable
public final java.lang.String standaloneMonthName(io.qt.core.QLocale locale, int month) {
return standaloneMonthName(locale, month, (int)Unspecified, io.qt.core.QLocale.FormatType.LongFormat);
}
/**
* See QCalendar::standaloneMonthName(QLocale,int,int,QLocale::FormatType)const
*/
@io.qt.QtUninvokable
public final java.lang.String standaloneMonthName(io.qt.core.QLocale locale, int month, int year, io.qt.core.QLocale.FormatType format){
return standaloneMonthName_native_cref_QLocale_int_int_QLocale_FormatType_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(locale), month, year, format.value());
}
@io.qt.QtUninvokable
private native java.lang.String standaloneMonthName_native_cref_QLocale_int_int_QLocale_FormatType_constfct(long __this__nativeId, long locale, int month, int year, int format);
/**
* Overloaded function for {@link #standaloneWeekDayName(io.qt.core.QLocale, int, io.qt.core.QLocale.FormatType)}
* with format = io.qt.core.QLocale.FormatType.LongFormat
.
*/
@io.qt.QtUninvokable
public final java.lang.String standaloneWeekDayName(io.qt.core.QLocale locale, int day) {
return standaloneWeekDayName(locale, day, io.qt.core.QLocale.FormatType.LongFormat);
}
/**
* See QCalendar::standaloneWeekDayName(QLocale,int,QLocale::FormatType)const
*/
@io.qt.QtUninvokable
public final java.lang.String standaloneWeekDayName(io.qt.core.QLocale locale, int day, io.qt.core.QLocale.FormatType format){
return standaloneWeekDayName_native_cref_QLocale_int_QLocale_FormatType_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(locale), day, format.value());
}
@io.qt.QtUninvokable
private native java.lang.String standaloneWeekDayName_native_cref_QLocale_int_QLocale_FormatType_constfct(long __this__nativeId, long locale, int day, int format);
/**
* Overloaded function for {@link #weekDayName(io.qt.core.QLocale, int, io.qt.core.QLocale.FormatType)}
* with format = io.qt.core.QLocale.FormatType.LongFormat
.
*/
@io.qt.QtUninvokable
public final java.lang.String weekDayName(io.qt.core.QLocale locale, int day) {
return weekDayName(locale, day, io.qt.core.QLocale.FormatType.LongFormat);
}
/**
* See QCalendar::weekDayName(QLocale,int,QLocale::FormatType)const
*/
@io.qt.QtUninvokable
public final java.lang.String weekDayName(io.qt.core.QLocale locale, int day, io.qt.core.QLocale.FormatType format){
return weekDayName_native_cref_QLocale_int_QLocale_FormatType_constfct(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(locale), day, format.value());
}
@io.qt.QtUninvokable
private native java.lang.String weekDayName_native_cref_QLocale_int_QLocale_FormatType_constfct(long __this__nativeId, long locale, int day, int format);
/**
* See QCalendar::availableCalendars()
*/
public native static io.qt.core.QStringList availableCalendars();
/**
* Constructor for internal use only.
* @param p expected to be null
.
*/
@io.qt.NativeAccess
protected QCalendar(QPrivateConstructor p) { super(p); }
@Override
@io.qt.QtUninvokable
public boolean equals(Object other) {
if (other instanceof io.qt.core.QCalendar) {
return operator_equal((io.qt.core.QCalendar) other);
}
return false;
}
@io.qt.QtUninvokable
@Override
public int hashCode() {
return hashCode_native(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@io.qt.QtUninvokable
private native static int hashCode_native(long __this_nativeId);
public static final int Unspecified = unspecified();
private static native int unspecified();
@Override
public QCalendar clone() {
return clone_native(QtJambi_LibraryUtilities.internal.nativeId(this));
}
private native QCalendar clone_native(long __this_nativeId);
}