Banco::getNome()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 2
Bugs 0 Features 0
Metric Value
c 2
b 0
f 0
dl 0
loc 4
rs 10
cc 1
eloc 2
nc 1
nop 0
1
<?php
2
3
namespace Umbrella\Ya\RetornoBoleto\Model;
4
5
use Easy\Collections\ArrayList;
6
use Easy\Collections\VectorInterface;
7
8
/**
9
 * Classe que representa um banco.
10
 */
11
class Banco
12
{
13
    protected $cod;
14
    protected $nome;
15
    protected $agencia;
16
    protected $dvAgencia;
17
    protected $conta;
18
    protected $dvConta;
19
    protected $dvAgenciaConta;
20
21
    /**
22
     * @var VectorInterface
23
     */
24
    protected $reservados;
25
26
    /**
27
     * Inicializa uma instância da classe Banco.
28
     */
29
    public function __construct()
30
    {
31
        $this->reservados = new ArrayList();
32
    }
33
34
    public function setReservados(VectorInterface $reservados)
35
    {
36
        $this->reservados = $reservados;
37
        return $this;
38
    }
39
40
    public function getReservados()
41
    {
42
        return $this->reservados;
43
    }
44
45
    public function getCod()
46
    {
47
        return $this->cod;
48
    }
49
50
    public function getAgencia()
51
    {
52
        return $this->agencia;
53
    }
54
55
    public function getDvAgencia()
56
    {
57
        return $this->dvAgencia;
58
    }
59
60
    public function getConta()
61
    {
62
        return $this->conta;
63
    }
64
65
    public function getDvConta()
66
    {
67
        return $this->dvConta;
68
    }
69
70
    public function setCod($cod)
71
    {
72
        $this->cod = $cod;
73
        return $this;
74
    }
75
76
    /**
77
     * @param string $agencia
78
     */
79
    public function setAgencia($agencia)
80
    {
81
        $this->agencia = $agencia;
82
        return $this;
83
    }
84
85
    /**
86
     * @param string $dvAgencia
87
     */
88
    public function setDvAgencia($dvAgencia)
89
    {
90
        $this->dvAgencia = $dvAgencia;
91
        return $this;
92
    }
93
94
    /**
95
     * @param string $conta
96
     */
97
    public function setConta($conta)
98
    {
99
        $this->conta = $conta;
100
        return $this;
101
    }
102
103
    /**
104
     * @param string $dvConta
105
     */
106
    public function setDvConta($dvConta)
107
    {
108
        $this->dvConta = $dvConta;
109
        return $this;
110
    }
111
112
    public function getDvAgenciaConta()
113
    {
114
        return $this->dvAgenciaConta;
115
    }
116
117
    /**
118
     * @param string $dvAgenciaConta
119
     */
120
    public function setDvAgenciaConta($dvAgenciaConta)
121
    {
122
        $this->dvAgenciaConta = $dvAgenciaConta;
123
        return $this;
124
    }
125
126
    public function getNome()
127
    {
128
        return $this->nome;
129
    }
130
131
    /**
132
     * @param string $nome
133
     */
134
    public function setNome($nome)
135
    {
136
        $this->nome = $nome;
137
        return $this;
138
    }
139
140
    /**
141
     * @param string $cnab
142
     */
143
    public function addReservado($cnab)
144
    {
145
        $trim = trim($cnab);
146
        if (!empty($trim)) {
147
            $this->reservados->add($cnab);
148
        }
149
        return $this;
150
    }
151
152
    public function removeReservado($cnab)
153
    {
154
        $this->reservados->remove($cnab);
155
        return $this;
156
    }
157
}
158