Your project should not use invalid return types 9
- Read doc
- Reliability
- Major
More information: https://insight.symfony.com/what-we-analyse/php.invalid_return_typehint
- } else {
- $parentNode = null;
- }
- }
- return $parentNode;
- }
- public function hasAttributeName(): bool
- {
- return $this->hasAttribute(Attribute::ATTRIBUTE_NAME);
- {
- public const ATTRIBUTE_MESSAGE = 'message';
- public function getParentOperation(): ?TagOperation
- {
- return $this->getStrictParent(AbstractDocument::TAG_OPERATION);
- }
- public function hasAttributeMessage(): bool
- {
- return $this->hasAttribute(self::ATTRIBUTE_MESSAGE);
- $message = $this->getDomDocumentHandler()->getElementByNameAndAttributes(AbstractDocument::TAG_MESSAGE, [
- 'name' => $messageName,
- ], true);
- }
- return $message;
- }
- public function getParts(): ?array
- {
- $parts = null;
- return $this->getFirstRestrictionChild() instanceof Restriction;
- }
- public function getFirstRestrictionChild(): ?TagRestriction
- {
- return $this->getChildByNameAndAttributes(AbstractDocument::TAG_RESTRICTION, []);
- }
- /**
- * Checks if the given tag is the same direct parent of this current tag.
- */
- public function getSuitableParent(bool $checkName = true, array $additionalTags = [], int $maxDeep = self::MAX_DEEP, bool $strict = false): ?AbstractNodeHandler
- {
- if (!$strict) {
- $enumerationTag = $this->getStrictParent(AbstractDocument::TAG_ENUMERATION);
- if ($enumerationTag instanceof TagEnumeration) {
- return $enumerationTag;
- }
- }
- return parent::getSuitableParent($checkName, $additionalTags, $maxDeep, $strict);
- }
- return $this->getValueAttributeValue(true);
- }
- public function getRestrictionParent(): ?TagRestriction
- {
- return $this->getStrictParent(AbstractDocument::TAG_RESTRICTION);
- }
- public function getRestrictionParentType(): string
- {
- /** @var null|TagRestriction $restrictionParent */
- public const OPTIONAL_HEADER = 'optional';
- public const ATTRIBUTE_REQUIRED = 'wsdl:required';
- public function getParentInput(): ?TagInput
- {
- return $this->getStrictParent(AbstractDocument::TAG_INPUT);
- }
- public function getAttributeRequired(): bool
- {
- return $this->hasAttribute(self::ATTRIBUTE_REQUIRED) ? $this->getAttribute(self::ATTRIBUTE_REQUIRED)->getValue(true, true, 'bool') : true;
- class TagMessage extends Tag
- {
- public function getPart(string $name): ?TagPart
- {
- return $this->getChildByNameAndAttributes(AbstractDocument::TAG_PART, [
- 'name' => $name,
- ]);
- }
- }
- $element = $this->getDomDocumentHandler()->getElementByNameAndAttributes(AbstractDocument::TAG_ELEMENT, [
- 'name' => $elementName,
- ], true);
- }
- return $element;
- }
- /**
- * @return null|AttributeHandler|int|string
- */
Your project should use return types 2
- Read doc
- Reliability
- Major
More information: https://insight.symfony.com/what-we-analyse/php.missing_return_typehint
- public function hasAttributeValue(): bool
- {
- return $this->hasAttribute(Attribute::ATTRIBUTE_VALUE);
- }
- public function getValueAttributeValue(bool $withNamespace = false, bool $withinItsType = true, ?string $asType = null)
- {
- return $this->getAttribute(Attribute::ATTRIBUTE_VALUE) instanceof Attribute ? $this->getAttribute(Attribute::ATTRIBUTE_VALUE)->getValue($withNamespace, $withinItsType, $asType) : '';
- }
- public function hasAttributeTargetNamespace(): bool
- public function hasAttributeTargetNamespace(): bool
- {
- return $this->hasAttribute(AbstractDocument::ATTRIBUTE_TARGET_NAMESPACE);
- }
- public function getTargetNamespaceAttributeValue()
- {
- return $this->getAttribute(AbstractDocument::ATTRIBUTE_TARGET_NAMESPACE) instanceof Attribute ? $this->getAttribute(AbstractDocument::ATTRIBUTE_TARGET_NAMESPACE)->getValue(true) : '';
- }
- /**
mikaelcom