public static extern unsafe SafeObjectHandle CreateThread( SECURITY_ATTRIBUTES *lpThreadAttributes, SIZE_T dwStackSize, THREAD_START_ROUTINE lpStartAddress, IntPtr lpParameter, CreateProcessFlags dwCreationFlags, int *lpThreadId);
internal static unsafe bool CreateDirectory(string path, SECURITY_ATTRIBUTES *lpSecurityAttributes) { // We always want to add for CreateDirectory to get around the legacy 248 character limitation path = PathInternal.EnsureExtendedPrefix(path); return(CreateDirectoryPrivate(path, lpSecurityAttributes)); }
private static extern unsafe SafeFileHandle CreateFilePrivate( string lpFileName, int dwDesiredAccess, FileShare dwShareMode, SECURITY_ATTRIBUTES *lpSecurityAttributes, FileMode dwCreationDisposition, int dwFlagsAndAttributes, IntPtr hTemplateFile);
public unsafe static extern SafeFileHandle CreateFileW( string lpFileName, DesiredAccess dwDesiredAccess, ShareModes dwShareMode, SECURITY_ATTRIBUTES *lpSecurityAttributes, CreationDisposition dwCreationDisposition, uint dwFlagsAndAttributes, IntPtr hTemplateFile);
private static unsafe partial IntPtr CreateFilePrivate_IntPtr( string lpFileName, int dwDesiredAccess, FileShare dwShareMode, SECURITY_ATTRIBUTES *lpSecurityAttributes, FileMode dwCreationDisposition, int dwFlagsAndAttributes, IntPtr hTemplateFile);
public unsafe static extern PipeHandle CreateNamedPipeW( string lpName, uint dwOpenMode, uint dwPipeMode, uint nMaxInstances, uint nOutBufferSize, uint nInBufferSize, uint nDefaultTimeOut, SECURITY_ATTRIBUTES *lpSecurityAttributes);
unsafe static extern System.Int32 FilterConnectCommunicationPort ( [MarshalAs(UnmanagedType.LPWStr)] System.String lpPortName, System.UInt32 dwOptions, System.IntPtr lpContext, System.UInt16 dwSizeOfContext, SECURITY_ATTRIBUTES *lpSecurityAttributes, System.IntPtr *hPort );
unsafe static extern bool CreateProcessAsUser( IntPtr hToken, string lpApplicationName, string lpCommandLine, SECURITY_ATTRIBUTES *lpProcessAttributes, SECURITY_ATTRIBUTES *lpThreadAttributes, bool bInheritHandles, uint dwCreationFlags, IntPtr lpEnvironment, string lpCurrentDirectory, ref STARTUPINFO lpStartupInfo, out PROCESS_INFORMATION lpProcessInformation);
internal static unsafe SafeFileHandle CreateFile( string lpFileName, int dwDesiredAccess, FileShare dwShareMode, SECURITY_ATTRIBUTES *lpSecurityAttributes, FileMode dwCreationDisposition, int dwFlagsAndAttributes, IntPtr hTemplateFile) { lpFileName = PathInternal.EnsureExtendedPrefixIfNeeded(lpFileName); return(CreateFilePrivate(lpFileName, dwDesiredAccess, dwShareMode, lpSecurityAttributes, dwCreationDisposition, dwFlagsAndAttributes, hTemplateFile)); }
/// <inheritdoc cref="CreateFile(char*, ACCESS_MASK, FileShare, SECURITY_ATTRIBUTES*, CreationDisposition, CreateFileFlags, SafeObjectHandle)"/> /// <devremarks> /// This should be removed as part of delivering <see href="https://github.com/dotnet/pinvoke/issues/286">the string-overload codegen feature</see>. /// </devremarks> public static unsafe SafeObjectHandle CreateFile( string filename, ACCESS_MASK access, FileShare share, [Friendly(FriendlyFlags.In | FriendlyFlags.Optional)] SECURITY_ATTRIBUTES *securityAttributes, CreationDisposition creationDisposition, CreateFileFlags flagsAndAttributes, SafeObjectHandle templateFile) { fixed(char *pFileName = filename) { return(CreateFile(pFileName, access, share, securityAttributes, creationDisposition, flagsAndAttributes, templateFile)); } }
private static unsafe IntPtr CreateFile( string lpFileName, int dwDesiredAccess, FileShare dwShareMode, SECURITY_ATTRIBUTES *securityAttrs, FileMode dwCreationDisposition, int dwFlagsAndAttributes, IntPtr hTemplateFile) { CREATEFILE2_EXTENDED_PARAMETERS parameters; parameters.dwSize = (uint)Marshal.SizeOf <CREATEFILE2_EXTENDED_PARAMETERS>(); parameters.dwFileAttributes = (uint)dwFlagsAndAttributes & 0x0000FFFF; parameters.dwSecurityQosFlags = (uint)dwFlagsAndAttributes & 0x000F0000; parameters.dwFileFlags = (uint)dwFlagsAndAttributes & 0xFFF00000; parameters.hTemplateFile = hTemplateFile; parameters.lpSecurityAttributes = securityAttrs; return(CreateFile2(lpFileName, dwDesiredAccess, dwShareMode, dwCreationDisposition, ref parameters)); }
public int CreateSharedHandle([NativeTypeName("IInspectable *")] IInspectable *pObject, [NativeTypeName("const SECURITY_ATTRIBUTES *")] SECURITY_ATTRIBUTES *pSecurityAttributes, [NativeTypeName("DWORD")] uint Access, [NativeTypeName("HSTRING")] IntPtr Name, [NativeTypeName("HANDLE *")] IntPtr *pHandle) { return(((delegate * unmanaged <IDisplayDeviceInterop *, IInspectable *, SECURITY_ATTRIBUTES *, uint, IntPtr, IntPtr *, int>)(lpVtbl[3]))((IDisplayDeviceInterop *)Unsafe.AsPointer(ref this), pObject, pSecurityAttributes, Access, Name, pHandle)); }
public static extern HANDLE CreateTransaction([NativeTypeName("LPSECURITY_ATTRIBUTES")] SECURITY_ATTRIBUTES *lpTransactionAttributes, [NativeTypeName("LPGUID")] Guid *UOW, [NativeTypeName("DWORD")] uint CreateOptions, [NativeTypeName("DWORD")] uint IsolationLevel, [NativeTypeName("DWORD")] uint IsolationFlags, [NativeTypeName("DWORD")] uint Timeout, [NativeTypeName("LPWSTR")] ushort *Description);
public static extern HRESULT DCompositionCreateSurfaceHandle([NativeTypeName("DWORD")] uint desiredAccess, SECURITY_ATTRIBUTES *securityAttributes, HANDLE *surfaceHandle);
public static extern unsafe SafeObjectHandle CreateMutex( [Friendly(FriendlyFlags.Optional | FriendlyFlags.In)] SECURITY_ATTRIBUTES *lpMutexAttributes, [MarshalAs(UnmanagedType.Bool)] bool bInitialOwner, string lpName);
public static extern HANDLE CreateFileMappingW(HANDLE hFile, [NativeTypeName("LPSECURITY_ATTRIBUTES")] SECURITY_ATTRIBUTES* lpFileMappingAttributes, [NativeTypeName("DWORD")] uint flProtect, [NativeTypeName("DWORD")] uint dwMaximumSizeHigh, [NativeTypeName("DWORD")] uint dwMaximumSizeLow, [NativeTypeName("LPCWSTR")] ushort* lpName);
public unsafe static extern SafeMailslotHandle CreateMailslotW( string lpName, uint nMaxMessageSize, uint lReadTimeout, SECURITY_ATTRIBUTES *lpSecurityAttributes);
public static extern HANDLE CreateFileMappingFromApp(HANDLE hFile, [NativeTypeName("PSECURITY_ATTRIBUTES")] SECURITY_ATTRIBUTES* SecurityAttributes, [NativeTypeName("ULONG")] uint PageProtection, [NativeTypeName("ULONG64")] ulong MaximumSize, [NativeTypeName("PCWSTR")] ushort* Name);
public static unsafe extern EventHandle CreateEventW( SECURITY_ATTRIBUTES *lpEventAttributes, bool bManualReset, bool bInitialState, string lpName);
public static extern int CreateDirectoryW([NativeTypeName("LPCWSTR")] ushort *lpPathName, [NativeTypeName("LPSECURITY_ATTRIBUTES")] SECURITY_ATTRIBUTES *lpSecurityAttributes);
public static extern IntPtr CreatePrivateNamespaceW([NativeTypeName("LPSECURITY_ATTRIBUTES")] SECURITY_ATTRIBUTES *lpPrivateNamespaceAttributes, [NativeTypeName("LPVOID")] void *lpBoundaryDescriptor, [NativeTypeName("LPCWSTR")] ushort *lpAliasPrefix);
public static extern IntPtr CreateFileW([NativeTypeName("LPCWSTR")] ushort *lpFileName, [NativeTypeName("DWORD")] uint dwDesiredAccess, [NativeTypeName("DWORD")] uint dwShareMode, [NativeTypeName("LPSECURITY_ATTRIBUTES")] SECURITY_ATTRIBUTES *lpSecurityAttributes, [NativeTypeName("DWORD")] uint dwCreationDisposition, [NativeTypeName("DWORD")] uint dwFlagsAndAttributes, [NativeTypeName("HANDLE")] IntPtr hTemplateFile);
public static extern int DCompositionCreateSurfaceHandle([NativeTypeName("DWORD")] uint desiredAccess, [NativeTypeName("SECURITY_ATTRIBUTES *")] SECURITY_ATTRIBUTES *securityAttributes, [NativeTypeName("HANDLE *")] IntPtr *surfaceHandle);
public unsafe static extern bool CreatePipe( out SafeFileHandle hReadPipe, out SafeFileHandle hWritePipe, SECURITY_ATTRIBUTES *lpPipeAttributes, uint nSize);
public int CreateSharedHandle([NativeTypeName("const SECURITY_ATTRIBUTES *")] SECURITY_ATTRIBUTES *pAttributes, [NativeTypeName("DWORD")] uint dwAccess, [NativeTypeName("LPCWSTR")] ushort *lpName, [NativeTypeName("HANDLE *")] IntPtr *pHandle) { return(((delegate * unmanaged <IDXGIResource1 *, SECURITY_ATTRIBUTES *, uint, ushort *, IntPtr *, int>)(lpVtbl[13]))((IDXGIResource1 *)Unsafe.AsPointer(ref this), pAttributes, dwAccess, lpName, pHandle)); }
public static extern HANDLE CreateFileMapping2(HANDLE File, SECURITY_ATTRIBUTES* SecurityAttributes, [NativeTypeName("ULONG")] uint DesiredAccess, [NativeTypeName("ULONG")] uint PageProtection, [NativeTypeName("ULONG")] uint AllocationAttributes, [NativeTypeName("ULONG64")] ulong MaximumSize, [NativeTypeName("PCWSTR")] ushort* Name, MEM_EXTENDED_PARAMETER* ExtendedParameters, [NativeTypeName("ULONG")] uint ParameterCount);
public int CreateSharedHandle([NativeTypeName("ID3D12DeviceChild *")] ID3D12DeviceChild *pObject, [NativeTypeName("const SECURITY_ATTRIBUTES *")] SECURITY_ATTRIBUTES *pAttributes, [NativeTypeName("DWORD")] uint Access, [NativeTypeName("LPCWSTR")] ushort *Name, [NativeTypeName("HANDLE *")] IntPtr *pHandle) { return(((delegate * unmanaged <ID3D12Device *, ID3D12DeviceChild *, SECURITY_ATTRIBUTES *, uint, ushort *, IntPtr *, int>)(lpVtbl[31]))((ID3D12Device *)Unsafe.AsPointer(ref this), pObject, pAttributes, Access, Name, pHandle)); }
public static extern IntPtr CreateJobObjectW([NativeTypeName("LPSECURITY_ATTRIBUTES")] SECURITY_ATTRIBUTES *lpJobAttributes, [NativeTypeName("LPCWSTR")] ushort *lpName);
public static extern IntPtr CreateConsoleScreenBuffer([NativeTypeName("DWORD")] uint dwDesiredAccess, [NativeTypeName("DWORD")] uint dwShareMode, [NativeTypeName("const SECURITY_ATTRIBUTES *")] SECURITY_ATTRIBUTES *lpSecurityAttributes, [NativeTypeName("DWORD")] uint dwFlags, [NativeTypeName("LPVOID")] void *lpScreenBufferData);
public static extern HANDLE CreateTransactionManager([NativeTypeName("LPSECURITY_ATTRIBUTES")] SECURITY_ATTRIBUTES *lpTransactionAttributes, [NativeTypeName("LPWSTR")] ushort *LogFileName, [NativeTypeName("ULONG")] uint CreateOptions, [NativeTypeName("ULONG")] uint CommitStrength);