PHP Class Eduardokum\LaravelBoleto\Cnab\Retorno\AbstractRetorno

Inheritance: implements Countable, implements SeekableIterator
Show file Open project: eduardokum/laravel-boleto Class Usage Examples

Protected Properties

Property Type Description
$codigoBanco string Código do banco
$detalhe Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240\Detalhe[] | Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400\Detalhe[]
$file array Arquivo transformado em array por linha.
$header Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240\Header | Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400\Header
$increment integer Incremeto de detalhes
$processado boolean Se Cnab ja foi processado
$totais array Helper de totais.
$trailer Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240\Trailer | Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400\Trailer

Public Methods

Method Description
__construct ( String $file )
count ( )
current ( )
getBancoNome ( ) : mixed
getCodigoBanco ( ) : string Retorna o código do banco
getDetalhe ( $i ) : Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240\Detalhe[] | Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400\Detalhe[]
getDetalhes ( ) : Collection
getHeader ( ) : Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240\Header | Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400\Header
getTrailer ( ) : Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240\Trailer | Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400\Trailer
key ( )
next ( )
rewind ( )
seek ( $position )
valid ( )

Protected Methods

Method Description
detalheAtual ( ) : Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240\Detalhe | Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400\Detalhe Retorna o detalhe atual.
incrementDetalhe ( ) Incrementa o detalhe.
isProcessado ( ) : boolean Se esta processado
processar ( ) Processa o arquivo
rem ( $i, $f, &$array ) : string Remove trecho do array.
setProcessado ( ) Seta cnab como processado
toArray ( ) : array Retorna o array.

Method Details

__construct() public method

public __construct ( String $file )
$file String

count() public method

public count ( )

current() public method

public current ( )

detalheAtual() protected method

Retorna o detalhe atual.
protected detalheAtual ( ) : Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240\Detalhe | Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400\Detalhe
return Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240\Detalhe | Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400\Detalhe

getBancoNome() public method

public getBancoNome ( ) : mixed
return mixed

getCodigoBanco() public method

Retorna o código do banco
public getCodigoBanco ( ) : string
return string

getDetalhe() public method

public getDetalhe ( $i ) : Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240\Detalhe[] | Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400\Detalhe[]
$i
return Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240\Detalhe[] | Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400\Detalhe[]

getDetalhes() public method

public getDetalhes ( ) : Collection
return Illuminate\Support\Collection

getHeader() public method

public getHeader ( ) : Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240\Header | Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400\Header
return Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240\Header | Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400\Header

getTrailer() public method

public getTrailer ( ) : Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240\Trailer | Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400\Trailer
return Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240\Trailer | Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400\Trailer

incrementDetalhe() abstract protected method

Incrementa o detalhe.
abstract protected incrementDetalhe ( )

isProcessado() protected method

Se esta processado
protected isProcessado ( ) : boolean
return boolean

key() public method

public key ( )

next() public method

public next ( )

processar() abstract protected method

Processa o arquivo
abstract protected processar ( )

rem() protected method

Remove trecho do array.
protected rem ( $i, $f, &$array ) : string
$i
$f
$array
return string

rewind() public method

public rewind ( )

seek() public method

public seek ( $position )

setProcessado() protected method

Seta cnab como processado
protected setProcessado ( )

toArray() abstract protected method

Retorna o array.
abstract protected toArray ( ) : array
return array

valid() public method

public valid ( )

Property Details

$codigoBanco protected property

Código do banco
protected string $codigoBanco
return string

$detalhe protected property

protected Detalhe[],Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240|Detalhe[],Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400 $detalhe
return Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240\Detalhe[] | Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400\Detalhe[]

$file protected property

Arquivo transformado em array por linha.
protected array $file
return array

$header protected property

protected Header,Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240|Header,Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400 $header
return Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240\Header | Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400\Header

$increment protected property

Incremeto de detalhes
protected int $increment
return integer

$processado protected property

Se Cnab ja foi processado
protected bool $processado
return boolean

$totais protected property

Helper de totais.
protected array $totais
return array

$trailer protected property

protected Trailer,Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240|Trailer,Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400 $trailer
return Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab240\Trailer | Eduardokum\LaravelBoleto\Contracts\Cnab\Retorno\Cnab400\Trailer