All Downloads are FREE. Search and download functionalities are using the official Maven repository.

nyla.solutions.commas.json.JsonAfterCommand Maven / Gradle / Ivy

The newest version!
package nyla.solutions.commas.json;

import nyla.solutions.commas.Command;
import nyla.solutions.core.data.Envelope;
import nyla.solutions.global.json.JSON;


/**
 * @author Gregory Green
 *
 */
public class JsonAfterCommand implements Command>
{

	/**
	 * Provide checks and transformation pass of the 
	 * @param resultAndOriginalArg array 0 - raw function result, 1 = Object[] containing the envelope and function context
	 */
	//@Override
	public String execute(Envelope env)
	{
		
		return json.toJson(env.getPayload());
			
	}// -----------------------------------------------

	private JSON json = JSON.newInstance();

}