UNA
Loading...
Searching...
No Matches
BxTimelineDb Class Reference
Inheritance diagram for BxTimelineDb:
BxBaseModNotificationsDb BxBaseModGeneralDb BxDolModuleDb BxDolModuleQuery BxDolDb iBxDolSingleton BxDolFactory iBxDolSingleton

Public Member Functions

 __construct (&$oConfig)
 
 deleteModuleEvents ($aData)
 
 updateStatusAdmin ($iContentId, $isActive)
 
 activateModuleEvents ($aData, $bActivate=true)
 
 getMaxDuration ($aParams)
 
 markAsRead ($iUserId, $iEventId)
 
 cleanRead ($iLimit)
 
 insertRepostTrack ($iEventId, $iAuthorId, $sAuthorIp, $iRepostedId)
 
 updateRepostTrack ($aParamsSet, $aParamsWhere)
 
 deleteRepostTrack ($iEventId)
 
 updateRepostCounter ($iId, $iCounter, $iIncrement=1)
 
 getReposted ($sType, $sAction, $iObjectId)
 
 getRepostedBy ($iRepostedId)
 
 getReposts ($iRepostedId)
 
 isReposted ($iRepostedId, $iOwnerId, $iAuthorId)
 
 saveMedia ($sType, $iEventId, $iItemId)
 
 deleteMedia ($sType, $iEventId)
 
 hasMedia ($iEventId)
 
 getMedia ($sType, $iEventId, $iOffset=0, $bFullInfo=false)
 
 getMediaById ($sType, $iMediaId)
 
 getUnusedLinks ($iUserId)
 
 deleteUnusedLinks ($iUserId, $iLinkId=0)
 
 saveLink ($iEventId, $iLinkId)
 
 deleteLink ($iId)
 
 deleteLinks ($iEventId)
 
 getLinks ($iEventId)
 
 getLinksBy ($aParams=array())
 
 getHot ()
 
 clearHot ()
 
 getHotTrackByDate ($iInterval=24)
 
 getHotTrackByCommentsDate ($sModule, $sTableTrack, $iInterval=24, $iThresholdAge=0, $iThresholdCount=0)
 
 getHotTrackByCommentsDateModule ($sModule, $sTableTrack, $iInterval=24, $iThresholdAge=0, $iThresholdCount=0)
 
 getHotTrackByVotesDate ($sModule, $sTableTrack, $iInterval=24, $iThresholdAge=0, $iThresholdCount=0)
 
 getHotTrackByVotesDateModule ($sModule, $sTableTrack, $iInterval=24, $iThresholdAge=0, $iThresholdCount=0)
 
 getHotTrackByVotesSum ($sModule, $sTableTrack, $iInterval=24)
 
 getHotTrackByVotesSumModule ($sModule, $sTableTrack, $iInterval=24)
 
 updateHotTrack ($aTrack)
 
 rebuildSlice ()
 
 getEvents ($aParams)
 
 getEventFlagTypes ()
 
 updateEventFlagsByType ($sType, $iEventId)
 
 deleteEventFlagsByType ($sType, $iEventId)
 
 deleteEventFlags ($iEventId)
 
 getMenuItemMaxOrder ($sSetName)
 
 getMenuItemId ($sSetName, $sName)
 
 insertMenuItem ($sSetName, $sModule, $sName, $sTitle, $iOrder)
 
 deleteMenuItem ($sSetName, $sName)
 
 insertEvent ($aParamsSet)
 
- Public Member Functions inherited from BxBaseModNotificationsDb
 getTable ()
 
 isTableAlias ()
 
 getTableAlias ()
 
 getAlertHandlerId ()
 
 insertData ($aData)
 
 deleteData ($aData)
 
 getHandlers ($aParams=array())
 
 getSetting ($aParams=array())
 
 updateSetting ($aParamsSet, $aParamsWhere)
 
 activateSettingById ($bActive, $mixedId)
 
 activateSettingByIdUser ($bActive, $iUserId, $mixedSettingId)
 
 changeSettingById ($sField, $mixedValue, $mixedId)
 
 changeSettingByIdUser ($sField, $mixedValue, $iUserId, $mixedSettingId)
 
 initSettingUser ($iUserId)
 
 insertSettingUser ($aParamsSet)
 
 deleteSettingUser ($aParamsWhere)
 
 updateEvent ($aParamsSet, $aParamsWhere)
 
 deleteEvent ($aParams, $sWhereAddon="")
 
