CanEasy COM-Help
CanEasy::IDatabase Interface Reference
Inheritance diagram for CanEasy::IDatabase:
CanEasy::IDatabaseItem

Detailed Description

Database is root entry of channels, message, signals,...

interface IDatabase : IDatabaseItem
{
HRESULT Load([in] BSTR sFilePath);
HRESULT Save([in] BSTR sFilePath);
HRESULT FindObject([in] IObjectFilter* filter, [in] IDispatch* iStartObj, [out, retval] IDatabaseItem**);
HRESULT Busses([out, retval] IBusCol* *pVal);
HRESULT GenerateBus([in] BSTR sBusName, [in] BSTR sFile);
HRESULT FindObjects([in] IObjectFilter* pFilter, [out, retval] ISelection**);
HRESULT ValueTables([out, retval] IValueTableCol** ppVal);
HRESULT DBChangedEvents([out, retval] VARIANT_BOOL *pVal);
HRESULT DBChangedEvents([in] VARIANT_BOOL boVal);
HRESULT BrowseDatabase([in] long hParentWindow, [in] IDatabaseItem *iRootObj, [in] IDatabaseItem *iSelectionObj, [in] enum DatabaseBrowse_Show enKindShow, [in] enum DatabaseBrowse_Select enKindSelect, [in] BSTR sTitle, [out, retval] IDatabaseItem**);
HRESULT EndDatabaseChange();
HRESULT SetTrsCtrlForMessages([in] BSTR sText);
HRESULT Variables([out, retval] INamespace **pItem);
HRESULT CreateTransmissionEvent([out, retval] ITransmissionEvent** pItem);
HRESULT AttributeChangeEvents([out, retval] VARIANT_BOOL* boVal);
HRESULT AttributeChangeEvents([in] VARIANT_BOOL boVal);
HRESULT TransmissionEvent([out, retval] ITransmissionEvent** pItem);
HRESULT FilterPreTransmit([in] BSTR sFilter, [in] BSTR sId, [in] enum CallbackPosition enPosition);
HRESULT FilterPreCopy([in] BSTR sFilter, [in] BSTR sId, [in] enum CallbackPosition enPosition);
HRESULT FilterTxConfirm([in] BSTR sFilter, [in] BSTR sId, [in] enum CallbackPosition enPosition, VARIANT_BOOL boAsynch);
HRESULT FilterRxConfirm([in] BSTR sFilter, [in] BSTR sId, [in] enum CallbackPosition enPosition, VARIANT_BOOL boAsynch);
HRESULT PreTransmitEvents([out, retval] VARIANT_BOOL* pVal);
HRESULT PreTransmitEvents([in] VARIANT_BOOL boVal);
HRESULT PreCopyEvents([out, retval] VARIANT_BOOL* pVal);
HRESULT PreCopyEvents([in] VARIANT_BOOL boVal);
HRESULT TxConfirmEvents([out, retval] VARIANT_BOOL* pVal);
HRESULT TxConfirmEvents([in] VARIANT_BOOL boVal);
HRESULT RxConfirmEvents([out, retval] VARIANT_BOOL* pVal);
HRESULT RxConfirmEvents([in] VARIANT_BOOL boVal);
HRESULT CreateOffsetFactorConversion([out, retval] IOffsetFactorConversion**);
HRESULT CreateDatabaseItem([in] BSTR sType, [out, retval] IDatabaseItem**);
HRESULT SetValue([in] BSTR sRef, [in] VARIANT val);
HRESULT GetValue([in] BSTR sRef, [out, retval] VARIANT*);
HRESULT GetValueString([in] BSTR sRef, [out, retval] BSTR*);
HRESULT Execute([in] BSTR sRef);
HRESULT TransmitRef([in] BSTR sRef);
HRESULT TransmitRefOn([in] BSTR sRef, [in] enum BusType enBusType, [in] long channel);
HRESULT IsValueLess([in] BSTR sRef, [in] double dVal, [in] long timeout, [out, retval] VARIANT_BOOL*);
HRESULT IsValueGreater([in] BSTR sRef, [in] double dVal, [in] long timeout, [out, retval] VARIANT_BOOL*);
HRESULT IsValueLessOrEqual([in] BSTR sRef, [in] double dVal, [in] long timeout, [out, retval] VARIANT_BOOL*);
HRESULT IsValueGreaterOrEqual([in] BSTR sRef, [in] double dVal, [in] long timeout, [out, retval] VARIANT_BOOL*);
HRESULT IsValueEqual([in] BSTR sRef, [in] double dVal, [in] long timeout, [out, retval] VARIANT_BOOL*);
HRESULT IsValueInRange([in] BSTR sRef, [in] double dMinVal, [in] double dMaxVal, [in] long timeout, [out, retval] VARIANT_BOOL*);
HRESULT IsTransmitted([in] BSTR sRef, [in] long timeoutMS, [in] enum DirectionFilter enFilter, [out, retval] VARIANT_BOOL*);
HRESULT ReadData([in] BSTR sRef);
HRESULT WriteData([in] BSTR sRef);
HRESULT CopyValue([in] IValue* s, [in] IValue* d);
};

