函数

GObjecttype_next_base

声明 [src]

GType
g_type_next_base (
  GType leaf_type,
  GType root_type
)

描述 [src]

给定一个 leaf_type 和一个包含在其祖先中的 root_type,返回 root_type 的直接父类型。换句话说,此函数确定直接派生自 root_type 同时也是 leaf_type 的基类的类型。给定一个根类型和一个叶类型,此函数可用于确定叶类型从根类型派生的类型和顺序。

参数

leaf_type

类型: GType

root_type 的后代和要 返回的类型。

root_type

类型: GType

返回 类型的直接父级。

返回值

类型: GType

root_type 的直接子级且为 leaf_type 的祖先。