windows-api_Windows API

windows-api

Windows API (Windows API)

Windows API includes all the programming interfaces (application programming interface or API) available in Windows operating systems from Microsoft. To use the Windows APIs, Microsoft provides a free Platform SDK, a collection of tools, and documentation to match a C language compiler

Windows API包括Microsoft在Windows操作系统中可用的所有编程接口(应用程序编程接口或API)。 为了使用Windows API,Microsoft提供了免费的Platform SDK,一系列工具以及与C语言编译器匹配的文档

Windows API的版本 (Versions of the Windows API)

The Windows API can be divided into the following groups:

Windows API可以分为以下几组:

  • Win16 version of the original 16-bit Windows API, whose specifications are available as Standard ECMA-234 ECMA-coded.

    原始16位Windows API的Win16版本,其规范可作为标准ECMA-234 ECMA编码获得。
  • Win32, 32-bit development for modern versions of Windows.

    Win32,现代版本Windows的32位开发。
  • Win32s, a subset of Win32 to install versions of Windows 16-bit applications to run 32-bit compiler.

    Win32s,Win32的子集,用于安装Windows 16位应用程序的版本以运行32位编译器。
  • Win64, evolving 64-bit versions of Windows for new 64-bit processors from Intel and AMD.

    Win64,不断发展的Windows 64位版本,用于来自Intel和AMD的新64位处理器。

Windows API的结构 (Structure of the Windows API)

APIs are a set of functions implemented in C language dynamic link libraries (Dynamic-link libraries or DLLs).

API是用C语言动态链接库(动态链接库或DLL)实现的一组功能。

The Windows API, despite being written for performance reasons, a mix of assembler and C language, have a complex object-oriented model with a very uniform and a style that was an inspiration for many other projects.

尽管Windows API是出于性能原因而编写的,但它是汇编语言和C语言的混合体,但它具有复杂的面向对象模型,具有非常统一的风格,这是许多其他项目的灵感来源。

The basic structure of the Windows API is largely unchanged from Windows 1.0 to date. There are three main groups of APIs: Kernel, GDI and user.

Windows API的基本结构从Windows 1.0到现在基本上没有变化。 API分为三大类:内核,GDI和用户。

内核API (Kernel API)

The kernel API provides applications with a high level interface to the services of the operating system kernel (memory management, processes, timing, etc.). On versions of Windows from Windows 1.0 to 4.9 (Windows ME), many of these APIs are simply references to the services provided by MS-DOS software interrupt. On systems with NT kernel, making the API calls to low-level API for NT Native API calls.

内核API为应用程序提供了与操作系统内核服务(内存管理,进程,定时等)的高级接口。 在Windows从Windows 1.0到4.9(Windows ME)的版本上,许多这些API只是对由MS-DOS软件中断提供的服务的引用。 在具有NT内核的系统上,将API调用转换为用于NT本机API调用的低级API。

GDI API (GDI API)

API GDI (Graphics Device Interface) are the graphics library for Windows systems. GDI virtualizes all graphics devices (monitors, printers, plotters) to have a homogeneous interface (called a Device Context) between the different types of devices. GDI also allows you to create and manipulate a set of graphical objects, including fonts, pens, brushes, bitmaps, etc..

API GDI(图形设备接口)是Windows系统的图形库。 GDI虚拟化所有图形设备(显示器,打印机,绘图仪),使其在不同类型的设备之间具有同类接口(称为设备上下文)。 GDI还允许您创建和处理一组图形对象,包括字体,钢笔,画笔,位图等。

用户API (User API)

The API user (from user interface) providing the service interface, based on the concepts of “window” and “message”.

基于“窗口”和“消息”的概念的API用户(来自用户界面)提供服务接口。

非Microsoft实现 (Non-Microsoft implementations)

Although the implementation of the Windows API is subject to copyright, there are proprietary implementations of other manufacturers and also several open source projects, among which we mention WINE to emulate the Windows API on Unix-type systems, and ReactOS aims to clone the ‘entire operating system.

尽管Windows API的实现受版权保护,但是也有其他制造商的专有实现以及一些开源项目,其中我们提到了WINE在Unix类型的系统上模拟Windows API,而ReactOS旨在克隆整个数据库。操作系统。

更高级别的图书馆 (Libraries at higher levels)

The layering of new features over time, the need for a complete backward compatibility and the huge amount of overall features (currently several thousand) has made Windows programming with the API difficult and inappropriate to the standards accepted today. For this time were born in many libraries (in languages like C + + and others) who propose an object model more abstract and simple to use, transforming the Windows API interface low.

随着时间的推移,新功能的分层,对完全向后兼容性的需求以及大量的总体功能(目前为数千)使使用API​​进行Windows编程变得困难且不适合当今接受的标准。 这段时间诞生于许多库(使用C ++等语言),它们提出了一个更抽象,更易于使用的对象模型,从而使Windows API接口的性能降低了。

封装Windows API的库示例包括: (Examples of libraries that encapsulate the Windows API are:)

  • Microsoft Foundation Classes (MFC), C + + library widely used but has a reduced level of abstraction.

    Microsoft基础类(MFC),C ++库被广泛使用,但是抽象水平降低。
  • Object Windows Library (OWL), library of Borland C + + with a higher level of abstraction.

    对象Windows库(OWL),具有更高抽象水平的Borland C ++库。
  • Active Template Library (ATL) library in C + + template-based Microsoft.

    基于C ++模板的Microsoft中的活动模板库(ATL)库。
  • Windows Foundation Classes (WFC) library for Java no longer used following the lawsuit brought by Sun Microsystems to Microsoft.

    在Sun Microsystems向Microsoft提起诉讼之后,不再使用Java的Windows基础类(WFC)库。
  • . NET framework, Microsoft’s library of language-independent because the compilers for the CLR.

    。 NET框架,Microsoft的语言独立库,因为CLR的编译器。

Windows API的未来 (The future of the Windows API)

The history of the Windows API is at a crossroads: the intent of Microsoft should give way to the library .NET especially with the new Windows Presentation Foundation component, available in version 3.0. NET Framework.

Windows API的历史处于十字路口:Microsoft的意图应该让位于.NET库,尤其是使用3.0版中提供的新Windows Presentation Foundation组件。 NET框架。

Study: From Wikipedia, the free encyclopedia. The text is available under the Creative Commons.

研究:来自维基百科,免费的百科全书。 该文本可在“ 知识共享”下找到

翻译自: https://www.eukhost.com/blog/webhosting/windows-api/

windows-api

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值