<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[std::map operator [] ohne automatisches hinzufügen]]></title><description><![CDATA[<p>Hallo!<br />
Ich möchte zum Mappen von Tastatureingaben in interne Programm-events gerne &quot;std::map&lt;int,EVENT&gt; keyMapper;&quot; verwenden.<br />
Zum mappen frage ich einfach &quot;keyMapper['pressed key'];&quot; ab. Das ganze funktioniert sehr gut, nur fügt der Operator &quot;[]&quot; automatisch einen neuen Wert in die Map ein, falls der Key nicht existiert.<br />
Kann man das irgendwie verhindern?</p>
<p>danke,</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/144056/std-map-operator-ohne-automatisches-hinzufügen</link><generator>RSS for Node</generator><lastBuildDate>Wed, 02 Sep 2026 13:11:29 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/144056.rss" rel="self" type="application/rss+xml"/><pubDate>Fri, 14 Apr 2006 07:29:15 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to std::map operator [] ohne automatisches hinzufügen on Fri, 14 Apr 2006 07:29:15 GMT]]></title><description><![CDATA[<p>Hallo!<br />
Ich möchte zum Mappen von Tastatureingaben in interne Programm-events gerne &quot;std::map&lt;int,EVENT&gt; keyMapper;&quot; verwenden.<br />
Zum mappen frage ich einfach &quot;keyMapper['pressed key'];&quot; ab. Das ganze funktioniert sehr gut, nur fügt der Operator &quot;[]&quot; automatisch einen neuen Wert in die Map ein, falls der Key nicht existiert.<br />
Kann man das irgendwie verhindern?</p>
<p>danke,</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1037256</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1037256</guid><dc:creator><![CDATA[pixsta]]></dc:creator><pubDate>Fri, 14 Apr 2006 07:29:15 GMT</pubDate></item><item><title><![CDATA[Reply to std::map operator [] ohne automatisches hinzufügen on Fri, 14 Apr 2006 07:47:54 GMT]]></title><description><![CDATA[<p>Hallo</p>
<p>schau dir die 3. Überladung von <a href="http://www.cppreference.com/cppmap/insert.html" rel="nofollow">insert</a> an.</p>
<p>bis bald<br />
akari</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1037263</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1037263</guid><dc:creator><![CDATA[akari]]></dc:creator><pubDate>Fri, 14 Apr 2006 07:47:54 GMT</pubDate></item><item><title><![CDATA[Reply to std::map operator [] ohne automatisches hinzufügen on Fri, 14 Apr 2006 07:47:59 GMT]]></title><description><![CDATA[<p>habe schon eine lösung (einfach mit find()).</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1037264</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1037264</guid><dc:creator><![CDATA[pixsta]]></dc:creator><pubDate>Fri, 14 Apr 2006 07:47:59 GMT</pubDate></item></channel></rss>