SML::OBJECT Class Reference
#include <sml/object.h>
List of all members.
Public Member Functions |
| void | AddRef () |
| void | Close (bool CloseDatabasesToo=false) |
| void | CloseDatabases () |
| int | ConvertPointMapToObject (const DPOINT2D &src, const GEOSTRUCT *SrcGeoref, DPOINT2D *pDest) |
| int | ConvertPointObjectToMap (const DPOINT2D &src, const GEOSTRUCT *DestGeoref, DPOINT2D *pDest) |
| ERRVALUE | DeleteExisting () |
| void | Free () |
| const RVC::CREDENTIALS * | GetCredentials () const |
| int | GetCurElemNum (ELEMTYPE elemtype) const |
| int | GetElemData (ELEMDATA **pElemData, ELEMTYPE ElemType, bool bAllocIfNeeded=false) |
| const FILEPATH & | GetFilePath () const |
| RVC::OBJECT * | GetInterfaceBase () const |
| const RVC::OBJITEM & | GetObjItem () const |
| RVC::OBJITEM & | GetObjItem () |
| RVC::OBJTYPE | GetObjType () const |
| STYPE | GetSMLSTYPE () const |
| bool | IsDirty () const |
| bool | IsDoingForEach (ELEMTYPE ElemType) const |
| bool | IsUserTempObject () const |
| OBJECT * | Next () const |
| void | OnInterfaceAttach (const RVC::OBJITEM &ObjItem) |
| void | OnInterfaceDestroy () |
| void | OnInterfaceDetach () |
| int | ReadGeoref (GEOSTRUCT **pGeostruct, const RVC::OBJITEM *ObjItem=0) |
| DEPRECATED int | ReadGeoref (GEOSTRUCT **pGeostruct, const RVC::OBJITEM &ObjItem) |
| void | Release () |
| void | SetDirty (bool bDirty=true) |
| void | SetFilePath (const FILEPATH &filepath) |
| void | SetIsUserTempObject (bool state) |
| void | SetObjItem (const RVC::OBJITEM &item) |
| ERRVALUE | Setup (const RVC::OBJITEM &item, const RVC::CREDENTIALS *Credentials) |
Static Public Member Functions |
| static OBJECT * | Allocate (RVC::OBJTYPE objtype) |
Protected Member Functions |
| | OBJECT (STYPE type, CONTEXT *context) |
| virtual | ~OBJECT () |
| void | ConstructInterface (RVC::OBJTYPE) const |
Protected Attributes |
| RVC::OBJECT * | m_Interface |
Static Protected Attributes |
| static OBJPROXY * | s_Proxy |
Detailed Description
- Note:
- Constructor/Destructor are private and only used by SML::CONTEXT which is a friend class
Constructor & Destructor Documentation
| SML::OBJECT::OBJECT |
( |
STYPE |
type, |
|
|
CONTEXT * |
context | |
|
) |
| | [protected] |
| virtual SML::OBJECT::~OBJECT |
( |
|
) |
[protected, virtual] |
Member Function Documentation
| void SML::OBJECT::AddRef |
( |
|
) |
|
| void SML::OBJECT::Close |
( |
bool |
CloseDatabasesToo = false |
) |
|
Close the object.
Note! Open/Close calls are not refcounted. Only internal SML should call Close() for now. This is mainly for effeciency. If you always balanced Open/Close calls, you'd be opening and closing the object all the time which would slow down SML. If you need something open, just call Open() and let SML close it when it decides it needs to.
| void SML::OBJECT::CloseDatabases |
( |
|
) |
|
Close the databases associated with an object.
| void SML::OBJECT::ConstructInterface |
( |
RVC::OBJTYPE |
|
) |
const [protected] |
| int SML::OBJECT::ConvertPointMapToObject |
( |
const DPOINT2D & |
src, |
|
|
const GEOSTRUCT * |
SrcGeoref, |
|
|
DPOINT2D * |
pDest | |
|
) |
| | |
Not const. May read last used georef for object if not already read.
| int SML::OBJECT::ConvertPointObjectToMap |
( |
const DPOINT2D & |
src, |
|
|
const GEOSTRUCT * |
DestGeoref, |
|
|
DPOINT2D * |
pDest | |
|
) |
| | |
Not const. May read last used georef for object if not already read.
| ERRVALUE SML::OBJECT::DeleteExisting |
( |
|
) |
|
If the object refers to an existing object, delete it, but keep the objitem setup to point to a NewRequest for the same descriptor same parent, etc.
..
| void SML::OBJECT::Free |
( |
|
) |
|
Destroies the SML::OBJECT.
"delete this" Necessary since destructor is private and not exported from DLL
| int SML::OBJECT::GetCurElemNum |
( |
ELEMTYPE |
elemtype |
) |
const |
| int SML::OBJECT::GetElemData |
( |
ELEMDATA ** |
pElemData, |
|
|
ELEMTYPE |
ElemType, |
|
|
bool |
bAllocIfNeeded = false | |
|
) |
| | |
| const FILEPATH& SML::OBJECT::GetFilePath |
( |
|
) |
const |
Not const. May need to alloc.
Get the filepath of the object.
Returns the RVC::OBJECT for the object.
The derived classes each have a GetInterface which returns the specific object type. For example SML::VECTOROBJECT has a GetInterface() that returns an RVC::VECTOR* The SML::OBJECT "owns" the pointer returned and will free it when the object is freed.
| STYPE SML::OBJECT::GetSMLSTYPE |
( |
|
) |
const |
| bool SML::OBJECT::IsDirty |
( |
|
) |
const |
| bool SML::OBJECT::IsDoingForEach |
( |
ELEMTYPE |
ElemType |
) |
const |
Returns TRUE if SML is busy executing a FOREACH loop on this object.
| bool SML::OBJECT::IsUserTempObject |
( |
|
) |
const |
Returns TRUE if the object is a temporary object created by the Script (eg: by calling CreateTempRaster()).
The object and its file will be deleted when the script exits.
| OBJECT* SML::OBJECT::Next |
( |
|
) |
const |
Returns the "next" object in the context's object list.
Used internally to iterate through the objects.
| void SML::OBJECT::OnInterfaceAttach |
( |
const RVC::OBJITEM & |
ObjItem |
) |
|
| void SML::OBJECT::OnInterfaceDestroy |
( |
|
) |
|
| void SML::OBJECT::OnInterfaceDetach |
( |
|
) |
|
| int SML::OBJECT::ReadGeoref |
( |
GEOSTRUCT ** |
pGeostruct, |
|
|
const RVC::OBJITEM * |
ObjItem = 0 | |
|
) |
| | |
Read the georef subobject.
If already read, it will just return what's been read in regardless of inode (I may change that. If you want to force the matter, you could SetGeoref(NULL) but that would cause a memory leak). If ObjItem is 0 (or omitted) it will just read the LastUsed georef
| DEPRECATED int SML::OBJECT::ReadGeoref |
( |
GEOSTRUCT ** |
pGeostruct, |
|
|
const RVC::OBJITEM & |
ObjItem | |
|
) |
| | |
Read the georef subobject.
If already read, it will just return what's been read in regardless of inode (I may change that. If you want to force the matter, you could SetGeoref(NULL) but that would cause a memory leak). If inode is 0 (or omitted) it will just read the LastUsed georef This is a slightly older version of the function which didn't allow for the possibility of not passing the ObjItem at all to force it to read the default georeference.
| void SML::OBJECT::Release |
( |
|
) |
|
| void SML::OBJECT::SetDirty |
( |
bool |
bDirty = true |
) |
|
Set the dirty flag so Flush() knows it has to do something.
| void SML::OBJECT::SetFilePath |
( |
const FILEPATH & |
filepath |
) |
|
Set the filepath of the object.
| void SML::OBJECT::SetIsUserTempObject |
( |
bool |
state |
) |
|
Pass true to tell SML that the object is a temporary object created by the Script (eg: by calling CreateTempRaster()).
The object and its file will be deleted when the script exits.
Setup the object This is to replace the need to call SetObjItem, SetCredentials, Open and Close just to set everything up.
Member Data Documentation
The documentation for this class was generated from the following file: