package com.sinosig.util.domain;

import java.io.Serializable;
import org.springframework.util.DigestUtils;

public class PSSystem implements Serializable {
    /**
	 * default serialVersionUID
	 */
	private static final long serialVersionUID = 1L;

    /**
     * 部署系统标识
     */
    String pssystemid;

    /**
     * 部署系统名称
     */
    String pssystemname;

    /*
	 * 逻辑名
	 */
	String logicname;

    /**
     * 部署域标识
     */
    String workflowid;

    /**
     * 部署域名称
     */
    String workflowname;

    /**
	 * 服务标识
	 */
	String serviceid;

	/**
	 * 服务路径
	 */
	String serviceurl;

    public String getPssystemid() {
        if (this.pssystemid == null) {
            return this.pssystemid;
        }
        String srtTmp = this.pssystemid;
        if (this.workflowid != null) {
            srtTmp = this.workflowid + srtTmp;
        }
        return DigestUtils.md5DigestAsHex(srtTmp.getBytes());
    }

    public void setPssystemid(String pssystemid) {
        this.pssystemid = pssystemid;
    }

    public String getPssystemName() {
        return this.pssystemname;
    }

    public void setPssystemName(String pssystemname) {
        this.pssystemname = pssystemname;
    }

    public String getWorkflowid() {
        if (this.workflowid != null) {
            return DigestUtils.md5DigestAsHex(this.workflowid.getBytes());
        }
        return this.workflowid;
    }

    public void setWorkflowid(String workflowid) {
        this.workflowid = workflowid;
    }

    public String getWorkflowname() {
        return this.workflowname;
    }

    public void setWorkflowname(String workflowname) {
        this.workflowname = workflowname;
    }

    public String getServiceid() {
		return serviceid;
	}

	public void setServiceid(String serviceid) {
		this.serviceid = serviceid;
	}

	public String getServiceurl() {
		return serviceurl;
	}

	public void setServiceurl(String serviceurl) {
		this.serviceurl = serviceurl;
	}

	public String getLogicname() {
		return logicname;
	}

	public void setLogicname(String logicname) {
		this.logicname = logicname;
	}

}
