=encoding euc-jp =head1 NAME =begin original Games::Go::SGF - Parse and dissect Standard Go Format files =end original Games::Go::SGF - SGFファイルの解析と分析 =head1 概要 use Games::Go::SGF; my $sgf = new Games::Go::SGF($sgfdata); print "Game played on ".$sgf->date."\n"; print $sgf->white. " (W) vs. ".$sgf->black." (B)\n"; print "Board size: ".$sgf->size.". Komi: ".$sgf->komi."\n"; while ($move = $sgf->move($move_no++)) { print "$move_no: ".$move->move,"\n"; } =head1 説明 =begin original This is a very simple SGF file parser, of currently limited functionality. It can read and step through SGF files, follow variations, and so on. It's good enough for getting simple statistics about games of Go, and building up C objects representing games stored as SGF. =end original これは非常に単純なSGFファイルのパーサで、現在のところ機能的に制限がある。 このモジュールを使って、SGFファイルの読み込みとステップ、手合いの変化のフォロー などができる。碁の試合に関する簡単な統計をとったり、SGFとして記録された試合を 表すCオブジェクトの構築を行うには十分役に立つだろう。 =begin original C<< $sgf->move >> returns either a normal C or a C object. They behave exactly the same, but the variation object has the additional methods C to get the main line of the game, C to get the first node in the n'th variation, and C to retrieve an array of variations. C<< $variation->move >> will, by default, follow the mainline. =end original C<< $sgf->move >>は通常のCオブジェクトか、 Cオブジェクトを返す。それらは全く同じように 振舞うが、Variationオブジェクトの方はメソッドが追加されている。 Cはゲームのメインラインを得ることができる。 Cはn回目の変化の最初のノードを得ることができる。 そしてCは変化を保持した配列を手繰り寄せる。 C<< $variation->move >>はデフォルトでメインラインを追いかける。 =head1 TODO =begin original Better documentation is planned; as is the ability to write as well as read SGF files. =end original よりよいドキュメントを計画中。SGFファイルの読み込みと同様に 書き込みができるようにする。 =head1 作者 Simon Cozens C =head1 参考 L, http://www.red-bean.com/sgf/