super(connSource, connDestination);
}
public PreparedStatement prepareStatement(ResultSet rs,
PreparedStatement statement, List<String> messages) throws Exception {
Encontro en = (Encontro) getObject(rs);
statement.setLong(1, en.getId());
statement.setString(2, en.getData());
statement.setDate(3, new java.sql.Date(en.getTimestamp().getTime()));
statement.setNull(4, Types.NULL);
if (!(en.getConteudo() == null)){
statement.setLong(5, en.getConteudo().getId());
} else {
statement.setNull(5, Types.NULL);
messages.add("Registro de ENCONTRO (id: " + en.getId()
+ ") com chave estrangeira de Conteudo = NULL");
}
if (!(en.getTurma() == null)){
statement.setLong(6, en.getTurma().getId());
} else {
statement.setNull(6, Types.NULL);
messages.add("Registro de ENCONTRO (id: " + en.getId()
+ ") com chave estrangeira de Turma = NULL");
}
return statement;
}