Fixed a number of interfaces in SearchApi that had properties in wrong order which caused memory access violations

pull/332/head
dahall 2021-04-05 09:34:52 -06:00
parent 6ede43cde1
commit aab989639c
1 changed files with 78 additions and 253 deletions

View File

@ -1466,7 +1466,7 @@ namespace Vanara.PInvoke
// put_ConnectTimeout( DWORD dwConnectTimeout ); // put_ConnectTimeout( DWORD dwConnectTimeout );
[PInvokeData("searchapi.h")] [PInvokeData("searchapi.h")]
[DispId(0x60010008)] [DispId(0x60010008)]
uint ConnectTimeout { get; [param: In] set; } uint ConnectTimeout { [param: In] set; get; }
/// <summary> /// <summary>
/// Sets the time-out value for data transactions between the indexer and the search filter host. This information is stored in /// Sets the time-out value for data transactions between the indexer and the search filter host. This information is stored in
@ -1484,7 +1484,7 @@ namespace Vanara.PInvoke
// put_DataTimeout( DWORD dwDataTimeout ); // put_DataTimeout( DWORD dwDataTimeout );
[PInvokeData("searchapi.h")] [PInvokeData("searchapi.h")]
[DispId(0x6001000a)] [DispId(0x6001000a)]
uint DataTimeout { get; [param: In] set; } uint DataTimeout { [param: In] set; get; }
/// <summary>Gets the number of items in the catalog.</summary> /// <summary>Gets the number of items in the catalog.</summary>
/// <returns> /// <returns>
@ -1649,7 +1649,7 @@ namespace Vanara.PInvoke
// HRESULT put_DiacriticSensitivity( BOOL fDiacriticSensitive ); // HRESULT put_DiacriticSensitivity( BOOL fDiacriticSensitive );
[PInvokeData("searchapi.h")] [PInvokeData("searchapi.h")]
[DispId(0x60010017)] [DispId(0x60010017)]
int DiacriticSensitivity { get; [param: In] set; } int DiacriticSensitivity { [param: In] set; get; }
/// <summary>Gets an ISearchCrawlScopeManager interface for this search catalog.</summary> /// <summary>Gets an ISearchCrawlScopeManager interface for this search catalog.</summary>
/// <returns> /// <returns>
@ -1784,7 +1784,7 @@ namespace Vanara.PInvoke
// put_ConnectTimeout( DWORD dwConnectTimeout ); // put_ConnectTimeout( DWORD dwConnectTimeout );
[PInvokeData("searchapi.h")] [PInvokeData("searchapi.h")]
[DispId(0x60010008)] [DispId(0x60010008)]
new uint ConnectTimeout { get; [param: In] set; } new uint ConnectTimeout { [param: In] set; get; }
/// <summary> /// <summary>
/// Sets the time-out value for data transactions between the indexer and the search filter host. This information is stored in /// Sets the time-out value for data transactions between the indexer and the search filter host. This information is stored in
@ -1802,7 +1802,7 @@ namespace Vanara.PInvoke
// put_DataTimeout( DWORD dwDataTimeout ); // put_DataTimeout( DWORD dwDataTimeout );
[PInvokeData("searchapi.h")] [PInvokeData("searchapi.h")]
[DispId(0x6001000a)] [DispId(0x6001000a)]
new uint DataTimeout { get; [param: In] set; } new uint DataTimeout { [param: In] set; get; }
/// <summary>Gets the number of items in the catalog.</summary> /// <summary>Gets the number of items in the catalog.</summary>
/// <returns> /// <returns>
@ -1967,7 +1967,7 @@ namespace Vanara.PInvoke
// HRESULT put_DiacriticSensitivity( BOOL fDiacriticSensitive ); // HRESULT put_DiacriticSensitivity( BOOL fDiacriticSensitive );
[PInvokeData("searchapi.h")] [PInvokeData("searchapi.h")]
[DispId(0x60010017)] [DispId(0x60010017)]
new int DiacriticSensitivity { get; [param: In] set; } new int DiacriticSensitivity { [param: In] set; get; }
/// <summary>Gets an ISearchCrawlScopeManager interface for this search catalog.</summary> /// <summary>Gets an ISearchCrawlScopeManager interface for this search catalog.</summary>
/// <returns> /// <returns>
@ -4090,7 +4090,7 @@ namespace Vanara.PInvoke
// put_QueryContentLocale( LCID lcid ); // put_QueryContentLocale( LCID lcid );
[PInvokeData("searchapi.h")] [PInvokeData("searchapi.h")]
[DispId(0x60010001)] [DispId(0x60010001)]
uint QueryContentLocale { get; [param: In] set; } uint QueryContentLocale { [param: In] set; get; }
/// <summary> /// <summary>
/// Gets or sets the language code identifier (LCID) for the locale to use when parsing Advanced Query Syntax (AQS) keywords. /// Gets or sets the language code identifier (LCID) for the locale to use when parsing Advanced Query Syntax (AQS) keywords.
@ -4104,7 +4104,7 @@ namespace Vanara.PInvoke
// put_QueryKeywordLocale( LCID lcid ); // put_QueryKeywordLocale( LCID lcid );
[PInvokeData("searchapi.h")] [PInvokeData("searchapi.h")]
[DispId(0x60010003)] [DispId(0x60010003)]
uint QueryKeywordLocale { get; [param: In] set; } uint QueryKeywordLocale { [param: In] set; get; }
/// <summary>Gets or sets a value that specifies how query terms are to be expanded.</summary> /// <summary>Gets or sets a value that specifies how query terms are to be expanded.</summary>
/// <value> /// <value>
@ -4128,7 +4128,7 @@ namespace Vanara.PInvoke
// put_QueryTermExpansion( SEARCH_TERM_EXPANSION expandTerms ); // put_QueryTermExpansion( SEARCH_TERM_EXPANSION expandTerms );
[PInvokeData("searchapi.h")] [PInvokeData("searchapi.h")]
[DispId(0x60010005)] [DispId(0x60010005)]
SEARCH_TERM_EXPANSION QueryTermExpansion { get; [param: In] set; } SEARCH_TERM_EXPANSION QueryTermExpansion { [param: In] set; get; }
/// <summary>Gets or sets the syntax of the query.</summary> /// <summary>Gets or sets the syntax of the query.</summary>
/// <value> /// <value>
@ -4151,7 +4151,7 @@ namespace Vanara.PInvoke
// put_QuerySyntax( SEARCH_QUERY_SYNTAX querySyntax ); // put_QuerySyntax( SEARCH_QUERY_SYNTAX querySyntax );
[PInvokeData("searchapi.h")] [PInvokeData("searchapi.h")]
[DispId(0x60010007)] [DispId(0x60010007)]
SEARCH_QUERY_SYNTAX QuerySyntax { get; [param: In] set; } SEARCH_QUERY_SYNTAX QuerySyntax { [param: In] set; get; }
/// <summary>Gets or sets the properties to include in the query if search terms do not explicitly specify properties.</summary> /// <summary>Gets or sets the properties to include in the query if search terms do not explicitly specify properties.</summary>
/// <value> /// <value>
@ -4176,7 +4176,7 @@ namespace Vanara.PInvoke
// HRESULT put_QueryContentProperties( LPCWSTR pszContentProperties ); // HRESULT put_QueryContentProperties( LPCWSTR pszContentProperties );
[PInvokeData("searchapi.h")] [PInvokeData("searchapi.h")]
[DispId(0x60010009)] [DispId(0x60010009)]
string QueryContentProperties { [return: MarshalAs(UnmanagedType.LPWStr)] get; [param: In, MarshalAs(UnmanagedType.LPWStr)] set; } string QueryContentProperties { [param: In, MarshalAs(UnmanagedType.LPWStr)] set; [return: MarshalAs(UnmanagedType.LPWStr)] get; }
/// <summary>Gets or sets the columns (or properties) requested in the select statement.</summary> /// <summary>Gets or sets the columns (or properties) requested in the select statement.</summary>
/// <value> /// <value>
@ -4199,7 +4199,7 @@ namespace Vanara.PInvoke
// put_QuerySelectColumns( LPCWSTR pszSelectColumns ); // put_QuerySelectColumns( LPCWSTR pszSelectColumns );
[PInvokeData("searchapi.h")] [PInvokeData("searchapi.h")]
[DispId(0x6001000b)] [DispId(0x6001000b)]
string QuerySelectColumns { [return: MarshalAs(UnmanagedType.LPWStr)] get; [param: In, MarshalAs(UnmanagedType.LPWStr)] set; } string QuerySelectColumns { [param: In, MarshalAs(UnmanagedType.LPWStr)] set; [return: MarshalAs(UnmanagedType.LPWStr)] get; }
/// <summary>Gets or sets the restrictions appended to a query in WHERE clauses.</summary> /// <summary>Gets or sets the restrictions appended to a query in WHERE clauses.</summary>
/// <value> /// <value>
@ -4223,7 +4223,7 @@ namespace Vanara.PInvoke
// HRESULT put_QueryWhereRestrictions( LPCWSTR pszRestrictions ); // HRESULT put_QueryWhereRestrictions( LPCWSTR pszRestrictions );
[PInvokeData("searchapi.h")] [PInvokeData("searchapi.h")]
[DispId(0x6001000d)] [DispId(0x6001000d)]
string QueryWhereRestrictions { [return: MarshalAs(UnmanagedType.LPWStr)] get; [param: In, MarshalAs(UnmanagedType.LPWStr)] set; } string QueryWhereRestrictions { [param: In, MarshalAs(UnmanagedType.LPWStr)] set; [return: MarshalAs(UnmanagedType.LPWStr)] get; }
/// <summary>Sets the sort order for the query result set.</summary> /// <summary>Sets the sort order for the query result set.</summary>
/// <value> /// <value>
@ -4243,7 +4243,7 @@ namespace Vanara.PInvoke
// put_QuerySorting( LPCWSTR pszSorting ); // put_QuerySorting( LPCWSTR pszSorting );
[PInvokeData("searchapi.h")] [PInvokeData("searchapi.h")]
[DispId(0x6001000f)] [DispId(0x6001000f)]
string QuerySorting { [return: MarshalAs(UnmanagedType.LPWStr)] get; [param: In, MarshalAs(UnmanagedType.LPWStr)] set; } string QuerySorting { [param: In, MarshalAs(UnmanagedType.LPWStr)] set; [return: MarshalAs(UnmanagedType.LPWStr)] get; }
/// <summary> /// <summary>
/// Generates a Structured Query Language (SQL) query based on a client-supplied query string expressed in either Advanced Query /// Generates a Structured Query Language (SQL) query based on a client-supplied query string expressed in either Advanced Query
@ -4331,7 +4331,7 @@ namespace Vanara.PInvoke
// put_QueryMaxResults( LONG cMaxResults ); // put_QueryMaxResults( LONG cMaxResults );
[PInvokeData("searchapi.h")] [PInvokeData("searchapi.h")]
[DispId(0x60010013)] [DispId(0x60010013)]
int QueryMaxResults { get; [param: In] set; } int QueryMaxResults { [param: In] set; get; }
} }
/// <summary> /// <summary>
@ -4347,130 +4347,53 @@ namespace Vanara.PInvoke
[ComImport, InterfaceType(ComInterfaceType.InterfaceIsIUnknown), Guid("04C18CCF-1F57-4CBD-88CC-3900F5195CE3"), CoClass(typeof(CSearchRoot))] [ComImport, InterfaceType(ComInterfaceType.InterfaceIsIUnknown), Guid("04C18CCF-1F57-4CBD-88CC-3900F5195CE3"), CoClass(typeof(CSearchRoot))]
public interface ISearchRoot public interface ISearchRoot
{ {
/// <summary>Not implemented.</summary> /// <summary>The name of the task to be inserted.</summary>
/// <param name="pszTaskArg"> // https://docs.microsoft.com/en-us/windows/desktop/api/searchapi/nf-searchapi-isearchroot-put_schedule HRESULT put_Schedule(
/// <para>Type: <c>LPCWSTR</c></para>
/// <para>Pointer to a null-terminated, Unicode buffer that contains the name of the task to be inserted.</para>
/// </param>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-put_schedule HRESULT put_Schedule(
// LPCWSTR pszTaskArg ); // LPCWSTR pszTaskArg );
[PInvokeData("searchapi.h", MSDNShortId = "NF:searchapi.ISearchRoot.put_Schedule")] [PInvokeData("searchapi.h", MSDNShortId = "")]
void put_Schedule([MarshalAs(UnmanagedType.LPWStr)] string pszTaskArg); [DispId(0x60010000)]
string Schedule { [param: In, MarshalAs(UnmanagedType.LPWStr)] set; [return: MarshalAs(UnmanagedType.LPWStr)] get; }
/// <summary>Not implemented.</summary>
/// <returns>
/// <para>Type: <c>LPWSTR*</c></para>
/// <para>Returns the address of a pointer to a null-terminated, Unicode buffer that contains the name of the task.</para>
/// </returns>
/// <remarks>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for
/// Crawl Scope Manager (CSM) indexing operations.
/// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-get_schedule HRESULT get_Schedule(
// LPWSTR *ppszTaskArg );
[PInvokeData("searchapi.h", MSDNShortId = "NF:searchapi.ISearchRoot.get_Schedule")]
[return: MarshalAs(UnmanagedType.LPWStr)]
string get_Schedule();
/// <summary>Sets the URL of the current search root.</summary> /// <summary>Sets the URL of the current search root.</summary>
/// <param name="pszURL">
/// <para>Type: <c>LPCWSTR</c></para>
/// <para>Pointer to a null-terminated, Unicode buffer that contains the URL of this search root.</para>
/// </param>
/// <remarks> /// <remarks>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for /// The CrawlScopeCommandLine code sample, available on Code Gallery and the Windows 7 SDK, demonstrates how to define command
/// Crawl Scope Manager (CSM) indexing operations. /// line options for Crawl Scope Manager (CSM) indexing operations.
/// </remarks> /// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-put_rooturl // https://docs.microsoft.com/en-us/windows/desktop/api/searchapi/nf-searchapi-isearchroot-put_rooturl HRESULT put_RootURL(
void put_RootURL([MarshalAs(UnmanagedType.LPWStr)] string pszURL); // LPCWSTR pszURL );
[PInvokeData("searchapi.h")]
/// <summary>Gets the URL of the starting point for this search root.</summary> [DispId(0x60010002)]
/// <returns> string RootURL { [param: In, MarshalAs(UnmanagedType.LPWStr)] set; [return: MarshalAs(UnmanagedType.LPWStr)] get; }
/// <para>Type: <c>LPWSTR*</c></para>
/// <para>A null-terminated, Unicode buffer that contains the URL.</para>
/// </returns>
/// <remarks>
/// <para>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for
/// Crawl Scope Manager (CSM) indexing operations.
/// </para>
/// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-get_rooturl
[return: MarshalAs(UnmanagedType.LPWStr)]
string get_RootURL();
/// <summary>Sets a value that indicates whether the search is rooted on a hierarchical tree structure.</summary> /// <summary>Sets a value that indicates whether the search is rooted on a hierarchical tree structure.</summary>
/// <param name="fIsHierarchical">
/// <para>Type: <c>BOOL</c></para>
/// <para><c>TRUE</c> for hierarchical tree structures, <c>FALSE</c> for non-hierarchical systems such as websites.</para>
/// </param>
/// <remarks> /// <remarks>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for /// The CrawlScopeCommandLine code sample, available on Code Gallery and the Windows 7 SDK, demonstrates how to define command
/// Crawl Scope Manager (CSM) indexing operations. /// line options for Crawl Scope Manager (CSM) indexing operations.
/// </remarks> /// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-put_ishierarchical HRESULT // https://docs.microsoft.com/en-us/windows/desktop/api/searchapi/nf-searchapi-isearchroot-put_ishierarchical HRESULT
// put_IsHierarchical( BOOL fIsHierarchical ); // put_IsHierarchical( BOOL fIsHierarchical );
[PInvokeData("searchapi.h", MSDNShortId = "NF:searchapi.ISearchRoot.put_IsHierarchical")] [PInvokeData("searchapi.h")]
void put_IsHierarchical([MarshalAs(UnmanagedType.Bool)] bool fIsHierarchical); [DispId(0x60010004)]
bool IsHierarchical { [param: In, MarshalAs(UnmanagedType.Bool)] set; [return: MarshalAs(UnmanagedType.Bool)] get; }
/// <summary>Gets a value that indicates whether the search is rooted on a hierarchical tree structure.</summary>
/// <returns>
/// <para>Type: <c>BOOL*</c></para>
/// <para>On return, points to <c>TRUE</c> for hierarchical tree structures, and <c>FALSE</c> for other structures such as websites.</para>
/// </returns>
/// <remarks>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for
/// Crawl Scope Manager (CSM) indexing operations.
/// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-get_ishierarchical HRESULT
// get_IsHierarchical( BOOL *pfIsHierarchical );
[return: MarshalAs(UnmanagedType.Bool)]
bool get_IsHierarchical();
/// <summary> /// <summary>
/// Sets a value that indicates whether the search engine is notified (by protocol handlers or other applications) about changes /// Sets a value that indicates whether the search engine is notified (by protocol handlers or other applications) about changes
/// to the URLs under the search root. /// to the URLs under the search root.
/// </summary> /// </summary>
/// <param name="fProvidesNotifications">
/// <para>Type: <c>BOOL</c></para>
/// <para><c>TRUE</c> if notifications are provided; otherwise, <c>FALSE</c>.</para>
/// </param>
/// <remarks> /// <remarks>
/// <para>That value that <c>ISearchRoot::put_ProvidesNotifications</c> sets is not protocol specific.</para> /// <para>That value that <c>ISearchRoot::put_ProvidesNotifications</c> sets is not protocol specific.</para>
/// <para> /// <para>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for /// The CrawlScopeCommandLine code sample, available on Code Gallery and the Windows 7 SDK, demonstrates how to define command
/// Crawl Scope Manager (CSM) indexing operations. /// line options for Crawl Scope Manager (CSM) indexing operations.
/// </para> /// </para>
/// </remarks> /// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-put_providesnotifications HRESULT // https://docs.microsoft.com/en-us/windows/desktop/api/searchapi/nf-searchapi-isearchroot-put_providesnotifications HRESULT
// put_ProvidesNotifications( BOOL fProvidesNotifications ); // put_ProvidesNotifications( BOOL fProvidesNotifications );
void put_ProvidesNotifications([MarshalAs(UnmanagedType.Bool)] bool fProvidesNotifications); [PInvokeData("searchapi.h")]
[DispId(0x60010006)]
/// <summary> bool ProvidesNotifications { [param: In, MarshalAs(UnmanagedType.Bool)] set; [return: MarshalAs(UnmanagedType.Bool)] get; }
/// Gets a value that indicates whether the search engine is notified (by protocol handlers or other applications) about changes
/// to the URLs under the search root.
/// </summary>
/// <returns>
/// <para>Type: <c>BOOL*</c></para>
/// <para>On return, points to <c>TRUE</c> if this search root provides notifications; otherwise, <c>FALSE</c>.</para>
/// </returns>
/// <remarks>
/// <para>The value <c>ISearchRoot::get_ProvidesNotifications</c> returns is not protocol specific.</para>
/// <para>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for
/// Crawl Scope Manager (CSM) indexing operations.
/// </para>
/// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-get_providesnotifications HRESULT
// get_ProvidesNotifications( BOOL *pfProvidesNotifications );
[return: MarshalAs(UnmanagedType.Bool)]
bool get_ProvidesNotifications();
/// <summary>Sets a value that indicates whether this search root should be indexed only by notification and not crawled.</summary> /// <summary>Sets a value that indicates whether this search root should be indexed only by notification and not crawled.</summary>
/// <param name="fUseNotificationsOnly">
/// <para>Type: <c>BOOL</c></para>
/// <para><c>TRUE</c> if this search root should be indexed only by notification; otherwise, <c>FALSE</c>.</para>
/// </param>
/// <remarks> /// <remarks>
/// <para> /// <para>
/// For search root URLs in a custom data store or on a remote system, it can be useful to limit the search engine to indexing /// For search root URLs in a custom data store or on a remote system, it can be useful to limit the search engine to indexing
@ -4478,179 +4401,81 @@ namespace Vanara.PInvoke
/// the store or across the network by avoiding the incremental crawls when the store is unchanged. /// the store or across the network by avoiding the incremental crawls when the store is unchanged.
/// </para> /// </para>
/// <para> /// <para>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for /// The CrawlScopeCommandLine code sample, available on Code Gallery and the Windows 7 SDK, demonstrates how to define command
/// Crawl Scope Manager (CSM) indexing operations. /// line options for Crawl Scope Manager (CSM) indexing operations.
/// </para> /// </para>
/// </remarks> /// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-put_usenotificationsonly HRESULT // https://docs.microsoft.com/en-us/windows/desktop/api/searchapi/nf-searchapi-isearchroot-put_usenotificationsonly HRESULT
// put_UseNotificationsOnly( BOOL fUseNotificationsOnly ); // put_UseNotificationsOnly( BOOL fUseNotificationsOnly );
void put_UseNotificationsOnly([MarshalAs(UnmanagedType.Bool)] bool fUseNotificationsOnly); [PInvokeData("searchapi.h")]
[DispId(0x60010008)]
/// <summary>Gets a value that indicates whether this search root should be indexed only by notification and not crawled.</summary> bool UseNotificationsOnly { [param: In, MarshalAs(UnmanagedType.Bool)] set; [return: MarshalAs(UnmanagedType.Bool)] get; }
/// <returns>
/// <para>Type: <c>BOOL*</c></para>
/// <para>On return, points to <c>TRUE</c> if this search root should be indexed only by notification; otherwise, <c>FALSE</c>.</para>
/// </returns>
/// <remarks>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for
/// Crawl Scope Manager (CSM) indexing operations.
/// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-get_usenotificationsonly HRESULT
// get_UseNotificationsOnly( BOOL *pfUseNotificationsOnly );
[return: MarshalAs(UnmanagedType.Bool)]
bool get_UseNotificationsOnly();
/// <summary>Sets the enumeration depth for this search root.</summary> /// <summary>Sets the enumeration depth for this search root.</summary>
/// <param name="dwDepth">
/// <para>Type: <c>DWORD</c></para>
/// <para>The depth (number of levels) to enumerate.</para>
/// </param>
/// <remarks> /// <remarks>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for /// The CrawlScopeCommandLine code sample, available on Code Gallery and the Windows 7 SDK, demonstrates how to define command
/// Crawl Scope Manager (CSM) indexing operations. /// line options for Crawl Scope Manager (CSM) indexing operations.
/// </remarks> /// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-put_enumerationdepth HRESULT // https://docs.microsoft.com/en-us/windows/desktop/api/searchapi/nf-searchapi-isearchroot-put_enumerationdepth HRESULT
// put_EnumerationDepth( DWORD dwDepth ); // put_EnumerationDepth( DWORD dwDepth );
void put_EnumerationDepth(uint dwDepth); [PInvokeData("searchapi.h")]
[DispId(0x6001000a)]
/// <summary>Gets the enumeration depth for this search root.</summary> uint EnumerationDepth { [param: In] set; get; }
/// <returns>
/// <para>Type: <c>DWORD*</c></para>
/// <para>A pointer to the depth (number of levels) to enumerate.</para>
/// </returns>
/// <remarks>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for
/// Crawl Scope Manager (CSM) indexing operations.
/// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-get_enumerationdepth HRESULT
// get_EnumerationDepth( DWORD *pdwDepth );
uint get_EnumerationDepth();
/// <summary> /// <summary>
/// <para>[ <c>put_HostDepth</c> may be altered or unavailable in subsequent versions of the operating system or product.]</para> /// <para>[ <c>put_HostDepth</c> may be altered or unavailable in subsequent versions of the operating system or product.]</para>
/// <para>Sets a value that indicates how far into a host tree to crawl when indexing.</para> /// <para>Sets a value that indicates how far into a host tree to crawl when indexing.</para>
/// </summary> /// </summary>
/// <param name="dwDepth">
/// <para>Type: <c>DWORD</c></para>
/// <para>The depth (number of levels) to crawl a host tree.</para>
/// </param>
/// <remarks> /// <remarks>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for /// The CrawlScopeCommandLine code sample, available on Code Gallery and the Windows 7 SDK, demonstrates how to define command
/// Crawl Scope Manager (CSM) indexing operations. /// line options for Crawl Scope Manager (CSM) indexing operations.
/// </remarks> /// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-put_hostdepth HRESULT put_HostDepth( // https://docs.microsoft.com/en-us/windows/desktop/api/searchapi/nf-searchapi-isearchroot-put_hostdepth HRESULT put_HostDepth(
// DWORD dwDepth ); // DWORD dwDepth );
void put_HostDepth(uint dwDepth); [PInvokeData("searchapi.h")]
[DispId(0x6001000c)]
/// <summary> uint HostDepth { [param: In] set; get; }
/// <para>[ <c>get_HostDepth</c> may be altered or unavailable in subsequent versions of the operating system or product.]</para>
/// <para>Gets a value that indicates how far into a host tree to crawl when indexing.</para>
/// </summary>
/// <returns>
/// <para>Type: <c>DWORD*</c></para>
/// <para>On return, points to the depth (number of levels) to crawl in the host tree.</para>
/// </returns>
/// <remarks>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for
/// Crawl Scope Manager (CSM) indexing operations.
/// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-get_hostdepth HRESULT get_HostDepth(
// DWORD *pdwDepth );
uint get_HostDepth();
/// <summary> /// <summary>
/// Sets a <c>BOOL</c> value that indicates whether the search engine should follow subdirectories and hierarchical scopes for /// Sets a <c>BOOL</c> value that indicates whether the search engine should follow subdirectories and hierarchical scopes for
/// this search root. /// this search root.
/// </summary> /// </summary>
/// <param name="fFollowDirectories">
/// <para>Type: <c>BOOL</c></para>
/// <para><c>TRUE</c> to follow directories or hierarchical scopes, otherwise <c>FALSE</c>. The default for this value is <c>TRUE</c>.</para>
/// </param>
/// <remarks> /// <remarks>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for /// The CrawlScopeCommandLine code sample, available on Code Gallery and the Windows 7 SDK, demonstrates how to define command
/// Crawl Scope Manager (CSM) indexing operations. /// line options for Crawl Scope Manager (CSM) indexing operations.
/// </remarks> /// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-put_followdirectories HRESULT // https://docs.microsoft.com/en-us/windows/desktop/api/searchapi/nf-searchapi-isearchroot-put_followdirectories HRESULT
// put_FollowDirectories( BOOL fFollowDirectories ); // put_FollowDirectories( BOOL fFollowDirectories );
void put_FollowDirectories([MarshalAs(UnmanagedType.Bool)] bool fFollowDirectories); [PInvokeData("searchapi.h")]
[DispId(0x6001000e)]
/// <summary>Gets a <c>BOOL</c> value that indicates whether the search engine follows subdirectories and hierarchical scopes.</summary> bool FollowDirectories { [param: In, MarshalAs(UnmanagedType.Bool)] set; [return: MarshalAs(UnmanagedType.Bool)] get; }
/// <returns>
/// <para>Type: <c>BOOL*</c></para>
/// <para>On return, points to <c>TRUE</c> if the search engine follows subdirectories and hierarchical scopes; otherwise, <c>FALSE</c>.</para>
/// </returns>
/// <remarks>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for
/// Crawl Scope Manager (CSM) indexing operations.
/// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-get_followdirectories HRESULT
// get_FollowDirectories( BOOL *pfFollowDirectories );
[return: MarshalAs(UnmanagedType.Bool)]
bool get_FollowDirectories();
/// <summary>Sets the type of authentication required to access the URLs under this search root.</summary> /// <summary>Sets the type of authentication required to access the URLs under this search root.</summary>
/// <param name="authType">
/// <para>Type: <c>AUTH_TYPE</c></para>
/// <para>A value from the AUTH_TYPE enumeration that indicates the authentication type.</para>
/// </param>
/// <remarks> /// <remarks>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for /// The CrawlScopeCommandLine code sample, available on Code Gallery and the Windows 7 SDK, demonstrates how to define command
/// Crawl Scope Manager (CSM) indexing operations. /// line options for Crawl Scope Manager (CSM) indexing operations.
/// </remarks> /// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-put_authenticationtype HRESULT // https://docs.microsoft.com/en-us/windows/desktop/api/searchapi/nf-searchapi-isearchroot-put_authenticationtype HRESULT
// put_AuthenticationType( AUTH_TYPE authType ); // put_AuthenticationType( AUTH_TYPE authType );
void put_AuthenticationType(AUTH_TYPE authType); [PInvokeData("searchapi.h")]
[DispId(0x60010010)]
/// <summary>Retrieves the type of authentication needed to access the URLs under this this search root.</summary> AUTH_TYPE AuthenticationType { [param: In] set; get; }
/// <returns>
/// <para>Type: <c>AUTH_TYPE*</c></para>
/// <para>
/// A pointer to a value from the AUTH_TYPE enumeration that indicates the authentication type required to access URLs under
/// this search root.
/// </para>
/// </returns>
/// <remarks>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for
/// Crawl Scope Manager (CSM) indexing operations.
/// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-get_authenticationtype HRESULT
// get_AuthenticationType( AUTH_TYPE *pAuthType );
AUTH_TYPE get_AuthenticationType();
/// <summary>Not implemented.</summary> /// <summary>Not implemented.</summary>
/// <param name="pszUser">This parameter is unused.</param> // https://docs.microsoft.com/en-us/windows/desktop/api/searchapi/nf-searchapi-isearchroot-put_user HRESULT put_User( LPCWSTR
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-put_user HRESULT put_User( LPCWSTR
// pszUser ); // pszUser );
void put_User([MarshalAs(UnmanagedType.LPWStr)] string pszUser); [PInvokeData("searchapi.h")]
[DispId(0x60010012)]
string User { [param: In, MarshalAs(UnmanagedType.LPWStr)] set; [return: MarshalAs(UnmanagedType.LPWStr)] get; }
/// <summary>Not implemented.</summary> /// <summary>Not implemented.</summary>
/// <returns>This parameter is unused.</returns> // https://docs.microsoft.com/en-us/windows/desktop/api/searchapi/nf-searchapi-isearchroot-put_password HRESULT put_Password(
/// <remarks>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for
/// Crawl Scope Manager (CSM) indexing operations.
/// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-get_user HRESULT get_User( LPWSTR
// *ppszUser );
[return: MarshalAs(UnmanagedType.LPWStr)]
string get_User();
/// <summary>Not implemented.</summary>
/// <param name="pszPassword">This parameter is unused.</param>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-put_password HRESULT put_Password(
// LPCWSTR pszPassword ); // LPCWSTR pszPassword );
void put_Password([MarshalAs(UnmanagedType.LPWStr)] string pszPassword); [PInvokeData("searchapi.h")]
[DispId(0x60010014)]
/// <summary>Not implemented.</summary> string Password { [param: In, MarshalAs(UnmanagedType.LPWStr)] set; [return: MarshalAs(UnmanagedType.LPWStr)] get; }
/// <returns>This parameter is unused.</returns>
/// <remarks>
/// <c>Windows 7 and later</c>: Check out the CrawlScopeCommandLine code sample to see how to define command line options for
/// Crawl Scope Manager (CSM) indexing operations.
/// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/searchapi/nf-searchapi-isearchroot-get_password HRESULT get_Password(
// LPWSTR *ppszPassword );
[return: MarshalAs(UnmanagedType.LPWStr)]
string get_Password();
} }
}
/// <summary>Provides methods to define scope rules for crawling and indexing.</summary> /// <summary>Provides methods to define scope rules for crawling and indexing.</summary>
/// <remarks> /// <remarks>