网站首页  词典首页

请输入您要查询的函数:

 

术语 gettapeparameters
释义 GetTapeParameters
语法:
C++
DWORD GetTapeParameters(
__in HANDLE hDevice,
__in DWORD dwOperation,
__out LPDWORD lpdwSize,
__out LPVOID lpTapeInformation
);
GetTapeParameters功能
该GetTapeParameters检索信息功能描述磁带或磁带驱动器。
参数
hDevice [in]
句柄有关的信息的要求的设备。这种处理是通过使用CreateFile函数创建。
dwOperation [in]
要求的资料类型。此参数必须是下列值之一。
ValueMeaning
GET_TAPE_DRIVE_INFORMATION
1Retrieves信息的磁带设备。
GET_TAPE_MEDIA_INFORMATION
0Retrieves信息在磁带设备的磁带。
lpdwSize [out]
指针变量,它接收的大小,以字节为单位,由lpTapeInformation参数指定的缓冲区。如果缓冲区太小,此参数接收所需的大小。
lpTapeInformation [out]
指针的结构,它包含所要求的资料。如果dwOperation参数GET_TAPE_MEDIA_INFORMATION,lpTapeInformation指向一个TAPE_GET_MEDIA_PARAMETERS结构。
如果dwOperation是GET_TAPE_DRIVE_INFORMATION,lpTapeInformation指向一个TAPE_GET_DRIVE_PARAMETERS结构。
返回值
如果函数成功,返回值为NO_ERROR。
如果函数失败,它可以返回以下错误代码之一。
错误codeDescription
ERROR_BEGINNING_OF_MEDIA
1102LAn试图访问数据之前开始的介质标记失败。
ERROR_BUS_RESET
1111LA复位条件检测总线上。
ERROR_DEVICE_NOT_PARTITIONED
1107LThe分区信息时,找不到磁带被加载。
ERROR_END_OF_MEDIA
1100LThe最终磁带标记达成了一项行动。
ERROR_FILEMARK_DETECTED
1101LA文件标记达成了一项行动。
ERROR_INVALID_BLOCK_LENGTH
1106LThe块大小不正确的,是在一个多卷分区的新磁带。
ERROR_MEDIA_CHANGED
1110LThe磁带,在驱动器已被替换或删除。
ERROR_NO_DATA_DETECTED
1104LThe终了数据标记达成了一项行动。
ERROR_NO_MEDIA_IN_DRIVE
1112LThere在驱动器中没有媒体。
ERROR_NOT_SUPPORTED
50LThe磁带驱动程序不支持请求的功能。
ERROR_PARTITION_FAILURE
1105LThe磁带不能分区。
ERROR_SETMARK_DETECTED
1103LA setmark达成了一项行动。
ERROR_UNABLE_TO_LOCK_MEDIA
1108LAn试图锁定弹射机制的失败。
ERROR_UNABLE_TO_UNLOAD_MEDIA
1109LAn尝试卸载磁带失败。
ERROR_WRITE_PROTECT
19LThe媒体是写保护。
备注
块的大小范围值(最高和最低)返回的GetTapeParameters函数设置为GET_TAPE_DRIVE_INFORMATION值将显示系统限制,而不是驱动器限制了dwOperation参数调用。然而,在磁带驱动器设备和媒体的驱动器,确定真正的块大小限制存在。因此,应用程序可能无法将所有的块中指定dwOperation GET_TAPE_DRIVE_INFORMATION取得上述范围的大小。
要求:
最低支持:client-Windows 2000专业版
最低支持server-Windows 2000服务器
HeaderWinbase.h(头文件:winuser.h)
LibraryKernel32.lib
DLLKernel32.dll
参见
CreateFile
SetTapeParameters
TAPE_GET_DRIVE_PARAMETERS
TAPE_GET_MEDIA_PARAMETERS
如果有任何问题和意见,请发送给微软(wsddocfb@microsoft.com)
生成日期:2009年7月30日
==英文原文==GetTapeParameters Function
The GetTapeParameters function retrieves information that describes the tape or the tape drive.
Syntax
C++
DWORD GetTapeParameters(
__in HANDLE hDevice,
__in DWORD dwOperation,
__out LPDWORD lpdwSize,
__out LPVOID lpTapeInformation
);
Parameters
hDevice [in]
Handle to the device about which information is sought. This handle is created by using the CreateFile function.
dwOperation [in]
Type of information requested. This parameter must be one of the following values.
ValueMeaning
GET_TAPE_DRIVE_INFORMATION
1Retrieves information about the tape device.
GET_TAPE_MEDIA_INFORMATION
0Retrieves information about the tape in the tape device.