Definition at line 5290 of file cand_tlb.idl.

Member Function Documentation

◆ BeginDatabaseChange()

HRESULT CanEasy::IDatabase::BeginDatabaseChange ( )

Deprecated: Should be called before doing many database changes

◆ BrowseDatabase()

HRESULT CanEasy::IDatabase::BrowseDatabase ( [in] long  hParentWindow,
[in] IDatabaseItem iRootObj,
[in] IDatabaseItem iSelectionObj,
[in] enum DatabaseBrowse_Show  enKindShow,
[in] enum DatabaseBrowse_Select  enKindSelect,
[in] BSTR  sTitle,
[out, retval] IDatabaseItem **   
)

Opens the browse dialog to select an item from the database

Parameters
hParentWindowHandle to window that should be used as parent
iRootObjRoot object to start showing items
iSelectionObjObject that should be selected
enKindShowKind of items that should be shown
enKindSelectKind of items that can be selected
sTitleTitle of the window
Returns
Pointer to selected database item

◆ CopyValue()

HRESULT CanEasy::IDatabase::CopyValue ( [in] IValue s,
[in] IValue d 
)

Copys the value, uses different ways dependent on other properties. Float, Double and Converted values use phys. Bigger than 64 bit use copy of tape.

Parameters
ssource value
ddest value

◆ CreateDatabaseItem()

HRESULT CanEasy::IDatabase::CreateDatabaseItem ( [in] BSTR  sType,
[out, retval] IDatabaseItem **   
)

Creates new database item

Parameters
sTypeString type of the database item (see xml export)

◆ CreateOffsetFactorConversion()

HRESULT CanEasy::IDatabase::CreateOffsetFactorConversion ( [out, retval] IOffsetFactorConversion **  )

Creates new conversion

◆ CreateTransmissionEvent()

HRESULT CanEasy::IDatabase::CreateTransmissionEvent ( [out, retval] ITransmissionEvent **  pItem)

Creates TransmissionEvent which can be registered to a database item to get send/receive events

◆ EndDatabaseChange()

HRESULT CanEasy::IDatabase::EndDatabaseChange ( )

Deprecated: Should be called after doing database changes are done

◆ Execute()

HRESULT CanEasy::IDatabase::Execute ( [in] BSTR  sRef)

Executes an executable database item. Can be schedule table or message.

Parameters
sRefString path to the database item to be executed

◆ FilterPreCopy()

HRESULT CanEasy::IDatabase::FilterPreCopy ( [in] BSTR  sFilter,
[in] BSTR  sId,
[in] enum CallbackPosition  enPosition 
)

Activated PreCopy events. See ITransmissionEvent for more help.

Parameters
sFilterString filter to reduce the number of events
sIdUnique identifier name
enPositionDeprecated: Priority when event has to be called

◆ FilterPreTransmit()

HRESULT CanEasy::IDatabase::FilterPreTransmit ( [in] BSTR  sFilter,
[in] BSTR  sId,
[in] enum CallbackPosition  enPosition 
)

Activated PreTransmit events. See ITransmissionEvent for more help.

