public function transform(LocationInterface $location)
    {
        return $this
            ->locationDataFactory
            ->create(
                $location->getId(),
                $location->getName(),
                $location->getCode(),
                $location->getType()
            );
    }
public function transform(LocationInterface $location)
    {
        return $this
            ->locationDataFactory
            ->create(
                $location->getId(),
                $location->getName(),
                $location->getCode(),
                $location->getType()
            );
    }
public function transform ( LocationInterface $ location ) { return $ this -> locationDataFactory -> create ( $ location -> getId ( ) , $ location -> getName ( ) , $ location -> getCode ( ) , $ location -> getType ( ) ) ; }
Transform a Location to LocationData.

@param LocationInterface $location Location

@return LocationData
Transform a Location to LocationData .