package it.csi.demo.democomp.business.business.dao.refappdao.metadata;

import it.csi.demo.democomp.business.business.dao.refappdao.dto.*;
import it.csi.demo.democomp.business.business.dao.metadata.*;
import java.util.List;

/**
 * @generated
 */
public class ProvinciaMetadata implements DAOMetadata {

	private String[] columnNames;

	public ProvinciaMetadata() {
		columnNames = new String[]{"ID_PROVINCIA", "DESCRIZIONE", "ID_REGIONE"};
	}

	public ProvinciaMetadata(String[] columnNames) {
		this.columnNames = columnNames;
	}

	/**
	 * Method 'getTableName'
	 * 
	 * @return String
	 * @generated
	 */
	public String getTableName() {
		return "REFAPP_D_PROVINCIA";
	}

	public String getColumnName(String prefixPropName, String propName) {
		if (prefixPropName != null && prefixPropName.length() > 0)
			return getColumnName(prefixPropName + "." + propName);
		else
			return getColumnName(propName);
	}

	/**
	 * Method 'getColumnName'
	 * 
	 * @param propName
	 * @return String
	 * @generated
	 */
	public String getColumnName(String propName) {
		if ("idProvincia".equalsIgnoreCase(propName)) {
			return "ID_PROVINCIA";
		}
		if ("descrizione".equalsIgnoreCase(propName)) {
			return "DESCRIZIONE";
		}
		if ("idRegione".equalsIgnoreCase(propName)) {
			return "ID_REGIONE";
		}
		/// se non trovato
		throw new IllegalArgumentException("proprieta' " + propName
				+ " non trovata per il DTO ProvinciaDto");
	}

	/**
	 * Method 'getColumnNames'
	 * 
	 * @return String[]
	 * @generated
	 */
	public String[] getColumnNames() {
		return this.columnNames;
	}

}
