controller/common/src/Controller/Common/Product/Import/Csv/Base.php
protected function getCache( $type, $name = null )
	{
		$context = $this->getContext();
		$config = $context->getConfig();

		if( ctype_alnum( $type ) === false )
		{
			$classname = is_string( $name ) ? '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Cache\\' . $type : '<not a string>';
			throw new \Aimeos\Controller\Common\Exception( sprintf( 'Invalid characters in class name "%1$s"', $classname ) );
		}

		if( $name === null ) {
			$name = $config->get( 'controller/common/product/import/csv/cache/' . $type . '/name', 'Standard' );
		}

		if( ctype_alnum( $name ) === false )
		{
			$classname = is_string( $name ) ? '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Cache\\' . $type . '\\' . $name : '<not a string>';
			throw new \Aimeos\Controller\Common\Exception( sprintf( 'Invalid characters in class name "%1$s"', $classname ) );
		}

		$classname = '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Cache\\' . ucfirst( $type ) . '\\' . $name;

		if( class_exists( $classname ) === false ) {
			throw new \Aimeos\Controller\Common\Exception( sprintf( 'Class "%1$s" not found', $classname ) );
		}

		$object = new $classname( $context );

		\Aimeos\MW\Common\Base::checkClass( '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Cache\\Iface', $object );

		return $object;
	}
protected function getCache( $type, $name = null )
	{
		$context = $this->getContext();
		$config = $context->getConfig();

		if( ctype_alnum( $type ) === false )
		{
			$classname = is_string( $name ) ? '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Cache\\' . $type : '<not a string>';
			throw new \Aimeos\Controller\Common\Exception( sprintf( 'Invalid characters in class name "%1$s"', $classname ) );
		}

		if( $name === null ) {
			$name = $config->get( 'controller/common/product/import/csv/cache/' . $type . '/name', 'Standard' );
		}

		if( ctype_alnum( $name ) === false )
		{
			$classname = is_string( $name ) ? '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Cache\\' . $type . '\\' . $name : '<not a string>';
			throw new \Aimeos\Controller\Common\Exception( sprintf( 'Invalid characters in class name "%1$s"', $classname ) );
		}

		$classname = '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Cache\\' . ucfirst( $type ) . '\\' . $name;

		if( class_exists( $classname ) === false ) {
			throw new \Aimeos\Controller\Common\Exception( sprintf( 'Class "%1$s" not found', $classname ) );
		}

		$object = new $classname( $context );

		\Aimeos\MW\Common\Base::checkClass( '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Cache\\Iface', $object );

		return $object;
	}
protected function getCache ( $ type , $ name = null ) { $ context = $ this -> getContext ( ) ; $ config = $ context -> getConfig ( ) ; if ( ctype_alnum ( $ type ) === false ) { $ classname = is_string ( $ name ) ? '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Cache\\' . $ type : '<not a string>' ; throw new \ Aimeos \ Controller \ Common \ Exception ( sprintf ( 'Invalid characters in class name "%1$s"' , $ classname ) ) ; } if ( $ name === null ) { $ name = $ config -> get ( 'controller/common/product/import/csv/cache/' . $ type . '/name' , 'Standard' ) ; } if ( ctype_alnum ( $ name ) === false ) { $ classname = is_string ( $ name ) ? '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Cache\\' . $ type . '\\' . $ name : '<not a string>' ; throw new \ Aimeos \ Controller \ Common \ Exception ( sprintf ( 'Invalid characters in class name "%1$s"' , $ classname ) ) ; } $ classname = '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Cache\\' . ucfirst ( $ type ) . '\\' . $ name ; if ( class_exists ( $ classname ) === false ) { throw new \ Aimeos \ Controller \ Common \ Exception ( sprintf ( 'Class "%1$s" not found' , $ classname ) ) ; } $ object = new $ classname ( $ context ) ; \ Aimeos \ MW \ Common \ Base :: checkClass ( '\\Aimeos\\Controller\\Common\\Product\\Import\\Csv\\Cache\\Iface' , $ object ) ; return $ object ; }
Returns the cache object for the given type

@param string $type Type of the cached data
@param string|null Name of the cache implementation
@return \Aimeos\Controller\Common\Product\Import\Csv\Cache\Iface Cache object
Returns the cache object for the given type