⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 nsfdata.h

📁 IBM Lotus C++ API 7.0a for IBM Lotus Notes/Domino Directory Release --------- ------------------
💻 H
📖 第 1 页 / 共 3 页
字号:
** the number for some breathing room.
**
** The SCHED_LIST and SCHED_ENTRY are the preR6 data types.  For R6 we used
** the SCHED_LIST.Spare value to convey the length of the SCHED_ENTRY_EXT
** data that follows.  If .Spare is 0, the data that follows is SCHED_ENTRY,
** NOT SCHED_ENTRY_EXT.
** Now that we convey the length of each SCHED_ENTRY_EXT that follows (R6 and
** later), we can easily extend SCHED_ENTRY_EXT w/o adversely affecting
** previous clients since from R6 on the clients should be using
** SCHED_LIST.Spare to do pointer shifts.  For example, say in R7 we add
** even more info to SCHED_ENTRY_EXT, we simply append it to the R6 definition
** and adjust SCHED_LIST.Spare to reflect the new size.  That way an R6 client
** can get the info it needs/wants and can skip the 'newer' data that it
** has no way of properly using/processing.
**
** Note: If the SCHED_LIST.Spare is 0 then a SCHED_ENTRY MUST follow.
** If the SCHED_LIST.Spare is non-0 then a SCHED_ENTRY_EXT MUST follow.
**
** We are NOT allowing mixing of data types since it would only cause confusion
** for older users!  The system will return SCHED_LIST/SCHED_ENTRY data if it
** detects that the caller is using the preR6 API calls (or is using the R6
** API calls with a "preR6" flag to indicate old API call in use).
*/

#define MAXSCHEDLISTSIZE        (MAXONESEGSIZE - 100 * sizeof(SCHED_ENTRY))
#define MAXENTRIESPERSCHEDLIST  ((MAXSCHEDLISTSIZE - sizeof (SCHED_LIST)) / sizeof(SCHED_ENTRY))

typedef struct {
    ALIGNED_NUMBER  nLongitude;         /* Longitude coordinate value */
    ALIGNED_NUMBER  nLatitude;          /* Latitude coordinate value */
} GEO_INFO;

/* Scheduling list header */

typedef struct {
    DWORD   NumEntries;         /* Total number of schedule entries follow */
    WORD    wApplicationID;     /* application id for UserAttr interpretation */
    WORD    Spare;              /* PreR6: spare
                                ** R6: This now conveys the length of a single
                                ** SCHED_ENTRY_xxx that follows.  Use this value
                                ** to skip entries that MAY be larger (ie: R7
                                ** extends SCHED_ENTRY_EXT by appending values
                                ** that R6 does not know about so SCHED_ENTRY_xxx
                                ** would actually be larger than the R6
                                ** SCHED_ENTRY_EXT
                                */
                                /* Now come the schedule entries...
                                ** IFF Spare==0 then SCHED_ENTRYs follow
                                ** Otherwise Spare==the length of the
                                ** SCHED_ENTRY_EXTs that follow
                                */
} SCHED_LIST;

/* Scheduling busy time entry */

typedef struct {
    UNID            Unid;       /* UNID of the entry */
    TIMEDATE_PAIR   Interval;   /* Interval of the entry */
    BYTE            Attr;       /* SCHED_ATTR_xxx attributes defined by Notes */
    BYTE            UserAttr;   /* Application specific attributes */
    BYTE            spare[2];
} SCHED_ENTRY;

/* R6 scheduling busy time entry */

typedef struct {
    UNID            Unid;       /* UNID of the entry */
    TIMEDATE_PAIR   Interval;   /* Interval of the entry */
    BYTE            Attr;       /* SCHED_ATTR_xxx attributes defined by Notes */
    BYTE            UserAttr;   /* Application specific attributes */
    BYTE            spare[2];

    /* Everything above this point is the same as SCHED_ENTRY for preR6 clients!
    ** Everything from here on down is R6 (or later) only!
    */

    UNID            ApptUnid;   /* ApptUNID of the entry */
    DWORD           dwEntrySize;/* Size of this entry (for future ease of expansion) */
    GEO_INFO        GEOInfo;    /* Geographical coordinates of the entry */
} SCHED_ENTRY_EXT;

