• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

wmixvideo / nfe / #6582

17 Jul 2025 09:30PM UTC coverage: 51.231% (+24.2%) from 26.996%
#6582

push

web-flow
Adequação do mapeamento de infLocalCarrega e infLocalDescarrega ao xs:choice do schema MDF-e (#1054)

* Adequação do mapeamento de infLocalCarrega e infLocalDescarrega ao xs:choice do schema MDF-e

* Adequação do mapeamento de infLocalCarrega e infLocalDescarrega ao xs:choice do schema MDF-e

14006 of 27339 relevant lines covered (51.23%)

0.51 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

50.0
/src/main/java/com/fincatto/documentofiscal/mdfe3/classes/nota/MDFInfoAutorizacaoDownload.java
1
package com.fincatto.documentofiscal.mdfe3.classes.nota;
2

3
import org.simpleframework.xml.Element;
4
import org.simpleframework.xml.Namespace;
5
import org.simpleframework.xml.Root;
6

7
import com.fincatto.documentofiscal.DFBase;
8
import com.fincatto.documentofiscal.validadores.DFStringValidador;
9

10
/**
11
 * Created by Eldevan Nery Junior on 03/11/17.
12
 * <h1>Autorizados para download do XML do DF-e</h1>
13
 */
14
@Root(name = "autXML")
15
@Namespace(reference = "http://www.portalfiscal.inf.br/mdfe")
16
public class MDFInfoAutorizacaoDownload extends DFBase {
17
    private static final long serialVersionUID = -5711457880712720488L;
18

19
    private static final String INFO = "Autorizacao Download MDFe";
20

21
    @Element(name = "CNPJ", required = false)
22
    private String cnpj;
23

24
    @Element(name = "CPF", required = false)
25
    private String cpf;
26

27
    public MDFInfoAutorizacaoDownload() {
1✔
28
        this.cnpj = null;
1✔
29
        this.cpf = null;
1✔
30
    }
1✔
31

32
    public String getCnpj() {
33
        return this.cnpj;
×
34
    }
35

36
    /**
37
     * CNPJ do autorizado<br>
38
     * Informar zeros não significativos
39
     */
40
    public void setCnpj(final String cnpj) {
41
        if (this.cpf != null) {
1✔
42
            throw new IllegalStateException("Nao deve setar CNPJ se CPF esteja setado em " + MDFInfoAutorizacaoDownload.INFO);
×
43
        }
44
        this.cnpj = DFStringValidador.cnpj(cnpj, MDFInfoAutorizacaoDownload.INFO);
1✔
45
    }
1✔
46

47
    public String getCpf() {
48
        return this.cpf;
×
49
    }
50

51
    /**
52
     * CPF do autorizado<br>
53
     * Informar zeros não significativos
54
     */
55
    public void setCpf(final String cpf) {
56
        if (this.cnpj != null) {
×
57
            throw new IllegalStateException("Nao deve setar CPF se CNPJ esteja setado em " + MDFInfoAutorizacaoDownload.INFO);
×
58
        }
59
        this.cpf = DFStringValidador.cpf(cpf, MDFInfoAutorizacaoDownload.INFO);
×
60
    }
×
61
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc