xxxxxxxxxx
use \WsdlToPhp\PackageBase\AbstractStructBase;
/**
* This class stands for sendEnvelope StructType
* @subpackage Structs
*/
class SendEnvelope extends AbstractStructBase
{
/**
* The urzadNadania
* Meta information extracted from the WSDL
* - base: xsd:int
* - maxOccurs: 1
* - minOccurs: 0
* @var int
*/
public $urzadNadania;
/**
* The pakiet
* Meta information extracted from the WSDL
* - maxOccurs: unbounded
* - minOccurs: 0
* @var PakietType[]
*/
public $pakiet;
/**
* The idBufor
* Meta information extracted from the WSDL
* - maxOccurs: 1
* - minOccurs: 0
* @var int
*/
public $idBufor;
/**
* The profil
* Meta information extracted from the WSDL
* - maxOccurs: 1
* - minOccurs: 0
* @var ProfilType
*/
public $profil;
/**
* Constructor method for sendEnvelope
* @uses SendEnvelope::setUrzadNadania()
* @uses SendEnvelope::setPakiet()
* @uses SendEnvelope::setIdBufor()
* @uses SendEnvelope::setProfil()
* @param int $urzadNadania
* @param PakietType[] $pakiet
* @param int $idBufor
* @param ProfilType $profil
*/
public function __construct($urzadNadania = null, array $pakiet = array(), $idBufor = null, ProfilType $profil = null)
{
$this
->setUrzadNadania($urzadNadania)
->setPakiet($pakiet)
->setIdBufor($idBufor)
->setProfil($profil);
}
/**
* Get urzadNadania value
* @return int|null
*/
public function getUrzadNadania()
{
return $this->urzadNadania;
}
/**
* Set urzadNadania value
* @param int $urzadNadania
* @return SendEnvelope
*/
public function setUrzadNadania($urzadNadania = null)
{
// validation for constraint: int
if (!is_null($urzadNadania) && !(is_int($urzadNadania) || ctype_digit($urzadNadania))) {
throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide an integer value, %s given', var_export($urzadNadania, true), gettype($urzadNadania)), __LINE__);
}
$this->urzadNadania = $urzadNadania;
return $this;
}
/**
* Get pakiet value
* @return PakietType[]|null
*/
public function getPakiet()
{
return $this->pakiet;
}
/**
* This method is responsible for validating the values passed to the setPakiet method
* This method is willingly generated in order to preserve the one-line inline validation within the setPakiet method
* @param array $values
* @return string A non-empty message if the values does not match the validation rules
*/
public static function validatePakietForArrayConstraintsFromSetPakiet(array $values = array())
{
$message = '';
$invalidValues = [];
foreach ($values as $sendEnvelopePakietItem) {
// validation for constraint: itemType
if (!$sendEnvelopePakietItem instanceof PakietType) {
$invalidValues[] = is_object($sendEnvelopePakietItem) ? get_class($sendEnvelopePakietItem) : sprintf('%s(%s)', gettype($sendEnvelopePakietItem), var_export($sendEnvelopePakietItem, true));
}
}
if (!empty($invalidValues)) {
$message = sprintf('The pakiet property can only contain items of type PakietType, %s given', is_object($invalidValues) ? get_class($invalidValues) : (is_array($invalidValues) ? implode(', ', $invalidValues) : gettype($invalidValues)));
}
unset($invalidValues);
return $message;
}
/**
* Set pakiet value
* @throws \InvalidArgumentException
* @param PakietType[] $pakiet
* @return SendEnvelope
*/
public function setPakiet(array $pakiet = array())
{
// validation for constraint: array
if ('' !== ($pakietArrayErrorMessage = self::validatePakietForArrayConstraintsFromSetPakiet($pakiet))) {
throw new \InvalidArgumentException($pakietArrayErrorMessage, __LINE__);
}
$this->pakiet = $pakiet;
return $this;
}
/**
* Add item to pakiet value
* @throws \InvalidArgumentException
* @param PakietType $item
* @return SendEnvelope
*/
public function addToPakiet(PakietType $item)
{
// validation for constraint: itemType
if (!$item instanceof PakietType) {
throw new \InvalidArgumentException(sprintf('The pakiet property can only contain items of type PakietType, %s given', is_object($item) ? get_class($item) : (is_array($item) ? implode(', ', $item) : gettype($item))), __LINE__);
}
$this->pakiet[] = $item;
return $this;
}
/**
* Get idBufor value
* @return int|null
*/
public function getIdBufor()
{
return $this->idBufor;
}
/**
* Set idBufor value
* @param int $idBufor
* @return SendEnvelope
*/
public function setIdBufor($idBufor = null)
{
// validation for constraint: int
if (!is_null($idBufor) && !(is_int($idBufor) || ctype_digit($idBufor))) {
throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide an integer value, %s given', var_export($idBufor, true), gettype($idBufor)), __LINE__);
}
$this->idBufor = $idBufor;
return $this;
}
/**
* Get profil value
* @return ProfilType|null
*/
public function getProfil()
{
return $this->profil;
}
/**
* Set profil value
* @param ProfilType $profil
* @return SendEnvelope
*/
public function setProfil(ProfilType $profil = null)
{
$this->profil = $profil;
return $this;
}
}
Don't be shy, don't hesitate to contact us for any subject, we'll be glad to help.
This platform is provided to give developpers and non developpers a way to easily consume SOAP Web Services or share their own SOAP Web Services with extra features powered by the platform.
© 2025 Providr.IO