@nodert-win10/windows.applicationmodel.appointments
Version:
Use the Windows.ApplicationModel.Appointments UWP API directly from Node.js
472 lines (352 loc) • 16 kB
TypeScript
declare module "windows.applicationmodel.appointments" {
export class Rect {
constructor();
}
export class Color {
constructor();
}
export enum AppointmentStoreAccessType {
appCalendarsReadWrite,
allCalendarsReadOnly,
allCalendarsReadWrite,
}
export enum AppointmentSensitivity {
public,
private,
}
export enum AppointmentBusyStatus {
busy,
tentative,
free,
outOfOffice,
workingElsewhere,
}
export enum AppointmentParticipantResponse {
none,
tentative,
accepted,
declined,
unknown,
}
export enum AppointmentParticipantRole {
requiredAttendee,
optionalAttendee,
resource,
}
export enum AppointmentRecurrenceUnit {
daily,
weekly,
monthly,
monthlyOnDay,
yearly,
yearlyOnDay,
}
export enum AppointmentDaysOfWeek {
none,
sunday,
monday,
tuesday,
wednesday,
thursday,
friday,
saturday,
}
export enum AppointmentWeekOfMonth {
first,
second,
third,
fourth,
last,
}
export enum AppointmentCalendarSyncStatus {
idle,
syncing,
upToDate,
authenticationError,
policyError,
unknownError,
manualAccountRemovalRequired,
}
export enum RecurrenceType {
master,
instance,
exceptionInstance,
}
export enum AppointmentDetailsKind {
plainText,
html,
}
export enum FindAppointmentCalendarsOptions {
none,
includeHidden,
}
export enum AppointmentSummaryCardView {
system,
app,
}
export enum AppointmentCalendarOtherAppReadAccess {
systemOnly,
limited,
full,
}
export enum AppointmentCalendarOtherAppWriteAccess {
none,
systemOnly,
}
export enum AppointmentConflictType {
none,
adjacent,
overlap,
}
export enum AppointmentStoreChangeType {
appointmentCreated,
appointmentModified,
appointmentDeleted,
changeTrackingLost,
calendarCreated,
calendarModified,
calendarDeleted,
}
export class Appointment {
location: String;
allDay: Boolean;
organizer: AppointmentOrganizer;
duration: Number;
details: String;
uri: Object;
busyStatus: AppointmentBusyStatus;
recurrence: AppointmentRecurrence;
subject: String;
startTime: Date;
sensitivity: AppointmentSensitivity;
reminder: Number;
invitees: Object;
allowNewTimeProposal: Boolean;
userResponse: AppointmentParticipantResponse;
roamingId: String;
replyTime: Date;
isResponseRequested: Boolean;
isOrganizedByUser: Boolean;
isCanceledMeeting: Boolean;
onlineMeetingLink: String;
hasInvitees: Boolean;
calendarId: String;
localId: String;
originalStartTime: Date;
remoteChangeNumber: Number;
detailsKind: AppointmentDetailsKind;
changeNumber: Number;
constructor();
}
export class AppointmentStore {
changeTracker: AppointmentStoreChangeTracker;
constructor();
createAppointmentCalendarAsync(name: String, callback: (error: Error, result: AppointmentCalendar) => void): void ;
createAppointmentCalendarAsync(name: String, userDataAccountId: String, callback: (error: Error, result: AppointmentCalendar) => void): void ;
getAppointmentCalendarAsync(calendarId: String, callback: (error: Error, result: AppointmentCalendar) => void): void ;
getAppointmentAsync(localId: String, callback: (error: Error, result: Appointment) => void): void ;
getAppointmentInstanceAsync(localId: String, instanceStartTime: Date, callback: (error: Error, result: Appointment) => void): void ;
findAppointmentCalendarsAsync(callback: (error: Error, result: Object) => void): void ;
findAppointmentCalendarsAsync(options: FindAppointmentCalendarsOptions, callback: (error: Error, result: Object) => void): void ;
findAppointmentsAsync(rangeStart: Date, rangeLength: Number, callback: (error: Error, result: Object) => void): void ;
findAppointmentsAsync(rangeStart: Date, rangeLength: Number, options: FindAppointmentsOptions, callback: (error: Error, result: Object) => void): void ;
findConflictAsync(appointment: Appointment, callback: (error: Error, result: AppointmentConflictResult) => void): void ;
findConflictAsync(appointment: Appointment, instanceStartTime: Date, callback: (error: Error, result: AppointmentConflictResult) => void): void ;
moveAppointmentAsync(appointment: Appointment, destinationCalendar: AppointmentCalendar, callback: (error: Error) => void): void ;
showAddAppointmentAsync(appointment: Appointment, selection: Object, callback: (error: Error, result: String) => void): void ;
showReplaceAppointmentAsync(localId: String, appointment: Appointment, selection: Object, callback: (error: Error, result: String) => void): void ;
showReplaceAppointmentAsync(localId: String, appointment: Appointment, selection: Object, preferredPlacement: Number, instanceStartDate: Date, callback: (error: Error, result: String) => void): void ;
showRemoveAppointmentAsync(localId: String, selection: Object, callback: (error: Error, result: Boolean) => void): void ;
showRemoveAppointmentAsync(localId: String, selection: Object, preferredPlacement: Number, instanceStartDate: Date, callback: (error: Error, result: Boolean) => void): void ;
showAppointmentDetailsAsync(localId: String, callback: (error: Error) => void): void ;
showAppointmentDetailsAsync(localId: String, instanceStartDate: Date, callback: (error: Error) => void): void ;
showEditNewAppointmentAsync(appointment: Appointment, callback: (error: Error, result: String) => void): void ;
findLocalIdsFromRoamingIdAsync(roamingId: String, callback: (error: Error, result: Object) => void): void ;
addListener(type: "StoreChanged", listener: (ev: Event) => void): void ;
removeListener(type: "StoreChanged", listener: (ev: Event) => void): void ;
on(type: "StoreChanged", listener: (ev: Event) => void): void ;
off(type: "StoreChanged", listener: (ev: Event) => void): void ;
addListener(type: string, listener: (ev: Event) => void): void ;
removeListener(type: string, listener: (ev: Event) => void): void ;
on(type: string, listener: (ev: Event) => void): void ;
off(type: string, listener: (ev: Event) => void): void ;
}
export class IAppointmentParticipant {
address: String;
displayName: String;
constructor();
}
export class AppointmentOrganizer {
displayName: String;
address: String;
constructor();
}
export class AppointmentInvitee {
role: AppointmentParticipantRole;
response: AppointmentParticipantResponse;
displayName: String;
address: String;
constructor();
}
export class AppointmentRecurrence {
unit: AppointmentRecurrenceUnit;
occurrences: Number;
month: Number;
interval: Number;
daysOfWeek: AppointmentDaysOfWeek;
day: Number;
weekOfMonth: AppointmentWeekOfMonth;
until: Date;
timeZone: String;
recurrenceType: RecurrenceType;
calendarIdentifier: String;
constructor();
}
export class AppointmentManager {
constructor();
static showAppointmentDetailsAsync(appointmentId: String, callback: (error: Error) => void): void ;
static showAppointmentDetailsAsync(appointmentId: String, instanceStartDate: Date, callback: (error: Error) => void): void ;
static showEditNewAppointmentAsync(appointment: Appointment, callback: (error: Error, result: String) => void): void ;
static requestStoreAsync(options: AppointmentStoreAccessType, callback: (error: Error, result: AppointmentStore) => void): void ;
static showAddAppointmentAsync(appointment: Appointment, selection: Object, callback: (error: Error, result: String) => void): void ;
static showAddAppointmentAsync(appointment: Appointment, selection: Object, preferredPlacement: Number, callback: (error: Error, result: String) => void): void ;
static showReplaceAppointmentAsync(appointmentId: String, appointment: Appointment, selection: Object, callback: (error: Error, result: String) => void): void ;
static showReplaceAppointmentAsync(appointmentId: String, appointment: Appointment, selection: Object, preferredPlacement: Number, callback: (error: Error, result: String) => void): void ;
static showReplaceAppointmentAsync(appointmentId: String, appointment: Appointment, selection: Object, preferredPlacement: Number, instanceStartDate: Date, callback: (error: Error, result: String) => void): void ;
static showRemoveAppointmentAsync(appointmentId: String, selection: Object, callback: (error: Error, result: Boolean) => void): void ;
static showRemoveAppointmentAsync(appointmentId: String, selection: Object, preferredPlacement: Number, callback: (error: Error, result: Boolean) => void): void ;
static showRemoveAppointmentAsync(appointmentId: String, selection: Object, preferredPlacement: Number, instanceStartDate: Date, callback: (error: Error, result: Boolean) => void): void ;
static showTimeFrameAsync(timeToShow: Date, duration: Number, callback: (error: Error) => void): void ;
}
export class FindAppointmentsOptions {
maxCount: Number;
includeHidden: Boolean;
calendarIds: Object;
fetchProperties: Object;
constructor();
}
export class AppointmentException {
appointment: Appointment;
exceptionProperties: Object;
isDeleted: Boolean;
constructor();
}
export class AppointmentCalendarSyncManager {
lastAttemptedSyncTime: Date;
lastSuccessfulSyncTime: Date;
status: AppointmentCalendarSyncStatus;
constructor();
syncAsync(callback: (error: Error, result: Boolean) => void): void ;
addListener(type: "SyncStatusChanged", listener: (ev: Event) => void): void ;
removeListener(type: "SyncStatusChanged", listener: (ev: Event) => void): void ;
on(type: "SyncStatusChanged", listener: (ev: Event) => void): void ;
off(type: "SyncStatusChanged", listener: (ev: Event) => void): void ;
addListener(type: string, listener: (ev: Event) => void): void ;
removeListener(type: string, listener: (ev: Event) => void): void ;
on(type: string, listener: (ev: Event) => void): void ;
off(type: string, listener: (ev: Event) => void): void ;
}
export class AppointmentCalendar {
summaryCardView: AppointmentSummaryCardView;
otherAppWriteAccess: AppointmentCalendarOtherAppWriteAccess;
displayColor: Object;
isHidden: Boolean;
displayName: String;
otherAppReadAccess: AppointmentCalendarOtherAppReadAccess;
localId: String;
sourceDisplayName: String;
canCancelMeetings: Boolean;
canNotifyInvitees: Boolean;
remoteId: String;
mustNofityInvitees: Boolean;
canUpdateMeetingResponses: Boolean;
canProposeNewTimeForMeetings: Boolean;
canCreateOrUpdateAppointments: Boolean;
canForwardMeetings: Boolean;
syncManager: AppointmentCalendarSyncManager;
userDataAccountId: String;
constructor();
findAppointmentsAsync(rangeStart: Date, rangeLength: Number, callback: (error: Error, result: Object) => void): void ;
findAppointmentsAsync(rangeStart: Date, rangeLength: Number, options: FindAppointmentsOptions, callback: (error: Error, result: Object) => void): void ;
findExceptionsFromMasterAsync(masterLocalId: String, callback: (error: Error, result: Object) => void): void ;
findAllInstancesAsync(masterLocalId: String, rangeStart: Date, rangeLength: Number, callback: (error: Error, result: Object) => void): void ;
findAllInstancesAsync(masterLocalId: String, rangeStart: Date, rangeLength: Number, pOptions: FindAppointmentsOptions, callback: (error: Error, result: Object) => void): void ;
getAppointmentAsync(localId: String, callback: (error: Error, result: Appointment) => void): void ;
getAppointmentInstanceAsync(localId: String, instanceStartTime: Date, callback: (error: Error, result: Appointment) => void): void ;
findUnexpandedAppointmentsAsync(callback: (error: Error, result: Object) => void): void ;
findUnexpandedAppointmentsAsync(options: FindAppointmentsOptions, callback: (error: Error, result: Object) => void): void ;
deleteAsync(callback: (error: Error) => void): void ;
saveAsync(callback: (error: Error) => void): void ;
deleteAppointmentAsync(localId: String, callback: (error: Error) => void): void ;
deleteAppointmentInstanceAsync(localId: String, instanceStartTime: Date, callback: (error: Error) => void): void ;
saveAppointmentAsync(pAppointment: Appointment, callback: (error: Error) => void): void ;
tryCreateOrUpdateAppointmentAsync(appointment: Appointment, notifyInvitees: Boolean, callback: (error: Error, result: Boolean) => void): void ;
tryCancelMeetingAsync(meeting: Appointment, subject: String, comment: String, notifyInvitees: Boolean, callback: (error: Error, result: Boolean) => void): void ;
tryForwardMeetingAsync(meeting: Appointment, invitees: Object, subject: String, forwardHeader: String, comment: String, callback: (error: Error, result: Boolean) => void): void ;
tryProposeNewTimeForMeetingAsync(meeting: Appointment, newStartTime: Date, newDuration: Number, subject: String, comment: String, callback: (error: Error, result: Boolean) => void): void ;
tryUpdateMeetingResponseAsync(meeting: Appointment, response: AppointmentParticipantResponse, subject: String, comment: String, sendUpdate: Boolean, callback: (error: Error, result: Boolean) => void): void ;
}
export class AppointmentStoreChange {
appointment: Appointment;
changeType: AppointmentStoreChangeType;
appointmentCalendar: AppointmentCalendar;
constructor();
}
export class AppointmentStoreChangeReader {
constructor();
readBatchAsync(callback: (error: Error, result: Object) => void): void ;
acceptChanges(): void;
acceptChangesThrough(lastChangeToAccept: AppointmentStoreChange): void;
}
export class AppointmentStoreChangedDeferral {
constructor();
complete(): void;
}
export class AppointmentStoreChangeTracker {
constructor();
getChangeReader(): AppointmentStoreChangeReader;
enable(): void;
reset(): void;
}
export class AppointmentConflictResult {
date: Date;
type: AppointmentConflictType;
constructor();
}
export class AppointmentStoreChangedEventArgs {
constructor();
getDeferral(): AppointmentStoreChangedDeferral;
}
export class AppointmentProperties {
static hasInvitees: String;
static allDay: String;
static allowNewTimeProposal: String;
static busyStatus: String;
static defaultProperties: Object;
static details: String;
static duration: String;
static recurrence: String;
static invitees: String;
static isCanceledMeeting: String;
static isOrganizedByUser: String;
static isResponseRequested: String;
static location: String;
static onlineMeetingLink: String;
static organizer: String;
static originalStartTime: String;
static reminder: String;
static replyTime: String;
static sensitivity: String;
static startTime: String;
static subject: String;
static uri: String;
static userResponse: String;
static detailsKind: String;
static remoteChangeNumber: String;
static changeNumber: String;
constructor();
}
export class AppointmentStoreNotificationTriggerDetails {
constructor();
}
}