Functions
SQMProject.h File Reference
#include "SQDef.h"
#include "SQErrorCodes.h"
#include "SQCommon.h"
#include "SQProject.h"
#include "SQMWorkset.h"

Go to the source code of this file.

Functions

SQ_ErrorCode SQ_OpenProjectTempDir (const char *szProjectName, SQ_Bool bRecover, const char *szTempDir, const char *szPassword, SQ_Project *pProject)
 
SQ_ErrorCode SQ_CanRecover (const char *szProjectName, const char *szTempDir, SQ_Bool *bCanRecover)
 
SQ_ErrorCode SQ_Decrypt (SQ_Project pProject)
 
SQ_ErrorCode SQ_Encrypt (SQ_Project pProject, const char *szPassword)
 
SQ_ErrorCode SQ_SaveAs (SQ_Project pProject, const char *szNewProjectPath)
 
SQ_ErrorCode SQ_GetProjectOptions (SQ_Project pProject, SQ_ProjectOptions *pSQMProj)
 
SQ_ErrorCode SQ_SetProjectOptions (SQ_Project pProject, SQ_ProjectOptions *pSQMProj)
 
SQ_ErrorCode SQ_GetNewWorkset (SQ_Project pProject, SQ_IntVector vecDatasets, SQ_Workset *pWorkset)
 

Function Documentation

◆ SQ_CanRecover()

SQ_ErrorCode SQ_CanRecover ( const char *  szProjectName,
const char *  szTempDir,
SQ_Bool bCanRecover 
)

Checks if it is possible to reconstruct the usp from the temporary directory.

Parameters
[in]szProjectNameThe full path to the SIMCA project file, UTF-8 encoded.
[in]szTempDirThe directory where temporary files should be saved, and where the project should recover from, UTF-8 encoded.
[in]bCanRecoverTell if the project can be recovered or not.
Returns
Returns SQ_E_OK if success or an error code

◆ SQ_Decrypt()

SQ_ErrorCode SQ_Decrypt ( SQ_Project  pProject)

Decrypts an encrypted project, use encrypt to encrypt it again.

Parameters
[in]pProjectThe handle to the project to decrypt.
Returns
Returns SQ_E_OK if success or an error code

◆ SQ_Encrypt()

SQ_ErrorCode SQ_Encrypt ( SQ_Project  pProject,
const char *  szPassword 
)

Encrypt a project. Note: An encrypted project can only be opened with the password that was supplied when the encryption was performed.

Parameters
[in]pProjectThe handle to the project to encrypt.
[in]szPasswordThe password that the project should be encrypted with, UTF-8 encoded.
Returns
Returns SQ_E_OK if success or an error code

◆ SQ_GetNewWorkset()

SQ_ErrorCode SQ_GetNewWorkset ( SQ_Project  pProject,
SQ_IntVector  vecDatasets,
SQ_Workset pWorkset 
)

Create a new empty workset. Use

See also
SQ_CreateDefaultWorkset or
SQ_AddObservations to add observations from the datasets. The workset can be manipulated with the functions in SQMWorksetCInterface.h Note that no new model is created in the project until SQ_CreateModel is called (
SQMWorksetCInterface.h) The returned workset handle must be released with SQ_ReleaseWorkset
Parameters
[in]pProjectThe handle to the project for which a new workset is to be created.
[in]vecDatasetsDataset numbers to build the workset from
[out]pWorksetThe handle to the new workset.
Returns
Returns SQ_E_OK if success or an error code

◆ SQ_GetProjectOptions()

SQ_ErrorCode SQ_GetProjectOptions ( SQ_Project  pProject,
SQ_ProjectOptions pSQMProj 
)

Gets the options for a project.

See also
tagSQMProjectOptions
Parameters
[in]pProjectThe handle to the project
[in]pSQMProjThe struct to get the project options from.
Returns
Returns SQ_E_OK if success or an error code

◆ SQ_OpenProjectTempDir()

SQ_ErrorCode SQ_OpenProjectTempDir ( const char *  szProjectName,
SQ_Bool  bRecover,
const char *  szTempDir,
const char *  szPassword,
SQ_Project pProject 
)

Initialize the predictor with a new project and use a temporary directory for intermediate storing project data. Using a temporary directory is faster when editing the projects from an interactive application. The predictor can handle multiple project that are identified with a project id. It is the users responsibility to remove the project when finished.

See also
RemoveProject
Parameters
[in]szProjectNameThe full path to the SIMCA project file, UTF-8 encoded.
[in]bRecoverIf Recover= SQ_True, SQM tries to recover from the szTempDir,else SQM does not.
[in]szTempDirThe directory where temporary files should be saved, and where the project should be recovered from, UTF-8 encoded.
[in]szPasswordIf the usp is encrypted, supply the password that was used to encrypt it, UTF-8 encoded, else use NULL.
[out]pProjectThe project handle
Returns
Returns SQ_E_OK if success or an error code

◆ SQ_SaveAs()

SQ_ErrorCode SQ_SaveAs ( SQ_Project  pProject,
const char *  szNewProjectPath 
)

Save the project with a new name. If the new project already exists it will be overwritten.

Parameters
[in]pProjectThe handle to the project to be saved.
[in]szNewProjectPathThe full path including the new name of the project, for example C:\SIMCA-QM\NewProject.usp, UTF-8 encoded.
Returns
Returns SQ_E_OK if success or an error code

◆ SQ_SetProjectOptions()

SQ_ErrorCode SQ_SetProjectOptions ( SQ_Project  pProject,
SQ_ProjectOptions pSQMProj 
)

Sets the options for a project.

See also
tagSQMProjectOptions
Parameters
[in]pProjectThe handle to the project
[in]pSQMProjThe struct to set the project options in.
Returns
Returns SQ_E_OK if success or an error code

Copyright (C) Sartorius Stedim Data Analytics AB - Generated by Doxygen