Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8723933
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T07:43:36+00:00 2026-06-13T07:43:36+00:00

<p> THAT’S OK: ${((Map<String,Integer>)view.get(upgrade_assignment_type_map)).toString()} </p> <p> THAT’S ALSO OK: for( String _name : ((Map<String,

  • 0
<p> THAT'S OK: ${((Map<String,Integer>)view.get("upgrade_assignment_type_map")).toString()} </p>

<p> THAT'S ALSO OK:
for( String _name : ((Map<String, Integer>)view.get("upgrade_assignment_type_map")).keySet() ) {
<p> ${_name}: ${((Map<String, Integer>)view.get("upgrade_assignment_type_map")).get(_name)} </p>
}
</p>
<br><br>
<p> SADLY THAT'S NOT OK::: ${((Map<String, Integer>)view.get("upgrade_assignment_type_map")).get("MANUAL")} </p>

The above code segment prints following output which is surprising for me:

THAT'S OK: {AUTO_WITH_BALANCE_EMPHASIS=2, AUTO_WITH_OFFENSIVE_EMPHASIS=0, MANUAL=3, AUTO_WITH_DEFENSIVE_EMPHASIS=1}

THAT'S ALSO OK:

AUTO_WITH_BALANCE_EMPHASIS: 2

AUTO_WITH_OFFENSIVE_EMPHASIS: 0

MANUAL: 3

AUTO_WITH_DEFENSIVE_EMPHASIS: 1



SADLY THAT'S NOT OK:::

The last line of code segment tries to get the value of key “MANUAL” but it’s not printing the value and if I try to convert it to toString (like ${((Map<String, Integer>)view.get("upgrade_assignment_type_map")).get("MANUAL").toString()} ) it gives me null at runtime. I don’t understand why it’s happening?

and when I print the length(after first colon <p> ${_name}: ${_name.length()} : ${((Map<String, Integer>)view.get("upgrade_assignment_type_map")).get(_name)} </p> ) of each key I got:

AUTO_WITH_BALANCE_EMPHASIS: 29 : 2

AUTO_WITH_OFFENSIVE_EMPHASIS: 29 : 0

MANUAL: 10 : 3

AUTO_WITH_DEFENSIVE_EMPHASIS: 30 : 1

Note: I am creating map inside java source as Map<String, Integer> nameToTypeMap = Maps.newHashMap();

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T07:43:37+00:00Added an answer on June 13, 2026 at 7:43 am

    Eclipse was not showing invalid characters and there were invalid characters (which were surprisingly compilable) in those string, so when I opened that particular file in vim, it shows me and I removed those invalid characters. That solves my problem.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

That's my program written in C++ (OOP): #include <iostream> #include <string> using namespace std;
I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
I've got a string that has curly quotes in it. I'd like to replace
That's about all I need to ask. Checked the PHP manual and saw a
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
That's probably a trick question, but I'm not sure; Do I have to call
That is, want a Rails application that lets me see a customized view of
That is my select function: public function search($for) { $q = $this->select()->from($this->_name, array('id', 'title',
I need a function that will clean a strings' special characters. I do NOT
That is I need to get rid of the sess* files that php is

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.