================================================================================
api/propertiesRenderer8.properties
================================================================================

class Person {
  name: String
  age: Int
  address: Address
  hobbies: List<String>
  friend: Person?
}

class Address {
  street: String
}

int = 123

float = 1.23

bool = true

string = "Pigeon"

unicodeString = "abc😀abc😎abc"

multiLineString = """
  have a
  great
  day
  """

list = List(
  123,
  1.23,
  bool,
  string,
  unicodeString,
  multiLineString,
  List(1, 2, 3),
  Set(1, 2, 3),
  Map("one", 1),
  new Dynamic { name = "Pigeon" }
)

set = Set(
  int,
  float,
  bool,
  string,
  unicodeString,
  multiLineString,
  List(1, 2, 3),
  Set(1, 2, 3),
  Map("one", 1),
  new Dynamic { name = "Pigeon" }
)

map = Map(
  "one", int,
  "two", float,
  "three", bool,
  "four", string,
  "five", unicodeString,
  "six", multiLineString,
  "seven", List(1, 2, 3),
  "eight", Set(1, 2, 3),
  "nine", Map("one", 1),
  "ten", new Dynamic { name = "Pigeon" },
  "eleven", null
)

listing = new Listing {
  123
  1.23
  bool
  string
  unicodeString
  multiLineString
  List(1, 2, 3)
  Set(1, 2, 3)
  Map("one", 1)
  new { name = "Pigeon" }
}

mapping = new Mapping {
  ["one"] = int
  ["two"] = float
  ["three"] = bool
  ["four"] = string
  ["five"] = unicodeString
  ["six"] = multiLineString
  ["seven"] = List(1, 2, 3)
  ["eight"] = Set(1, 2, 3)
  ["nine"] = Map("one", 1)
  ["ten"] = new { name = "Pigeon" }
  ["eleven"] = null
}

typedObject = new Person {
  name = "Pigeon"
  age = 30
  address {
    street = "Folsom St."
  }
  hobbies = List(
    "swimming",
    "gardening",
    "reading"
  )
  friend = null
}

container {
  name = "Pigeon"
  age = 30
  address {
    street = "Folsom St."
    hobbies = List(
      "swimming",
      "gardening",
      "reading"
    )
  }
  friend = null
}

output {
  renderer = new PropertiesRenderer {
    converters = (jsonValueRenderer.converters) {
      [Set]     = (it) -> jsonValueRenderer.renderValue(it)
      [List]    = (it) -> jsonValueRenderer.renderValue(it)
      [Listing] = (it) -> jsonValueRenderer.renderValue(it)
    }
  }
  local jsonValueRenderer = new JsonRenderer { indent = "" }
}

--------------------------------------------------------------------------------

