Hello World Example

A simple example that contains a single component that writes a message “hello world” and a counter on standard output.

// Simple Hello World Insense program
 
// Interface for Hello component
type IHello is interface ( out any output )
 
// Hello World component
component Hello presents IHello {
 
	count = 1
 
	constructor() {
	}
 
	behaviour {
		send any("\nHello World ") on output
		send any(count) on output
		count := count + 1
	}
} 
 
hello = new Hello()
connect hello.output to standardOut