Parameters
sFilterString filter to reduce the number of events
sIdUnique identifier name
enPositionDeprecated: Priority when event has to be called

◆ FilterRxConfirm()

HRESULT CanEasy::IDatabase::FilterRxConfirm ( [in] BSTR  sFilter,
[in] BSTR  sId,
[in] enum CallbackPosition  enPosition,
VARIANT_BOOL  boAsynch 
)

Deprecated: Activated RxConfirm events. Use TransmissionEvent instead. See ITransmissionEvent for more help.

Parameters
sFilterString filter to reduce the number of events
sIdUnique identifier name
enPositionDeprecated: Priority when event has to be called
boAsynchShould be set to true. If set to false the event is called from high prio transmission thread.

◆ FilterTxConfirm()

HRESULT CanEasy::IDatabase::FilterTxConfirm ( [in] BSTR  sFilter,
[in] BSTR  sId,
[in] enum CallbackPosition  enPosition,
VARIANT_BOOL  boAsynch 
)

Deprecated: Activated TxConfirm events. Use TransmissionEvent instead. See ITransmissionEvent for more help.

Parameters
sFilterString filter to reduce the number of events
sIdUnique identifier name
enPositionDeprecated: Priority when event has to be called
boAsynchShould be set to true. If set to false the event is called from high prio transmission thread.

◆ FindObject()

HRESULT CanEasy::IDatabase::FindObject ( [in] IObjectFilter filter,
[in] IDispatch *  iStartObj,
[out, retval] IDatabaseItem **   
)

Searches for a database item by filter

Parameters
filterFilter object to identify item
iStartObjPointer to database item to start search
Returns
Pointer to found database item or null of nothing matched

◆ FindObjects()

HRESULT CanEasy::IDatabase::FindObjects ( [in] IObjectFilter pFilter,
[out, retval] ISelection **   
)

Searches for mulitple database items by filter

Parameters
pFilterFilter object to identify items
Returns
Selection containing all found items

◆ GenerateBus()

HRESULT CanEasy::IDatabase::GenerateBus ( [in] BSTR  sBusName,
[in] BSTR  sFile 
)

Import a bus from file (DBC, ARXML)

Parameters
sBusNameBus name to import
sFileFile to import

◆ GetValue()

HRESULT CanEasy::IDatabase::GetValue ( [in] BSTR  sRef,
[out, retval] VARIANT *   
)

Returns a value by string path

Parameters
sRefString path to the database item thas has to read
Returns
Value of the database item (can be string or physical value)

◆ GetValueString()

HRESULT CanEasy::IDatabase::GetValueString ( [in] BSTR  sRef,
[out, retval] BSTR *   
)

Returns a string value by string path

Parameters
sRefString path to the database item thas has to read
Returns
Value of the database item as string

◆ IsTransmitted()

HRESULT CanEasy::IDatabase::IsTransmitted ( [in] BSTR  sRef,
[in] long  timeoutMS,
[in] enum DirectionFilter  enFilter,
[out, retval] VARIANT_BOOL *   
)

Returns true if the message was transmitted in defined time

Parameters
sRefString path to message to be checked
timeoutMSTimeout in milliseconds
enFilterDirection filter (rx, tx)
Returns
True if message was transmitted otherwise False

◆ IsValueEqual()

HRESULT CanEasy::IDatabase::IsValueEqual ( [in] BSTR  sRef,
[in] double  dVal,
[in] long  timeout,
[out, retval] VARIANT_BOOL *   
)

Returns true if value becomes equal to value in defined time

Parameters
sRefString path to the database item to be checked
dValExpected value to compare
timeoutTimeout in milliseconds
Returns
True if valid otherwise False

◆ IsValueGreater()

HRESULT CanEasy::IDatabase::IsValueGreater ( [in] BSTR  sRef,
[in] double  dVal,
[in] long  timeout,
[out, retval] VARIANT_BOOL *   
)

Returns true if value becomes greater than value in defined time

Parameters
sRefString path to the database item to be checked
dValExpected value to compare
timeoutTimeout in milliseconds
Returns
True if valid otherwise False

