<?php

namespace StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for CustomRecordTypeParents StructType
 * @subpackage Structs
 */
class CustomRecordTypeParents extends AbstractStructBase
{
    /**
     * The childDescr
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * @var string
     */
    public $childDescr;
    /**
     * Constructor method for CustomRecordTypeParents
     * @uses CustomRecordTypeParents::setChildDescr()
     * @param string $childDescr
     */
    public function __construct($childDescr = null)
    {
        $this
            ->setChildDescr($childDescr);
    }
    /**
     * Get childDescr value
     * @return string|null
     */
    public function getChildDescr()
    {
        return $this->childDescr;
    }
    /**
     * Set childDescr value
     * @param string $childDescr
     * @return \StructType\CustomRecordTypeParents
     */
    public function setChildDescr($childDescr = null)
    {
        // validation for constraint: string
        if (!is_null($childDescr) && !is_string($childDescr)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($childDescr, true), gettype($childDescr)), __LINE__);
        }
        $this->childDescr = $childDescr;
        return $this;
    }
}
