PHP 클래스 Sonata\Component\Basket\Basket

저자: Thomas Rabaix ([email protected])
상속: implements Serializable, implements Sonata\Component\Basket\BasketInterface
파일 보기 프로젝트 열기: sonata-project/ecommerce 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$basketElements array
$billingAddress Sonata\Component\Customer\AddressInterface
$billingAddressId integer
$cptElement integer
$currency Sonata\Component\Currency\CurrencyInterface
$customer Sonata\Component\Customer\CustomerInterface
$customerId integer
$deliveryAddress Sonata\Component\Customer\AddressInterface
$deliveryAddressId integer
$deliveryMethod Sonata\Component\Delivery\ServiceDeliveryInterface
$deliveryMethodCode string
$inBuild boolean
$locale string
$options array
$paymentMethod Sonata\Component\Payment\PaymentInterface
$paymentMethodCode string
$positions array
$productPool Sonata\Component\Product\Pool

공개 메소드들

메소드 설명
__construct ( )
addBasketElement ( Sonata\Component\Basket\BasketElementInterface $basketElement )
buildPrices ( )
clean ( )
countBasketElements ( )
getBasketElements ( )
getBillingAddress ( )
getBillingAddressId ( )
getCurrency ( )
getCustomer ( )
getCustomerId ( )
getDeliveryAddress ( )
getDeliveryAddressId ( )
getDeliveryMethod ( )
getDeliveryMethodCode ( )
getDeliveryPrice ( $vat = false )
getDeliveryVat ( )
getElement ( Sonata\Component\Product\ProductInterface $product )
getElementByPos ( $pos )
getLocale ( )
getOption ( $name, $default = null )
getOptions ( )
getPaymentMethod ( )
getPaymentMethodCode ( )
getPositions ( )
getProductPool ( )
getSerializationFields ( )
getTotal ( $vat = false, $recurrentOnly = null )
getUnserializationFields ( )
getVatAmount ( )
getVatAmounts ( )
hasBasketElements ( )
hasProduct ( Sonata\Component\Product\ProductInterface $product )
hasRecurrentPayment ( )
isAddable ( Sonata\Component\Product\ProductInterface $product )
isEmpty ( )
isValid ( $elementsOnly = false )
removeBasketElement ( Sonata\Component\Basket\BasketElementInterface $element )
removeElement ( Sonata\Component\Basket\BasketElementInterface $element )
removeElements ( array $elementsToRemove )
reset ( $full = true )
serialize ( )
setBasketElements ( $basketElements )
setBillingAddress ( Sonata\Component\Customer\AddressInterface $address = null )
setBillingAddressId ( $billingAddressId )
setCurrency ( Sonata\Component\Currency\CurrencyInterface $currency )
setCustomer ( Sonata\Component\Customer\CustomerInterface $customer = null )
setCustomerId ( $customerId )
setDeliveryAddress ( Sonata\Component\Customer\AddressInterface $address = null )
setDeliveryAddressId ( $deliveryAddressId )
setDeliveryMethod ( Sonata\Component\Delivery\ServiceDeliveryInterface $method = null )
setDeliveryMethodCode ( $deliveryMethodCode )
setLocale ( $locale )
setOption ( $name, $value )
setOptions ( $options )
setPaymentMethod ( Sonata\Component\Payment\PaymentInterface $method = null )
setPaymentMethodCode ( $paymentMethodCode )
setProductPool ( Pool $pool )
unserialize ( $data )

메소드 상세

__construct() 공개 메소드

public __construct ( )

addBasketElement() 공개 메소드

public addBasketElement ( Sonata\Component\Basket\BasketElementInterface $basketElement )
$basketElement Sonata\Component\Basket\BasketElementInterface

buildPrices() 공개 메소드

public buildPrices ( )

clean() 공개 메소드

public clean ( )

countBasketElements() 공개 메소드

public countBasketElements ( )

getBasketElements() 공개 메소드

public getBasketElements ( )

getBillingAddress() 공개 메소드

public getBillingAddress ( )

getBillingAddressId() 공개 메소드

public getBillingAddressId ( )

getCurrency() 공개 메소드

public getCurrency ( )

getCustomer() 공개 메소드

public getCustomer ( )

getCustomerId() 공개 메소드

public getCustomerId ( )

getDeliveryAddress() 공개 메소드

public getDeliveryAddress ( )

getDeliveryAddressId() 공개 메소드

getDeliveryMethod() 공개 메소드

public getDeliveryMethod ( )

getDeliveryMethodCode() 공개 메소드

getDeliveryPrice() 공개 메소드

public getDeliveryPrice ( $vat = false )

getDeliveryVat() 공개 메소드

public getDeliveryVat ( )

getElement() 공개 메소드

public getElement ( Sonata\Component\Product\ProductInterface $product )
$product Sonata\Component\Product\ProductInterface

getElementByPos() 공개 메소드

public getElementByPos ( $pos )

getLocale() 공개 메소드

public getLocale ( )

getOption() 공개 메소드

public getOption ( $name, $default = null )

getOptions() 공개 메소드

public getOptions ( )

getPaymentMethod() 공개 메소드

public getPaymentMethod ( )

