Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
|
Public Member Functions | |
getId () | |
setId ($id) | |
getSku () | |
getOptionId () | |
getQty () | |
getPosition () | |
getIsDefault () | |
getPrice () | |
getPriceType () | |
getCanChangeQuantity () | |
setSku ($sku) | |
setOptionId ($optionId) | |
setQty ($qty) | |
setPosition ($position) | |
setIsDefault ($isDefault) | |
setPrice ($price) | |
setPriceType ($priceType) | |
setCanChangeQuantity ($canChangeQuantity) | |
getExtensionAttributes () | |
setExtensionAttributes (\Magento\Bundle\Api\Data\LinkExtensionInterface $extensionAttributes) | |
![]() | |
__construct (\Magento\Framework\Model\Context $context, \Magento\Framework\Registry $registry, ExtensionAttributesFactory $extensionFactory, AttributeValueFactory $customAttributeFactory, \Magento\Framework\Model\ResourceModel\AbstractResource $resource=null, \Magento\Framework\Data\Collection\AbstractDb $resourceCollection=null, array $data=[]) | |
getCustomAttributes () | |
getCustomAttribute ($attributeCode) | |
setCustomAttributes (array $attributes) | |
setCustomAttribute ($attributeCode, $attributeValue) | |
setData ($key, $value=null) | |
unsetData ($key=null) | |
getData ($key='', $index=null) | |
setId ($value) | |
__sleep () | |
__wakeup () | |
![]() | |
__construct (\Magento\Framework\Model\Context $context, \Magento\Framework\Registry $registry, \Magento\Framework\Model\ResourceModel\AbstractResource $resource=null, \Magento\Framework\Data\Collection\AbstractDb $resourceCollection=null, array $data=[]) | |
__sleep () | |
__wakeup () | |
setIdFieldName ($name) | |
getIdFieldName () | |
getId () | |
setId ($value) | |
isDeleted ($isDeleted=null) | |
hasDataChanges () | |
setData ($key, $value=null) | |
unsetData ($key=null) | |
setDataChanges ($value) | |
getOrigData ($key=null) | |
setOrigData ($key=null, $data=null) | |
dataHasChangedFor ($field) | |
getResourceName () | |
getResourceCollection () | |
getCollection () | |
load ($modelId, $field=null) | |
beforeLoad ($identifier, $field=null) | |
afterLoad () | |
isSaveAllowed () | |
setHasDataChanges ($flag) | |
save () | |
afterCommitCallback () | |
isObjectNew ($flag=null) | |
beforeSave () | |
validateBeforeSave () | |
getCacheTags () | |
cleanModelCache () | |
afterSave () | |
delete () | |
beforeDelete () | |
afterDelete () | |
afterDeleteCommit () | |
getResource () | |
getEntityId () | |
setEntityId ($entityId) | |
clearInstance () | |
getStoredData () | |
getEventPrefix () | |
![]() | |
__construct (array $data=[]) | |
addData (array $arr) | |
setData ($key, $value=null) | |
unsetData ($key=null) | |
getData ($key='', $index=null) | |
getDataByPath ($path) | |
getDataByKey ($key) | |
setDataUsingMethod ($key, $args=[]) | |
getDataUsingMethod ($key, $args=null) | |
hasData ($key='') | |
toArray (array $keys=[]) | |
convertToArray (array $keys=[]) | |
toXml (array $keys=[], $rootName='item', $addOpenTag=false, $addCdata=true) | |
convertToXml (array $arrAttributes=[], $rootName='item', $addOpenTag=false, $addCdata=true) | |
toJson (array $keys=[]) | |
convertToJson (array $keys=[]) | |
toString ($format='') | |
__call ($method, $args) | |
isEmpty () | |
serialize ($keys=[], $valueSeparator='=', $fieldSeparator=' ', $quote='"') | |
debug ($data=null, &$objects=[]) | |
offsetSet ($offset, $value) | |
offsetExists ($offset) | |
offsetUnset ($offset) | |
offsetGet ($offset) | |
Data Fields | |
const | KEY_ID = 'id' |
const | KEY_SKU = 'sku' |
const | KEY_OPTION_ID = 'option_id' |
const | KEY_QTY = 'qty' |
const | KEY_POSITION = 'position' |
const | KEY_IS_DEFAULT = 'is_default' |
const | KEY_PRICE = 'price' |
const | KEY_PRICE_TYPE = 'price_type' |
const | KEY_CAN_CHANGE_QUANTITY = 'selection_can_change_quantity' |
![]() | |
const | CUSTOM_ATTRIBUTES = 'custom_attributes' |
![]() | |
const | EXTENSION_ATTRIBUTES_KEY = 'extension_attributes' |
![]() | |
const | PRICE_TYPE_FIXED = 0 |
const | PRICE_TYPE_PERCENT = 1 |
getCanChangeQuantity | ( | ) |
{Get whether quantity could be changed
Implements LinkInterface.
Definition at line 105 of file Link.php.
getExtensionAttributes | ( | ) |
{Retrieve existing extension attributes object or create a new one.
Implements LinkInterface.
Definition at line 203 of file Link.php.
getId | ( | ) |
#- {Get the identifier
Implements LinkInterface.
Definition at line 33 of file Link.php.
getIsDefault | ( | ) |
{Get is default
Implements LinkInterface.
Definition at line 81 of file Link.php.
getOptionId | ( | ) |
{Get option id
Implements LinkInterface.
Definition at line 57 of file Link.php.
getPosition | ( | ) |
{Get position
Implements LinkInterface.
Definition at line 73 of file Link.php.
getPrice | ( | ) |
{Get price
Implements LinkInterface.
Definition at line 89 of file Link.php.
getPriceType | ( | ) |
{Get price type
Implements LinkInterface.
Definition at line 97 of file Link.php.
getQty | ( | ) |
{Get qty
Implements LinkInterface.
Definition at line 65 of file Link.php.
getSku | ( | ) |
{Get linked product sku
Implements LinkInterface.
Definition at line 49 of file Link.php.
setCanChangeQuantity | ( | $canChangeQuantity | ) |
Set whether quantity could be changed
int | $canChangeQuantity |
Implements LinkInterface.
Definition at line 193 of file Link.php.
setExtensionAttributes | ( | \Magento\Bundle\Api\Data\LinkExtensionInterface | $extensionAttributes | ) |
{Set an extension attributes object.
\Magento\Bundle\Api\Data\LinkExtensionInterface | $extensionAttributes |
\Magento\Bundle\Api\Data\LinkExtensionInterface | $extensionAttributes |
Implements LinkInterface.
Definition at line 214 of file Link.php.
setId | ( | $id | ) |
{Set id
string | $id |
Implements LinkInterface.
Definition at line 41 of file Link.php.
setIsDefault | ( | $isDefault | ) |
Set is default
bool | $isDefault |
Implements LinkInterface.
Definition at line 160 of file Link.php.
setOptionId | ( | $optionId | ) |
Set option id
int | $optionId |
Implements LinkInterface.
Definition at line 127 of file Link.php.
setPosition | ( | $position | ) |
Set position
int | $position |
Implements LinkInterface.
Definition at line 149 of file Link.php.
setPrice | ( | $price | ) |
Set price
float | $price |
Implements LinkInterface.
Definition at line 171 of file Link.php.
setPriceType | ( | $priceType | ) |
Set price type
int | $priceType |
Implements LinkInterface.
Definition at line 182 of file Link.php.
setQty | ( | $qty | ) |
Set qty
float | $qty |
Implements LinkInterface.
Definition at line 138 of file Link.php.
setSku | ( | $sku | ) |
Set linked product sku
string | $sku |
Implements LinkInterface.
Definition at line 116 of file Link.php.
const KEY_CAN_CHANGE_QUANTITY = 'selection_can_change_quantity' |