<?php
namespace SabaiApps\Framework\Criteria;

/**
 * Abstract base class for field-based criteria.
 * Stores two field names for use in criteria evaluation.
 */
abstract class AbstractFieldCriteria extends AbstractCriteria {

	/**
	 * @var string The primary field name.
	 */
	private $_field;

	/**
	 * @var string The secondary field name.
	 */
	private $_field2;

	/**
	 * Constructor.
	 *
	 * @param string $field  The primary field name.
	 * @param string $field2 The secondary field name.
	 */
	public function __construct( $field, $field2 ) {
		$this->_field  = $field;
		$this->_field2 = $field2;
	}

	/**
	 * Gets the primary field name.
	 *
	 * @return string
	 */
	public function getField() {
		return $this->_field;
	}

	/**
	 * Gets the secondary field name.
	 *
	 * @return string
	 */
	public function getField2() {
		return $this->_field2;
	}
}
