src/POData/Writers/Atom/AtomODataWriter.php
/**
     * Begin an item in a collection
     *  
     * @param ODataBagContent $bag Bag property object to begin write property
     *
     * 
     * @return AtomODataWriter
     */
Begin an item in a collection

@param ODataBagContent $bag Bag property object to begin write property


Begin an item in a collection @param ODataBagContent $bag Bag property object to begin write property
protected function writeBagContent(ODataBagContent $bag)
    {
        foreach ($bag->propertyContents as $content) {
            if ($content instanceof ODataPropertyContent) {
                $this->xmlWriter->startElementNs(
                    ODataConstants::ODATA_NAMESPACE_PREFIX, 
                    ODataConstants::COLLECTION_ELEMENT_NAME, 
                    null
                );
                    $this->writeProperties($content);
                    $this->xmlWriter->endElement();
            } else {  
                    $this->xmlWriter->startElementNs(
                        ODataConstants::ODATA_NAMESPACE_PREFIX, 
                        ODataConstants::COLLECTION_ELEMENT_NAME, 
                        null
                    );
                    $this->xmlWriter->text($content);
                    $this->xmlWriter->endElement();
            }
        }
	    return $this;
    }
protected function writeBagContent ( ODataBagContent $ bag ) { foreach ( $ bag -> propertyContents as $ content ) { if ( $ content instanceof ODataPropertyContent ) { $ this -> xmlWriter -> startElementNs ( ODataConstants :: ODATA_NAMESPACE_PREFIX , ODataConstants :: COLLECTION_ELEMENT_NAME , null ) ; $ this -> writeProperties ( $ content ) ; $ this -> xmlWriter -> endElement ( ) ; } else { $ this -> xmlWriter -> startElementNs ( ODataConstants :: ODATA_NAMESPACE_PREFIX , ODataConstants :: COLLECTION_ELEMENT_NAME , null ) ; $ this -> xmlWriter -> text ( $ content ) ; $ this -> xmlWriter -> endElement ( ) ; } } return $ this ; }
Begin an item in a collection
Begin an item in a collection
//probably just a primitive string