#ifndef _FORMZ_FILE_PATHS_API_H
#define _FORMZ_FILE_PATHS_API_H

#ifdef __cplusplus
extern "C" {
#endif


/* @doc EXTERNAL MODEL */
/********************************************************************************************************

	@module File search path lists.

	@desc	File search path lists.

	@toc	file_search_path

*********************************************************************************************************/

/********************************************************************************************************

	@type	File paths pointer

	@desc	Pointer to a data structure that holds information about the file search paths.

	@avail	7.0.0.0

	@see	

	@toc	file_search_path

*********************************************************************************************************/
typedef struct file_paths_td* fz_file_paths_ptr;

/********************************************************************************************************

	@enum	

	@desc	Type of path.<nl>
			These types determine how the path.

	@avail	7.0.0.0

	@see	<auto>

	@toc	file_search_path

*********************************************************************************************************/
typedef enum fz_file_path_type_enum
{
	FZ_FILE_PATH_TYPE_ABS = 0,			/*	@emem	The path is an absolute path. */
	FZ_FILE_PATH_TYPE_REL_APPL,			/*	@emem	The path is relative to the application folder. */
	FZ_FILE_PATH_TYPE_REL_VTVS,			/*	@emem	The path is relative to the current project. */
	FZ_FILE_PATH_TYPE_REL_USERDOC,		/*	@emem	The path is relative to the user documents folder. */

	FZ_FILE_PATH_TYPE_MAX
}	fz_file_path_type_enum;

/********************************************************************************************************

	@func		

	@desc		Creates a new file search path.<nl>

	@return		Error codes

	@avail		7.0.0.0

	@see		

	@exfile		

	@toc		file_search_path

*********************************************************************************************************/
typedef fzrt_error_td	(FZRT_SPEC *fz_file_paths_init_func)(
	fz_file_paths_ptr		*file_paths		/*	@parm	<in_out> | File search paths pointer */
	);

/********************************************************************************************************

	@func		

	@desc		The list get string callback function.<nl>

	@return		Error codes

	@avail		7.0.0.0

	@see		

	@exfile		

	@toc		file_search_path

*********************************************************************************************************/
typedef fzrt_error_td	(FZRT_SPEC *fz_file_paths_finit_func)(
	fz_file_paths_ptr		*file_paths		/*	@parm	<in_out> | File search paths pointer */
	);

/********************************************************************************************************

	@func		

	@desc		The list get string callback function.<nl>

	@return		Error codes

	@avail		7.0.0.0

	@see		

	@exfile		

	@toc		file_search_path

*********************************************************************************************************/
typedef fzrt_error_td	(FZRT_SPEC *fz_file_paths_get_count_func)(
	fz_file_paths_ptr		file_paths,		/*	@parm	<in> | File search paths */
	fzrt_int					*count			/*	@parm	<out> | The number of file search path items */
	);

/********************************************************************************************************

	@func		

	@desc		Adds a new file search path item to the file search path.<nl>

	@return		Error codes

	@avail		7.0.0.0

	@see		

	@exfile		

	@toc		file_search_path

*********************************************************************************************************/
typedef fzrt_error_td	(FZRT_SPEC *fz_file_paths_add_func)(
	fz_file_paths_ptr		file_paths,		/*	@parm	<in> | File search paths */
	fzrt_int					windex,			/*	@parm	<in> |  */
	fzrt_floc_ptr			floc,			/*	@parm	<in> |  */
	fz_file_path_type_enum	path_type,		/*	@parm	<in> | Path search type. Absolute or relative from various locations */
	char					*relative_path	/*	@parm	<in> |  */
	);

/********************************************************************************************************

	@func		

	@desc		Removes a file search path item to the file search path.<nl>

	@return		Error codes

	@avail		7.0.0.0

	@see		

	@exfile		

	@toc		file_search_path

*********************************************************************************************************/
typedef fzrt_error_td	(FZRT_SPEC *fz_file_paths_remove_func)(
	fz_file_paths_ptr		file_paths,		/*	@parm	<in> | File search paths */
	fzrt_int					index			/*	@parm	<in> | Index of the file search path item to remove */
	);

/********************************************************************************************************

	@func		

	@desc		The list get string callback function.<nl>

	@return		Error codes

	@avail		7.0.0.0

	@see		

	@exfile		

	@toc		file_search_path

*********************************************************************************************************/
typedef fzrt_error_td	(FZRT_SPEC *fz_file_paths_search_func)(
	fzrt_int					windex,			/*	@parm	<in> | The project window index */
	fz_file_paths_ptr		file_paths,		/*	@parm	<in> | File search paths */
	char					*file_name,		/*	@parm	<in> | File name to search for */
	fzrt_floc_ptr			floc,			/*	@parm	<out> | File location */
	fzrt_boolean			*found			/*	@parm	<out> | Was a file found.
														TRUE if a file was found, FALSE otherwise */
	);

/********************************************************************************************************

	@func		

	@desc		The list get string callback function.<nl>

	@return		Error codes

	@avail		7.0.0.0

	@see		

	@exfile		

	@toc		file_search_path

*********************************************************************************************************/
typedef fzrt_error_td	(FZRT_SPEC *fz_file_paths_dialog_func)(
	fzrt_int					windex,			/*	@parm	<in> | The project window index */
	fz_file_paths_ptr		file_paths		/*	@parm	<in_out> | File search paths */
	);

/********************************************************************************************************

	@func		

	@desc		The list get string callback function.<nl>

	@return		Error codes

	@avail		8.6.0.0

	@see		

	@exfile		

	@toc		file_search_path

*********************************************************************************************************/
typedef fzrt_error_td	(*fz_file_paths_iost_func)(
	fz_file_paths_ptr		file_paths,
	fz_iost_ptr				iost
	);
	
	
/********************************************************************************************************

	@func		

	@desc		The list get string callback function.<nl>

	@return		Error codes

	@avail		7.0.0.0

	@see		

	@exfile		

	@toc		file_search_path

*********************************************************************************************************/
typedef fzrt_error_td	(FZRT_SPEC *fz_file_path_item_get_active_func)(
	fz_file_paths_ptr		file_paths,		/*	@parm	<out> | File search paths */
	fzrt_int					index,			/*	@parm	<in> |  */
	fzrt_boolean			*is_active		/*	@parm	<out> | Is the path active. 
														TRUE if the path is active, FALSE otherwise */
	);

/********************************************************************************************************

	@func		

	@desc		The list get string callback function.<nl>

	@return		Error codes

	@avail		7.0.0.0

	@see		

	@exfile		

	@toc		file_search_path

*********************************************************************************************************/
typedef fzrt_error_td	(FZRT_SPEC *fz_file_path_item_get_locked_func)(
	fz_file_paths_ptr		file_paths,		/*	@parm	<out> | File search paths */
	fzrt_int					index,			/*	@parm	<in> |  */
	fzrt_boolean			*is_locked		/*	@parm	<out> | Is the path locked. 
														TRUE if the path is locked, FALSE otherwise */
	);

/********************************************************************************************************

	@func		

	@desc		The list get string callback function.<nl>

	@return		Error codes

	@avail		7.0.0.0

	@see		

	@exfile		

	@toc		file_search_path

*********************************************************************************************************/
typedef fzrt_error_td	(FZRT_SPEC *fz_file_path_item_get_nested_func)(
	fz_file_paths_ptr		file_paths,		/*	@parm	<out> | File search paths */
	fzrt_int					index,			/*	@parm	<in> |  */
	fzrt_boolean			*is_nested,		/*	@parm	<out> | Does the path search nested folders. 
														TRUE if the path searches nested folders, FALSE otherwise */
	fzrt_boolean			*is_full_search	/*	@parm	<out> | Does the path search all nested folders. 
														TRUE if the path searches all nested folders (may be slow), 
														FALSE if only a limited number of nested folders are searched (faster) */
	);

/********************************************************************************************************

	@func		

	@desc		The list get string callback function.<nl>

	@return		Error codes

	@avail		7.0.0.0

	@see		

	@exfile		

	@toc		file_search_path

*********************************************************************************************************/
typedef fzrt_error_td	(FZRT_SPEC *fz_file_path_item_get_type_func)(
	fz_file_paths_ptr		file_paths,		/*	@parm	<out> | File search paths */
	fzrt_int					index,			/*	@parm	<in> |  */
	fz_file_path_type_enum	*path_type		/*	@parm	<out> | Path search type. Absolute or relative from various locations */
	);

/********************************************************************************************************

	@func		

	@desc		The list get string callback function.<nl>

	@return		Error codes

	@avail		7.0.0.0

	@see		

	@exfile		

	@toc		file_search_path

*********************************************************************************************************/
typedef fzrt_error_td	(FZRT_SPEC *fz_file_path_item_get_floc_func)(
	fz_file_paths_ptr		file_paths,		/*	@parm	<out> | File search paths */
	fzrt_int					index,			/*	@parm	<in> |  */
	fzrt_floc_ptr			floc			/*	@parm	<out> | Folder location */
	);

/********************************************************************************************************

	@func		

	@desc		The list get string callback function.<nl>

	@return		Error codes

	@avail		7.0.0.0

	@see		

	@exfile		

	@toc		file_search_path

*********************************************************************************************************/
typedef fzrt_error_td	(FZRT_SPEC *fz_file_path_item_set_active_func)(
	fz_file_paths_ptr		file_paths,		/*	@parm	<out> | File search paths */
	fzrt_int					index,			/*	@parm	<in> |  */
	fzrt_boolean			is_active		/*	@parm	<in> | Is the path active. 
														TRUE if the path is active, FALSE otherwise */
	);

/********************************************************************************************************

	@func		

	@desc		The list get string callback function.<nl>

	@return		Error codes

	@avail		7.0.0.0

	@see		

	@exfile		

	@toc		file_search_path

*********************************************************************************************************/
typedef fzrt_error_td	(FZRT_SPEC *fz_file_path_item_set_locked_func)(
	fz_file_paths_ptr		file_paths,		/*	@parm	<out> | File search paths */
	fzrt_int					index,			/*	@parm	<in> |  */
	fzrt_boolean			is_locked		/*	@parm	<in> | Is the path locked. 
														TRUE if the path is locked, FALSE otherwise */
	);

/********************************************************************************************************

	@func		

	@desc		The list get string callback function.<nl>

	@return		Error codes

	@avail		7.0.0.0

	@see		

	@exfile		

	@toc		file_search_path

*********************************************************************************************************/
typedef fzrt_error_td	(FZRT_SPEC *fz_file_path_item_set_nested_func)(
	fz_file_paths_ptr		file_paths,		/*	@parm	<out> | File search paths */
	fzrt_int					index,			/*	@parm	<in> |  */
	fzrt_boolean			is_nested,		/*	@parm	<in> | Does the path search nested folders. 
														TRUE if the path searches nested folders, FALSE otherwise */
	fzrt_boolean			is_full_search	/*	@parm	<in> | Does the path search all nested folders. 
														TRUE if the path searches all nested folders (may be slow), 
														FALSE if only a limited number of nested folders are searched (faster) */
	);

/********************************************************************************************************

	@func		

	@desc		The list get string callback function.<nl>

	@return		Error codes

	@avail		7.0.0.0

	@see		

	@exfile		

	@toc		file_search_path

*********************************************************************************************************/
typedef fzrt_error_td	(FZRT_SPEC *fz_file_path_item_set_type_func)(
	fz_file_paths_ptr		file_paths,		/*	@parm	<out> | File search paths */
	fzrt_int					index,			/*	@parm	<in> |  */
	fz_file_path_type_enum	path_type		/*	@parm	<in> | Path search type. Absolute or relative from various locations */
	);

#ifdef __cplusplus
}
#endif

#endif /* _FORMZ_FILE_PATHS_API_H */

