FindSyncContextFromName function (filehc.h)

Retrieves the FIO_CONTEXT structure that is associated with the specified user name.

Syntax

FILEHC_EXPORT BOOL FindSyncContextFromName(
  [in]  PNAME_CACHE_CONTEXT pNameCache,
  [in]  LPBYTE              lpbName,
  [in]  DWORD               cbName,
  [in]  CACHE_READ_CALLBACK pfnCallback,
  [in]  LPVOID              lpvClientContext,
  [in]  HANDLE              hToken,
  [in]  ACCESS_MASK         accessMask,
  [out] FIO_CONTEXT         **ppContext
);

Parameters

[in] pNameCache

A pointer to the name cache that the client is to use.

[in] lpbName

A pointer to the name of the cached item.

[in] cbName

The size, in bytes, of the value in lpbName.

[in] pfnCallback

A pointer to a FCACHE_READ_CALLBACK function.

Note  If this parameter is NULL, no callback function is called.
 

[in] lpvClientContext

A pointer to the context that is associated with the client. This context is passed to the callback function.

[in] hToken

Request the cache to evaluate the embedded security descriptor. If hToken is zero, it is ignored.

[in] accessMask

The security descriptor data. For more information, see ACCESS_MASK.

[out] ppContext

A pointer to a pointer to the FIO_CONTEXT structure that is associated with the user name.

If the function returns TRUE, this parameter can return a NULL pointer. This occurs when the user passes a NULL FIO_CONTEXT to _AssociateContextWithName.

Return value

Returns TRUE if the name is found in the cache; otherwise, it returns FALSE.

Requirements

Requirement Value
Target Platform Windows
Header filehc.h
Library Fcachdll.lib
DLL Fcachdll.dll

See also

ACCESS_MASK

AssociateContextWithName

FCACHE_READ_CALLBACK

FIO_CONTEXT