NCBI C++ ToolKit
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
CSelectProjectOptions Class Reference

Search Toolkit Book for CSelectProjectOptions

CProjectSelectOptions - describes how new Project Items shall be added to a workspace. More...

#include <gui/core/select_project_options.hpp>

Public Types

enum  EAction {
  eInvalidAction = -1 , eDecideLater , eCreateNewProject , eCreateSeparateProjects ,
  eAddToExistingProject
}
 
using TProjectId = objects::CGBProjectHandle::TId
 
typedef CRef< objects::CProjectItem > TItemRef
 
typedef vector< TItemRefTItems
 
typedef CRef< objects::CLoaderDescriptor > TLoaderRef
 
typedef vector< TLoaderRefTLoaders
 
typedef map< TLoaderRef, TItemsTData
 

Public Member Functions

 CSelectProjectOptions ()
 CSelectProjectOptions. More...
 
void Set_DecideLater ()
 
void Set_CreateNewProject (const string &folder=kEmptyStr)
 
void Set_CreateSeparateProjects ()
 
void Set_AddToExistingProject (TProjectId &project_id, const string &folder=kEmptyStr)
 
void SetNewProjectName (const string &newProjectName)
 
EAction GetAction ()
 
TProjectId GetTargetProjectId ()
 
string GetFolderName ()
 
bool AddItemsToWorkspace (CProjectService *service, const TData &data)
 

Static Public Member Functions

static void InitProjectnameGenerator (objects::CGBWorkspace &ws, CUniqueLabelGenerator &projectNames)
 
static CGBDocumentCreateProject (CProjectService *service, const string &prjName, const string &prjDesc)
 

Protected Member Functions

bool x_ShowSelectProjectDialog (CProjectService *service, TItems &items)
 
void x_AddToExistingProject (CProjectService *service, TItems &items, const TLoaders &loaders)
 
void x_CreateOneProject (CProjectService *service, TItems &items, const TLoaders &loaders)
 
void x_CreateSeparateProjects (CProjectService *service, const TData &data)
 for every Project Item in m_Items creates a new project, adds the item to the project and loads the data More...
 

Protected Attributes

EAction m_Action
 
TProjectId m_TargetProjectId
 
string m_FolderName
 
string m_NewProjectName
 

Detailed Description

CProjectSelectOptions - describes how new Project Items shall be added to a workspace.

If folder name is not empty a new Project Folder will be created for the items.

Definition at line 54 of file select_project_options.hpp.

Member Typedef Documentation

◆ TData

Definition at line 88 of file select_project_options.hpp.

◆ TItemRef

typedef CRef<objects::CProjectItem> CSelectProjectOptions::TItemRef

Definition at line 82 of file select_project_options.hpp.

◆ TItems

Definition at line 83 of file select_project_options.hpp.

◆ TLoaderRef

typedef CRef<objects::CLoaderDescriptor> CSelectProjectOptions::TLoaderRef

Definition at line 85 of file select_project_options.hpp.

◆ TLoaders

Definition at line 86 of file select_project_options.hpp.

◆ TProjectId

using CSelectProjectOptions::TProjectId = objects::CGBProjectHandle::TId

Definition at line 64 of file select_project_options.hpp.

Member Enumeration Documentation

◆ EAction

Enumerator
eInvalidAction 
eDecideLater 
eCreateNewProject 
eCreateSeparateProjects 
eAddToExistingProject 

Definition at line 57 of file select_project_options.hpp.

Constructor & Destructor Documentation

◆ CSelectProjectOptions()

CSelectProjectOptions::CSelectProjectOptions ( )

CSelectProjectOptions.

Definition at line 51 of file select_project_options.cpp.

Member Function Documentation

◆ AddItemsToWorkspace()

bool CSelectProjectOptions::AddItemsToWorkspace ( CProjectService service,
const TData data 
)

◆ CreateProject()

CGBDocument * CSelectProjectOptions::CreateProject ( CProjectService service,
const string prjName,
const string prjDesc 
)
static

◆ GetAction()

CSelectProjectOptions::EAction CSelectProjectOptions::GetAction ( void  )

Definition at line 87 of file select_project_options.cpp.

References m_Action.

Referenced by CFileLoadManager::GetTask().

◆ GetFolderName()

string CSelectProjectOptions::GetFolderName ( )

Definition at line 99 of file select_project_options.cpp.

References m_FolderName.

Referenced by CFileLoadManager::GetTask().

◆ GetTargetProjectId()

CSelectProjectOptions::TProjectId CSelectProjectOptions::GetTargetProjectId ( )

Definition at line 93 of file select_project_options.cpp.

References m_TargetProjectId.

Referenced by CBlastSearchTask::Init_RetrieveRID().

◆ InitProjectnameGenerator()

void CSelectProjectOptions::InitProjectnameGenerator ( objects::CGBWorkspace &  ws,
CUniqueLabelGenerator projectNames 
)
static

◆ Set_AddToExistingProject()

void CSelectProjectOptions::Set_AddToExistingProject ( TProjectId project_id,
const string folder = kEmptyStr 
)

◆ Set_CreateNewProject()

void CSelectProjectOptions::Set_CreateNewProject ( const string folder = kEmptyStr)

◆ Set_CreateSeparateProjects()

void CSelectProjectOptions::Set_CreateSeparateProjects ( )

◆ Set_DecideLater()

void CSelectProjectOptions::Set_DecideLater ( )

◆ SetNewProjectName()

void CSelectProjectOptions::SetNewProjectName ( const string newProjectName)
inline

Definition at line 76 of file select_project_options.hpp.

References m_NewProjectName.

◆ x_AddToExistingProject()

void CSelectProjectOptions::x_AddToExistingProject ( CProjectService service,
TItems items,
const TLoaders loaders 
)
protected

◆ x_CreateOneProject()

void CSelectProjectOptions::x_CreateOneProject ( CProjectService service,
TItems items,
const TLoaders loaders 
)
protected

◆ x_CreateSeparateProjects()

void CSelectProjectOptions::x_CreateSeparateProjects ( CProjectService service,
const TData data 
)
protected

◆ x_ShowSelectProjectDialog()

bool CSelectProjectOptions::x_ShowSelectProjectDialog ( CProjectService service,
TItems items 
)
protected

Member Data Documentation

◆ m_Action

EAction CSelectProjectOptions::m_Action
protected

◆ m_FolderName

string CSelectProjectOptions::m_FolderName
protected

◆ m_NewProjectName

string CSelectProjectOptions::m_NewProjectName
protected

◆ m_TargetProjectId

TProjectId CSelectProjectOptions::m_TargetProjectId
protected

The documentation for this class was generated from the following files:
Modified on Thu Apr 25 08:20:47 2024 by modify_doxy.py rev. 669887