V2EX  ›  英汉词典

General Type

Definition / 释义

“general type”常指“通用类型/一般类型”,表示不特指某一种具体类别的类型;在计算机与编程语境中,常用来指泛型/通用的类型参数(接近 generic type 的意思),用于让代码适用于多种数据类型。

Pronunciation / 发音

/ˈdʒenərəl taɪp/

Examples / 例句

This is a general type of error that can happen on any device.
这是一种可能在任何设备上发生的通用错误类型。

In the API design, we use a general type so the same function can work with strings, numbers, or custom objects.
在这个 API 设计中,我们使用通用类型,让同一个函数能处理字符串、数字或自定义对象。

Etymology / 词源

general 源自拉丁语 generalis(“普遍的、一般的”),与 genus(“种类、类别”)相关;type 源自希腊语 typos(“印记、模子、模型”),引申为“类型、类别”。合在一起,“general type”字面意思就是“普遍/通用的类别”。

Related Words / 相关词

Literary Works / 文学作品

  • Java Generics and Collections — Maurice Naftalin & Philip Wadler
  • Effective Java — Joshua Bloch
  • C# in Depth — Jon Skeet
  • The C++ Programming Language — Bjarne Stroustrup
关于   ·   帮助文档   ·   自助推广系统   ·   博客   ·   API   ·   FAQ   ·   Solana   ·   1861 人在线   最高记录 6679   ·     Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 12ms · UTC 11:41 · PVG 19:41 · LAX 03:41 · JFK 06:41
♥ Do have faith in what you're doing.