Package org.apache.sling.servlets.get.impl.util

# Class JsonObjectCreator

java.lang.Object
org.apache.sling.servlets.get.impl.util.JsonObjectCreator

public class JsonObjectCreator extends Object

## Constructor Summary

Constructors
Constructor
Description
`JsonObjectCreator(org.apache.sling.api.resource.Resource resource, boolean ecmaSupport)`
Create a new json object creator

## Method Summary

Modifier and Type
Method
Description
`jakarta.json.JsonObjectBuilder`
`create()`
Create the object builder
`static String`
`formatEcma(Calendar date)`
Helper method to format a calendar

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### JsonObjectCreator

public JsonObjectCreator(org.apache.sling.api.resource.Resource resource, boolean ecmaSupport)
Create a new json object creator

Parameters:
  `resource` - The source
  `ecmaSupport` - ECMA date format for Calendar

## Method Details

### create

public jakarta.json.JsonObjectBuilder create()
Create the object builder

Returns:
  The object builder

### formatEcma

public static String formatEcma(Calendar date)
Helper method to format a calendar

Parameters:
  `date` - The calendar
Returns:
  The formated output