Skip to content

Latest commit

 

History

History
22 lines (17 loc) · 774 Bytes

File metadata and controls

22 lines (17 loc) · 774 Bytes

Greeting Example

This example shows a basic Java interface and implementation with a method named greetSomeone, included in a Java package named greeting. It takes a string, representing a person's name, as input. It returns a greeting that includes this name as output.

The example also includes a file Starter that will invoke this method, using a name supplied as a command-line argument. For example, you may run this program by passing the name "Donna" to the program:

$ mvn compile exec:java -Dexec.mainClass="greeting.Starter" -Dexec.args="Mason"

This will output the greeting:

Hello Mason!

Although this example is not a Temporal Workflow, you will use this code to create a Temporal Workflow during the first exercise in this course.