package br.mp.mprj.portal.portlet.gestaomensagens.service.model;

import java.io.Serializable;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;

/**
 * This class is used by SOAP remote services, specifically {@link br.mp.mprj.portal.portlet.gestaomensagens.service.service.http.TemplateServiceSoap}.
 *
 * @author Henrique Simoes
 * @see br.mp.mprj.portal.portlet.gestaomensagens.service.service.http.TemplateServiceSoap
 * @generated
 */
public class TemplateSoap implements Serializable {
    private String _uuid;
    private long _templateId;
    private long _companyId;
    private long _groupId;
    private long _userId;
    private String _nome;
    private int _estilo;
    private boolean _ativo;
    private String _cabecalho;
    private String _rodape;
    private String _corpo;
    private Date _dataCriacao;
    private Date _dataAtualizacao;
    private long _thumbnailFileEntryId;
    private String _thumbnailURL;

    public TemplateSoap() {
    }

    public static TemplateSoap toSoapModel(Template model) {
        TemplateSoap soapModel = new TemplateSoap();

        soapModel.setUuid(model.getUuid());
        soapModel.setTemplateId(model.getTemplateId());
        soapModel.setCompanyId(model.getCompanyId());
        soapModel.setGroupId(model.getGroupId());
        soapModel.setUserId(model.getUserId());
        soapModel.setNome(model.getNome());
        soapModel.setEstilo(model.getEstilo());
        soapModel.setAtivo(model.getAtivo());
        soapModel.setCabecalho(model.getCabecalho());
        soapModel.setRodape(model.getRodape());
        soapModel.setCorpo(model.getCorpo());
        soapModel.setDataCriacao(model.getDataCriacao());
        soapModel.setDataAtualizacao(model.getDataAtualizacao());
        soapModel.setThumbnailFileEntryId(model.getThumbnailFileEntryId());
        soapModel.setThumbnailURL(model.getThumbnailURL());

        return soapModel;
    }

    public static TemplateSoap[] toSoapModels(Template[] models) {
        TemplateSoap[] soapModels = new TemplateSoap[models.length];

        for (int i = 0; i < models.length; i++) {
            soapModels[i] = toSoapModel(models[i]);
        }

        return soapModels;
    }

    public static TemplateSoap[][] toSoapModels(Template[][] models) {
        TemplateSoap[][] soapModels = null;

        if (models.length > 0) {
            soapModels = new TemplateSoap[models.length][models[0].length];
        } else {
            soapModels = new TemplateSoap[0][0];
        }

        for (int i = 0; i < models.length; i++) {
            soapModels[i] = toSoapModels(models[i]);
        }

        return soapModels;
    }

    public static TemplateSoap[] toSoapModels(List<Template> models) {
        List<TemplateSoap> soapModels = new ArrayList<TemplateSoap>(models.size());

        for (Template model : models) {
            soapModels.add(toSoapModel(model));
        }

        return soapModels.toArray(new TemplateSoap[soapModels.size()]);
    }

    public long getPrimaryKey() {
        return _templateId;
    }

    public void setPrimaryKey(long pk) {
        setTemplateId(pk);
    }

    public String getUuid() {
        return _uuid;
    }

    public void setUuid(String uuid) {
        _uuid = uuid;
    }

    public long getTemplateId() {
        return _templateId;
    }

    public void setTemplateId(long templateId) {
        _templateId = templateId;
    }

    public long getCompanyId() {
        return _companyId;
    }

    public void setCompanyId(long companyId) {
        _companyId = companyId;
    }

    public long getGroupId() {
        return _groupId;
    }

    public void setGroupId(long groupId) {
        _groupId = groupId;
    }

    public long getUserId() {
        return _userId;
    }

    public void setUserId(long userId) {
        _userId = userId;
    }

    public String getNome() {
        return _nome;
    }

    public void setNome(String nome) {
        _nome = nome;
    }

    public int getEstilo() {
        return _estilo;
    }

    public void setEstilo(int estilo) {
        _estilo = estilo;
    }

    public boolean getAtivo() {
        return _ativo;
    }

    public boolean isAtivo() {
        return _ativo;
    }

    public void setAtivo(boolean ativo) {
        _ativo = ativo;
    }

    public String getCabecalho() {
        return _cabecalho;
    }

    public void setCabecalho(String cabecalho) {
        _cabecalho = cabecalho;
    }

    public String getRodape() {
        return _rodape;
    }

    public void setRodape(String rodape) {
        _rodape = rodape;
    }

    public String getCorpo() {
        return _corpo;
    }

    public void setCorpo(String corpo) {
        _corpo = corpo;
    }

    public Date getDataCriacao() {
        return _dataCriacao;
    }

    public void setDataCriacao(Date dataCriacao) {
        _dataCriacao = dataCriacao;
    }

    public Date getDataAtualizacao() {
        return _dataAtualizacao;
    }

    public void setDataAtualizacao(Date dataAtualizacao) {
        _dataAtualizacao = dataAtualizacao;
    }

    public long getThumbnailFileEntryId() {
        return _thumbnailFileEntryId;
    }

    public void setThumbnailFileEntryId(long thumbnailFileEntryId) {
        _thumbnailFileEntryId = thumbnailFileEntryId;
    }

    public String getThumbnailURL() {
        return _thumbnailURL;
    }

    public void setThumbnailURL(String thumbnailURL) {
        _thumbnailURL = thumbnailURL;
    }
}
