Commit 599674e4 authored by Hugo Beauzée-Luyssen's avatar Hugo Beauzée-Luyssen
Browse files

IFile: Rename "ready" into "parsed"

A file is now always "ready" in the sense that is always has a type
parent 68abcae2
......@@ -50,9 +50,12 @@ class IFile
/// Returns wether the file has been added as a stand alone file (true), or as
/// part of a folder (false)
virtual bool isStandAlone() = 0;
/// Explicitely mark a file as "ready" (meaning all required metadata have been parsed)
virtual bool setReady() = 0;
virtual bool isReady() const = 0;
/// Explicitely mark a file as fully parsed, meaning no metadata service needs to run anymore.
//FIXME: This lacks granularity as we don't have a straight forward way to know which service
//needs to run or not.
virtual bool markParsed() = 0;
virtual bool isParsed() const = 0;
virtual unsigned int lastModificationDate() = 0;
......@@ -227,12 +227,12 @@ unsigned int File::lastModificationDate()
return m_lastModificationDate;
bool File::isReady() const
bool File::isParsed() const
return m_isParsed;
bool File::setReady()
bool File::markParsed()
if ( m_isParsed == true )
return true;
......@@ -72,8 +72,8 @@ class File : public IFile, public Cache<File, IFile, policy::FileTable, policy::
virtual bool isStandAlone() override;
virtual unsigned int lastModificationDate() override;
virtual bool isReady() const;
bool setReady();
virtual bool markParsed() override;
virtual bool isParsed() const override;
DBConnection m_dbConnection;
......@@ -94,7 +94,7 @@ void Parser::done( FilePtr file, ServiceStatus status, void* data )
if (t->it == t->end)
delete t;
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment