protected function unmarshall(DOMElement $element)
    {
        $areaMapEntries = new AreaMapEntryCollection();
        $areaMapEntryElts = $this->getChildElementsByTagName($element, 'areaMapEntry');

        foreach ($areaMapEntryElts as $areaMapEntryElt) {
            $marshaller = $this->getMarshallerFactory()->createMarshaller($areaMapEntryElt);
            $areaMapEntries[] = $marshaller->unmarshall($areaMapEntryElt);
        }

        $object = new AreaMapping($areaMapEntries);

        if (($defaultValue = $this->getDOMElementAttributeAs($element, 'defaultValue', 'float')) !== null) {
            $object->setDefaultValue($defaultValue);
        }

        if (($lowerBound = $this->getDOMElementAttributeAs($element, 'lowerBound', 'float')) !== null) {
            $object->setLowerBound($lowerBound);
        }

        if (($upperBound = $this->getDOMElementAttributeAs($element, 'upperBound', 'float')) !== null) {
            $object->setUpperBound($upperBound);
        }

        return $object;
    }
protected function unmarshall(DOMElement $element)
    {
        $areaMapEntries = new AreaMapEntryCollection();
        $areaMapEntryElts = $this->getChildElementsByTagName($element, 'areaMapEntry');

        foreach ($areaMapEntryElts as $areaMapEntryElt) {
            $marshaller = $this->getMarshallerFactory()->createMarshaller($areaMapEntryElt);
            $areaMapEntries[] = $marshaller->unmarshall($areaMapEntryElt);
        }

        $object = new AreaMapping($areaMapEntries);

        if (($defaultValue = $this->getDOMElementAttributeAs($element, 'defaultValue', 'float')) !== null) {
            $object->setDefaultValue($defaultValue);
        }

        if (($lowerBound = $this->getDOMElementAttributeAs($element, 'lowerBound', 'float')) !== null) {
            $object->setLowerBound($lowerBound);
        }

        if (($upperBound = $this->getDOMElementAttributeAs($element, 'upperBound', 'float')) !== null) {
            $object->setUpperBound($upperBound);
        }

        return $object;
    }
protected function unmarshall ( DOMElement $ element ) { $ areaMapEntries = new AreaMapEntryCollection ( ) ; $ areaMapEntryElts = $ this -> getChildElementsByTagName ( $ element , 'areaMapEntry' ) ; foreach ( $ areaMapEntryElts as $ areaMapEntryElt ) { $ marshaller = $ this -> getMarshallerFactory ( ) -> createMarshaller ( $ areaMapEntryElt ) ; $ areaMapEntries [ ] = $ marshaller -> unmarshall ( $ areaMapEntryElt ) ; } $ object = new AreaMapping ( $ areaMapEntries ) ; if ( ( $ defaultValue = $ this -> getDOMElementAttributeAs ( $ element , 'defaultValue' , 'float' ) ) !== null ) { $ object -> setDefaultValue ( $ defaultValue ) ; } if ( ( $ lowerBound = $ this -> getDOMElementAttributeAs ( $ element , 'lowerBound' , 'float' ) ) !== null ) { $ object -> setLowerBound ( $ lowerBound ) ; } if ( ( $ upperBound = $ this -> getDOMElementAttributeAs ( $ element , 'upperBound' , 'float' ) ) !== null ) { $ object -> setUpperBound ( $ upperBound ) ; } return $ object ; }
Unmarshall a DOMElement object corresponding to a QTI areaMapping element.

@param \DOMElement $element A DOMElement object.
@return \qtism\data\QtiComponent An AreaMapping object.
@throws \qtism\data\storage\xml\marshalling\UnmarshallingException
Unmarshall a DOMElement object corresponding to a QTI areaMapping element .