lpdwSize [out]
Pointer to a variable that receives the size, in bytes, of the buffer specified by the lpTapeInformation parameter. If the buffer is too small, this parameter receives the required size.
lpTapeInformation [out]
Pointer to a structure that contains the requested information. If the dwOperation parameter is GET_TAPE_MEDIA_INFORMATION, lpTapeInformation points to a TAPE_GET_MEDIA_PARAMETERS structure.
If dwOperation is GET_TAPE_DRIVE_INFORMATION, lpTapeInformation points to a TAPE_GET_DRIVE_PARAMETERS structure.
Return Value
If the function succeeds, the return value is NO_ERROR.
If the function fails, it can return one of the following error codes.
Error codeDescription
ERROR_BEGINNING_OF_MEDIA
1102LAn attempt to access data before the beginning-of-medium marker failed.
ERROR_BUS_RESET
1111LA reset condition was detected on the bus.
ERROR_DEVICE_NOT_PARTITIONED
1107LThe partition information could not be found when a tape was being loaded.
ERROR_END_OF_MEDIA
1100LThe end-of-tape marker was reached during an operation.
ERROR_FILEMARK_DETECTED
1101LA filemark was reached during an operation.
ERROR_INVALID_BLOCK_LENGTH
1106LThe block size is incorrect on a new tape in a multivolume partition.
ERROR_MEDIA_CHANGED
1110LThe tape that was in the drive has been replaced or removed.
ERROR_NO_DATA_DETECTED
1104LThe end-of-data marker was reached during an operation.
ERROR_NO_MEDIA_IN_DRIVE
1112LThere is no media in the drive.
ERROR_NOT_SUPPORTED
50LThe tape driver does not support a requested function.
ERROR_PARTITION_FAILURE
1105LThe tape could not be partitioned.
ERROR_SETMARK_DETECTED
1103LA setmark was reached during an operation.
ERROR_UNABLE_TO_LOCK_MEDIA
1108LAn attempt to lock the ejection mechanism failed.
ERROR_UNABLE_TO_UNLOAD_MEDIA
1109LAn attempt to unload the tape failed.
ERROR_WRITE_PROTECT
19LThe media is write protected.

Remarks
The block size range values (maximum and minimum) returned by the GetTapeParameters function called with the dwOperation parameter set to the GET_TAPE_DRIVE_INFORMATION value will indicate system limits, not drive limits. However, it is the tape drive device and the media present in the drive that determine the true block size limits. Thus, an application may not be able to set all the block sizes mentioned in the range obtained by specifying GET_TAPE_DRIVE_INFORMATION in dwOperation.
Requirements
Minimum supported clientWindows 2000 Professional
Minimum supported serverWindows 2000 Server
HeaderWinbase.h (include Windows.h)
LibraryKernel32.lib
DLLKernel32.dll
See Also
CreateFile
SetTapeParameters
TAPE_GET_DRIVE_PARAMETERS
TAPE_GET_MEDIA_PARAMETERS
Send comments about this topic to Microsoft
Build date: 7/30/2009
==原始网址==http://msdn.microsoft.com/en-us/library/aa362526(VS.85).aspx\n
随便看

 

windows api函数参考手册包含2258条windows api函数文档,详细介绍nodejs、java、rust调用windows api的方法技巧,是学习windows api编程的入门中文文档。

 

Copyright © 2004-2023 Winrtm.com All Rights Reserved
京ICP备2021023879号-40 更新时间:2024/10/6 13:21:56