<?php
/**
 * ColumnConfiguration Base Implementation
 * 
 * @author Elze Kool <info@visualmedia.nl>
 */

namespace VisualM\ManagementBundle\AdminList\Column;

/**
 * ColumnConfiguration Base Implementation
 *
 * @author Elze Kool <info@visualmedia.nl>
 */
abstract class ColumnConfigurationAbstract implements ColumnConfigurationInterface
{
    /**
     * Field
     * @var string
     */
    private $field;
    
    /**
     * Title
     * @var string
     */
    private $title;
    
    /**
     * Sortable
     * @var boolean
     */
    private $sortable;

    /**
     * Item Template
     * @var string
     */
    private $itemTemplate;

    /**
     * Header Template
     * @var string
     */
    private $headerTemplate;
    
    /**
     * Footer Template
     * @var string
     */
    private $footerTemplate;
    
    /**
     * Item Class
     * @var string
     */
    private $itemClass;
    
    /**
     * Constructor
     * 
     * @param string  $field          Field (null for no field binding)
     * @param string  $title          Title
     * @param boolean $sortable       Sortable
     * @param string  $itemTemplate   Item Template
     * @param string  $headerTemplate Header Template
     * @param string  $footerTemplate Header Template
     * @param string  $itemClass      Item Class
     */
    public function __construct($field, $title, $sortable, $itemTemplate, $headerTemplate, $footerTemplate, $itemClass = '')
    {
        $this->field = $field;
        $this->title = $title;
        $this->sortable = $sortable;
        $this->itemTemplate = $itemTemplate;
        $this->headerTemplate = $headerTemplate;
        $this->footerTemplate = $footerTemplate;
        $this->itemClass = $itemClass;
    }

    /**
     * {@inheritdoc}
     */
    public function getField()
    {
        return $this->field;
    }
    
    /**
     * {@inheritdoc}
     */
    public function getTitle()
    {
        return $this->title;
    }

    /**
     * {@inheritdoc}
     */
    public function getSortable()
    {
        return $this->sortable;
    }

    /**
     * {@inheritdoc}
     */
    public function getItemTemplate()
    {
        return $this->itemTemplate;
    }

    /**
     * {@inheritdoc}
     */
    public function getHeaderTemplate()
    {
        return $this->headerTemplate;
    }

    /**
     * {@inheritdoc}
     */
    public function getFooterTemplate()
    {
        return $this->footerTemplate;
    }
    
    /**
     * Get Class for Item <td>
     * 
     * @return string
     */
    public function getItemClass()
    {
        return $this->itemClass;
    }
    
    
    /**
     * Get Class for Header <th>
     * 
     * @return string
     */
    public function getHeaderClass()
    {
        return '';
    }
    
    /**
     * Get Class for Footer <th>
     * 
     * @return string
     */
    public function getFooterClass()
    {
        return '';
    }

}