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 9269475
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T15:07:54+00:00 2026-06-18T15:07:54+00:00

I am not a java developer, and this is not my homework or something.

  • 0

I am not a java developer, and this is not my homework or something. I am just in need of getting the values of these parameters: end & begin. this is what I have:

rs = [{}, {end=2013/11/5, begin=2012/11/6}]

I am wonder if I could get values like this:

rs[1].end
rs[1].begin

the source is:

protected QueryParameters prepareForm(final ActionContext context) {
    final SearchErrorLogForm form = context.getForm();
    Map<String, Object> rs = form.getValues();
    System.out.println(rs);

    /*the output is: {pageParameters={}, period={end=2013/11/5, begin=2013/11/6}} */
}

sorry, the rs type is hashmap.

  • 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-18T15:07:55+00:00Added an answer on June 18, 2026 at 3:07 pm

    That is not a valid statement.

    A proper way of assigning an array would be:

    String dates[] = {"2013/11/5","2012/11/6"};
    String start = dates[0];
    String end = dates[1];
    

    There is a excellent tutourial at oracle docs

    Okay, that is a Map containing two Maps as it seems. The first map named “pageParameters” is empty. The second one is named period and contains two items. The key “end” maps to the value “2013/11/5”. The key “begin” maps to the value “2013/11/6”.

    To access the objects in the map you could do like this:

    final Map<String, String> period = (Map<String, String>) rs.get("period");
    final String begin = period.get("begin");
    final String end = period.get("end");
    

    If you would like to change a value in the map period you will need to overwrite the already existing one:

    period.put("end", "NEW_END");
    rs.put("period", period);
    

    For further information, Oracle has great tutorials on Hashmaps.

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

Sidebar

Related Questions

I'm just starting to get into C++ (I'm an experienced Python/Java developer getting into
i'm not a java developer, but i need to write a small applet to
Why does Java not have a file copy method? This seems like such an
Why are some exceptions in Java not caught by catch (Exception ex) ? This
I'm not familiar with Java but I need to make a request to a
I'm not a Java developer so I might get some terms wrong... but. An
hello i'm a beginner java developer and this is one question in a list
I am a java Developer,new to C# silverlight. in this class I want to
I am a Java developer and I'm just starting to teach myself c++ as
Professionally I am a back-end Java developer, but recently I've been interested in writing

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.