[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [computer-go] SGF parsers
> I did read somewhere the properties had to be unique... But it's not a
> simple name=value pair as a property has a list of values, like in
> AW[aa][ab][ba]
Yes, I oversimplified.
Properties (propnames) have to be unique. With "well formed input"
you can just append/concatenate values (propvalues)
and name:=value vs. name:=list_of_values is just a case
of nasty semantics.
In the AB[aa] AB[ab] case, you could simply concatenate,
and make your internal representation a string of coordinates.
But is is up to you to choose your internal representation.
If your goal is _not_ an sgf-editor, lean&mean seems the simplest ...
NB. I know that ;AB[aa]AB[ab] is invalid sgf, but it won't harm to allow it
by silently converting it to AB[aa][ab].
No harm done if you convert it _internally_ to AB[aaab] .
If this seems all too trivial: please ignore ...
HTH,
AvK
_______________________________________________
computer-go mailing list
computer-go@xxxxxxxxxxxxxxxxx
http://www.computer-go.org/mailman/listinfo/computer-go/