Rename abigail::corpus::{get_file_path --> get_path}

* include/abg-corpus.h (corpus::{get_path, set_path): Renamed
	corpus::get_file_path and corpus::set_file_path into these as
	get_path/set_path is what is used elsewhere as well.
	* src/abg-corpus.cc (corpus::{get_path, set_path}): Likewise.
	* tests/test-write-read-archive.cc (main): Adjust for the change
	above.

Signed-off-by: Dodji Seketeli <dodji@redhat.com>
This commit is contained in:
Dodji Seketeli 2013-08-29 16:29:25 +02:00
parent 67ff0340be
commit 5767379648
3 changed files with 10 additions and 10 deletions

View File

@ -61,10 +61,10 @@ public:
drop_translation_units();
string&
get_file_path() const;
get_path() const;
void
set_file_path(const string&);
set_path(const string&);
bool
is_empty() const;

View File

@ -239,7 +239,7 @@ corpus::drop_translation_units()
/// @return the file path associated to the current corpus.
string&
corpus::get_file_path() const
corpus::get_path() const
{
return m_priv->path;
}
@ -252,7 +252,7 @@ corpus::drop_translation_units()
/// the corpus object into the on-disk file at this path.
/// @param the new file path to assciate to the current corpus.
void
corpus::set_file_path(const string& path)
corpus::set_path(const string& path)
{
m_priv->path = path;
}
@ -267,7 +267,7 @@ corpus::set_file_path(const string& path)
}
/// Serialize the current corpus to disk in a file which path is given
/// by corpus::get_file_path.
/// by corpus::get_path.
///
/// @return true upon successful completion, false otherwise.
bool
@ -285,7 +285,7 @@ corpus::write() const
return true;
}
/// Open the archive which path is given by corpus::get_file_path and
/// Open the archive which path is given by corpus::get_path and
/// de-serialize each of the translation units it contains.
///
/// @return the number of entries read and properly de-serialized,

View File

@ -112,7 +112,7 @@ main()
if (!abi_corpus.write())
{
cerr << "failed to write archive file: " << abi_corpus.get_file_path();
cerr << "failed to write archive file: " << abi_corpus.get_path();
return 1;
}
@ -126,7 +126,7 @@ main()
if (abi_corpus.get_translation_units().size())
{
cerr << "In-memory object of abi corpus at '"
<< abi_corpus.get_file_path()
<< abi_corpus.get_path()
<< "' still has translation units after call to "
"corpus::drop_translation_units!";
return false;
@ -135,7 +135,7 @@ main()
if (!abi_corpus.read())
{
cerr << "Failed to load the abi corpus from path '"
<< abi_corpus.get_file_path()
<< abi_corpus.get_path()
<< "'";
return 1;
}
@ -144,7 +144,7 @@ main()
{
cerr << "Read " << abi_corpus.get_translation_units().size()
<< " elements from the abi corpus at "
<< abi_corpus.get_file_path()
<< abi_corpus.get_path()
<< " instead of "
<< NUM_ARCHIVES_ELEMENTS;
return 1;