EmptyProductImage

Extends \ProductImage

Class EmptyProductImage

category

System

package

Product

subpackage

Entities

Methods

ProductImage constructor.

__construct(\FilenameStringType $filename) 
inherited

Arguments

$filename

\FilenameStringType

Filename of the image.

Get Alt Text

getAltText(\LanguageCode $language) : string
inherited

Returns the alternative text of a product image.

Throws
\InvalidArgumentException

if the language code is not valid.

Arguments

$language

\LanguageCode

The language code of the alt text to return.

Response

string

The alternative text of the product image.

Get Filename

getFilename() : string
inherited

Returns the filename of the product.

Response

string

The filename of the product.

Is Visible

isVisible() : boolean
inherited

Checks if the product image is set to visible or not.

Response

boolean

Is the product image visible?

Set Alt Text

setAltText(\StringType $text, \LanguageCode $language) : string
inherited

Sets the alternative text of the product image.

Arguments

$text

\StringType

The alternative text for the product image.

$language

\LanguageCode

The language code of the alternative text.

Response

string

The alternative text of the product image.

Set Visible

setVisible(\BoolType $visible) : \ProductImageInterface
inherited

Activates or deactivates the products image visibility.

Arguments

$visible

\BoolType

Should the product image be visible?

Response

\ProductImageInterface

Same instance for chained method calls.

Properties

Filename of the product image

filename : string
inherited
var

Type(s)

string

Alt texts of the image.

altTexts : array
inherited
var

Type(s)

array

Is the product image visible?

visibility : boolean
inherited
var

Type(s)

boolean