/**
 * @license Copyright 2017 The FOAM Authors. All Rights Reserved.
 * http://www.apache.org/licenses/LICENSE-2.0
 */

package foam.lib.json;

import foam.core.PropertyInfo;
import foam.lib.parse.*;

public class PropertyParser
  extends ProxyParser
{
  private PropertyInfo property;

  public PropertyParser(PropertyInfo p) {
    super(
      new Seq1(5,
        new Whitespace(),
        new Alt(
          new KeyParser(p.getName()),
          new KeyParser(p.getShortName())),
        new Whitespace(),
        new Literal(":"),
        new Whitespace(),
        p.jsonParser(),
        new Whitespace()));
    property = p;
  }

  public PStream parse(PStream ps, ParserContext x) {
    ps = super.parse(ps, x);
    if (ps == null) return null;
    property.set(x.get("obj"), ps.value());
    return ps;
  }
}

@@ -721,16 +721,17 @@
     if (
+ 
 ps == nu
@@ -732,16 +732,17 @@
  == null
+ 
 ) return
@@ -810,11 +810,102 @@
  ps;%0A  %7D
+%0A%0A  public String toString() %7B%0A    return %22PropertyParser(%22 + property.getName() + %22)%22;%0A  %7D
 %0A%7D%0A

Add toString method to PropertyParser.