/// <summary>
/// Validações particulares do banco Banestes
/// </summary>
public override void ValidaBoleto(Boleto boleto)
{
try
{
//Carteiras válidas
// 00 - Sem registro;
//Atribui o nome do banco ao local de pagamento
boleto.LocalPagamento += Nome + ". Após o vencimento, somente no BANESTES";
//Verifica se o nosso número é válido
if (Utils.ToInt64(boleto.NossoNumero) == 0)
throw new NotImplementedException("Nosso número inválido");
//Verifica se data do processamento é valida
if (boleto.DataProcessamento == DateTime.MinValue)
boleto.DataProcessamento = DateTime.Now;
//Verifica se data do documento é valida
if (boleto.DataDocumento == DateTime.MinValue)
boleto.DataDocumento = DateTime.Now;
boleto.FormataCampos();
}
catch (Exception e)
{
throw new Exception("Erro ao validar boletos.", e);
}
}