Command
QisLib_SaveOASISStructure

QisLib_SaveOASISStructure


Function:
	int QisLib_SaveOASISStructure(const char* TargetFileName);

Inputs:
	TargetFileName: Name and path of the OASIS file to which the cell is to be saved.

Return:
	success: 0
	failure: one of the following values :

Errors:
	-1: QisLib has not been initialized.
	-2: The OASIS file has not been loaded into the memory.
	-3: Cannot save data to the same OASIS file.
	-5: The specified input is either invalid or null.
	-6: No OASIS file has been opened.
	-7: File open in progress, operation not permitted.
	3: Usage Error: No open files.
	30: Memory Error: Cannot allocate memory.

Description:
	- This function saves the currently opened cell and all the cells it references down
	the hierarchy to the output file.
	- This operation has same effect as extracting the current cell from the OASIS file
	while preserving the hierarchy. This command is simillar to QisLib_SaveOASIS.
	- This function will work only if the input OASIS file is opened in edit mode
	(QisLib_SetLoadMemory is on or file was created from scratch using QisLib_NewOASIS).
	This function will fail if the input file is GDSII.
	- This function does not save settings such as layer on/off, nesting level, array mode etc.
	- Data is output on the same layer as the input. However QisLib_SetOutputLayerMap can
	be used to control the mapping of the input layers to different output layers.
	- If a progress message callback function has been set using
	QisLib_SetProgressMessageCallback, QisLib updates the file save percentage to the
	user program while this function is executing.
	- If this operation needs to be cancelled, use QisLib_Stop. This can only be done if
	QisLib_SetProcessEvents is turned on. Also, for Unix/Linux, the program's
	application context must be passed to QisLib_InitLib.
	- The Grid of the output OASIS file can be controlled by using QisLib_SetDBU and
	QisLib_SetResolution. By default, these values will be same as the input OASIS file.

References:
QisLib_SetOutputLayerMap
QisLib_SetLoadMemory
QisLib_NewOASIS
QisLib_SetProgressMessageCallback
QisLib_SetDBU
QisLib_Stop
QisLib_SetResolution
QisLib_SetProcessEvents