◆ IsValueGreaterOrEqual()

HRESULT CanEasy::IDatabase::IsValueGreaterOrEqual ( [in] BSTR  sRef,
[in] double  dVal,
[in] long  timeout,
[out, retval] VARIANT_BOOL *   
)

Returns true if value becomes greater or equal to value in defined time

Parameters
sRefString path to the database item to be checked
dValExpected value to compare
timeoutTimeout in milliseconds
Returns
True if valid otherwise False

◆ IsValueInRange()

HRESULT CanEasy::IDatabase::IsValueInRange ( [in] BSTR  sRef,
[in] double  dMinVal,
[in] double  dMaxVal,
[in] long  timeout,
[out, retval] VARIANT_BOOL *   
)

Returns true if value becomes in defined range in defined time

Parameters
sRefString path to the database item to be checked
dMinValExpected minimum value to compare
dMaxValExpected maximum value to compare
timeoutTimeout in milliseconds
Returns
True if valid otherwise False

◆ IsValueLess()

HRESULT CanEasy::IDatabase::IsValueLess ( [in] BSTR  sRef,
[in] double  dVal,
[in] long  timeout,
[out, retval] VARIANT_BOOL *   
)

Returns true if value becomes less than value in defined time

Parameters
sRefString path to the database item to be checked
dValExpected value to compare
timeoutTimeout in milliseconds
Returns
True if valid otherwise False

◆ IsValueLessOrEqual()

HRESULT CanEasy::IDatabase::IsValueLessOrEqual ( [in] BSTR  sRef,
[in] double  dVal,
[in] long  timeout,
[out, retval] VARIANT_BOOL *   
)

Returns true if value becomes less or equal to value in defined time

Parameters
sRefString path to the database item to be checked
dValExpected value to compare
timeoutTimeout in milliseconds
Returns
True if valid otherwise False

◆ Load()

HRESULT CanEasy::IDatabase::Load ( [in] BSTR  sFilePath)

Loads a database from file (dbc, xml, arxml)

◆ ReadData()

HRESULT CanEasy::IDatabase::ReadData ( [in] BSTR  sRef)

Reads data via UDS or XCP protocol

Parameters
sRefString path to variable

◆ Save()

HRESULT CanEasy::IDatabase::Save ( [in] BSTR  sFilePath)

Saves the database to a file

◆ SetTrsCtrlForMessages()

HRESULT CanEasy::IDatabase::SetTrsCtrlForMessages ( [in] BSTR  sText)

Sets the passed transmission control name for all messages of this database.

◆ SetValue()

HRESULT CanEasy::IDatabase::SetValue ( [in] BSTR  sRef,
[in] VARIANT  val 
)

Sets a value by string path

Parameters
sRefString path to the database item thas has to be changed
valValue to set (can be string or physical value)

◆ TransmitRef()

HRESULT CanEasy::IDatabase::TransmitRef ( [in] BSTR  sRef)

Transmits a database item

Parameters
sRefString path to the database item to be transmitted

◆ TransmitRefOn()

HRESULT CanEasy::IDatabase::TransmitRefOn ( [in] BSTR  sRef,
[in] enum BusType  enBusType,
[in] long  channel 
)

Transmits a database item on a bus/channel

Parameters
sRefString path to the database item to be transmitted
enBusTypeBus type to send on (CAN)
channelVirtual channel to send on (1)

◆ WriteData()

HRESULT CanEasy::IDatabase::WriteData ( [in] BSTR  sRef)

Writes data via UDS or XCP protocol

Parameters
sRefString path to variable

Property Documentation

◆ AttributeChangeEvents

VARIANT_BOOL CanEasy::IDatabase::AttributeChangeEvents
getset

Deprecated: Activates/Deactivates attribute changes events. Use _DatabaseItemEvents instead.

◆ Busses

IBusCol CanEasy::IDatabase::Busses
get

Returns collection containing all channels/busses

◆ DBChangedEvents

VARIANT_BOOL CanEasy::IDatabase::DBChangedEvents
getset

Deprecated: Activate database change events. Use _DatabaseItemEvents instead.

◆ PreCopyEvents