getPaymentMethodCode() 공개 메소드

getPositions() 공개 메소드

public getPositions ( )

getProductPool() 공개 메소드

public getProductPool ( )

getSerializationFields() 공개 메소드

getTotal() 공개 메소드

public getTotal ( $vat = false, $recurrentOnly = null )

getUnserializationFields() 공개 메소드

getVatAmount() 공개 메소드

public getVatAmount ( )

getVatAmounts() 공개 메소드

public getVatAmounts ( )

hasBasketElements() 공개 메소드

public hasBasketElements ( )

hasProduct() 공개 메소드

public hasProduct ( Sonata\Component\Product\ProductInterface $product )
$product Sonata\Component\Product\ProductInterface

hasRecurrentPayment() 공개 메소드

public hasRecurrentPayment ( )

isAddable() 공개 메소드

public isAddable ( Sonata\Component\Product\ProductInterface $product )
$product Sonata\Component\Product\ProductInterface

isEmpty() 공개 메소드

public isEmpty ( )

isValid() 공개 메소드

public isValid ( $elementsOnly = false )

removeBasketElement() 공개 메소드

public removeBasketElement ( Sonata\Component\Basket\BasketElementInterface $element )
$element Sonata\Component\Basket\BasketElementInterface

removeElement() 공개 메소드

public removeElement ( Sonata\Component\Basket\BasketElementInterface $element )
$element Sonata\Component\Basket\BasketElementInterface

removeElements() 공개 메소드

public removeElements ( array $elementsToRemove )
$elementsToRemove array

reset() 공개 메소드

public reset ( $full = true )

serialize() 공개 메소드

public serialize ( )

setBasketElements() 공개 메소드

public setBasketElements ( $basketElements )

setBillingAddress() 공개 메소드

public setBillingAddress ( Sonata\Component\Customer\AddressInterface $address = null )
$address Sonata\Component\Customer\AddressInterface

setBillingAddressId() 공개 메소드

public setBillingAddressId ( $billingAddressId )

setCurrency() 공개 메소드

public setCurrency ( Sonata\Component\Currency\CurrencyInterface $currency )
$currency Sonata\Component\Currency\CurrencyInterface

setCustomer() 공개 메소드

public setCustomer ( Sonata\Component\Customer\CustomerInterface $customer = null )
$customer Sonata\Component\Customer\CustomerInterface

setCustomerId() 공개 메소드

public setCustomerId ( $customerId )

setDeliveryAddress() 공개 메소드

public setDeliveryAddress ( Sonata\Component\Customer\AddressInterface $address = null )
$address Sonata\Component\Customer\AddressInterface

setDeliveryAddressId() 공개 메소드

public setDeliveryAddressId ( $deliveryAddressId )

setDeliveryMethod() 공개 메소드

public setDeliveryMethod ( Sonata\Component\Delivery\ServiceDeliveryInterface $method = null )
$method Sonata\Component\Delivery\ServiceDeliveryInterface

setDeliveryMethodCode() 공개 메소드

public setDeliveryMethodCode ( $deliveryMethodCode )

setLocale() 공개 메소드

public setLocale ( $locale )

setOption() 공개 메소드

public setOption ( $name, $value )

setOptions() 공개 메소드

public setOptions ( $options )

setPaymentMethod() 공개 메소드

public setPaymentMethod ( Sonata\Component\Payment\PaymentInterface $method = null )
$method Sonata\Component\Payment\PaymentInterface

setPaymentMethodCode() 공개 메소드

public setPaymentMethodCode ( $paymentMethodCode )

setProductPool() 공개 메소드

public setProductPool ( Pool $pool )
$pool Sonata\Component\Product\Pool

unserialize() 공개 메소드

public unserialize ( $data )

프로퍼티 상세

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

protected array $basketElements
리턴 array

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

protected AddressInterface,Sonata\Component\Customer $billingAddress
리턴 Sonata\Component\Customer\AddressInterface

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

protected int $billingAddressId
리턴 integer

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

protected int $cptElement
리턴 integer

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

protected CurrencyInterface,Sonata\Component\Currency $currency
리턴 Sonata\Component\Currency\CurrencyInterface

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

protected CustomerInterface,Sonata\Component\Customer $customer
리턴 Sonata\Component\Customer\CustomerInterface

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

protected int $customerId
리턴 integer

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

protected AddressInterface,Sonata\Component\Customer $deliveryAddress
리턴 Sonata\Component\Customer\AddressInterface

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

protected int $deliveryAddressId
리턴 integer

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

protected ServiceDeliveryInterface,Sonata\Component\Delivery $deliveryMethod
리턴 Sonata\Component\Delivery\ServiceDeliveryInterface

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

protected string $deliveryMethodCode
리턴 string

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

protected bool $inBuild
리턴 boolean

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

protected string $locale
리턴 string

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

protected array $options
리턴 array

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

protected PaymentInterface,Sonata\Component\Payment $paymentMethod
리턴 Sonata\Component\Payment\PaymentInterface

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

protected string $paymentMethodCode
리턴 string

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

protected array $positions
리턴 array

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

protected Pool,Sonata\Component\Product $productPool
리턴 Sonata\Component\Product\Pool