[Interest] equivalent of python glob

Jérôme Godbout godboutj at amotus.ca
Mon Aug 26 16:33:22 CEST 2019

This is what I did for pathJoin

const QString SEPARATOR("/");
QString FileSystemUtil::pathJoin(const QStringList& paths)
    QString rv;
    for(const QString& s : paths)
        if(!rv.isEmpty() && !rv.endsWith(SEPARATOR))
            rv += SEPARATOR;
        if(!rv.isEmpty() && s.startsWith(SEPARATOR))
            rv += s.right(s.size() - SEPARATOR.size());
            rv += s;
    return rv;

-----Original Message-----
From: Interest <interest-bounces at qt-project.org> On Behalf Of Thiago Macieira
Sent: August 26, 2019 1:37 AM
To: interest at qt-project.org
Subject: Re: [Interest] equivalent of python glob

On Sunday, 25 August 2019 16:34:03 PDT Hamish Moffatt wrote:
> On a related note, where is the equivalent of os.path.join()?

String concatenation. You don't need a function to do it for you.

Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel System Software Products

Interest mailing list
Interest at qt-project.org

More information about the Interest mailing list