|
SAGA API
v9.6
|
Go to the documentation of this file.
92 for(
size_t i=0; i<
Count(); i++)
94 if( !File.
Cmp(
Get(i)->Get_File_Name(bNative)) )
106 for(
size_t i=0; i<
Count(); i++)
108 if( pObject ==
Get(i) )
131 pObject->m_Managed++;
143 for(
size_t i=0; i<
Count(); i++)
145 if( pObject ==
Get(i) )
147 return(
Delete(i, bDetach) );
161 if( pObject->m_Managed > 0 )
163 pObject->m_Managed--;
166 if( !bDetach && !pObject->m_Managed )
173 for(
size_t j=i+1; j<
Count(); i++, j++)
175 pObjects[i] = pObjects[j];
189 for(
size_t i=
Count(); i>0; i--)
197 return(
Count() == 0 );
225 delete(m_pPointCloud);
267 if( (pObject =
Table ().
Find(File, bNative)) != NULL )
return( pObject );
268 if( (pObject =
Shapes ().
Find(File, bNative)) != NULL )
return( pObject );
269 if( (pObject =
PointCloud().
Find(File, bNative)) != NULL )
return( pObject );
270 if( (pObject =
TIN ().
Find(File, bNative)) != NULL )
return( pObject );
271 if( (pObject =
Grid ().
Find(File, bNative)) != NULL )
return( pObject );
272 if( (pObject =
Grids ().
Find(File, bNative)) != NULL )
return( pObject );
285 if(
TIN ().
Exists(pObject) )
return(
true );
291 for(
int j=0; j<
Grids(i).Get_Grid_Count(); j++)
293 if( pObject ==
Grids(i).Get_Grid_Ptr(j) )
321 if( pCollection && pCollection->
Add(pObject) )
388 default : pObject = NULL ;
break;
402 return( _Add_External(File) );
529 if( pObject && !
Add(pObject) )
531 delete(pObject); pObject = NULL;
545 if( pObject && !
Add(pObject) )
547 delete(pObject); pObject = NULL;
561 if( pObject && !
Add(pObject) )
563 delete(pObject); pObject = NULL;
577 if( pObject && !
Add(pObject) )
579 delete(pObject); pObject = NULL;
593 if( pObject && !
Add(pObject) )
595 delete(pObject); pObject = NULL;
609 if( pObject && !
Add(pObject) )
611 delete(pObject); pObject = NULL;
627 return( pCollection && pCollection->
Delete(pObject, bDetach) );
654 if(
Table().Count() )
710 for(
size_t i=0; i<
TIN().
Count(); i++)
738 if(
Grids().Count() )
@ PARAMETER_TYPE_FilePath
CSG_Data_Manager g_Data_Manager
CSG_Data_Object * Get(size_t i) const
bool Add(CSG_Data_Object *pObject)
SAGA_API_DLL_EXPORT bool SG_File_Cmp_Extension(const CSG_String &FileName, const CSG_String &Extension)
CSG_Data_Object * Get_Item(int Index) const
CSG_PointCloud * Add_PointCloud(void)
const SG_Char * Get_Name(void) const
CSG_Data_Manager & SG_Get_Data_Manager(void)
CSG_TIN * asTIN(void) const
@ SG_DATAOBJECT_TYPE_Grids
bool Exists(CSG_Data_Object *pObject) const
virtual TSG_Data_Object_Type Get_ObjectType(void) const =0
Returns the object type as defined by TSG_Data_Object_Type. Used for run time type checking.
CSG_Data_Object * asDataObject(void) const
CSG_Data_Collection & Shapes(void) const
CSG_String & Prepend(const CSG_String &String)
bool Inc_Array(sLong nValues=1)
int Cmp(const CSG_String &String) const
@ SG_UI_DATAOBJECT_UPDATE
SAGA_API_DLL_EXPORT bool SG_File_Exists(const CSG_String &FileName)
double Get_YMin(bool bCells=false) const
double Get_Cellsize(void) const
bool Exists(CSG_Data_Object *pObject) const
#define DATAOBJECT_CREATE
double Get_YMin(bool bCells=false) const
CSG_Data_Object * Find(const CSG_String &File, bool bNative=true) const
int SG_UI_Msg_Lock(bool bOn)
CSG_Grid * Add_Grid(void)
CSG_Grids * Add_Grids(void)
bool SG_UI_DataObject_Add(CSG_Data_Object *pDataObject, int Show)
bool Dec_Array(bool bShrink=true)
sLong Get_Count(void) const
double Get_XMin(bool bCells=false) const
CSG_Table * Add_Table(void)
bool Delete(CSG_Data_Object *pObject, bool bDetach=false)
CSG_Data_Collection & TIN(void) const
virtual ~CSG_Data_Manager(void)
@ SG_DATAOBJECT_TYPE_Grid
CSG_Data_Object * Add(CSG_Data_Object *pObject)
static CSG_String Format(const char *Format,...)
double Get_XMin(bool bCells=false) const
@ SG_DATAOBJECT_TYPE_Shapes
@ SG_DATAOBJECT_TYPE_Undefined
@ SG_DATAOBJECT_TYPE_Table
bool is_Empty(void) const
CSG_String Get_Summary(void) const
CSG_Data_Collection & PointCloud(void) const
CSG_Data_Object * Find(const CSG_String &File, bool bNative=true) const
double Get_Cellsize(void) const
void ** Get_Array(void) const
CSG_Data_Collection & Grids(void) const
virtual TSG_Shape_Type Get_Type(void) const
CSG_Array_Pointer m_Objects
CSG_Data_Collection & Grid(void) const
TSG_Data_Object_Type m_Type
CSG_Shapes * Add_Shapes(void)
bool Delete(CSG_Data_Object *pObject, bool bDetach=false)
CSG_Data_Collection & Table(void) const
class CSG_Parameter_List * asList(void) const
CSG_Data_Collection(TSG_Data_Object_Type Type)
@ SG_DATAOBJECT_TYPE_PointCloud
virtual bool is_Valid(void) const =0
virtual ~CSG_Data_Collection(void)
#define DATAOBJECT_NOTSET