<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title>Answers to: Error on creating a typed Map in Ivyscript (Ivyscript and Generics)</title><link>https://answers.axonivy.com/questions/878/error-on-creating-a-typed-map-in-ivyscript-ivyscript-and-generics</link><description>&lt;p&gt;If I create a typed Map in a script step, (e.g. &lt;code&gt;Map&amp;lt;Integer, String&amp;gt; map = new HashMap&amp;lt;Integer,String&amp;gt;();&lt;/code&gt;) I get the error "Unexpected token: ','".&lt;/p&gt;
&lt;p&gt;&lt;img alt="alt text" src="/upfiles/[1406105117]HashMap_7.png"&gt;&lt;/p&gt;
&lt;p&gt;Nevertheless the code compiles and the process can be executed. Why does this error appear on the script step?&lt;/p&gt;</description><atom:link href="https://answers.axonivy.com/questions/878/error-on-creating-a-typed-map-in-ivyscript-ivyscript-and-generics" rel="self"></atom:link><language>en</language><lastBuildDate>Wed, 23 Jul 2014 16:44:27 -0400</lastBuildDate><item><title>Answer by Barbara Brugger</title><link>https://answers.axonivy.com/questions/878/error-on-creating-a-typed-map-in-ivyscript-ivyscript-and-generics/879</link><description>&lt;p&gt;The error is not very specific: In Ivyscript Generics are generally not supported, except for List. The code will compile anyway and can also be executed because the Map in the example is threaten as like it wasn't typed.&lt;/p&gt;
&lt;p&gt;If you need to use Generics you can switch to Java instead of Ivyscript.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Barbara Brugger</dc:creator><pubDate>Wed, 23 Jul 2014 16:44:27 -0400</pubDate><guid>https://answers.axonivy.com/questions/878/error-on-creating-a-typed-map-in-ivyscript-ivyscript-and-generics/879</guid></item></channel></rss>