- Public Member Functions inherited from BxBaseModGeneralDb
 getContentInfoById ($iContentId)
 
 getEntriesBy ($aParams=array())
 
 getEntriesNumByContext ($iProfileId)
 
 getEntriesByAuthor ($iProfileId)
 
 getEntriesNumByAuthor ($iProfileId)
 
 getEntriesNumByParams ($aParams=[])
 
 updateEntriesBy ($aParamsSet, $aParamsWhere)
 
 publishEntries ()
 
 alterFulltextIndex ()
 
 deleteNestedById ($iNestedId, $sTableKey, $sTableName)
 
 getNestedBy ($aParams, $sTableName)
 
 getStatByProfile ($iAuthorId)
 
- Public Member Functions inherited from BxDolModuleDb
 __construct ($oConfig)
 
 getPrefix ()
 
- Public Member Functions inherited from BxDolModuleQuery
 __clone ()
 
 getModuleById ($iId, $bFromCache=true)
 
 getModuleByName ($sName, $bFromCache=true)
 
 getModuleByUri ($sUri, $bFromCache=true)
 
 enableModuleByUri ($sUri)
 
 disableModuleByUri ($sUri)
 
 setModulePendingUninstall ($sUri, $bPendingUninstall)
 
 isModule ($sUri)
 
 isModuleByName ($sName)
 
 isModuleParamsUsed ($sName, $sUri, $sPath, $sPrefixDb, $sPrefixClass)
 
 isEnabled ($sUri)
 
 isEnabledByName ($sName)
 
 getModules ()
 
 getModulesBy ($aParams=array(), $bFromCache=true)
 
 isModuleContent ($sName)
 
 isModuleContext ($sName)
 
 isModuleProfile ($sName)
 
 getModulesUri ()
 
 getDependent ($sName, $sUri)
 
 updateModule ($aParamsSet, $aParamsWhere=array())
 
 checkModulesSubtypes ()
 
- Public Member Functions inherited from BxDolDb
 setReadOnlyMode ($b)
 
 connect ()
 
 disconnect ()
 
 ping ()
 
 pdoExec ($sQuery)
 
 pdoQuery ($sQuery)
 
 pdoExceptionHandler ($oException)
 
 getOption ($sName)
 
 getOne ($oStatement, $aBindings=array(), $iIndex=0)
 
 getRow ($oStatement, $aBindings=array(), $iFetchType=PDO::FETCH_ASSOC)
 
 getColumn ($oStatement, $aBindings=array(), $iFetchColumnNumber=0)
 
 getFirstRow ($oStatement, $aBindings=array(), $iFetchType=PDO::FETCH_ASSOC)
 
 getNextRow ($iFetchType=PDO::FETCH_ASSOC)
 
 getAll ($oStatement, $aBindings=array(), $iFetchType=PDO::FETCH_ASSOC)
 
 fillArray ($oStatement, $aBindings=array(), $iFetchType=PDO::FETCH_ASSOC)
 
 getAllWithKey ($oStatement, $sFieldKey, $aBindings=array(), $iFetchType=PDO::FETCH_ASSOC)
 
 getPairs ($oStatement, $sFieldKey, $sFieldValue, $aBindings=array(), $iFetchType=PDO::FETCH_ASSOC)
 
 getNumRows ($oStatement=null)
 
 getAffectedRows ($oStatement=null)
 
 lastId ()
 
 query ($oStatement, $aBindings=array(), $bVerbose=null)
 
 res ($oStatement, $aBindings=array(), $bVerbose=null)
 
 getServerInfo ()
 
 getVersion ()
 
 listTables ()
 
 getFields ($sTable)
 
 fetchField ($oStatement, $iField, $aBindings=array())
 
 isTableExists ($sTable)
 
 isFieldExists ($sTable, $sFieldName)
 
 isIndexExists ($sTable, $sIndexName)
 
 error ($aError)
 
 cacheParams ($bForceCacheInvalidate=false, $bForceCacheInvalidateMixed=false)
 
 cacheParamsClear ($sCacheName='')
 
 isParam ($sKey, $bFromCache=true)
 
 addParam ($sName, $sValue, $iKateg, $sDesc, $sType)
 
 getParam ($sKey, $bFromCache=true)
 
 setParam ($sKey, $mixedValue, $iMixId=0)
 
 getParamsMix ($iId)
 
 getParamsMixActive ($sType)
 
 getParamsMixes ($sType, $mixedPublished=false)
 
 setTimezone ($sTimezone)
 
 getEncoding ()
 
 setErrorChecking ($b)
 
 getDbCacheObject ()
 
 genDbCacheKey ($sName)
 
 getCache ($sName, $sFunc)
 
 setCache ($sName, $mData)
 
 fromCache ($sName, $sFunc)
 
 cleanCache ($sName)
 
fromMemory ($sName, $sFunc)
 
 cleanMemory ($sName)
 
 cleanMemoryAll ()
 
 escape ($s)
 
 implode_escape ($mixed)
 
 unescape ($mixed)
 
 prepare ($sQuery)
 
 prepareAsString ($sQuery)
 
 arrayToSQL ($a, $sDiv=',', $sOperator='=', $bWildcardSpaceChars=false)
 
 executeSQL ($sPath, $aReplace=array(), $isBreakOnError=true)
 

