/*
 * $Id: TabInfo.java,v 1.9 2005/08/25 01:50:26 marbobo Exp $
 *
 * Copyright (c) Siemens AG 2008 
 *           (c) Universität Paderborn 2008 
 * Licensed under EUPL 1.1. 
 *
 * $Log: TabInfo.java,v $
 * Revision 1.9  2005/08/25 01:50:26  marbobo
 * + Serialisierbar gemacht
 *
 * Revision 1.8  2005/08/10 19:11:14  marbobo
 * + Hide-Parameter hinzugefügt
 *
 * Revision 1.7  2005/08/09 19:51:20  marbobo
 * + Eigenschaften von registerkarten ändern implementiert
 *
 * Revision 1.6  2005/01/07 21:21:43  jonyp
 * getTabLabel now return descripton of the tab
 *
 * Revision 1.5  2004/08/19 22:34:37  jonyp
 * *** empty log message ***
 *
 * Revision 1.4  2004/08/04 23:22:09  marbobo
 * + Flag für Kategorien/Projekte berücksichtigen
 *
 * Revision 1.3  2004/07/13 14:42:12  jonyp
 * *** empty log message ***
 *
 * Revision 1.2  2004/07/13 14:37:03  jonyp
 * commented out functionality for getTabLabel();
 *
 * Revision 1.1  2004/07/10 22:42:20  marbobo
 * + Initiale Version
 *
 */

package vkc.view.bean;

import java.io.Serializable;

public class TabInfo implements Serializable {
	public static final Integer VIEWTYPEID_CLASSIC = new Integer(1);
	public static final Integer VIEWTYPEID_ALTERNATE = new Integer(2);
	
	private boolean enabled = true;
	private boolean hide = false;
	
	private Integer tabId = null;
	private Integer tabFlag = null; 
	private Integer tabStatus = null; 
	private Integer viewTypeId = VIEWTYPEID_CLASSIC;
	
	private String tabDescription = "";
	private String tabLink = "";
	private String tabName = "";
	private String tabFlagLabel = "";
	private String tabStatusLabel = "";
	private String uniqueName = "";
	
	public String getTabDescription() {
		return tabDescription;
	}

	public void setTabDescription(String string) {
		tabDescription = string;
	}

	public Integer getTabId() {
		return tabId;
	}

	public void setTabId(Integer integer) {
		tabId = integer;
	}

	public String getTabLabel() {
/*
	    String label = getTabName();
	    
	    if (!StringUtils.isEmpty(getTabDescription())) {
	        label += "\\n\\n" + getTabDescription();
	    }
	    
	    if (!StringUtils.isEmpty(getTabFlagLabel())) {
	        label += "\n\n" + getTabFlagLabel();
	    }

	    if (!StringUtils.isEmpty(getTabStatusLabel())) {
	        label += "\\n\\n" + getTabStatusLabel();
	    }
	    
	    return label;
	    */
	    return getTabDescription();
	}
	
	public String getTabLink() {
		return tabLink;
	}

	public void setTabLink(String string) {
		tabLink = string;
	}

	public String getTabName() {
		return tabName;
	}

	public void setTabName(String string) {
		tabName = string;
	}

    public String getTabShortName() {
		if (getTabName().length() > 12) {
			return getTabName().substring(0, 11) + "...";
		} 

		return getTabName();
    }

    public Integer getTabFlag() {
        return tabFlag;
    }

    public void setTabFlag(Integer tabFlag1) {
        tabFlag = tabFlag1;
    }

    public Integer getTabStatus() {
        return tabStatus;
    }

    public void setTabStatus(Integer tabStatus1) {
        tabStatus = tabStatus1;
    }

    public String getTabFlagLabel() {
        return tabFlagLabel;
    }
    
    public void setTabFlagLabel(String tabFlagLabel1) {
        tabFlagLabel = tabFlagLabel1;
    }

    public String getTabStatusLabel() {
        return tabStatusLabel;
    }
    
    public void setTabStatusLabel(String tabStatusLabel1) {
        tabStatusLabel = tabStatusLabel1;
    }

	public boolean isEnabled() {
		return enabled;
	}

	public void setEnabled(boolean enabled) {
		this.enabled = enabled;
	}

	public String getUniqueName() {
		return uniqueName;
	}

	public void setUniqueName(String uniqueName) {
		this.uniqueName = uniqueName;
	}

	public Integer getViewTypeId() {
		return viewTypeId;
	}

	public void setViewTypeId(Integer viewTypeId) {
		this.viewTypeId = viewTypeId;
	}

	public boolean isHide() {
		return hide;
	}

	public void setHide(boolean hide) {
		this.hide = hide;
	}
}