1Z0-858 Exam Details

  • Exam Code
    :1Z0-858
  • Exam Name
    :Java Enterprise Edition 5 Web Component Developer Certified Professional
  • Certification
    :Oracle Certifications
  • Vendor
    :Oracle
  • Total Questions
    :276 Q&As
  • Last Updated
    :Jan 20, 2026

Oracle 1Z0-858 Online Questions & Answers

  • Question 1:

    You are building a dating web site. The client's date of birth is collected along with lots of other information. The Person class has a derived method, getAge():int, which returns the person's age calculated from the date of birth and today's date. In one of your JSPs you need to print a special message to clients within the age group of 25 through 35. Which two EL code snippets will return true for this condition? (Choose two.)

    A. ${client.age in [25,35]}
    B. ${client.age between [25,35]}
    C. ${client.age between 25 and 35}
    D. ${client.age = 25}
    E. ${client.age le 35 and client.age ge 25}
    F. ${not client.age > 35 andand client.age < 25}

  • Question 2:

    You are building a web application with a scheduling component. On the JSP, you need to show the current date, the date of the previous week, and the date of the next week. To help you present this information, you have created the following EL functions in the 'd' namespace:

    name: curDate; signature: java.util.Date currentDate() name: addWeek; signature: java.util.Date addWeek (java.util.Date, int) name: dateString; signature: java.util.String getDateString(java.util.Date)

    Which EL code snippet will generate the string for the previous week?

    A. ${d:dateString(addWeek(curDate(), -1))}
    B. ${d:dateString[addWeek[curDate[], -1]]}
    C. ${d:dateString[d:addWeek[d:curDate[], -1]]}
    D. ${d:dateString(d:addWeek(d:curDate(), -1))}

  • Question 3:

    Given a web application in which the request parameter productID contains a product identifier. Which two EL expressions evaluate the value of the productID? (Choose two.)

    A. ${productID}
    B. ${param.productID}
    C. ${params.productID}
    D. ${params.productID[1]}
    E. ${paramValues.productID}
    F. ${paramValues.productID[0]}
    G. ${pageContext.request.productID}

  • Question 4:

    You are building a dating service web site. Part of the form to submit a client's profile is a group of radio buttons for the person's hobbies:

    20.

    Hiking

    21.

    Skiing

    22.

    SCUBA Diving

    23.

    After the user submits this form, a confirmation screen is displayed with these hobbies listed. Assume that an application-scoped variable, hobbies, holds a map between the Hobby enumerated type and the display name.

    Which EL code snippet will display Nth element of the user's selected hobbies?

    A. ${hobbies[hobbyEnum[N]}
    B. ${hobbies[paramValues.hobbyEnum[N]]}
    C. ${hobbies[paramValues@'hobbyEnum'@N]}
    D. ${hobbies.get(paramValues.hobbyEnum[N])}
    E. ${hobbies[paramValues.hobbyEnum.get(N)]}

  • Question 5:

    A web application allows the HTML title banner to be set using a servlet context initialization parameter called titleStr. Which two properly set the title in this scenario? (Choose two.)

    A. ${titleStr}
    B. ${initParam.titleStr}
    C. ${params[0].titleStr}
    D. ${paramValues.titleStr}
    E. ${initParam['titleStr']}
    F. ${servletParams.titleStr}
    G. ${request.get("titleStr")}

  • Question 6:

    Which two prevent a servlet from handling requests? (Choose two.)

    A. The servlet's init method returns a non-zero status.
    B. The servlet's init method throws a ServletException.
    C. The servlet's init method sets the ServletResponse's content length to 0.
    D. The servlet's init method sets the ServletResponse's content type to null.
    E. The servlet's init method does NOT return within a time period defined by the servlet container.

  • Question 7:

    You are creating a servlet that generates stock market graphs. You want to provide the web browser with precise information about the amount of data being sent in the response stream. Which two HttpServletResponse methods will you use to provide this information? (Choose two.)

    A. response.setLength(numberOfBytes);
    B. response.setContentLength(numberOfBytes);
    C. response.setHeader("Length", numberOfBytes);
    D. response.setIntHeader("Length", numberOfBytes);
    E. response.setHeader("Content-Length", numberOfBytes);
    F. response.setIntHeader("Content-Length", numberOfBytes);

  • Question 8:

    A web browser need NOT always perform a complete request for a particular page that it suspects might NOT have changed. The HTTP specification provides a mechanism for the browser to retrieve only a partial response from the web server; this response includes information, such as the Last- Modified date but NOT the body of the page. Which HTTP method will the browser use to retrieve such a partial response?

    A. GET
    B. ASK
    C. SEND
    D. HEAD
    E. TRACE
    F. OPTIONS

  • Question 9:

    Your company has a corporate policy that prohibits storing a customer's credit card number in any corporate database. However, users have complained that they do NOT want to re-enter their credit card number for each transaction. Your management has decided to use client-side cookies to record the user's credit card number for 120 days. Furthermore, they also want to protect this information during transit from the web browser to the web container; so the cookie must only be transmitted over HTTPS. Which code snippet creates the "creditCard" cookie and adds it to the out going response to be stored on the user's web browser?

    A. 10. Cookie c = new Cookie("creditCard", usersCard);11. c.setSecure(true);12.
    B. setAge(10368000);13. response.addCookie(c);
    C. 10. Cookie c = new Cookie("creditCard", usersCard);11. c.setHttps(true);12.
    D. setMaxAge(10368000);13. response.setCookie(c);
    E. 10. Cookie c = new Cookie("creditCard", usersCard);11. c.setSecure(true);12.
    F. setMaxAge(10368000);13. response.addCookie(c);
    G. 10. Cookie c = new Cookie("creditCard", usersCard);11. c.setHttps(true);12.
    H. setAge(10368000);13. response.addCookie(c);
    I. 10. Cookie c = new Cookie("creditCard", usersCard);11. c.setSecure(true);12.
    J. setAge(10368000);13. response.setCookie(c);

  • Question 10:

    Which retrieves all cookies sent in a given HttpServletRequest request?

    A. request.getCookies()
    B. request.getAttributes()
    C. request.getSession().getCookies()
    D. request.getSession().getAttributes()

Tips on How to Prepare for the Exams

Nowadays, the certification exams become more and more important and required by more and more enterprises when applying for a job. But how to prepare for the exam effectively? How to prepare for the exam in a short time with less efforts? How to get a ideal result and how to find the most reliable resources? Here on Vcedump.com, you will find all the answers. Vcedump.com provide not only Oracle exam questions, answers and explanations but also complete assistance on your exam preparation and certification application. If you are confused on your 1Z0-858 exam preparations and Oracle certification application, do not hesitate to visit our Vcedump.com to find your solutions here.