JsonObjectValueAdapter () { YAMLMapping parentMapping = myProperty instanceof YAMLKeyValue ? ((YAMLKeyValue)myProperty).getParentMapping() : ObjectUtils.tryCast(myProperty.getParent(), YAMLMapping.class); return parentMapping != null ? new YamlObjectAdapter(parentMapping) : null; }