ARTFiddle
New Fiddle
My Fiddles
Tutorial Fiddles
ART Syntax Help
About
Contact
Register
Log in
file1.art
% Select and while commands are very ofter used together #set type = "int", "string", "DateTime" #adapt "file2.art"
file2.art
public void InitVariables() { #while type #select type #option "int" ?@type? var = InitializeInt(); #endoption #option "string" ?@type? var = InitializeString(); #endoption #otherwise throw Exception("No initialization code for type" + \"?@type?\"); #endotherwise #endselect #endwhile }
file3.art
output
public void InitVariables() { int var = InitializeInt(); string var = InitializeString(); throw Exception("No initialization code for type" + "DateTime"); }