Gobject简介

Introduction
Most modern programming languages come with their own native object systems and additional fundamental algorithmic language constructs. Just as GLib serves as an implementation of such fundamental types and algorithms (linked lists, hash tables and so forth), the GLib Object System provides the required implementations of a flexible, extensible, and intentionally easy to map (into other languages) object-oriented framework for C. The substantial elements that are provided can be summarized as:
A generic type system to register arbitrary single-inherited flat and deep derived types as well as interfaces for structured types. It takes care of creation, initialization and memory management of the assorted object and class structures, maintains parent/child relationships and deals with dynamic implementations of such types. That is, their type specific implementations are relocatable/unloadable during runtime.
A collection of fundamental type implementations, such as integers, doubles, enums and structured types, to name a few.
A sample fundamental type implementation to base object hierarchies upon - the GObject fundamental type.
A signal system that allows very flexible user customization of virtual/overridable object methods and can serve as a powerful notification mechanism.
An extensible parameter/value system, supporting all the provided fundamental types that can be used to generically handle object properties or otherwise parameterized types.

  1. 简介
    大多数现代编程语言都有自己的本地对象系统,和基本的算法语言结构。
    就像Glib提供了基本的类型和算法实现(像链表,哈希表等等)。
    Glib对象系统使用c提供了要求一个灵活的、扩展的,有意容易映射到一个面向对象框架的实现。
    这边本质元素提供到如下的总结中:
    <1>.一个通用结构系统能任意注册单继承平面和深度派生类型就像结构化类型的接口一样。
    它负责各种对象和类结构的创建、初始化、内存管理。
    维护了父子关系。处理这种类型的动态实现。
    也就是说,它们的类型特定实现在运行时可重新定位和卸载。
    <2>.一个收集了基本类型的实现,列入整数,浮点,枚举,结构类型。仅举几个例子。
    <3>.基于对象层次结构的基本类型实现 - GObject基本类型。
    <4>.一种信号系统,允许非常灵活的用户定制虚拟/可覆盖对象方法,并可作为强大的通知机制。
    <5>.一个可扩展 参数/值 系统,支持所有提供的基本类型,可用于一般处理对象属性或其他参数化类型。

来自: https://developer.gnome.org/gobject/stable/pr01.html

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

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值