/* R6 Detailed busytime information is harvested and stored in a fairly
** compact manner thanks to length encoding of everything.  The format
** is basically:
**
**  SCHED_DETAIL_LIST (Detail list prefix header)
**  TEXT_LIST (of items that harvested and whose info follows)
**  SCHED_DETAIL_ENTRY (Actual harvested info per UNID)
**
** Since it may be desirable in the future to extend the detail format
** the SCHED_DETAIL_xxx structures are length encoded.  Any additional
** SCHED_DETAIL_LIST (or 'overhead') extensions MUST be inserted between
** the TEXT_LIST and the SCHED_DETAIL_ENTRY.  Any additional
** SCHED_DETAIL_ENTRY extensions MUST be inserted at the end of the
** structure so that they can easily be trimmed off by older clients.
**
** Minor clarification for those nitpickers out there, the SCHED_DETAIL_ENTRY
** is NOT just a single struct but is really composed of 2 parts, a
** 'prefix' that contains all info common to that detail (ie: entry
** UNID or flags) and then the actual data in an encoded form.  That
** form is described in greater detail below.  A hierarchical view
** of how the data is organzied (where indenting is used to
** semi-convey 'containment') when 3 items are harvested for 2 UNIDs
** would be:
**
**  SCHED_DETAIL_LIST (Detail list header)
**      TEXT_LIST (of 3 item names that were harvested)
**      SCHED_DETAIL_ENTRY (Actual harvested info for UNID1)
**          SCHED_DETAIL_DATA (Actual item data)
**          SCHED_DETAIL_DATA (Actual item data)
**          SCHED_DETAIL_DATA (Actual item data)
**      SCHED_DETAIL_ENTRY (Actual harvested info for UNID2)
**          SCHED_DETAIL_DATA (Actual item data)
**          SCHED_DETAIL_DATA (Actual item data)
**          SCHED_DETAIL_DATA (Actual item data)
**
*/

/* Flags used on SCHED_DETAIL_LIST */

#define SCHED_DETAIL_LIST_ATTR_NODATA           0x01 /* List has no data */
#define SCHED_DETAIL_LIST_ATTR_RESERVED2        0x02
#define SCHED_DETAIL_LIST_ATTR_RESERVED3        0x04
#define SCHED_DETAIL_LIST_ATTR_RESERVED4        0x08
#define SCHED_DETAIL_LIST_ATTR_RESERVED5        0x10
#define SCHED_DETAIL_LIST_ATTR_RESERVED6        0x20
#define SCHED_DETAIL_LIST_ATTR_RESERVED7        0x40
#define SCHED_DETAIL_LIST_ATTR_RESERVED8        0x80

/* R6 Schedule detail list header */

typedef struct {
    WORD        wHeaderLen;     /* Length of THIS header, in case it
                                ** ever grows, so that new items can be
                                ** easily skipped
                                */
    WORD        wEntryLen;      /* Length of THIS entire list and ALL of
                                ** its related data.
                                */
    WORD        wNumEntries;    /* Number of entries that follow */
    WORD        wOffsetItems;   /* Offset from list start to TEXT_LIST */
    WORD        wOffsetDetails; /* Offset from list start to SCHED_DETAIL_ENTRY */
    BYTE        Attr;           /* SCHED_DETAIL_LIST_ATTR_xxx attributes */
    BYTE        bReserved;      /* Reserved space/padding for ODS */

    /* Now comes the TEXT_LIST that corresponds to the item names
    ** and then comes the SCHED_DETAIL_ENTRY for each UNID
    */
} SCHED_DETAIL_LIST;

/* Flags used on SCHED_DETAIL_ENTRY */

#define SCHED_DETAIL_ENTRY_ATTR_PRIVATE         0x01    /* Entry is private */
#define SCHED_DETAIL_ENTRY_ATTR_RESERVED2       0x02
#define SCHED_DETAIL_ENTRY_ATTR_RESERVED3       0x04
#define SCHED_DETAIL_ENTRY_ATTR_RESERVED4       0x08
#define SCHED_DETAIL_ENTRY_ATTR_RESERVED5       0x10
#define SCHED_DETAIL_ENTRY_ATTR_RESERVED6       0x20
#define SCHED_DETAIL_ENTRY_ATTR_RESERVED7       0x40
#define SCHED_DETAIL_ENTRY_ATTR_RESERVED8       0x80

/* R6 Schedule detail list entry */

typedef struct {
    WORD        wPrefixLen;     /* Length of THIS prefix entry, in case it
                                ** ever grows, so that new items can be
                                ** easily skipped
                                */
    WORD        wEntryLen;      /* Length of THIS entire entry and ALL of
                                ** its related data.
                                */
    UNID        Unid;           /* UNID of the entry this is details of */
    WORD        wOffsetDetails; /* Offset from entry start to actual data */
    BYTE        Attr;           /* SCHED_DETAIL_ENTRY_ATTR_xxx attributes (TBD) */
    BYTE        bReserved;      /* Reserved space/padding for ODS */

    /* Now comes the data that corresponds to the item values (1 per item name)
    ** UNLESS dwEntryLen == wPrefixLen (which means NO details available
    ** for this UNID)
    */
} SCHED_DETAIL_ENTRY;

/* Flags used on SCHED_DETAIL_DATA */

#define SCHED_DETAIL_DATA_ATTR_TRUNCATED        0x01 /* Used to indicate value is trunated */
#define SCHED_DETAIL_DATA_ATTR_NOTFOUND         0x02 /* Item/value not found */
#define SCHED_DETAIL_DATA_ATTR_RESERVED3        0x04
#define SCHED_DETAIL_DATA_ATTR_RESERVED4        0x08
#define SCHED_DETAIL_DATA_ATTR_RESERVED5        0x10
#define SCHED_DETAIL_DATA_ATTR_RESERVED6        0x20
#define SCHED_DETAIL_DATA_ATTR_RESERVED7        0x40
#define SCHED_DETAIL_DATA_ATTR_RESERVED8        0x80

