Enum sgf_parse::go::Prop[][src]

pub enum Prop {
Show 69 variants B(Move), KO, MN(i64), W(Move), AB(HashSet<Point>), AE(HashSet<Point>), AW(HashSet<Point>), PL(Color), C(Text), DM(Double), GB(Double), GW(Double), HO(Double), N(SimpleText), UC(Double), V(f64), BM(Double), DO, IT, TE(Double), AR(HashSet<(Point, Point)>), CR(HashSet<Point>), DD(HashSet<Point>), LB(HashSet<(Point, SimpleText)>), LN(HashSet<(Point, Point)>), MA(HashSet<Point>), SL(HashSet<Point>), SQ(HashSet<Point>), TR(HashSet<Point>), AP((SimpleText, SimpleText)), CA(SimpleText), FF(i64), GM(i64), ST(i64), SZ((u8, u8)), AN(SimpleText), BR(SimpleText), BT(SimpleText), CP(SimpleText), DT(SimpleText), EV(SimpleText), GN(SimpleText), GC(Text), ON(SimpleText), OT(SimpleText), PB(SimpleText), PC(SimpleText), PW(SimpleText), RE(SimpleText), RO(SimpleText), RU(SimpleText), SO(SimpleText), TM(f64), US(SimpleText), WR(SimpleText), WT(SimpleText), BL(f64), OB(i64), OW(i64), WL(f64), FG(Option<(i64, SimpleText)>), PM(i64), VW(HashSet<Point>), Unknown(String, Vec<String>), Invalid(String, Vec<String>), HA(i64), KM(f64), TB(HashSet<Point>), TW(HashSet<Point>),
}
Expand description

An SGF Property with identifier and value.

All general properties from the SGF specification and all game specific properties will return the approprite enum instance with parsed data. Unrecognized properties will return Prop::Unknown. Recognized general or game specific properties with invalid values will return Prop::Invalid.

See property value types for a list of types recognized by SGF. For parsing purposes the following mappings are used:

Variants

B

Tuple Fields of B

0: Move
KO
MN

Tuple Fields of MN

0: i64
W

Tuple Fields of W

0: Move
AB

Tuple Fields of AB

0: HashSet<Point>
AE

Tuple Fields of AE

0: HashSet<Point>
AW

Tuple Fields of AW

0: HashSet<Point>
PL

Tuple Fields of PL

0: Color
C

Tuple Fields of C

0: Text
DM

Tuple Fields of DM

0: Double
GB

Tuple Fields of GB

0: Double
GW

Tuple Fields of GW

0: Double
HO

Tuple Fields of HO

0: Double
N

Tuple Fields of N

0: SimpleText
UC

Tuple Fields of UC

0: Double
V

Tuple Fields of V

0: f64
BM

Tuple Fields of BM

0: Double
DO
IT
TE

Tuple Fields of TE

0: Double
AR

Tuple Fields of AR

0: HashSet<(Point, Point)>
CR

Tuple Fields of CR

0: HashSet<Point>
DD

Tuple Fields of DD

0: HashSet<Point>
LB

Tuple Fields of LB

0: HashSet<(Point, SimpleText)>
LN

Tuple Fields of LN

0: HashSet<(Point, Point)>
MA

Tuple Fields of MA

0: HashSet<Point>
SL

Tuple Fields of SL

0: HashSet<Point>
SQ

Tuple Fields of SQ

0: HashSet<Point>
TR

Tuple Fields of TR

0: HashSet<Point>
AP

Tuple Fields of AP

0: (SimpleText, SimpleText)
CA

Tuple Fields of CA

0: SimpleText
FF

Tuple Fields of FF

0: i64
GM

Tuple Fields of GM

0: i64
ST

Tuple Fields of ST

0: i64
SZ

Tuple Fields of SZ

0: (u8, u8)
AN

Tuple Fields of AN

0: SimpleText
BR

Tuple Fields of BR

0: SimpleText
BT

Tuple Fields of BT

0: SimpleText
CP

Tuple Fields of CP

0: SimpleText
DT

Tuple Fields of DT

0: SimpleText
EV

Tuple Fields of EV

0: SimpleText
GN

Tuple Fields of GN

0: SimpleText
GC

Tuple Fields of GC

0: Text
ON

Tuple Fields of ON

0: SimpleText
OT

Tuple Fields of OT

0: SimpleText
PB

Tuple Fields of PB

0: SimpleText
PC

Tuple Fields of PC

0: SimpleText
PW

Tuple Fields of PW

0: SimpleText
RE

Tuple Fields of RE

0: SimpleText
RO

Tuple Fields of RO

0: SimpleText
RU

Tuple Fields of RU

0: SimpleText
SO

Tuple Fields of SO

0: SimpleText
TM

Tuple Fields of TM

0: f64
US

Tuple Fields of US

0: SimpleText
WR

Tuple Fields of WR

0: SimpleText
WT

Tuple Fields of WT

0: SimpleText
BL

Tuple Fields of BL

0: f64
OB

Tuple Fields of OB

0: i64
OW

Tuple Fields of OW

0: i64
WL

Tuple Fields of WL

0: f64
FG

Tuple Fields of FG

0: Option<(i64, SimpleText)>
PM

Tuple Fields of PM

0: i64
VW

Tuple Fields of VW

0: HashSet<Point>
Unknown

Tuple Fields of Unknown

0: String1: Vec<String>
Invalid

Tuple Fields of Invalid

0: String1: Vec<String>
HA

Tuple Fields of HA

0: i64
KM

Tuple Fields of KM

0: f64
TB

Tuple Fields of TB

0: HashSet<Point>
TW

Tuple Fields of TW

0: HashSet<Point>

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Formats the value using the given formatter. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Returns a new property parsed from the provided identifier and values Read more

Returns a the identifier associated with the SgfProp. Read more

Returns the PropertyType associated with the property. Read more

Validates a set of properties. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

Converts the given value to a String. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.