equal
deleted
inserted
replaced
504 def codes: List[(String, Int)] = symbols.codes |
504 def codes: List[(String, Int)] = symbols.codes |
505 |
505 |
506 def decode(text: String): String = symbols.decode(text) |
506 def decode(text: String): String = symbols.decode(text) |
507 def encode(text: String): String = symbols.encode(text) |
507 def encode(text: String): String = symbols.encode(text) |
508 |
508 |
509 def decode_string: XML.Decode.T[String] = (x => decode(XML.Decode.string(x))) |
509 def decode_yxml(text: String): XML.Body = YXML.parse_body(decode(text)) |
510 def encode_string: XML.Encode.T[String] = (x => XML.Encode.string(encode(x))) |
510 def decode_yxml_failsafe(text: String): XML.Body = YXML.parse_body_failsafe(decode(text)) |
|
511 def encode_yxml(body: XML.Body): String = encode(YXML.string_of_body(body)) |
511 |
512 |
512 def decode_strict(text: String): String = |
513 def decode_strict(text: String): String = |
513 { |
514 { |
514 val decoded = decode(text) |
515 val decoded = decode(text) |
515 if (encode(decoded) == text) decoded |
516 if (encode(decoded) == text) decoded |