PHP 클래스 Elcodi\Component\Product\Entity\Product

상속: extends Elcodi\Component\Core\Entity\Abstracts\AbstractEntity, implements Elcodi\Component\Product\Entity\Interfaces\ProductInterface, use trait Elcodi\Component\Product\Entity\Traits\ProductPriceTrait, use trait Elcodi\Component\Core\Entity\Traits\DateTimeTrait, use trait Elcodi\Component\Core\Entity\Traits\EnabledTrait, use trait Elcodi\Component\Core\Entity\Traits\ETaggableTrait, use trait Elcodi\Component\MetaData\Entity\Traits\MetaDataTrait, use trait Elcodi\Component\Media\Entity\Traits\ImagesContainerTrait, use trait Elcodi\Component\Media\Entity\Traits\PrincipalImageTrait
파일 보기 프로젝트 열기: elcodi/elcodi 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$attributes Doctrine\Common\Collections\Collection Attributes associated with this product
$principalVariant Elcodi\Component\Product\Entity\Interfaces\VariantInterface Principal variant for this product
$type integer Product type
$variants Doctrine\Common\Collections\Collection Variants for this product

공개 메소드들

메소드 설명
addAttribute ( Elcodi\Component\Attribute\Entity\Interfaces\AttributeInterface $attribute ) Adds an attribute if not already in the collection.
addCategory ( Elcodi\Component\Product\Entity\Interfaces\CategoryInterface $category ) Add category.
addVariant ( Elcodi\Component\Product\Entity\Interfaces\VariantInterface $variant ) Adds a Variant for this Product.
getAttributes ( ) : Doctrine\Common\Collections\Collection Returns product attributes.
getPrincipalVariant ( ) : Elcodi\Component\Product\Entity\Interfaces\VariantInterface Returns product principal variant.
getPurchasableType ( ) : string Get purchasable type.
getType ( ) : integer Get Type.
getVariants ( ) : Doctrine\Common\Collections\Collection Gets product variants.
hasVariants ( ) : boolean Tells if this product has variants.
removeAttribute ( Elcodi\Component\Attribute\Entity\Interfaces\AttributeInterface $attribute ) Removes an attribute from the collection.
removeCategory ( Elcodi\Component\Product\Entity\Interfaces\CategoryInterface $category ) Remove category.
setAttributes ( Doctrine\Common\Collections\Collection $attributes ) Sets product attributes.
setCategories ( Doctrine\Common\Collections\Collection $categories ) Set categories.
setManufacturer ( Elcodi\Component\Product\Entity\Interfaces\ManufacturerInterface $manufacturer = null ) Set product manufacturer.
setPrincipalCategory ( Elcodi\Component\Product\Entity\Interfaces\CategoryInterface $principalCategory = null ) Set the principalCategory.
setPrincipalVariant ( Elcodi\Component\Product\Entity\Interfaces\VariantInterface $principalVariant ) Sets product principal variant.
setType ( integer $type ) Sets Type.
setVariants ( Doctrine\Common\Collections\Collection $variants ) Sets product variants.

메소드 상세

addAttribute() 공개 메소드

Adds an attribute if not already in the collection.
public addAttribute ( Elcodi\Component\Attribute\Entity\Interfaces\AttributeInterface $attribute )
$attribute Elcodi\Component\Attribute\Entity\Interfaces\AttributeInterface Attribute

addCategory() 공개 메소드

Add category.
public addCategory ( Elcodi\Component\Product\Entity\Interfaces\CategoryInterface $category )
$category Elcodi\Component\Product\Entity\Interfaces\CategoryInterface Category

addVariant() 공개 메소드

Adds a Variant for this Product.
public addVariant ( Elcodi\Component\Product\Entity\Interfaces\VariantInterface $variant )
$variant Elcodi\Component\Product\Entity\Interfaces\VariantInterface

getAttributes() 공개 메소드

Returns product attributes.
public getAttributes ( ) : Doctrine\Common\Collections\Collection
리턴 Doctrine\Common\Collections\Collection Attributes

getPrincipalVariant() 공개 메소드

Returns product principal variant.
public getPrincipalVariant ( ) : Elcodi\Component\Product\Entity\Interfaces\VariantInterface
리턴 Elcodi\Component\Product\Entity\Interfaces\VariantInterface

getPurchasableType() 공개 메소드

Get purchasable type.
public getPurchasableType ( ) : string
리턴 string Purchasable type

getType() 공개 메소드

Get Type.
public getType ( ) : integer
리턴 integer Type

getVariants() 공개 메소드

Gets product variants.
public getVariants ( ) : Doctrine\Common\Collections\Collection
리턴 Doctrine\Common\Collections\Collection Variants

hasVariants() 공개 메소드

Tells if this product has variants.
public hasVariants ( ) : boolean
리턴 boolean Product has variants

removeAttribute() 공개 메소드

Removes an attribute from the collection.
public removeAttribute ( Elcodi\Component\Attribute\Entity\Interfaces\AttributeInterface $attribute )
$attribute Elcodi\Component\Attribute\Entity\Interfaces\AttributeInterface Attribute to be removed

removeCategory() 공개 메소드

Remove category.
public removeCategory ( Elcodi\Component\Product\Entity\Interfaces\CategoryInterface $category )
$category Elcodi\Component\Product\Entity\Interfaces\CategoryInterface Category

setAttributes() 공개 메소드

Sets product attributes.
public setAttributes ( Doctrine\Common\Collections\Collection $attributes )
$attributes Doctrine\Common\Collections\Collection Attributes

setCategories() 공개 메소드

Set categories.
public setCategories ( Doctrine\Common\Collections\Collection $categories )
$categories Doctrine\Common\Collections\Collection Categories

setManufacturer() 공개 메소드

Set product manufacturer.
public setManufacturer ( Elcodi\Component\Product\Entity\Interfaces\ManufacturerInterface $manufacturer = null )
$manufacturer Elcodi\Component\Product\Entity\Interfaces\ManufacturerInterface Manufacturer

setPrincipalCategory() 공개 메소드

Set the principalCategory.
public setPrincipalCategory ( Elcodi\Component\Product\Entity\Interfaces\CategoryInterface $principalCategory = null )
$principalCategory Elcodi\Component\Product\Entity\Interfaces\CategoryInterface Principal category

setPrincipalVariant() 공개 메소드

Sets product principal variant.
public setPrincipalVariant ( Elcodi\Component\Product\Entity\Interfaces\VariantInterface $principalVariant )
$principalVariant Elcodi\Component\Product\Entity\Interfaces\VariantInterface

setType() 공개 메소드

Sets Type.
public setType ( integer $type )
$type integer Type

setVariants() 공개 메소드

Sets product variants.
public setVariants ( Doctrine\Common\Collections\Collection $variants )
$variants Doctrine\Common\Collections\Collection Variants

프로퍼티 상세

$attributes 보호되어 있는 프로퍼티

Attributes associated with this product
protected Collection,Doctrine\Common\Collections $attributes
리턴 Doctrine\Common\Collections\Collection

$principalVariant 보호되어 있는 프로퍼티

Principal variant for this product
protected VariantInterface,Elcodi\Component\Product\Entity\Interfaces $principalVariant
리턴 Elcodi\Component\Product\Entity\Interfaces\VariantInterface

$type 보호되어 있는 프로퍼티

Product type
protected int $type
리턴 integer

$variants 보호되어 있는 프로퍼티

Variants for this product
protected Collection,Doctrine\Common\Collections $variants
리턴 Doctrine\Common\Collections\Collection