Java Magazine, Jan/Feb 2016
Gosu A Modern Down to Earth Language for the JVM A low ceremony language used in large enterprise apps offers an extraordinarily flexible yet static type system SCOTT MCKINNEY ORACLE COM JAVAMAGAZINE JANUARY FEBRUARY 2016 65 jvm languages Gosu is about 13 years old It began as a simple scripting language here at Guidewire Software late in 2002 We needed a straightforward language for our customers to customize our products Our basic criteria for the language included that it be Java interoperable statically typed familiar and easy to use Static typing facilitates our larger goal to provide a safe and pleasurable user experience via deterministic tooling such as rich parser feedback code completion refactoring usage searching and so forth We would much rather have pulled a language from the shelf than build our own but at the time there werent any scripting languages available that came close to satisfying our needs As a fledgling startup we werent about to compromise at this critical stage Guidewires success would be won at least in part on our customers ability to tailor our products using our language and tools As a result Gosu came to life Since then weve come a long long way With more customers came demand for more Gosu features which over time led Gosu to become a powerful general purpose programming language Thus unlike many programming languages nearly every step of Gosus development is a result of true pragmatism its features were developed and refined for broad usability and have been vetted in the field by hundreds of medium to very large international corpo rations employing thousands of developers writing missioncritical software with Gosu Hello Getting down to business you are probably more interested in Gosus capabilities and syntax than in its history so lets get to it Here is Gosus Hello World print Hello World Thats it Because Gosu is inherently scriptable there is no need for boilerplate code such as a Main class or main method But if youre feeling nostalgic this also works class RunMe static function main args String print Hello World This class prints Hello World to the console The same holds for the former simpler example So in addition to conventional class files Gosu supports program source files that are free form scripting files You can code up anything in a program including statements functions whole classes whatever in any arrangement you like
You must have JavaScript enabled to view digital editions.