public function toDTO($filterByKey = null)
    {
        if (! $this->getAttribute("recipient") || ! $this->getAttribute("mosaicId"))
            return [];

        return [
            "type" => $this->type,
            "recipient" => $this->recipient()->address()->toClean(),
            "mosaicId" => $this->mosaicId()->toDTO(),
            "fee" => $this->fee,
        ];
    }
public function toDTO($filterByKey = null)
    {
        if (! $this->getAttribute("recipient") || ! $this->getAttribute("mosaicId"))
            return [];

        return [
            "type" => $this->type,
            "recipient" => $this->recipient()->address()->toClean(),
            "mosaicId" => $this->mosaicId()->toDTO(),
            "fee" => $this->fee,
        ];
    }
public function toDTO ( $ filterByKey = null ) { if ( ! $ this -> getAttribute ( "recipient" ) || ! $ this -> getAttribute ( "mosaicId" ) ) return [ ] ; return [ "type" => $ this -> type , "recipient" => $ this -> recipient ( ) -> address ( ) -> toClean ( ) , "mosaicId" => $ this -> mosaicId ( ) -> toDTO ( ) , "fee" => $ this -> fee , ] ; }
Mosaic Levy DTO builds a package with offsets `type`,
`recipient`, `mosaicId` and `fee`.

Those fields are required by NIS for the mosaic levy identification.

@return  array       Associative array with fields present in `$fillable` property.
Mosaic Levy DTO builds a package with offsets type recipient mosaicId and fee .