DB_NestedSet::apiVersion (Previous) (Next) DB_NestedSet::createLeftNode

View this page in Last updated: Sun, 05 Oct 2008
English | French | German | Japanese | Plain HTML

DB_NestedSet::convertTreeModel()

DB_NestedSet::convertTreeModel()  -- <1.3 のツリーを 1.3 の形式に変換する

説明

これは、1.3 の新機能を使用するためにツリーの形式を変換します。 以前のバージョンで作成したツリーは変換をしなくても動作しますが、 先行順のソートなどの新機能がうまく動きません。

使用法: - 新たなノードテーブル (tb_nodes2) を現在のノードテーブル (tb_nodes1) から作成します (構造をコピーするだけ)。 - '旧' セットのインスタンス (NeSe1) および新セットのインスタンス (NeSe2) を作成します。 - これで、node_table だけが異なる同一のオブジェクトがふたつ出来上がりました。 - DB_NestedSet::convertTreeModel(&$orig, &$copy); をコールします。 - tb_nodes2 の中にある tb_nodes1 のコピーを消します。

パラメータ

&$orig

&$copy

integer $_parent

親ノードの ID (private)。

object $copy

新しいツリーをコピーするオブジェクト。

返り値

成功した場合に True を返します。

例外・エラー

例外はスローされません。

注意

この関数は、スタティックにコールする ことはできません。

DB_NestedSet::apiVersion (Previous) (Next) DB_NestedSet::createLeftNode

Download Documentation Last updated: Sun, 05 Oct 2008
Do you think that something on this page is wrong? Please file a bug report or add a note.
User Notes:
There are no user contributed notes for this page.