<?php

namespace patest\StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for
 * GetTicketViewAssociationsByApplicationObjectIdentifierResponse StructType
 * Meta information extracted from the WSDL
 * - nillable: true
 * - type: tns:GetTicketViewAssociationsByApplicationObjectIdentifierResponse
 * @subpackage Structs
 */
class GetTicketViewAssociationsByApplicationObjectIdentifierResponse extends AbstractStructBase
{
    /**
     * The Associations
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var \patest\ArrayType\ArrayOfGetTicketViewAssociationByApplicationObjectIdentifierResponse
     */
    public $Associations;
    /**
     * Constructor method for
     * GetTicketViewAssociationsByApplicationObjectIdentifierResponse
     * @uses GetTicketViewAssociationsByApplicationObjectIdentifierResponse::setAssociations()
     * @param \patest\ArrayType\ArrayOfGetTicketViewAssociationByApplicationObjectIdentifierResponse $associations
     */
    public function __construct(\patest\ArrayType\ArrayOfGetTicketViewAssociationByApplicationObjectIdentifierResponse $associations = null)
    {
        $this
            ->setAssociations($associations);
    }
    /**
     * Get Associations value
     * An additional test has been added (isset) before returning the property value as
     * this property may have been unset before, due to the fact that this property is
     * removable from the request (nillable=true+minOccurs=0)
     * @return \patest\ArrayType\ArrayOfGetTicketViewAssociationByApplicationObjectIdentifierResponse|null
     */
    public function getAssociations()
    {
        return isset($this->Associations) ? $this->Associations : null;
    }
    /**
     * Set Associations value
     * This property is removable from request (nillable=true+minOccurs=0), therefore
     * if the value assigned to this property is null, it is removed from this object
     * @param \patest\ArrayType\ArrayOfGetTicketViewAssociationByApplicationObjectIdentifierResponse $associations
     * @return \patest\StructType\GetTicketViewAssociationsByApplicationObjectIdentifierResponse
     */
    public function setAssociations(\patest\ArrayType\ArrayOfGetTicketViewAssociationByApplicationObjectIdentifierResponse $associations = null)
    {
        if (is_null($associations) || (is_array($associations) && empty($associations))) {
            unset($this->Associations);
        } else {
            $this->Associations = $associations;
        }
        return $this;
    }
}