Protected Member Functions

 _getFilterAddon ($iOwnerId, $sFilter)
 
 _getSqlPartsEvents ($aParams)
 
 _getSqlPartsEventsListStatusAdmin ($aParams)
 
 _getSqlPartsEventsList ($aParams)
 
 _isList ($aParams)
 
- Protected Member Functions inherited from BxBaseModGeneralDb
 _getEntriesBySearchIds ($aParams, &$aMethod, &$sSelectClause, &$sJoinClause, &$sWhereClause, &$sOrderClause, &$sLimitClause)
 
 _addCustomConditions ($aParams, &$aMethod, &$sSelectClause, &$sJoinClause, &$sWhereClause, &$sOrderClause, &$sLimitClause)
 
 _addConditionsForAuthorStatus ($aParams, &$aMethod, &$sSelectClause, &$sJoinClause, &$sWhereClause, &$sOrderClause, &$sLimitClause)
 
 _addConditionsForCf ($aParams, &$aMethod, &$sSelectClause, &$sJoinClause, &$sWhereClause, &$sOrderClause, &$sLimitClause)
 
 _getEntriesBySearchIdsOrder ($aParams, &$sOrderClause)
 
 _getEbsiLike ($sValue)
 
- Protected Member Functions inherited from BxDolDb
 balancer ()
 
 isParamInCache ($sKey)
 
 log ($s)
 
 executeStatement ($oStatement, $aBindings=array(), $bVerbose=null, &$iErrorCode=null)
 
 executeStatementException ($oStatement, $aBindings=array(), $bVerbose=null)
 
 executeStatementSilent ($oStatement, $aBindings=array(), $bVerbose=null)
 
 errorOutput ($aError)
 

Protected Attributes

 $_sTableSlice
 
 $_sTableEvent2User
 
 $_aTablesEventFlags
 
 $_sTableRepostsTrack
 
 $_sTableHotTrack
 
 $_aTablesMedia
 
 $_aTablesMedia2Events
 
- Protected Attributes inherited from BxBaseModNotificationsDb
 $_oConfig
 
 $_sTable
 
 $_sTableAlias
 
 $_sTableHandlers
 
 $_sTableSettings
 
 $_sTableSettings2Users
 
 $_sHandlerMask
 
 $_aDeliveryTypes
 
- Protected Attributes inherited from BxBaseModGeneralDb
 $_oConfig
 
- Protected Attributes inherited from BxDolModuleDb
 $_sPrefix
 
- Protected Attributes inherited from BxDolDb
 $_bPdoPersistent
 
 $_iPdoFetchType
 
 $_iPdoErrorMode
 
 $_bErrorChecking
 
 $_aError
 
 $_sHost
 
 $_sPort
 
 $_sSocket
 
 $_sDbname
 
 $_sUser
 
 $_sPassword
 
 $_sCharset
 
 $_sStorageEngine
 
 $_oStatement = null
 
 $_oDbCacheObject = null
 

Additional Inherited Members

- Static Public Member Functions inherited from BxDolModuleQuery
static getInstance ()
 
- Static Public Member Functions inherited from BxDolDb
static getInstanceWithConf ($aDbConf, &$sError)
 
static getLink ()
 
- Static Protected Attributes inherited from BxDolDb
static $_rLink
 
static $_aDbCacheData
 
static $_aParams
 
static $_sParamsCacheName = 'sys_options'
 
static $_sParamsCacheNameMixed = 'sys_options_mixed_'
 
static $_sParamsCacheNameMix = 'sys_options_mix_'
 
static $_sErrorKey = 'bx_db_error'
 
static $_aErrors
 
static $_bReadOnlyMode = true
 
static $_bMultuServersMode = false
 

Constructor & Destructor Documentation

◆ __construct()

BxTimelineDb::__construct ( & $oConfig)

Reimplemented from BxBaseModNotificationsDb.

Member Function Documentation

◆ _getFilterAddon()

BxTimelineDb::_getFilterAddon ( $iOwnerId,
$sFilter )
protected

Direct posts in Timeline made by a timeline owner ($iOwnerId)

Direct posts in Timeline made by users except a timeline owner ($iOwnerId)

All (Direct and System) posts in Timeline (owned by $iOwnerId) made by users except the viewer

◆ _getSqlPartsEvents()

BxTimelineDb::_getSqlPartsEvents ( $aParams)
protected

Reimplemented from BxBaseModNotificationsDb.

◆ _getSqlPartsEventsList()

BxTimelineDb::_getSqlPartsEventsList ( $aParams)
protected

