<?xml version="1.0" encoding="ISO-8859-1"?>

<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/">
	<channel>
		<title><![CDATA[Java Programming Forums - The Java Community - JavaServer Pages: JSP & JSTL]]></title>
		<link>http://www.javaprogrammingforums.com/</link>
		<description />
		<language>en</language>
		<lastBuildDate>Tue, 21 May 2013 12:40:25 GMT</lastBuildDate>
		<generator>vBulletin</generator>
		<ttl>60</ttl>
		<image>
			<url>http://www.javaprogrammingforums.com/images/misc/rss.png</url>
			<title><![CDATA[Java Programming Forums - The Java Community - JavaServer Pages: JSP & JSTL]]></title>
			<link>http://www.javaprogrammingforums.com/</link>
		</image>
		<item>
			<title><![CDATA[Java WebApps & CAC/smart card authentication?]]></title>
			<link>http://www.javaprogrammingforums.com/javaserver-pages-jsp-jstl/28713-java-webapps-cac-smart-card-authentication.html</link>
			<pubDate>Thu, 25 Apr 2013 20:00:28 GMT</pubDate>
			<description><![CDATA[Hi, 
 
I'm in completely new territory and I am unsure of where to start investigating. 
 
I work for a big org with many Windows PCs controlled by a...]]></description>
			<content:encoded><![CDATA[<div>Hi,<br />
<br />
I'm in completely new territory and I am unsure of where to start investigating.<br />
<br />
I work for a big org with many Windows PCs controlled by a Microsoft network.  We are using WebLogic 11g and Java 6<br />
<br />
The org began using CACs ( smart cards ) to authenticate users who want to get into their PCs and into Windows.<br />
<br />
My boss would like the users of our Java webapp ( Spring 3.1 and legacy servlets duct taped together ) to be able<br />
to access our Java webapp, without authentication, if they are already in Windows via their CAC.<br />
<br />
Like I wrote, I do not know what is involved or where to start for this goal.<br />
<br />
Would I try to get the WebApp to talk to the Microsoft Network or the user's PC to ask if that person has been CAC authenticated?<br />
<br />
Would I try to read a web certificate from the CAC with Java? If so, I have never used certificates before. Where could I go to learn about as if I am complete beginner, which I am?<br />
<br />
Thanks in advance for any information or tips<br />
<br />
Steve</div>

]]></content:encoded>
			<category domain="http://www.javaprogrammingforums.com/javaserver-pages-jsp-jstl/"><![CDATA[JavaServer Pages: JSP & JSTL]]></category>
			<dc:creator>tinker123</dc:creator>
			<guid isPermaLink="true">http://www.javaprogrammingforums.com/javaserver-pages-jsp-jstl/28713-java-webapps-cac-smart-card-authentication.html</guid>
		</item>
		<item>
			<title>Problem with RowMapper</title>
			<link>http://www.javaprogrammingforums.com/javaserver-pages-jsp-jstl/28589-problem-rowmapper.html</link>
			<pubDate>Wed, 24 Apr 2013 09:32:50 GMT</pubDate>
			<description><![CDATA[Hello Im having problems with RowMapper<>  
 
<div class="bbcode_container"> 
                 
<div class="bbcode_description" style="height:24px;...]]></description>
			<content:encoded><![CDATA[<div>Hello Im having problems with RowMapper&lt;&gt; <br />
<br />
<div class="bbcode_container">
                <div class="bbcode_description">Code :</div>
                <hr /><code class="bbcode_code"><div class="" style="font-family:monospace;"><pre style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">&nbsp;
import org.springframework.jdbc.core.JdbcTemplate;
import org.springframework.jdbc.core.RowMapper;
import org.springframework.jdbc.core.simple.*;
import org.springframework.jdbc.core.simple.SimpleJdbcInsert;
import org.springframework.transaction.annotation.Transactional;
&nbsp;
import javax.sql.DataSource;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
&nbsp;
public class CustomerManagerImpl implements CustomerManager {
&nbsp;
    private JdbcTemplate jdbc;
&nbsp;
&nbsp;
    public CustomerManagerImpl(DataSource dataSource) {
        this.jdbc = new JdbcTemplate(dataSource);
    }
&nbsp;
    @Override
    public void deleteCustomer(long id) {
        jdbc.update(&quot;DELETE FROM customers WHERE id=?&quot;, id);
    }
&nbsp;
    @Override
    public void updateCustomer(Customer c) {
        jdbc.update(&quot;UPDATE customers set fullname=?,address=?,phone=?,email=? where id=?&quot;,
                c.getFullname(), c.getAddress(), c.getPhone(), c.getEmail(), c.getId());
    }
&nbsp;
    private RowMapper&lt;Customer&gt; customerMapper = new RowMapper&lt;Customer&gt;() {
        @Override
        public Customer mapRow(ResultSet rs, int rowNum) throws SQLException {
            return new Customer(rs.getLong(&quot;id&quot;),rs.getString(&quot;fullname&quot;),rs.getString(&quot;address&quot;),rs.getString(&quot;phone&quot;),rs.getString(&quot;email&quot;));
        }
    };
&nbsp;
    @Transactional
    @Override
    public List&lt;Customer&gt; getAllCustomers() {
        return jdbc.query(&quot;SELECT * FROM customers&quot;, customerMapper);
    }
&nbsp;
    @Override
    public Customer getCustomerById(long id) {
        return jdbc.queryForObject(&quot;SELECT * FROM customers WHERE id=?&quot;, customerMapper, id);
    }
&nbsp;
    @Override
    public void createCustomer(Customer c) {
        SimpleJdbcInsert insertCustomer = new SimpleJdbcInsert(jdbc).withTableName(&quot;customers&quot;).usingGeneratedKeyColumns(&quot;id&quot;);
        Map&lt;String, Object&gt; parameters = new HashMap&lt;&gt;(2);
        parameters.put(&quot;fullname&quot;, c.getFullname());
        parameters.put(&quot;address&quot;, c.getAddress());
        parameters.put(&quot;phone&quot;, c.getPhone());
        parameters.put(&quot;email&quot;, c.getEmail());
        Number id = insertCustomer.executeAndReturnKey(parameters);
        c.setId(id.longValue());
    }
&nbsp;
}</pre></div></code><hr />
</div> <br />
<div class="bbcode_container">
	<div class="bbcode_description">PHP Code:</div>
	<hr /><code class="bbcode_code"><code><span style="color: #000000">
<span style="color: #0000BB">java</span><span style="color: #007700">:&nbsp;</span><span style="color: #0000BB">type&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">RowMapper&nbsp;does&nbsp;not&nbsp;take&nbsp;parameters<br />java</span><span style="color: #007700">:&nbsp;</span><span style="color: #0000BB">no&nbsp;suitable&nbsp;method&nbsp;found&nbsp;</span><span style="color: #007700">for&nbsp;</span><span style="color: #0000BB">update</span><span style="color: #007700">(</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">String</span><span style="color: #007700">,</span><span style="color: #0000BB">long</span><span style="color: #007700">)<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">method&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">JdbcTemplate</span><span style="color: #007700">.</span><span style="color: #0000BB">update</span><span style="color: #007700">(</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">String</span><span style="color: #007700">,</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">Object</span><span style="color: #007700">&#91;&#93;)&nbsp;</span><span style="color: #0000BB">is&nbsp;not&nbsp;applicable<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">(</span><span style="color: #0000BB">actual&nbsp;argument&nbsp;long&nbsp;cannot&nbsp;be&nbsp;converted&nbsp;to&nbsp;java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">Object</span><span style="color: #007700">&#91;&#93;&nbsp;</span><span style="color: #0000BB">by&nbsp;method&nbsp;invocation&nbsp;conversion</span><span style="color: #007700">)<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">method&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">JdbcTemplate</span><span style="color: #007700">.</span><span style="color: #0000BB">update</span><span style="color: #007700">(</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">String</span><span style="color: #007700">,</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">Object</span><span style="color: #007700">&#91;&#93;,</span><span style="color: #0000BB">int</span><span style="color: #007700">&#91;&#93;)&nbsp;</span><span style="color: #0000BB">is&nbsp;not&nbsp;applicable<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">(</span><span style="color: #0000BB">actual&nbsp;</span><span style="color: #007700">and&nbsp;</span><span style="color: #0000BB">formal&nbsp;argument&nbsp;lists&nbsp;differ&nbsp;in&nbsp;length</span><span style="color: #007700">)<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">method&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">JdbcTemplate</span><span style="color: #007700">.</span><span style="color: #0000BB">update</span><span style="color: #007700">(</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">String</span><span style="color: #007700">,</span><span style="color: #0000BB">org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">PreparedStatementSetter</span><span style="color: #007700">)&nbsp;</span><span style="color: #0000BB">is&nbsp;not&nbsp;applicable<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">(</span><span style="color: #0000BB">actual&nbsp;argument&nbsp;long&nbsp;cannot&nbsp;be&nbsp;converted&nbsp;to&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">PreparedStatementSetter&nbsp;by&nbsp;method&nbsp;invocation&nbsp;conversion</span><span style="color: #007700">)<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">method&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">JdbcTemplate</span><span style="color: #007700">.</span><span style="color: #0000BB">update</span><span style="color: #007700">(</span><span style="color: #0000BB">org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">PreparedStatementCreator</span><span style="color: #007700">,</span><span style="color: #0000BB">org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">support</span><span style="color: #007700">.</span><span style="color: #0000BB">KeyHolder</span><span style="color: #007700">)&nbsp;</span><span style="color: #0000BB">is&nbsp;not&nbsp;applicable<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">(</span><span style="color: #0000BB">actual&nbsp;argument&nbsp;java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">String&nbsp;cannot&nbsp;be&nbsp;converted&nbsp;to&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">PreparedStatementCreator&nbsp;by&nbsp;method&nbsp;invocation&nbsp;conversion</span><span style="color: #007700">)<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">method&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">JdbcTemplate</span><span style="color: #007700">.</span><span style="color: #0000BB">update</span><span style="color: #007700">(</span><span style="color: #0000BB">org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">PreparedStatementCreator</span><span style="color: #007700">)&nbsp;</span><span style="color: #0000BB">is&nbsp;not&nbsp;applicable<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">(</span><span style="color: #0000BB">actual&nbsp;</span><span style="color: #007700">and&nbsp;</span><span style="color: #0000BB">formal&nbsp;argument&nbsp;lists&nbsp;differ&nbsp;in&nbsp;length</span><span style="color: #007700">)<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">method&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">JdbcTemplate</span><span style="color: #007700">.</span><span style="color: #0000BB">update</span><span style="color: #007700">(</span><span style="color: #0000BB">org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">PreparedStatementCreator</span><span style="color: #007700">,</span><span style="color: #0000BB">org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">PreparedStatementSetter</span><span style="color: #007700">)&nbsp;</span><span style="color: #0000BB">is&nbsp;not&nbsp;applicable<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">(</span><span style="color: #0000BB">actual&nbsp;argument&nbsp;java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">String&nbsp;cannot&nbsp;be&nbsp;converted&nbsp;to&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">PreparedStatementCreator&nbsp;by&nbsp;method&nbsp;invocation&nbsp;conversion</span><span style="color: #007700">)<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">method&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">JdbcTemplate</span><span style="color: #007700">.</span><span style="color: #0000BB">update</span><span style="color: #007700">(</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">String</span><span style="color: #007700">)&nbsp;</span><span style="color: #0000BB">is&nbsp;not&nbsp;applicable<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">(</span><span style="color: #0000BB">actual&nbsp;</span><span style="color: #007700">and&nbsp;</span><span style="color: #0000BB">formal&nbsp;argument&nbsp;lists&nbsp;differ&nbsp;in&nbsp;length</span><span style="color: #007700">)<br /></span><span style="color: #0000BB">java</span><span style="color: #007700">:&nbsp;</span><span style="color: #0000BB">no&nbsp;suitable&nbsp;method&nbsp;found&nbsp;</span><span style="color: #007700">for&nbsp;</span><span style="color: #0000BB">update</span><span style="color: #007700">(</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">String</span><span style="color: #007700">,</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">String</span><span style="color: #007700">,</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">String</span><span style="color: #007700">,</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">String</span><span style="color: #007700">,</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">String</span><span style="color: #007700">,</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">Long</span><span style="color: #007700">)<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">method&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">JdbcTemplate</span><span style="color: #007700">.</span><span style="color: #0000BB">update</span><span style="color: #007700">(</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">String</span><span style="color: #007700">,</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">Object</span><span style="color: #007700">&#91;&#93;)&nbsp;</span><span style="color: #0000BB">is&nbsp;not&nbsp;applicable<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">(</span><span style="color: #0000BB">actual&nbsp;</span><span style="color: #007700">and&nbsp;</span><span style="color: #0000BB">formal&nbsp;argument&nbsp;lists&nbsp;differ&nbsp;in&nbsp;length</span><span style="color: #007700">)<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">method&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">JdbcTemplate</span><span style="color: #007700">.</span><span style="color: #0000BB">update</span><span style="color: #007700">(</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">String</span><span style="color: #007700">,</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">Object</span><span style="color: #007700">&#91;&#93;,</span><span style="color: #0000BB">int</span><span style="color: #007700">&#91;&#93;)&nbsp;</span><span style="color: #0000BB">is&nbsp;not&nbsp;applicable<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">(</span><span style="color: #0000BB">actual&nbsp;</span><span style="color: #007700">and&nbsp;</span><span style="color: #0000BB">formal&nbsp;argument&nbsp;lists&nbsp;differ&nbsp;in&nbsp;length</span><span style="color: #007700">)<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">method&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">JdbcTemplate</span><span style="color: #007700">.</span><span style="color: #0000BB">update</span><span style="color: #007700">(</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">String</span><span style="color: #007700">,</span><span style="color: #0000BB">org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">PreparedStatementSetter</span><span style="color: #007700">)&nbsp;</span><span style="color: #0000BB">is&nbsp;not&nbsp;applicable<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">(</span><span style="color: #0000BB">actual&nbsp;</span><span style="color: #007700">and&nbsp;</span><span style="color: #0000BB">formal&nbsp;argument&nbsp;lists&nbsp;differ&nbsp;in&nbsp;length</span><span style="color: #007700">)<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">method&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">JdbcTemplate</span><span style="color: #007700">.</span><span style="color: #0000BB">update</span><span style="color: #007700">(</span><span style="color: #0000BB">org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">PreparedStatementCreator</span><span style="color: #007700">,</span><span style="color: #0000BB">org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">support</span><span style="color: #007700">.</span><span style="color: #0000BB">KeyHolder</span><span style="color: #007700">)&nbsp;</span><span style="color: #0000BB">is&nbsp;not&nbsp;applicable<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">(</span><span style="color: #0000BB">actual&nbsp;</span><span style="color: #007700">and&nbsp;</span><span style="color: #0000BB">formal&nbsp;argument&nbsp;lists&nbsp;differ&nbsp;in&nbsp;length</span><span style="color: #007700">)<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">method&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">JdbcTemplate</span><span style="color: #007700">.</span><span style="color: #0000BB">update</span><span style="color: #007700">(</span><span style="color: #0000BB">org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">PreparedStatementCreator</span><span style="color: #007700">)&nbsp;</span><span style="color: #0000BB">is&nbsp;not&nbsp;applicable<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">(</span><span style="color: #0000BB">actual&nbsp;</span><span style="color: #007700">and&nbsp;</span><span style="color: #0000BB">formal&nbsp;argument&nbsp;lists&nbsp;differ&nbsp;in&nbsp;length</span><span style="color: #007700">)<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">method&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">JdbcTemplate</span><span style="color: #007700">.</span><span style="color: #0000BB">update</span><span style="color: #007700">(</span><span style="color: #0000BB">org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">PreparedStatementCreator</span><span style="color: #007700">,</span><span style="color: #0000BB">org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">PreparedStatementSetter</span><span style="color: #007700">)&nbsp;</span><span style="color: #0000BB">is&nbsp;not&nbsp;applicable<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">(</span><span style="color: #0000BB">actual&nbsp;</span><span style="color: #007700">and&nbsp;</span><span style="color: #0000BB">formal&nbsp;argument&nbsp;lists&nbsp;differ&nbsp;in&nbsp;length</span><span style="color: #007700">)<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">method&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">JdbcTemplate</span><span style="color: #007700">.</span><span style="color: #0000BB">update</span><span style="color: #007700">(</span><span style="color: #0000BB">java</span><span style="color: #007700">.</span><span style="color: #0000BB">lang</span><span style="color: #007700">.</span><span style="color: #0000BB">String</span><span style="color: #007700">)&nbsp;</span><span style="color: #0000BB">is&nbsp;not&nbsp;applicable<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">(</span><span style="color: #0000BB">actual&nbsp;</span><span style="color: #007700">and&nbsp;</span><span style="color: #0000BB">formal&nbsp;argument&nbsp;lists&nbsp;differ&nbsp;in&nbsp;length</span><span style="color: #007700">)<br /></span><span style="color: #0000BB">java</span><span style="color: #007700">:&nbsp;</span><span style="color: #0000BB">type&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">RowMapper&nbsp;does&nbsp;not&nbsp;take&nbsp;parameters&nbsp;<br /></span>
</span>
</code></code><hr />
</div><div class="bbcode_container">
                <div class="bbcode_description">Code :</div>
                <hr /><code class="bbcode_code"><div class="" style="font-family:monospace;"><pre style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">@Override
    public List&lt;Lease&gt; getLeasesForCustomer(final Customer c) {
        return jdbc.query(&quot;SELECT * FROM leases WHERE customerId=?&quot;, new RowMapper&lt;Lease&gt;() {
            @Override
            public Lease mapRow(ResultSet rs, int rowNum) throws SQLException {
                long bookId = rs.getLong(&quot;bookId&quot;);
                Book book = null;
                try {
                    book = bookManager.getBookById(bookId);
                } catch (BookException e) {
                    log.error(&quot;cannot find book&quot;, e);
                }
                return new Lease(rs.getLong(&quot;id&quot;), book, c, rs.getDate(&quot;startdate&quot;), rs.getDate(&quot;expectedend&quot;), rs.getDate(&quot;realend&quot;));
            }
        },
                c.getId());
    }</pre></div></code><hr />
</div> <br />
<div class="bbcode_container">
	<div class="bbcode_description">PHP Code:</div>
	<hr /><code class="bbcode_code"><code><span style="color: #000000">
<span style="color: #0000BB">java</span><span style="color: #007700">:&nbsp;</span><span style="color: #0000BB">type&nbsp;org</span><span style="color: #007700">.</span><span style="color: #0000BB">springframework</span><span style="color: #007700">.</span><span style="color: #0000BB">jdbc</span><span style="color: #007700">.</span><span style="color: #0000BB">core</span><span style="color: #007700">.</span><span style="color: #0000BB">RowMapper&nbsp;does&nbsp;not&nbsp;take&nbsp;parameters&nbsp;<br /></span>
</span>
</code></code><hr />
</div></div>

]]></content:encoded>
			<category domain="http://www.javaprogrammingforums.com/javaserver-pages-jsp-jstl/"><![CDATA[JavaServer Pages: JSP & JSTL]]></category>
			<dc:creator>justyStepi</dc:creator>
			<guid isPermaLink="true">http://www.javaprogrammingforums.com/javaserver-pages-jsp-jstl/28589-problem-rowmapper.html</guid>
		</item>
		<item>
			<title><![CDATA[[SOLVED] problems with lib imports and statements]]></title>
			<link>http://www.javaprogrammingforums.com/javaserver-pages-jsp-jstl/28555-problems-lib-imports-statements.html</link>
			<pubDate>Tue, 23 Apr 2013 18:41:35 GMT</pubDate>
			<description><![CDATA[<div class="bbcode_container"> 
                 
<div class="bbcode_description" style="height:24px; background-image:...]]></description>
			<content:encoded><![CDATA[<div><div class="bbcode_container">
                <div class="bbcode_description">Code :</div>
                <hr /><code class="bbcode_code"><div class="" style="font-family:monospace;"><pre style="font: normal normal 1em/1.2em monospace; margin:0; padding:0; background:none; vertical-align:top;">import org.springframework.jdbc.core.JdbcTemplate;
import org.springframework.jdbc.core.RowMapper;
import org.springframework.jdbc.core.simple.SimpleJdbcInsert;
import org.springframework.transaction.annotation.Transactional;
&nbsp;
import javax.sql.DataSource;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
&nbsp;
public class CustomerManagerImpl implements CustomerManager {
&nbsp;
    private JdbcTemplate jdbc;
&nbsp;
&nbsp;
    public CustomerManagerImpl(DataSource dataSource) {
        this.jdbc = new JdbcTemplate(dataSource);
    }
&nbsp;
    @Override
    public void deleteCustomer(long id) {
        jdbc.update(&quot;DELETE FROM customers WHERE id=?&quot;, id);
    }
&nbsp;
    @Override
    public void updateCustomer(Customer c) {
        jdbc.update(&quot;UPDATE customers set fullname=?,address=?,phone=?,email=? where id=?&quot;,
                c.getFullname(), c.getAddress(), c.getPhone(), c.getEmail(), c.getId());
    }
&nbsp;
    private RowMapper&lt;Customer&gt; customerMapper = new RowMapper&lt;Customer&gt;() {
        @Override
        public Customer mapRow(ResultSet rs, int rowNum) throws SQLException {
            return new Customer(rs.getLong(&quot;id&quot;),rs.getString(&quot;fullname&quot;),rs.getString(&quot;address&quot;),rs.getString(&quot;phone&quot;),rs.getString(&quot;email&quot;));
        }
    };
&nbsp;
    @Transactional
    @Override
    public List&lt;Customer&gt; getAllCustomers() {
        return jdbc.query(&quot;SELECT * FROM customers&quot;, customerMapper);
    }
&nbsp;
    @Override
    public Customer getCustomerById(long id) {
        return jdbc.queryForObject(&quot;SELECT * FROM customers WHERE id=?&quot;, customerMapper, id);
    }
&nbsp;
    @Override
    public void createCustomer(Customer c) {
        SimpleJdbcInsert insertCustomer = new SimpleJdbcInsert(jdbc).withTableName(&quot;customers&quot;).usingGeneratedKeyColumns(&quot;id&quot;);
        Map&lt;String, Object&gt; parameters = new HashMap&lt;&gt;(2);
        parameters.put(&quot;fullname&quot;, c.getFullname());
        parameters.put(&quot;address&quot;, c.getAddress());
        parameters.put(&quot;phone&quot;, c.getPhone());
        parameters.put(&quot;email&quot;, c.getEmail());
        Number id = insertCustomer.executeAndReturnKey(parameters);
        c.setId(id.longValue());
    }
&nbsp;
}</pre></div></code><hr />
</div> Here you can see the errors: <br />
<br />
<a href="http://www.javaprogrammingforums.com/attachments/javaserver-pages-jsp-jstl/2025d1366742353-problems-lib-imports-statements-errp1-jpg"  title="Name:  errP1.jpg
Views: 0
Size:  29.7 KB">errP1.jpg</a><a href="http://www.javaprogrammingforums.com/attachments/javaserver-pages-jsp-jstl/2026d1366742357-problems-lib-imports-statements-errp2-jpg"  title="Name:  errP2.jpg
Views: 0
Size:  28.5 KB">errP2.jpg</a></div>


	<div style="padding:10px">

	

	

	
		<fieldset class="fieldset">
			<legend>Attached Images</legend>
			<ul>
			<li>
	<img class="inlineimg" src="http://www.javaprogrammingforums.com/images/attach/jpg.gif" alt="File Type: jpg" />
	<a href="http://www.javaprogrammingforums.com/attachments/javaserver-pages-jsp-jstl/2025d1366742353-problems-lib-imports-statements-errp1-jpg">errP1.jpg</a> 
(29.7 KB)
</li><li>
	<img class="inlineimg" src="http://www.javaprogrammingforums.com/images/attach/jpg.gif" alt="File Type: jpg" />
	<a href="http://www.javaprogrammingforums.com/attachments/javaserver-pages-jsp-jstl/2026d1366742357-problems-lib-imports-statements-errp2-jpg">errP2.jpg</a> 
(28.5 KB)
</li>
			</ul>
			</fieldset>
	

	

	</div>
]]></content:encoded>
			<category domain="http://www.javaprogrammingforums.com/javaserver-pages-jsp-jstl/"><![CDATA[JavaServer Pages: JSP & JSTL]]></category>
			<dc:creator>justyStepi</dc:creator>
			<guid isPermaLink="true">http://www.javaprogrammingforums.com/javaserver-pages-jsp-jstl/28555-problems-lib-imports-statements.html</guid>
		</item>
	</channel>
</rss>
