public static function toString(Version $version)
    {
        return sprintf(
            '%d.%d.%d%s%s',
            $version->getMajor(),
            $version->getMinor(),
            $version->getPatch(),
            $version->getPreRelease()
                ? '-' . join('.', $version->getPreRelease())
                : '',
            $version->getBuild()
                ? '+' . join('.', $version->getBuild())
                : ''
        );
    }
public static function toString(Version $version)
    {
        return sprintf(
            '%d.%d.%d%s%s',
            $version->getMajor(),
            $version->getMinor(),
            $version->getPatch(),
            $version->getPreRelease()
                ? '-' . join('.', $version->getPreRelease())
                : '',
            $version->getBuild()
                ? '+' . join('.', $version->getBuild())
                : ''
        );
    }
public static function toString ( Version $ version ) { return sprintf ( '%d.%d.%d%s%s' , $ version -> getMajor ( ) , $ version -> getMinor ( ) , $ version -> getPatch ( ) , $ version -> getPreRelease ( ) ? '-' . join ( '.' , $ version -> getPreRelease ( ) ) : '' , $ version -> getBuild ( ) ? '+' . join ( '.' , $ version -> getBuild ( ) ) : '' ) ; }
Returns the string representation of a Version instance.

@param Version $version A version.

@return string The string representation.
Returns the string representation of a Version instance .