Hooks:

'bx_timeline', 'get_list_by_type' - hook to override SQL query parts which are used to get events list

  • $unit_name - equals bx_timeline
  • $action - equals get_list_by_type
  • $object_id - not used
  • $sender_id - not used
  • $extra_params - array of additional params with the following array keys:
    • type - [string] a type of events list
    • owner_id - [int] owner profile id
    • params - [array] browse params array as key&value pairs
    • table - [string] datatbase table name
    • table_alias - [string] datatbase table alias
    • join_clause - [string] by ref, 'join' part of SQL query, can be overridden in hook processing
    • join_subclause - [string] or [array] by ref, 'join subclause' part of SQL query, string is attached to 'join' part, array is used to create query with UNIONs, can be overridden in hook processing
    • where_clause - [string] by ref, 'where' part of SQL query, can be overridden in hook processing
    • where_clause_status - [string] by ref, 'status' condition in 'where' part of SQL query, can be overridden in hook processing
    • where_clause_filter - [string] by ref, 'filter' condition in 'where' part of SQL query, can be overridden in hook processing
    • where_clause_timeline - [string] by ref, 'timeline' condition in 'where' part of SQL query, can be overridden in hook processing
    • where_clause_modules - [string] by ref, 'modules' condition in 'where' part of SQL query, can be overridden in hook processing
    • where_clause_hidden - [string] by ref, 'hidden' condition in 'where' part of SQL query, can be overridden in hook processing
    • where_clause_medias - [string] by ref, 'medias' condition in 'where' part of SQL query, can be overridden in hook processing
    • where_clause_muted - [string] by ref, 'muted' conditions in 'where' part of SQL query, can be overridden in hook processing
    • where_clause_unpublished - [string] by ref, 'unpublished' condition in 'where' part of SQL query, can be overridden in hook processing
    • where_clause_cf - [string] by ref, 'cf' condition in 'where' part of SQL query, can be overridden in hook processing
    • where_subclause - [string] or [array] by ref, 'where subclause' part of SQL query, string is attached to 'where' part, array is used to create query with UNIONs, can be overridden in hook processing
      HOOKS
      'bx_timeline', 'get_list_by_type' - hook to override SQL query parts which are used to get events list

Reimplemented from BxBaseModNotificationsDb.

◆ activateModuleEvents()

BxTimelineDb::activateModuleEvents ( $aData,
$bActivate = true )

Reimplemented from BxBaseModNotificationsDb.

◆ deleteModuleEvents()

BxTimelineDb::deleteModuleEvents ( $aData)

Reimplemented from BxBaseModNotificationsDb.

◆ getEvents()

BxTimelineDb::getEvents ( $aParams)

Hooks:

'bx_timeline', 'get_events_before' - hook to override params which are used to get events

Hooks:

'bx_timeline', 'get_events' - hook to override events list which will be received from database

  • $unit_name - equals bx_timeline
  • $action - equals get_events
  • $object_id - not used
  • $sender_id - not used
  • $extra_params - array of additional params with the following array keys:
    • browse - [string] browsing type
    • params - [array] browse params array as key&value pairs
    • table - [string] datatbase table name
    • table_alias - [string] datatbase table alias
    • method - [string] by ref, database class method name,
      See also
      BxDolDb, can be overridden in hook processing
    • select_clause - [string] by ref, 'select' part of SQL query, can be overridden in hook processing
    • join_clause - [string] by ref, 'join' part of SQL query, can be overridden in hook processing
    • where_clause - [string] by ref, 'where' part of SQL query, can be overridden in hook processing
    • order_clause - [string] by ref, 'order' part of SQL query, can be overridden in hook processing
    • limit_clause - [string] by ref, 'limit' part of SQL query, can be overridden in hook processing
      HOOKS
      'bx_timeline', 'get_events' - hook to override events list which will be received from database

Reimplemented from BxBaseModNotificationsDb.

◆ getHotTrackByVotesSum()

BxTimelineDb::getHotTrackByVotesSum ( $sModule,
$sTableTrack,
$iInterval = 24 )

Hot Track by Sum of Votes during specified Period is currently disabled.

◆ getHotTrackByVotesSumModule()

BxTimelineDb::getHotTrackByVotesSumModule ( $sModule,
$sTableTrack,
$iInterval = 24 )

Hot Track by Sum of Votes during specified Period is currently disabled.

◆ insertEvent()

BxTimelineDb::insertEvent ( $aParamsSet)

TEMPORARY: to find the source of Duplicates.

Reimplemented from BxBaseModNotificationsDb.

◆ updateStatusAdmin()

BxTimelineDb::updateStatusAdmin ( $iContentId,
$isActive )

Reimplemented from BxBaseModGeneralDb.


The documentation for this class was generated from the following file: