equal
deleted
inserted
replaced
14 object Assign_Update |
14 object Assign_Update |
15 { |
15 { |
16 def unapply(text: String): Option[(Document_ID.Version, Document.Assign_Update)] = |
16 def unapply(text: String): Option[(Document_ID.Version, Document.Assign_Update)] = |
17 try { |
17 try { |
18 import XML.Decode._ |
18 import XML.Decode._ |
19 Some(pair(long, list(pair(long, list(long))))(Symbol.decode_yxml(text))) |
19 def decode_upd(body: XML.Body): (Long, List[Long]) = |
|
20 space_explode(',', string(body)).map(Value.Long.parse) match { |
|
21 case a :: bs => (a, bs) |
|
22 case _ => throw new XML.XML_Body(body) |
|
23 } |
|
24 Some(pair(long, list(decode_upd _))(Symbol.decode_yxml(text))) |
20 } |
25 } |
21 catch { |
26 catch { |
22 case ERROR(_) => None |
27 case ERROR(_) => None |
23 case _: XML.Error => None |
28 case _: XML.Error => None |
24 } |
29 } |