def ARRAY_TO_OBJECT(expression):
return {'<STR_LIT>': expression}<EOL>
Converts an array into a single document.
See https://docs.mongodb.com/manual/reference/operator/aggregation/arrayToObject/
for more details
:param expression: An expression that can be any valid expression as long as it resolves to an array.
:return: Aggregation operator