<commit_before>package io.denkbar.step.examples.java;
import java.util.Date;
import java.util.HashMap;
import java.util.Map;

import org.junit.Test;

import step.grid.io.OutputMessage;
import step.handlers.javahandler.AbstractScript;
import step.handlers.javahandler.Function;
import step.handlers.javahandler.ScriptRunner;
import step.handlers.javahandler.ScriptRunner.ScriptContext;

public class Java_Clock_Example extends AbstractScript {

	@Function
	public void Demo_Java_Clock() throws Exception {

		Date date;
		output.startMeasure("Demo_Java_Clock_subMeasurement");
		date = new Date();
		output.stopMeasure();

		output.add("prettyMessage", input.getString("prettyString") + date.toString());
		output.add("timestamp", date.getTime());
	}
	
	@Test
	public void Demo_Java_Clock_Test() {
	    Map<String, String> properties = new HashMap<>();
	    ScriptContext ctx = ScriptRunner.getExecutionContext(properties);
	    
	    OutputMessage result = ctx.run("Demo_Java_Clock","{ \"prettyString\" : \"Current time is : \" }");
    
	    System.out.println(result.getPayload());
	    
	}

}<commit_msg>Fixing demo keyword for java<commit_after>package io.denkbar.step.examples.java;
import java.util.Date;
import java.util.HashMap;
import java.util.Map;

import org.junit.Test;

import step.grid.io.OutputMessage;
import step.handlers.javahandler.AbstractScript;
import step.handlers.javahandler.Function;
import step.handlers.javahandler.ScriptRunner;
import step.handlers.javahandler.ScriptRunner.ScriptContext;

public class Java_Clock_Example extends AbstractScript {

	@Function
	public void Demo_Keyword_Java() throws Exception {

		Date date;
		output.startMeasure("Demo_Java_Clock_subMeasurement");
		date = new Date();
		output.stopMeasure();

		String label = input.containsKey("label")?input.getString("label"):"Date:";
		output.add("date", label + date.toString());
		output.add("timestamp", date.getTime());
	}
	
	@Test
	public void Demo_Java_Clock_Test() {
	    Map<String, String> properties = new HashMap<>();
	    ScriptContext ctx = ScriptRunner.getExecutionContext(properties);
	    
	    OutputMessage result = ctx.run("Demo_Keyword_Java","{ \"label\" : \"Current time is : \" }");
    
	    System.out.println(result.getPayload());
	    
	}

}
{'fraction_non_alphanumeric': 0.12692816218598502, 'fraction_numerical': 0.0, 'mean_word_length': 4.942408376963351, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6083748', 'n_tokens_mistral': 729, 'n_tokens_neox': 690, 'n_words': 133}