// Path: 02-Sourcecode/nfscan-server/src/main/java/cc/nfscan/server/domain/ElectronicTaxReceiptArchive.java
// @DynamoDBTable(tableName = "NFSCAN-ELECTRONICTAXRECEIPTARCHIVE")
// public class ElectronicTaxReceiptArchive implements IDomain {
// 
//     private static final long serialVersionUID = 1L;
// 
//     /**
//      * identifier
//      */
//     private String id;
// 
//     /**
//      * access key that contains all required receipt information to donate
//      */
//     private String accessKey;
// 
//     /**
//      * total
//      */
//     private Double total;
// 
//     /**
//      * dateInsertion of this object
//      */
//     private Date dateInsertion;
// 
// 
//     public ElectronicTaxReceiptArchive() {
//     }
// 
//     @DynamoDBHashKey(attributeName = "electronictaxreceiptarchive_id")
//     public String getId() {
//         return id;
//     }
// 
//     public void setId(String id) {
//         this.id = id;
//     }
// 
//     @DynamoDBAttribute(attributeName = "accessKey")
//     public String getAccessKey() {
//         return accessKey;
//     }
// 
//     public void setAccessKey(String accessKey) {
//         this.accessKey = accessKey;
//     }
// 
//     @DynamoDBAttribute(attributeName = "total")
//     public Double getTotal() {
//         return total;
//     }
// 
//     public void setTotal(Double total) {
//         this.total = total;
//     }
// 
//     @DynamoDBAttribute(attributeName = "dateInsertion")
//     public Date getDateInsertion() {
//         return dateInsertion;
//     }
// 
//     public void setDateInsertion(Date dateInsertion) {
//         this.dateInsertion = dateInsertion;
//     }
// 
//     @Override
//     public String toString() {
//         return "ElectronicTaxReceiptArchive{" +
//                 "id='" + id + '\'' +
//                 ", accessKey='" + accessKey + '\'' +
//                 ", dateInsertion=" + dateInsertion +
//                 '}';
//     }
// }


import cc.nfscan.server.domain.ElectronicTaxReceiptArchive;
import org.springframework.dao.DataAccessException;
import org.springframework.stereotype.Repository;
package cc.nfscan.server.dao;



/**
 * ElectronicTaxReceipt Archive Data Access Object
 *
 * @author Paulo Miguel Almeida <a href="http://github.com/PauloMigAlmeida">@PauloMigAlmeida</a>
 */
@Repository
public class EletronicTaxReceiptArchiveDAO extends AbstractDAO<ElectronicTaxReceiptArchive> {

    /**
     * Specifies which Entity we are going to provide this functionality
     *
     * @return a class object
     */
    @Override
    public Class<ElectronicTaxReceiptArchive> getType() {
        return ElectronicTaxReceiptArchive.class;
    }


    /**
     * Find object by id
     *
     * @param entity object we want to find
     * @return a entity object or null
     * @throws DataAccessException
     */
    @Override
    public ElectronicTaxReceiptArchive findById(ElectronicTaxReceiptArchive entity) throws DataAccessException {
        if (!entity.getId().trim().isEmpty()) {
// Path: 02-Sourcecode/nfscan-server/src/main/java/cc/nfscan/server/domain/ElectronicTaxReceiptArchive.java
// @DynamoDBTable(tableName = "NFSCAN-ELECTRONICTAXRECEIPTARCHIVE")
// public class ElectronicTaxReceiptArchive implements IDomain {
// 
//     private static final long serialVersionUID = 1L;
// 
//     /**
//      * identifier
//      */
//     private String id;
// 
//     /**
//      * access key that contains all required receipt information to donate
//      */
//     private String accessKey;
// 
//     /**
//      * total
//      */
//     private Double total;
// 
//     /**
//      * dateInsertion of this object
//      */
//     private Date dateInsertion;
// 
// 
//     public ElectronicTaxReceiptArchive() {
//     }
// 
//     @DynamoDBHashKey(attributeName = "electronictaxreceiptarchive_id")
//     public String getId() {
//         return id;
//     }
// 
//     public void setId(String id) {
//         this.id = id;
//     }
// 
//     @DynamoDBAttribute(attributeName = "accessKey")
//     public String getAccessKey() {
//         return accessKey;
//     }
// 
//     public void setAccessKey(String accessKey) {
//         this.accessKey = accessKey;
//     }
// 
//     @DynamoDBAttribute(attributeName = "total")
//     public Double getTotal() {
//         return total;
//     }
// 
//     public void setTotal(Double total) {
//         this.total = total;
//     }
// 
//     @DynamoDBAttribute(attributeName = "dateInsertion")
//     public Date getDateInsertion() {
//         return dateInsertion;
//     }
// 
//     public void setDateInsertion(Date dateInsertion) {
//         this.dateInsertion = dateInsertion;
//     }
// 
//     @Override
//     public String toString() {
//         return "ElectronicTaxReceiptArchive{" +
//                 "id='" + id + '\'' +
//                 ", accessKey='" + accessKey + '\'' +
//                 ", dateInsertion=" + dateInsertion +
//                 '}';
//     }
// }


// Path: 02-Sourcecode/nfscan-server/src/main/java/cc/nfscan/server/dao/EletronicTaxReceiptArchiveDAO.java
import cc.nfscan.server.domain.ElectronicTaxReceiptArchive;
import org.springframework.dao.DataAccessException;
import org.springframework.stereotype.Repository;

package cc.nfscan.server.dao;



/**
 * ElectronicTaxReceipt Archive Data Access Object
 *
 * @author Paulo Miguel Almeida <a href="http://github.com/PauloMigAlmeida">@PauloMigAlmeida</a>
 */
@Repository
public class EletronicTaxReceiptArchiveDAO extends AbstractDAO<ElectronicTaxReceiptArchive> {

    /**
     * Specifies which Entity we are going to provide this functionality
     *
     * @return a class object
     */
    @Override
    public Class<ElectronicTaxReceiptArchive> getType() {
        return ElectronicTaxReceiptArchive.class;
    }


    /**
     * Find object by id
     *
     * @param entity object we want to find
     * @return a entity object or null
     * @throws DataAccessException
     */
    @Override
    public ElectronicTaxReceiptArchive findById(ElectronicTaxReceiptArchive entity) throws DataAccessException {
        if (!entity.getId().trim().isEmpty()) {
            return dynamoDBMapper.load(getType(), entity.getId());