Magento Extensions Rating 2024
EXTENSIONS BY CATEGORY
B2B (Business-To-Business)
Blog
Customer
ERP (Enterprise Resource Planning)
Mega Menu
One Step Checkout
Order
POS (Point Of Sale)
Search
Shopping Cart
Sitemap
SEO
Social
Stock & Inventory Management
EXTENSIONS BY DEVELOPER
aheadWorks
Amasty
Boost My Shop
BSS Commerce
Magestore
MageWorx
Mirasvit
Templates Master
Wyomind
XTENTO
Magento 2 Documentation
Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
vendor
magento
framework
GraphQl
Config
Element
Argument.php
Go to the documentation of this file.
1
<?php
6
declare(strict_types=1);
7
8
namespace
Magento\Framework\GraphQl\Config\Element
;
9
15
class
Argument
implements
FieldInterface
16
{
20
private
$name;
21
25
private
$type;
26
30
private
$description;
31
35
private
$baseType;
36
40
private
$required;
41
45
private
$isList;
46
50
private
$itemsRequired;
51
55
private
$defaultValue;
56
68
public
function
__construct
(
69
string
$name,
70
string
$type,
71
string
$baseType,
72
string
$description,
73
bool
$required,
74
bool
$isList,
75
string
$itemType =
''
,
76
bool
$itemsRequired =
false
,
77
string
$defaultValue =
null
78
) {
79
$this->
name
=
$name
;
80
$this->type = $isList ? $itemType :
$type
;
81
$this->baseType = $baseType;
82
$this->description =
$description
;
83
$this->required =
$required
;
84
$this->
isList
= $isList;
85
$this->itemsRequired = $itemsRequired;
86
$this->defaultValue = $defaultValue;
87
}
88
94
public
function
getName
() : string
95
{
96
return
$this->name;
97
}
98
104
public
function
getTypeName
() : string
105
{
106
return
$this->type;
107
}
108
114
public
function
getBaseType
() : string
115
{
116
return
$this->baseType;
117
}
118
124
public
function
isList
() : bool
125
{
126
return
$this->isList;
127
}
128
134
public
function
isRequired
() : bool
135
{
136
return
$this->required;
137
}
138
144
public
function
areItemsRequired
() : bool
145
{
146
return
$this->itemsRequired;
147
}
148
154
public
function
getDescription
() : string
155
{
156
return
$this->description;
157
}
158
164
public
function
getDefaultValue
() : ?string
165
{
166
return
$this->defaultValue;
167
}
168
174
public
function
hasDefaultValue
() : bool
175
{
176
return
$this->defaultValue ?
true
:
false
;
177
}
178
}
$description
$description
Definition:
pre_composer_update_2.3.php:162
Magento\Framework\GraphQl\Config\Element\Argument\getDescription
getDescription()
Definition:
Argument.php:154
Magento\Framework\GraphQl\Config\Element\Argument\getDefaultValue
getDefaultValue()
Definition:
Argument.php:164
Magento\Framework\GraphQl\Config\Element\Argument\isRequired
isRequired()
Definition:
Argument.php:134
Magento\Framework\GraphQl\Config\Element\Argument\getTypeName
getTypeName()
Definition:
Argument.php:104
$type
$type
Definition:
item.phtml:13
name
Magento\Framework\GraphQl\Config\Element\Argument\getBaseType
getBaseType()
Definition:
Argument.php:114
Magento\Framework\GraphQl\Config\Element\Argument\areItemsRequired
areItemsRequired()
Definition:
Argument.php:144
Magento\Framework\GraphQl\Config\Element\Argument
Definition:
Argument.php:15
Magento\Framework\GraphQl\Config\Element\Argument\isList
isList()
Definition:
Argument.php:124
Magento\Framework\GraphQl\Config\Element\Argument\getName
getName()
Definition:
Argument.php:94
Magento\Framework\GraphQl\Config\Element\Argument\hasDefaultValue
hasDefaultValue()
Definition:
Argument.php:174
Magento\Framework\GraphQl\Config\Element\Argument\__construct
__construct(string $name, string $type, string $baseType, string $description, bool $required, bool $isList, string $itemType='', bool $itemsRequired=false, string $defaultValue=null)
Definition:
Argument.php:68
Magento\Framework\GraphQl\Config\Element
Definition:
Argument.php:8
Magento\Framework\GraphQl\Config\Element\FieldInterface
Definition:
FieldInterface.php:15
$required
$required
Definition:
wrapper.phtml:8
$name
if(!isset($_GET['name'])) $name
Definition:
log.php:14