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

nyla.solutions.global.patterns.command.commas.json.JsonAfterCommand Maven / Gradle / Ivy

Go to download

Nyla Solutions Global Java API provides support for basic application utilities (application configuration, data encryption, debugger and text processing).

The newest version!
package nyla.solutions.global.patterns.command.commas.json;
import nyla.solutions.global.data.Envelope;
import nyla.solutions.global.json.JSON;
import nyla.solutions.global.patterns.command.Command;


/**
 * @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();

}