OpendTect 8.0
Loading...
Searching...
No Matches
SurveyCreator Class Referenceabstract

Utility class to work with OpendTect survey/project zip files. More...

#include <surveyfile.h>

Inheritance diagram for SurveyCreator:
[legend]

Public Member Functions

virtual ~SurveyCreator ()
 
virtual uiRetVal activate ()
 
virtual uiRetVal deactivate ()
 
uiRetVal errMsg () const
 
BufferString getSurveyDir () const
 
BufferString getSurveyNm () const
 
BufferString getTempBaseDir () const
 
virtual BufferString getZipArchiveLocation () const =0
 
bool isManaged () const
 
bool isMounted () const
 
bool isOK () const
 
virtual uiRetVal mount (bool isnew=false, TaskRunner *=nullptr)
 
virtual uiRetVal save (TaskRunner *=nullptr)
 
void setManaged (bool yn)
 
virtual uiRetVal unmount (bool save=true, TaskRunner *=nullptr)
 
uiRetVal warningMsg () const
 

Static Public Member Functions

static BufferString bckupExtStr ()
 
static const char * extStr ()
 

Protected Member Functions

 SurveyCreator (const char *survnm, const char *dataroot, bool ismanaged)
 
virtual bool createSurvey (TaskRunner *)=0
 

Protected Attributes

SurveyChanger * changer_ = nullptr
 
bool ismanaged_ = true
 
uiRetVal lasterrs_
 
uiRetVal lastwarning_
 
bool mounted_ = false
 
bool owndataroot_ = false
 
SurveyDiskLocation * surveyloc_ = nullptr
 
BufferString surveynm_
 

Detailed Description

Utility class to work with OpendTect survey/project zip files.

Encapsulates actions on a OpendTect survey/project zip file including:

  • unpacking to a temporary base data folder (mount)
  • making the unpacked survey the active survey (activate)
  • cleaning up the unpacked folder back and optionally saving the survey back to a zip file with backup (unmount) The default extension for the survey/project files is ".odz". Backup files have an extension of "odz_bck". The destructor automatically deletes the temporary base folder and unpacked survey without saving.

Constructor & Destructor Documentation

◆ ~SurveyCreator()

virtual SurveyCreator::~SurveyCreator ( )
virtual

◆ SurveyCreator()

SurveyCreator::SurveyCreator ( const char * survnm,
const char * dataroot,
bool ismanaged )
protected

Member Function Documentation

◆ activate()

virtual uiRetVal SurveyCreator::activate ( )
virtual

Reimplemented in SurveyFile.

◆ bckupExtStr()

static BufferString SurveyCreator::bckupExtStr ( )
inlinestatic

◆ createSurvey()

virtual bool SurveyCreator::createSurvey ( TaskRunner * )
protectedpure virtual

Implemented in EmptyTempSurvey, and SurveyFile.

◆ deactivate()

virtual uiRetVal SurveyCreator::deactivate ( )
virtual

◆ errMsg()

uiRetVal SurveyCreator::errMsg ( ) const
inline

◆ extStr()

static const char * SurveyCreator::extStr ( )
inlinestatic

◆ getSurveyDir()

BufferString SurveyCreator::getSurveyDir ( ) const

◆ getSurveyNm()

BufferString SurveyCreator::getSurveyNm ( ) const
inline

◆ getTempBaseDir()

BufferString SurveyCreator::getTempBaseDir ( ) const

◆ getZipArchiveLocation()

virtual BufferString SurveyCreator::getZipArchiveLocation ( ) const
pure virtual

Implemented in EmptyTempSurvey, and SurveyFile.

◆ isManaged()

bool SurveyCreator::isManaged ( ) const
inline

◆ isMounted()

bool SurveyCreator::isMounted ( ) const
inline

◆ isOK()

bool SurveyCreator::isOK ( ) const

◆ mount()

virtual uiRetVal SurveyCreator::mount ( bool isnew = false,
TaskRunner * = nullptr )
virtual

◆ save()

virtual uiRetVal SurveyCreator::save ( TaskRunner * = nullptr)
virtual

◆ setManaged()

void SurveyCreator::setManaged ( bool yn)
inline

◆ unmount()

virtual uiRetVal SurveyCreator::unmount ( bool save = true,
TaskRunner * = nullptr )
virtual

◆ warningMsg()

uiRetVal SurveyCreator::warningMsg ( ) const
inline

Member Data Documentation

◆ changer_

SurveyChanger* SurveyCreator::changer_ = nullptr
protected

◆ ismanaged_

bool SurveyCreator::ismanaged_ = true
protected

◆ lasterrs_

uiRetVal SurveyCreator::lasterrs_
mutableprotected

◆ lastwarning_

uiRetVal SurveyCreator::lastwarning_
mutableprotected

◆ mounted_

bool SurveyCreator::mounted_ = false
protected

◆ owndataroot_

bool SurveyCreator::owndataroot_ = false
protected

◆ surveyloc_

SurveyDiskLocation* SurveyCreator::surveyloc_ = nullptr
protected

◆ surveynm_

BufferString SurveyCreator::surveynm_
protected

Generated at for the OpendTect seismic interpretation project. Copyright (C): dGB Beheer B.V. 1995-2026