pub struct QDate { /* private fields */ }Expand description
C++ class: QDate.
Implementations§
Source§impl QDate
impl QDate
Sourcepub unsafe fn add_days(&self, days: c_longlong) -> CppBox<QDate>
pub unsafe fn add_days(&self, days: c_longlong) -> CppBox<QDate>
Calls C++ function: QDate QDate::addDays(long long days) const.
Sourcepub unsafe fn add_months_1a(&self, months: c_int) -> CppBox<QDate>
pub unsafe fn add_months_1a(&self, months: c_int) -> CppBox<QDate>
Calls C++ function: QDate QDate::addMonths(int months) const.
Sourcepub unsafe fn add_months_2a(
&self,
months: c_int,
cal: impl CastInto<Ref<QCalendar>>,
) -> CppBox<QDate>
pub unsafe fn add_months_2a( &self, months: c_int, cal: impl CastInto<Ref<QCalendar>>, ) -> CppBox<QDate>
Calls C++ function: QDate QDate::addMonths(int months, QCalendar cal) const.
Sourcepub unsafe fn add_years_1a(&self, years: c_int) -> CppBox<QDate>
pub unsafe fn add_years_1a(&self, years: c_int) -> CppBox<QDate>
Calls C++ function: QDate QDate::addYears(int years) const.
Sourcepub unsafe fn add_years_2a(
&self,
years: c_int,
cal: impl CastInto<Ref<QCalendar>>,
) -> CppBox<QDate>
pub unsafe fn add_years_2a( &self, years: c_int, cal: impl CastInto<Ref<QCalendar>>, ) -> CppBox<QDate>
Calls C++ function: QDate QDate::addYears(int years, QCalendar cal) const.
Sourcepub unsafe fn copy_from(&self, other: impl CastInto<Ref<QDate>>) -> Ref<QDate>
pub unsafe fn copy_from(&self, other: impl CastInto<Ref<QDate>>) -> Ref<QDate>
Calls C++ function: QDate& QDate::operator=(const QDate& other).
Sourcepub unsafe fn current_date() -> CppBox<QDate>
pub unsafe fn current_date() -> CppBox<QDate>
Calls C++ function: static QDate QDate::currentDate().
Sourcepub unsafe fn day_1a(&self, cal: impl CastInto<Ref<QCalendar>>) -> c_int
pub unsafe fn day_1a(&self, cal: impl CastInto<Ref<QCalendar>>) -> c_int
Calls C++ function: int QDate::day(QCalendar cal) const.
Sourcepub unsafe fn day_of_week_0a(&self) -> c_int
pub unsafe fn day_of_week_0a(&self) -> c_int
Calls C++ function: int QDate::dayOfWeek() const.
Sourcepub unsafe fn day_of_week_1a(&self, cal: impl CastInto<Ref<QCalendar>>) -> c_int
pub unsafe fn day_of_week_1a(&self, cal: impl CastInto<Ref<QCalendar>>) -> c_int
Calls C++ function: int QDate::dayOfWeek(QCalendar cal) const.
Sourcepub unsafe fn day_of_year_0a(&self) -> c_int
pub unsafe fn day_of_year_0a(&self) -> c_int
Calls C++ function: int QDate::dayOfYear() const.
Sourcepub unsafe fn day_of_year_1a(&self, cal: impl CastInto<Ref<QCalendar>>) -> c_int
pub unsafe fn day_of_year_1a(&self, cal: impl CastInto<Ref<QCalendar>>) -> c_int
Calls C++ function: int QDate::dayOfYear(QCalendar cal) const.
Sourcepub unsafe fn days_in_month_0a(&self) -> c_int
pub unsafe fn days_in_month_0a(&self) -> c_int
Calls C++ function: int QDate::daysInMonth() const.
Sourcepub unsafe fn days_in_month_1a(
&self,
cal: impl CastInto<Ref<QCalendar>>,
) -> c_int
pub unsafe fn days_in_month_1a( &self, cal: impl CastInto<Ref<QCalendar>>, ) -> c_int
Calls C++ function: int QDate::daysInMonth(QCalendar cal) const.
Sourcepub unsafe fn days_in_year_0a(&self) -> c_int
pub unsafe fn days_in_year_0a(&self) -> c_int
Calls C++ function: int QDate::daysInYear() const.
Sourcepub unsafe fn days_in_year_1a(
&self,
cal: impl CastInto<Ref<QCalendar>>,
) -> c_int
pub unsafe fn days_in_year_1a( &self, cal: impl CastInto<Ref<QCalendar>>, ) -> c_int
Calls C++ function: int QDate::daysInYear(QCalendar cal) const.
Sourcepub unsafe fn days_to(&self, arg1: impl CastInto<Ref<QDate>>) -> c_longlong
pub unsafe fn days_to(&self, arg1: impl CastInto<Ref<QDate>>) -> c_longlong
Calls C++ function: long long QDate::daysTo(const QDate& arg1) const.
Sourcepub unsafe fn end_of_day_time_spec_int(
&self,
spec: TimeSpec,
offset_seconds: c_int,
) -> CppBox<QDateTime>
pub unsafe fn end_of_day_time_spec_int( &self, spec: TimeSpec, offset_seconds: c_int, ) -> CppBox<QDateTime>
Calls C++ function: QDateTime QDate::endOfDay(Qt::TimeSpec spec = …, int offsetSeconds = …) const.
Sourcepub unsafe fn end_of_day_q_time_zone(
&self,
zone: impl CastInto<Ref<QTimeZone>>,
) -> CppBox<QDateTime>
pub unsafe fn end_of_day_q_time_zone( &self, zone: impl CastInto<Ref<QTimeZone>>, ) -> CppBox<QDateTime>
Calls C++ function: QDateTime QDate::endOfDay(const QTimeZone& zone) const.
Sourcepub unsafe fn end_of_day_time_spec(&self, spec: TimeSpec) -> CppBox<QDateTime>
pub unsafe fn end_of_day_time_spec(&self, spec: TimeSpec) -> CppBox<QDateTime>
Calls C++ function: QDateTime QDate::endOfDay(Qt::TimeSpec spec = …) const.
Sourcepub unsafe fn end_of_day(&self) -> CppBox<QDateTime>
pub unsafe fn end_of_day(&self) -> CppBox<QDateTime>
Calls C++ function: QDateTime QDate::endOfDay() const.
Sourcepub unsafe fn from_julian_day(jd: c_longlong) -> CppBox<QDate>
pub unsafe fn from_julian_day(jd: c_longlong) -> CppBox<QDate>
Calls C++ function: static QDate QDate::fromJulianDay(long long jd_).
Sourcepub unsafe fn from_string_q_string_date_format(
s: impl CastInto<Ref<QString>>,
f: DateFormat,
) -> CppBox<QDate>
pub unsafe fn from_string_q_string_date_format( s: impl CastInto<Ref<QString>>, f: DateFormat, ) -> CppBox<QDate>
Calls C++ function: static QDate QDate::fromString(const QString& s, Qt::DateFormat f = …).
Sourcepub unsafe fn from_string_2_q_string(
s: impl CastInto<Ref<QString>>,
format: impl CastInto<Ref<QString>>,
) -> CppBox<QDate>
pub unsafe fn from_string_2_q_string( s: impl CastInto<Ref<QString>>, format: impl CastInto<Ref<QString>>, ) -> CppBox<QDate>
Calls C++ function: static QDate QDate::fromString(const QString& s, const QString& format).
Sourcepub unsafe fn from_string_2_q_string_q_calendar(
s: impl CastInto<Ref<QString>>,
format: impl CastInto<Ref<QString>>,
cal: impl CastInto<Ref<QCalendar>>,
) -> CppBox<QDate>
pub unsafe fn from_string_2_q_string_q_calendar( s: impl CastInto<Ref<QString>>, format: impl CastInto<Ref<QString>>, cal: impl CastInto<Ref<QCalendar>>, ) -> CppBox<QDate>
Calls C++ function: static QDate QDate::fromString(const QString& s, const QString& format, QCalendar cal).
Sourcepub unsafe fn from_string_q_string(
s: impl CastInto<Ref<QString>>,
) -> CppBox<QDate>
pub unsafe fn from_string_q_string( s: impl CastInto<Ref<QString>>, ) -> CppBox<QDate>
Calls C++ function: static QDate QDate::fromString(const QString& s).
Sourcepub unsafe fn get_date_mut(
&self,
year: *mut c_int,
month: *mut c_int,
day: *mut c_int,
)
pub unsafe fn get_date_mut( &self, year: *mut c_int, month: *mut c_int, day: *mut c_int, )
Calls C++ function: void QDate::getDate(int* year, int* month, int* day).
Sourcepub unsafe fn get_date(
&self,
year: *mut c_int,
month: *mut c_int,
day: *mut c_int,
)
pub unsafe fn get_date( &self, year: *mut c_int, month: *mut c_int, day: *mut c_int, )
Calls C++ function: void QDate::getDate(int* year, int* month, int* day) const.
Sourcepub unsafe fn is_leap_year(year: c_int) -> bool
pub unsafe fn is_leap_year(year: c_int) -> bool
Calls C++ function: static bool QDate::isLeapYear(int year).
Sourcepub unsafe fn is_valid_0a(&self) -> bool
pub unsafe fn is_valid_0a(&self) -> bool
Calls C++ function: bool QDate::isValid() const.
Sourcepub unsafe fn is_valid_3a(y: c_int, m: c_int, d: c_int) -> bool
pub unsafe fn is_valid_3a(y: c_int, m: c_int, d: c_int) -> bool
Calls C++ function: static bool QDate::isValid(int y, int m, int d).
Sourcepub unsafe fn long_day_name_2a(
weekday: c_int,
type_: MonthNameType,
) -> CppBox<QString>
pub unsafe fn long_day_name_2a( weekday: c_int, type_: MonthNameType, ) -> CppBox<QString>
Calls C++ function: static QString QDate::longDayName(int weekday, QDate::MonthNameType type = …).
Sourcepub unsafe fn long_day_name_1a(weekday: c_int) -> CppBox<QString>
pub unsafe fn long_day_name_1a(weekday: c_int) -> CppBox<QString>
Calls C++ function: static QString QDate::longDayName(int weekday).
Sourcepub unsafe fn long_month_name_2a(
month: c_int,
type_: MonthNameType,
) -> CppBox<QString>
pub unsafe fn long_month_name_2a( month: c_int, type_: MonthNameType, ) -> CppBox<QString>
Calls C++ function: static QString QDate::longMonthName(int month, QDate::MonthNameType type = …).
Sourcepub unsafe fn long_month_name_1a(month: c_int) -> CppBox<QString>
pub unsafe fn long_month_name_1a(month: c_int) -> CppBox<QString>
Calls C++ function: static QString QDate::longMonthName(int month).
Sourcepub unsafe fn month_1a(&self, cal: impl CastInto<Ref<QCalendar>>) -> c_int
pub unsafe fn month_1a(&self, cal: impl CastInto<Ref<QCalendar>>) -> c_int
Calls C++ function: int QDate::month(QCalendar cal) const.
Sourcepub unsafe fn new_3a(y: c_int, m: c_int, d: c_int) -> CppBox<QDate>
pub unsafe fn new_3a(y: c_int, m: c_int, d: c_int) -> CppBox<QDate>
Calls C++ function: [constructor] void QDate::QDate(int y, int m, int d).
Sourcepub unsafe fn new_4a(
y: c_int,
m: c_int,
d: c_int,
cal: impl CastInto<Ref<QCalendar>>,
) -> CppBox<QDate>
pub unsafe fn new_4a( y: c_int, m: c_int, d: c_int, cal: impl CastInto<Ref<QCalendar>>, ) -> CppBox<QDate>
Calls C++ function: [constructor] void QDate::QDate(int y, int m, int d, QCalendar cal).
Sourcepub unsafe fn new_copy(other: impl CastInto<Ref<QDate>>) -> CppBox<QDate>
pub unsafe fn new_copy(other: impl CastInto<Ref<QDate>>) -> CppBox<QDate>
Calls C++ function: [constructor] void QDate::QDate(const QDate& other).
Sourcepub unsafe fn set_date_3a(&self, year: c_int, month: c_int, day: c_int) -> bool
pub unsafe fn set_date_3a(&self, year: c_int, month: c_int, day: c_int) -> bool
Calls C++ function: bool QDate::setDate(int year, int month, int day).
Sourcepub unsafe fn set_date_4a(
&self,
year: c_int,
month: c_int,
day: c_int,
cal: impl CastInto<Ref<QCalendar>>,
) -> bool
pub unsafe fn set_date_4a( &self, year: c_int, month: c_int, day: c_int, cal: impl CastInto<Ref<QCalendar>>, ) -> bool
Calls C++ function: bool QDate::setDate(int year, int month, int day, QCalendar cal).
Sourcepub unsafe fn short_day_name_2a(
weekday: c_int,
type_: MonthNameType,
) -> CppBox<QString>
pub unsafe fn short_day_name_2a( weekday: c_int, type_: MonthNameType, ) -> CppBox<QString>
Calls C++ function: static QString QDate::shortDayName(int weekday, QDate::MonthNameType type = …).
Sourcepub unsafe fn short_day_name_1a(weekday: c_int) -> CppBox<QString>
pub unsafe fn short_day_name_1a(weekday: c_int) -> CppBox<QString>
Calls C++ function: static QString QDate::shortDayName(int weekday).
Sourcepub unsafe fn short_month_name_2a(
month: c_int,
type_: MonthNameType,
) -> CppBox<QString>
pub unsafe fn short_month_name_2a( month: c_int, type_: MonthNameType, ) -> CppBox<QString>
Calls C++ function: static QString QDate::shortMonthName(int month, QDate::MonthNameType type = …).
Sourcepub unsafe fn short_month_name_1a(month: c_int) -> CppBox<QString>
pub unsafe fn short_month_name_1a(month: c_int) -> CppBox<QString>
Calls C++ function: static QString QDate::shortMonthName(int month).
Sourcepub unsafe fn start_of_day_time_spec_int(
&self,
spec: TimeSpec,
offset_seconds: c_int,
) -> CppBox<QDateTime>
pub unsafe fn start_of_day_time_spec_int( &self, spec: TimeSpec, offset_seconds: c_int, ) -> CppBox<QDateTime>
Calls C++ function: QDateTime QDate::startOfDay(Qt::TimeSpec spec = …, int offsetSeconds = …) const.
Sourcepub unsafe fn start_of_day_q_time_zone(
&self,
zone: impl CastInto<Ref<QTimeZone>>,
) -> CppBox<QDateTime>
pub unsafe fn start_of_day_q_time_zone( &self, zone: impl CastInto<Ref<QTimeZone>>, ) -> CppBox<QDateTime>
Calls C++ function: QDateTime QDate::startOfDay(const QTimeZone& zone) const.
Sourcepub unsafe fn start_of_day_time_spec(&self, spec: TimeSpec) -> CppBox<QDateTime>
pub unsafe fn start_of_day_time_spec(&self, spec: TimeSpec) -> CppBox<QDateTime>
Calls C++ function: QDateTime QDate::startOfDay(Qt::TimeSpec spec = …) const.
Sourcepub unsafe fn start_of_day(&self) -> CppBox<QDateTime>
pub unsafe fn start_of_day(&self) -> CppBox<QDateTime>
Calls C++ function: QDateTime QDate::startOfDay() const.
Sourcepub unsafe fn to_julian_day(&self) -> c_longlong
pub unsafe fn to_julian_day(&self) -> c_longlong
Calls C++ function: long long QDate::toJulianDay() const.
Sourcepub unsafe fn to_string_date_format(
&self,
format: DateFormat,
) -> CppBox<QString>
pub unsafe fn to_string_date_format( &self, format: DateFormat, ) -> CppBox<QString>
Calls C++ function: QString QDate::toString(Qt::DateFormat format = …) const.
Sourcepub unsafe fn to_string_date_format_q_calendar(
&self,
format: DateFormat,
cal: impl CastInto<Ref<QCalendar>>,
) -> CppBox<QString>
pub unsafe fn to_string_date_format_q_calendar( &self, format: DateFormat, cal: impl CastInto<Ref<QCalendar>>, ) -> CppBox<QString>
Calls C++ function: QString QDate::toString(Qt::DateFormat format, QCalendar cal) const.
Sourcepub unsafe fn to_string_q_string(
&self,
format: impl CastInto<Ref<QString>>,
) -> CppBox<QString>
pub unsafe fn to_string_q_string( &self, format: impl CastInto<Ref<QString>>, ) -> CppBox<QString>
Calls C++ function: QString QDate::toString(const QString& format) const.
Sourcepub unsafe fn to_string_q_string_q_calendar(
&self,
format: impl CastInto<Ref<QString>>,
cal: impl CastInto<Ref<QCalendar>>,
) -> CppBox<QString>
pub unsafe fn to_string_q_string_q_calendar( &self, format: impl CastInto<Ref<QString>>, cal: impl CastInto<Ref<QCalendar>>, ) -> CppBox<QString>
Calls C++ function: QString QDate::toString(const QString& format, QCalendar cal) const.
Sourcepub unsafe fn to_string_q_string_view(
&self,
format: impl CastInto<Ref<QStringView>>,
) -> CppBox<QString>
pub unsafe fn to_string_q_string_view( &self, format: impl CastInto<Ref<QStringView>>, ) -> CppBox<QString>
Calls C++ function: QString QDate::toString(QStringView format) const.
Sourcepub unsafe fn to_string_q_string_view_q_calendar(
&self,
format: impl CastInto<Ref<QStringView>>,
cal: impl CastInto<Ref<QCalendar>>,
) -> CppBox<QString>
pub unsafe fn to_string_q_string_view_q_calendar( &self, format: impl CastInto<Ref<QStringView>>, cal: impl CastInto<Ref<QCalendar>>, ) -> CppBox<QString>
Calls C++ function: QString QDate::toString(QStringView format, QCalendar cal) const.
Sourcepub unsafe fn to_string(&self) -> CppBox<QString>
pub unsafe fn to_string(&self) -> CppBox<QString>
Calls C++ function: QString QDate::toString() const.
Sourcepub unsafe fn week_number_1a(&self, year_num: *mut c_int) -> c_int
pub unsafe fn week_number_1a(&self, year_num: *mut c_int) -> c_int
Calls C++ function: int QDate::weekNumber(int* yearNum = …) const.
Sourcepub unsafe fn week_number_0a(&self) -> c_int
pub unsafe fn week_number_0a(&self) -> c_int
Calls C++ function: int QDate::weekNumber() const.