Package com.signalapp.dao
Class DerivadorDAO
- java.lang.Object
-
- com.signalapp.dao.BaseDAO<Derivador>
-
- com.signalapp.dao.DerivadorDAO
-
-
Field Summary
-
Fields inherited from class com.signalapp.dao.BaseDAO
connection
-
-
Constructor Summary
Constructors Constructor Description DerivadorDAO()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DerivadorfindByComponenteId(int componenteId)Finds a derivador component by its componente IDprotected java.lang.String[]getColumnNames()Gets the column names for the Derivadores tableprotected java.lang.StringgetTableName()Gets the name of the database tableprotected DerivadormapResultSetToEntity(java.sql.ResultSet rs)Maps a ResultSet row to a Derivador entityprotected voidsetPreparedStatementParams(java.sql.PreparedStatement ps, Derivador entity)Sets the parameters for a PreparedStatement based on Derivador properties
-
-
-
Method Detail
-
getTableName
protected java.lang.String getTableName()
Gets the name of the database table- Specified by:
getTableNamein classBaseDAO<Derivador>- Returns:
- The table name "derivadores"
-
getColumnNames
protected java.lang.String[] getColumnNames()
Gets the column names for the Derivadores table- Specified by:
getColumnNamesin classBaseDAO<Derivador>- Returns:
- Array of column names
-
mapResultSetToEntity
protected Derivador mapResultSetToEntity(java.sql.ResultSet rs) throws java.sql.SQLException
Maps a ResultSet row to a Derivador entity- Specified by:
mapResultSetToEntityin classBaseDAO<Derivador>- Parameters:
rs- The ResultSet containing the database row- Returns:
- A new Derivador object with data from the ResultSet
- Throws:
java.sql.SQLException- if a database error occurs
-
setPreparedStatementParams
protected void setPreparedStatementParams(java.sql.PreparedStatement ps, Derivador entity) throws java.sql.SQLExceptionSets the parameters for a PreparedStatement based on Derivador properties- Specified by:
setPreparedStatementParamsin classBaseDAO<Derivador>- Parameters:
ps- The PreparedStatement to set parameters forentity- The Derivador entity containing the values to set- Throws:
java.sql.SQLException- if a database error occurs
-
findByComponenteId
public Derivador findByComponenteId(int componenteId) throws java.sql.SQLException
Finds a derivador component by its componente ID- Parameters:
componenteId- The ID of the associated componente- Returns:
- The Derivador object if found, null otherwise
- Throws:
java.sql.SQLException- if a database error occurs
-
-