(module
  (clazz
    (identifier)
    (classBody
      (classProperty
        (identifier)
        (typeAnnotation
          (type
            (qualifiedIdentifier
              (identifier)))))
      (classProperty
        (identifier)
        (typeAnnotation
          (type
            (qualifiedIdentifier
              (identifier)))))
      (classProperty
        (identifier)
        (typeAnnotation
          (type
            (qualifiedIdentifier
              (identifier)))))
      (classProperty
        (identifier)
        (typeAnnotation
          (type
            (qualifiedIdentifier
              (identifier))
            (typeArgumentList
              (type
                (qualifiedIdentifier
                  (identifier)))))))
      (classProperty
        (identifier)
        (typeAnnotation
          (type
            (type
              (qualifiedIdentifier
                (identifier))))))))
  (clazz
    (identifier)
    (classBody
      (classProperty
        (identifier)
        (typeAnnotation
          (type
            (qualifiedIdentifier
              (identifier)))))))
  (classProperty
    (identifier)
    (intLiteral))
  (classProperty
    (identifier)
    (floatLiteral))
  (classProperty
    (identifier)
    (trueLiteral))
  (classProperty
    (identifier)
    (slStringLiteral))
  (classProperty
    (identifier)
    (slStringLiteral))
  (classProperty
    (identifier)
    (mlStringLiteral))
  (classProperty
    (identifier)
    (methodCallExpr
      (identifier)
      (argumentList
        (intLiteral)
        (floatLiteral)
        (variableExpr
          (identifier))
        (variableExpr
          (identifier))
        (variableExpr
          (identifier))
        (variableExpr
          (identifier))
        (methodCallExpr
          (identifier)
          (argumentList
            (intLiteral)
            (intLiteral)
            (intLiteral)))
        (methodCallExpr
          (identifier)
          (argumentList
            (intLiteral)
            (intLiteral)
            (intLiteral)))
        (methodCallExpr
          (identifier)
          (argumentList
            (slStringLiteral)
            (intLiteral)))
        (newExpr
          (type
            (qualifiedIdentifier
              (identifier)))
          (objectBody
            (objectProperty
              (identifier)
              (slStringLiteral)))))))
  (classProperty
    (identifier)
    (methodCallExpr
      (identifier)
      (argumentList
        (variableExpr
          (identifier))
        (variableExpr
          (identifier))
        (variableExpr
          (identifier))
        (variableExpr
          (identifier))
        (variableExpr
          (identifier))
        (variableExpr
          (identifier))
        (methodCallExpr
          (identifier)
          (argumentList
            (intLiteral)
            (intLiteral)
            (intLiteral)))
        (methodCallExpr
          (identifier)
          (argumentList
            (intLiteral)
            (intLiteral)
            (intLiteral)))
        (methodCallExpr
          (identifier)
          (argumentList
            (slStringLiteral)
            (intLiteral)))
        (newExpr
          (type
            (qualifiedIdentifier
              (identifier)))
          (objectBody
            (objectProperty
              (identifier)
              (slStringLiteral)))))))
  (classProperty
    (identifier)
    (methodCallExpr
      (identifier)
      (argumentList
        (slStringLiteral)
        (variableExpr
          (identifier))
        (slStringLiteral)
        (variableExpr
          (identifier))
        (slStringLiteral)
        (variableExpr
          (identifier))
        (slStringLiteral)
        (variableExpr
          (identifier))
        (slStringLiteral)
        (variableExpr
          (identifier))
        (slStringLiteral)
        (variableExpr
          (identifier))
        (slStringLiteral)
        (methodCallExpr
          (identifier)
          (argumentList
            (intLiteral)
            (intLiteral)
            (intLiteral)))
        (slStringLiteral)
        (methodCallExpr
          (identifier)
          (argumentList
            (intLiteral)
            (intLiteral)
            (intLiteral)))
        (slStringLiteral)
        (methodCallExpr
          (identifier)
          (argumentList
            (slStringLiteral)
            (intLiteral)))
        (slStringLiteral)
        (newExpr
          (type
            (qualifiedIdentifier
              (identifier)))
          (objectBody
            (objectProperty
              (identifier)
              (slStringLiteral))))
        (slStringLiteral)
        (nullLiteral))))
  (classProperty
    (identifier)
    (newExpr
      (type
        (qualifiedIdentifier
          (identifier)))
      (objectBody
        (objectElement
          (intLiteral))
        (objectElement
          (floatLiteral))
        (objectElement
          (variableExpr
            (identifier)))
        (objectElement
          (variableExpr
            (identifier)))
        (objectElement
          (variableExpr
            (identifier)))
        (objectElement
          (variableExpr
            (identifier)))
        (objectElement
          (methodCallExpr
            (identifier)
            (argumentList
              (intLiteral)
              (intLiteral)
              (intLiteral))))
        (objectElement
          (methodCallExpr
            (identifier)
            (argumentList
              (intLiteral)
              (intLiteral)
              (intLiteral))))
        (objectElement
          (methodCallExpr
            (identifier)
            (argumentList
              (slStringLiteral)
              (intLiteral))))
        (objectElement
          (newExpr
            (objectBody
              (objectProperty
                (identifier)
                (slStringLiteral))))))))
  (classProperty
    (identifier)
    (newExpr
      (type
        (qualifiedIdentifier
          (identifier)))
      (objectBody
        (objectEntry
          (slStringLiteral)
          (variableExpr
            (identifier)))
        (objectEntry
          (slStringLiteral)
          (variableExpr
            (identifier)))
        (objectEntry
          (slStringLiteral)
          (variableExpr
            (identifier)))
        (objectEntry
          (slStringLiteral)
          (variableExpr
            (identifier)))
        (objectEntry
          (slStringLiteral)
          (variableExpr
            (identifier)))
        (objectEntry
          (slStringLiteral)
          (variableExpr
            (identifier)))
        (objectEntry
          (slStringLiteral)
          (methodCallExpr
            (identifier)
            (argumentList
              (intLiteral)
              (intLiteral)
              (intLiteral))))
        (objectEntry
          (slStringLiteral)
          (methodCallExpr
            (identifier)
            (argumentList
              (intLiteral)
              (intLiteral)
              (intLiteral))))
        (objectEntry
          (slStringLiteral)
          (methodCallExpr
            (identifier)
            (argumentList
              (slStringLiteral)
              (intLiteral))))
        (objectEntry
          (slStringLiteral)
          (newExpr
            (objectBody
              (objectProperty
                (identifier)
                (slStringLiteral)))))
        (objectEntry
          (slStringLiteral)
          (nullLiteral)))))
  (classProperty
    (identifier)
    (newExpr
      (type
        (qualifiedIdentifier
          (identifier)))
      (objectBody
        (objectProperty
          (identifier)
          (slStringLiteral))
        (objectProperty
          (identifier)
          (intLiteral))
        (objectProperty
          (identifier)
          (objectBody
            (objectProperty
              (identifier)
              (slStringLiteral))))
        (objectProperty
          (identifier)
          (methodCallExpr
            (identifier)
            (argumentList
              (slStringLiteral)
              (slStringLiteral)
              (slStringLiteral))))
        (objectProperty
          (identifier)
          (nullLiteral)))))
  (classProperty
    (identifier)
    (objectBody
      (objectProperty
        (identifier)
        (slStringLiteral))
      (objectProperty
        (identifier)
        (intLiteral))
      (objectProperty
        (identifier)
        (objectBody
          (objectProperty
            (identifier)
            (slStringLiteral))
          (objectProperty
            (identifier)
            (methodCallExpr
              (identifier)
              (argumentList
                (slStringLiteral)
                (slStringLiteral)
                (slStringLiteral))))))
      (objectProperty
        (identifier)
        (nullLiteral))))
  (classProperty
    (identifier)
    (objectBody
      (objectProperty
        (identifier)
        (newExpr
          (type
            (qualifiedIdentifier
              (identifier)))
          (objectBody
            (objectProperty
              (identifier)
              (objectLiteral
                (parenthesizedExpr
                  (propertyCallExpr
                    (variableExpr
                      (identifier))
                    (identifier)))
                (objectBody
                  (objectEntry
                    (variableExpr
                      (identifier))
                    (functionLiteral
                      (parameterList
                        (typedIdentifier
                          (identifier)))
                      (methodCallExpr
                        (variableExpr
                          (identifier))
                        (identifier)
                        (argumentList
                          (variableExpr
                            (identifier))))))
                  (objectEntry
                    (variableExpr
                      (identifier))
                    (functionLiteral
                      (parameterList
                        (typedIdentifier
                          (identifier)))
                      (methodCallExpr
                        (variableExpr
                          (identifier))
                        (identifier)
                        (argumentList
                          (variableExpr
                            (identifier))))))
                  (objectEntry
                    (variableExpr
                      (identifier))
                    (functionLiteral
                      (parameterList
                        (typedIdentifier
                          (identifier)))
                      (methodCallExpr
                        (variableExpr
                          (identifier))
                        (identifier)
                        (argumentList
                          (variableExpr
                            (identifier))))))))))))
      (objectProperty
        (modifier)
        (identifier)
        (newExpr
          (type
            (qualifiedIdentifier
              (identifier)))
          (objectBody
            (objectProperty
              (identifier)
              (slStringLiteral))))))))