VARIANT_BOOL CanEasy::IDatabase::PreCopyEvents
getset

Activates/Deactivates PreCopy events

◆ PreTransmitEvents

VARIANT_BOOL CanEasy::IDatabase::PreTransmitEvents
getset

Activates/Deactivates PreTransmit events

◆ RxConfirmEvents

VARIANT_BOOL CanEasy::IDatabase::RxConfirmEvents
getset

Deprecated: Activates/Deactivates RxConfirm events. Use TransmissionEvent instead.

◆ TransmissionEvent

ITransmissionEvent CanEasy::IDatabase::TransmissionEvent
get

Returns the class to get transmission events.

Example: Use item.TransmissionEvent.Active = true to activate the events.

◆ TxConfirmEvents

VARIANT_BOOL CanEasy::IDatabase::TxConfirmEvents
getset

Deprecated: Activates/Deactivates TxConfirm events. Use TransmissionEvent instead.

◆ ValueTables

IValueTableCol CanEasy::IDatabase::ValueTables
get

Returns collection containing all value tables

◆ Variables

INamespace CanEasy::IDatabase::Variables
get

Returns namespace containing variables of the database

CanEasy::IDatabase::TxConfirmEvents
VARIANT_BOOL TxConfirmEvents
CanEasy::IDatabase::IsValueInRange
HRESULT IsValueInRange([in] BSTR sRef, [in] double dMinVal, [in] double dMaxVal, [in] long timeout, [out, retval] VARIANT_BOOL *)
CanEasy::IDatabase::Save
HRESULT Save([in] BSTR sFilePath)
CanEasy::IDatabase::ReadData
HRESULT ReadData([in] BSTR sRef)
CanEasy::IDatabase::FilterRxConfirm
HRESULT FilterRxConfirm([in] BSTR sFilter, [in] BSTR sId, [in] enum CallbackPosition enPosition, VARIANT_BOOL boAsynch)
CanEasy::DatabaseBrowse_Show
DatabaseBrowse_Show
The DatabaseBrowse_Show enumeration defines filters for the database browse dialog.
Definition: cand_tlb.idl:400
CanEasy::IDatabase::Variables
INamespace Variables
CanEasy::IDatabase::SetTrsCtrlForMessages
HRESULT SetTrsCtrlForMessages([in] BSTR sText)
CanEasy::BusType
BusType
The BusType enumeration defines all the supported bus types.
Definition: cand_tlb.idl:90
CanEasy::IDatabase::GenerateBus
HRESULT GenerateBus([in] BSTR sBusName, [in] BSTR sFile)
CanEasy::IDatabase::IsValueGreater
HRESULT IsValueGreater([in] BSTR sRef, [in] double dVal, [in] long timeout, [out, retval] VARIANT_BOOL *)
CanEasy::DirectionFilter
DirectionFilter
The DirectionFilter enumeration defines filters for the replay.
Definition: cand_tlb.idl:478
CanEasy::IDatabase::CreateDatabaseItem
HRESULT CreateDatabaseItem([in] BSTR sType, [out, retval] IDatabaseItem **)
CanEasy::IDatabase::FindObjects
HRESULT FindObjects([in] IObjectFilter *pFilter, [out, retval] ISelection **)
CanEasy::IDatabase::FilterTxConfirm
HRESULT FilterTxConfirm([in] BSTR sFilter, [in] BSTR sId, [in] enum CallbackPosition enPosition, VARIANT_BOOL boAsynch)
CanEasy::IDatabase::PreCopyEvents
VARIANT_BOOL PreCopyEvents
CanEasy::IDatabase::Busses
IBusCol Busses
CanEasy::IDatabase::CreateOffsetFactorConversion
HRESULT CreateOffsetFactorConversion([out, retval] IOffsetFactorConversion **)
CanEasy::IDatabase::TransmitRefOn
HRESULT TransmitRefOn([in] BSTR sRef, [in] enum BusType enBusType, [in] long channel)
CanEasy::IDatabase::IsTransmitted
HRESULT IsTransmitted([in] BSTR sRef, [in] long timeoutMS, [in] enum DirectionFilter enFilter, [out, retval] VARIANT_BOOL *)
CanEasy::DatabaseBrowse_Select
DatabaseBrowse_Select
The DatabaseBrowse_Select enumeration defines filters for the selection in the database browse dialog...
Definition: cand_tlb.idl:413
CanEasy::IDatabase::FindObject
HRESULT FindObject([in] IObjectFilter *filter, [in] IDispatch *iStartObj, [out, retval] IDatabaseItem **)
CanEasy::IDatabase::IsValueGreaterOrEqual
HRESULT IsValueGreaterOrEqual([in] BSTR sRef, [in] double dVal, [in] long timeout, [out, retval] VARIANT_BOOL *)
CanEasy::IDatabase::FilterPreTransmit
HRESULT FilterPreTransmit([in] BSTR sFilter, [in] BSTR sId, [in] enum CallbackPosition enPosition)
CanEasy::IDatabase::SetValue
HRESULT SetValue([in] BSTR sRef, [in] VARIANT val)
CanEasy::IDatabase::CopyValue
HRESULT CopyValue([in] IValue *s, [in] IValue *d)
CanEasy::IDatabase::TransmissionEvent
ITransmissionEvent TransmissionEvent
Returns the class to get transmission events.
CanEasy::IDatabase::FilterPreCopy
HRESULT FilterPreCopy([in] BSTR sFilter, [in] BSTR sId, [in] enum CallbackPosition enPosition)
CanEasy::IDatabase::IsValueEqual
HRESULT IsValueEqual([in] BSTR sRef, [in] double dVal, [in] long timeout, [out, retval] VARIANT_BOOL *)
CanEasy::IDatabase::PreTransmitEvents
VARIANT_BOOL PreTransmitEvents
CanEasy::IDatabase::DBChangedEvents
VARIANT_BOOL DBChangedEvents
CanEasy::IDatabase::CreateTransmissionEvent
HRESULT CreateTransmissionEvent([out, retval] ITransmissionEvent **pItem)
CanEasy::IDatabase::ValueTables
IValueTableCol ValueTables
CanEasy::IDatabase::GetValueString
HRESULT GetValueString([in] BSTR sRef, [out, retval] BSTR *)
CanEasy::IDatabase::TransmitRef
HRESULT TransmitRef([in] BSTR sRef)
CanEasy::IDatabase::EndDatabaseChange
HRESULT EndDatabaseChange()
CanEasy::IDatabase::AttributeChangeEvents
VARIANT_BOOL AttributeChangeEvents
CanEasy::IDatabase::IsValueLess
HRESULT IsValueLess([in] BSTR sRef, [in] double dVal, [in] long timeout, [out, retval] VARIANT_BOOL *)
CanEasy::IDatabase::WriteData
HRESULT WriteData([in] BSTR sRef)
CanEasy::IDatabase::BeginDatabaseChange
HRESULT BeginDatabaseChange()
CanEasy::IDatabase::IsValueLessOrEqual
HRESULT IsValueLessOrEqual([in] BSTR sRef, [in] double dVal, [in] long timeout, [out, retval] VARIANT_BOOL *)
CanEasy::IDatabase::BrowseDatabase
HRESULT BrowseDatabase([in] long hParentWindow, [in] IDatabaseItem *iRootObj, [in] IDatabaseItem *iSelectionObj, [in] enum DatabaseBrowse_Show enKindShow, [in] enum DatabaseBrowse_Select enKindSelect, [in] BSTR sTitle, [out, retval] IDatabaseItem **)
CanEasy::CallbackPosition
CallbackPosition
Deprecated: The CallbackPosition enumeration defines the position when a transmission callback has to...
Definition: cand_tlb.idl:289
CanEasy::IDatabase::RxConfirmEvents
VARIANT_BOOL RxConfirmEvents
CanEasy::IDatabase::GetValue
HRESULT GetValue([in] BSTR sRef, [out, retval] VARIANT *)
CanEasy::IDatabase::Load
HRESULT Load([in] BSTR sFilePath)
CanEasy::IDatabase::Execute
HRESULT Execute([in] BSTR sRef)