private function _bootstrapMatch( $siteId, $lang, $currency, $active,
		MShop_Locale_Item_Site_Interface $siteItem, array $sitePath, array $siteSubTree )
	{
		// Try to find exact match
		$search = $this->createSearch( $active );

		$expr = array( $search->compare( '==', 'locale.siteid', $sitePath ) );

		if( !empty( $lang ) ) {
			$expr[] = $search->compare( '==', 'locale.languageid', $lang );
		}

		if( !empty( $currency ) ) {
			$expr[] = $search->compare( '==', 'locale.currencyid', $currency );
		}

		$expr[] = $search->getConditions();


		if ( $active === true )
		{
			$expr[] = $search->compare( '>', 'locale.currency.status', 0 );
			$expr[] = $search->compare( '>', 'locale.language.status', 0 );
			$expr[] = $search->compare( '>', 'locale.site.status', 0 );
		}

		$search->setConditions( $search->combine( '&&', $expr ) );
		$result = $this->_search( $search );

		// Try to find first item where site matches
		foreach( $result as $row )
		{
			if( $row['siteid'] == $siteId ) {
				return $this->_createItem( $row, $siteItem, $sitePath, $siteSubTree );
			}
		}

		if( ( $row = reset( $result ) ) !== false )
		{
			$row['siteid'] = $siteId;
			return $this->_createItem( $row, $siteItem, $sitePath, $siteSubTree );
		}

		return false;
	}