Ground-Truthing GUI 1.0

- Main Page
- Related Pages
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | List of all members
CreateFileAbstraction Class Reference

Creates a text file related to an image. More...

`#include <createfileabstraction.h>`

## Public Member Functions
| CreateFileAbstraction (Image &image_1)
| The first constructor of the CreateFileAbstraction class This constructor is called when the user opens a image which is not associated to a text file. More...
| CreateFileAbstraction (QString filePath_1)
| The second constructor of the CreateFileAbstraction class This constructor is called when the user opens a text file which is already associated to an image. More...
virtual | ~CreateFileAbstraction ()
| Class destructor.
virtual void | createFile ()
| Creates the text file associated to the image. More...
virtual QString | removeExtension (QString filename_with_extension) const
| Removes the ".tiff" extension from the image filepath. More...
virtual FileAbstraction * | getFile () const
| Returns the text file associated to the image. More...
virtual Image * | getImage () const
| Returns the image to which the text file is associated. More...
virtual void | setImage (Image *image_1)
| Set the image to which the text file is associated. More...
virtual void | setFile (FileAbstraction *file_1)
| Set the text file. More...
virtual bool | fileExists () const
| When the user opens an image, checks if a text file associated to this image already exists. More...

## Detailed Description

Creates a text file related to an image.

This class creates a text file when the user opens an image for the first time.

Note
  The text file has the same name as the image to which it is related. It is also created in the same directory.

Author

Author
  David Carmona-Moreno

Version

Revision
  1.0

Date

Date
  2016/01/11 14:00:00

Bug:
  Not known bugs

Contacts: nikol.nosp@m.aos..nosp@m.arvan.nosp@m.itop.nosp@m.oulos.nosp@m.@epf.nosp@m.l.ch and david.nosp@m..car.nosp@m.mona-.nosp@m.more.nosp@m.no@ep.nosp@m.fl.c.nosp@m.h

Created on: Mon Jan 12 14:00:00 2016

## Constructor & Destructor Documentation

CreateFileAbstraction::CreateFileAbstraction | ( | Image & | image_1 | ) |
| inline

The first constructor of the CreateFileAbstraction class This constructor is called when the user opens a image which is not associated to a text file.

Parameters

  image_1 | The image to which the text file is going to be associated.

CreateFileAbstraction::CreateFileAbstraction | ( | QString | filePath_1 | ) |
| inline

The second constructor of the CreateFileAbstraction class This constructor is called when the user opens a text file which is already associated to an image.

Parameters

  filePath_1 | The filepath of the text file

## Member Function Documentation

void CreateFileAbstraction::createFile | ( |  | ) |
| virtual

Creates the text file associated to the image.

Returns
  Void.

bool CreateFileAbstraction::fileExists | ( |  | ) | const
| virtual

When the user opens an image, checks if a text file associated to this image already exists.

Returns
  True if the text file exists and False if it does not.

FileAbstraction * CreateFileAbstraction::getFile | ( |  | ) | const
| virtual

Returns the text file associated to the image.

Returns
  The text file associated to the image

Image * CreateFileAbstraction::getImage | ( |  | ) | const
| virtual

Returns the image to which the text file is associated.

Returns
  The image to which the text file is associated

QString CreateFileAbstraction::removeExtension | ( | QString | filename_with_extension | ) | const
| virtual

Removes the ".tiff" extension from the image filepath.

Parameters

  filename_with_extension | The image filename

Returns
  A filename without the extension ".tiff"

void CreateFileAbstraction::setFile | ( | FileAbstraction * | file_1 | ) |
| virtual

Set the text file.

Parameters

  file_1 | The text file

Returns
  Void.

void CreateFileAbstraction::setImage | ( | Image * | image_1 | ) |
| virtual

Set the image to which the text file is associated.

Parameters

  image_1 | The image to which the text file is associated

Returns
  Void.

The documentation for this class was generated from the following files:

- /media/david/4A52443C52442F4F/Users/David/Desktop/Projet EPFL/Ground_Truthing_20_10_2015/createfileabstraction.h
- /media/david/4A52443C52442F4F/Users/David/Desktop/Projet EPFL/Ground_Truthing_20_10_2015/createfileabstraction.cpp