/* R6 Schedule detail list actual data */

typedef struct {
    WORD        wType;          /* Notes data type for the data */
    WORD        wDataLen;       /* Length of the data that immediately follows */
    BYTE        Attr;           /* SCHED_DETAIL_DATA_ATTR_xxx attributes */
    BYTE        bReserved;      /* Reserved space/padding for ODS */

    /* Now comes the actual data that corresponds to the item values */
} SCHED_DETAIL_DATA;

/* Since we have new structs for R6, we have to have new MAXSCHEDxxx values */

#define MAXSCHEDLISTEXTSIZE         ( MAXONESEGSIZE - 100 * sizeof(SCHED_ENTRY_EXT) )
#define MAXENTRIESPERSCHEDLISTEXT   ( ( MAXSCHEDLISTEXTSIZE - sizeof(SCHED_LIST) ) / sizeof(SCHED_ENTRY_EXT) )

/* The Attr field contains these bits.  Note that if bit3 is set
** then the entry will take up busy time.
** The lower nibble of the attributes defines the the entry type.
** NOTE: We are reserving the upper 4 bits of the Attr field for future use.

*/
#define SCHED_ATTR_FOREIGN_UNID 	0x10 /* Used by gateways to return foreign UNIDs */
#define SCHED_ATTR_REPEAT_EVENT 	0x20 /* Used by V5 C&S to identify new repeating meetings */
#define SCHED_ATTR_RESERVED4		0x40
#define SCHED_ATTR_RESERVED8    	0x80

/* these are the entry type bits */
#define SCHED_ATTR_TYPE_BITS    0x0F
#define SCHED_ATTR_FREE_BASE    0x00
#define SCHED_ATTR_BUSY_BASE    0x08

/* Entry types that don't block off busy time */
#define SCHED_ATTR_NULL             (SCHED_ATTR_FREE_BASE + 0x00)
#define SCHED_ATTR_PENCILED         (SCHED_ATTR_FREE_BASE + 0x01)
#define SCHED_ATTR_FREE_RESERVED2   (SCHED_ATTR_FREE_BASE + 0x02)
#define SCHED_ATTR_FREE_RESERVED3   (SCHED_ATTR_FREE_BASE + 0x03)
#define SCHED_ATTR_FREE_RESERVED4   (SCHED_ATTR_FREE_BASE + 0x04)
#define SCHED_ATTR_FREE_RESERVED5   (SCHED_ATTR_FREE_BASE + 0x05)
#define SCHED_ATTR_FREE_RESERVED6   (SCHED_ATTR_FREE_BASE + 0x06)
#define SCHED_ATTR_FREE_RESERVED7   (SCHED_ATTR_FREE_BASE + 0x07)

/* Entry types that block off busy time */
#define SCHED_ATTR_APPT             (SCHED_ATTR_BUSY_BASE + 0x00)
#define SCHED_ATTR_NONWORK          (SCHED_ATTR_BUSY_BASE + 0x01)
#define SCHED_ATTR_BUSY_RESERVED2   (SCHED_ATTR_BUSY_BASE + 0x02)
#define SCHED_ATTR_BUSY_RESERVED3   (SCHED_ATTR_BUSY_BASE + 0x03)
#define SCHED_ATTR_BUSY_RESERVED4   (SCHED_ATTR_BUSY_BASE + 0x04)
#define SCHED_ATTR_BUSY_RESERVED5   (SCHED_ATTR_BUSY_BASE + 0x05)
#define SCHED_ATTR_BUSY_RESERVED6   (SCHED_ATTR_BUSY_BASE + 0x06)
#define SCHED_ATTR_BUSY_RESERVED7   (SCHED_ATTR_BUSY_BASE + 0x07)


#define SCHED_ATTR_TYPE(attr) ((attr) & SCHED_ATTR_TYPE_BITS)
#define SCHED_ATTR_AVAILABLE(attr) (!((attr) & SCHED_ATTR_BUSY_BASE))


/* Function templates */


STATUS LNPUBLIC   NSFTranslateSpecial(void far *InputString,
							WORD InputStringLength,
							void far *OutputString,
							WORD OutputStringBufferLength,
							NOTEID NoteID,
							void far *IndexPosition,
							INDEXSPECIALINFO far *IndexInfo,
							HANDLE hUnreadList,
							HANDLE hCollapsedList,
							char far *FileTitle,
							char far *ViewTitle,
							WORD far *retLength);

/* End of Note Storage File Data Definitions */

#ifdef __cplusplus
}
#endif


#endif

#if defined(OS400) && (__OS400_TGTVRM__ >= 510)
#pragma datamodel(pop)
#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -