XBRL-Instance.php
public function isDRSValidForFact( $fact,  $drs)
	{
		foreach ( $drs as $hypercube => $roles )
		{
			foreach ( $roles as $role => $hypercubeItems )
			{
				if ( ! isset( $hypercubes[ $hypercube ][ $role ] ) )
				{
					$closed = isset( $hypercubeItems['parents'][ $fact['label'] ]['closed'] ) && $hypercubeItems['parents'][ $fact['label'] ]['closed'];

					if ( ! $this->isHypercubeDimensionallyValid( $fact['contextRef'], $hypercubeItems, $closed ) ) continue;

					return true;
				}
			}
		}

		return false;
	}
public function isDRSValidForFact( $fact,  $drs)
	{
		foreach ( $drs as $hypercube => $roles )
		{
			foreach ( $roles as $role => $hypercubeItems )
			{
				if ( ! isset( $hypercubes[ $hypercube ][ $role ] ) )
				{
					$closed = isset( $hypercubeItems['parents'][ $fact['label'] ]['closed'] ) && $hypercubeItems['parents'][ $fact['label'] ]['closed'];

					if ( ! $this->isHypercubeDimensionallyValid( $fact['contextRef'], $hypercubeItems, $closed ) ) continue;

					return true;
				}
			}
		}

		return false;
	}
public function isDRSValidForFact ( $ fact , $ drs ) { foreach ( $ drs as $ hypercube => $ roles ) { foreach ( $ roles as $ role => $ hypercubeItems ) { if ( ! isset ( $ hypercubes [ $ hypercube ] [ $ role ] ) ) { $ closed = isset ( $ hypercubeItems [ 'parents' ] [ $ fact [ 'label' ] ] [ 'closed' ] ) && $ hypercubeItems [ 'parents' ] [ $ fact [ 'label' ] ] [ 'closed' ] ; if ( ! $ this -> isHypercubeDimensionallyValid ( $ fact [ 'contextRef' ] , $ hypercubeItems , $ closed ) ) continue ; return true ; } } } return false ; }
Returns true if ANY hypercube in a DRS is valid for the context
@param array $fact An array for a specific fact
@param array $drs A DRS array returned by a call to getPrimaryItemDRS
@return boolean
Returns true if ANY hypercube in a DRS is valid for the context