Overview

Packages

  • ClipIt
    • clipit
      • api
    • urjc
      • backend
  • Elgg
    • Core
      • Access
      • Authentication
      • Cache
      • Caches
      • Core
      • DataMode
        • Site
      • DataModel
        • Annotations
        • Entities
        • Extender
        • File
        • Importable
        • Loggable
        • Notable
        • Object
        • User
      • DataStorage
      • Exception
      • Exceptions
        • Stub
      • FileStore
        • Disk
      • Groups
      • Helpers
      • HMAC
      • Memcache
      • Metadata
      • Navigation
      • ODD
      • Output
      • Plugins
        • Settings
      • Sessions
      • SocialModel
        • Friendable
        • Locatable
      • WebServicesAPI
      • Widgets
      • XML
      • XMLRPC
    • Exceptions
      • Stub
  • None
  • PHP

Classes

  • ElggAttributeLoader
  • ElggBatch
  • ElggData
  • Overview
  • Package
  • Class
  • Tree

Class ElggData

A generic class that contains shared code b/w ElggExtender, ElggEntity, and ElggRelationship

ElggData implements Loggable, Iterator, ArrayAccess, Exportable

Direct known subclasses

ElggEntity, ElggExtender, ElggRelationship

Indirect known subclasses

ElggAnnotation, ElggFile, ElggGroup, ElggMetadata, ElggObject, ElggPlugin, ElggSite, ElggUser, ElggWidget
Abstract
Package: Elgg\Core\DataModel
Located at ElggData.php
Methods summary
protected
# initializeAttributes( )

Initialize the attributes array.

Initialize the attributes array.

This is vital to distinguish between metadata and base parameters.

public mixed
# __get( string $name )

Return an attribute or a piece of metadata.

Return an attribute or a piece of metadata.

Parameters

$name
string
$name Name

Returns

mixed
public mixed
# __set( string $name, mixed $value )

Set an attribute or a piece of metadata.

Set an attribute or a piece of metadata.

Parameters

$name
string
$name Name
$value
mixed
$value Value

Returns

mixed
public boolean
# __isset( string $name )

Test if property is set either as an attribute or metadata.

Test if property is set either as an attribute or metadata.

Parameters

$name
string
$name The name of the attribute or metadata.

Returns

boolean

Tip

Use isset($entity->property)
abstract protected mixed
# get( string $name )

Fetch the specified attribute

Fetch the specified attribute

Parameters

$name
string
$name The attribute to fetch

Returns

mixed
The attribute, if it exists. Otherwise, null.
abstract protected boolean
# set( string $name, mixed $value )

Set the specified attribute

Set the specified attribute

Parameters

$name
string
$name The attribute to set
$value
mixed
$value The value to set it to

Returns

boolean
The success of your set function?
abstract public string
# getURL( )

Get a URL for this object

Get a URL for this object

Returns

string
abstract public boolean
# save( )

Save this data to the appropriate database table.

Save this data to the appropriate database table.

Returns

boolean
abstract public boolean
# delete( )

Delete this data.

Delete this data.

Returns

boolean
public integer
# getTimeCreated( )

Returns the UNIX epoch time that this entity was created

Returns the UNIX epoch time that this entity was created

Returns

integer
UNIX epoch time
public string
# getClassName( )

Return the class name of the object.

Return the class name of the object.

Returns

string

Implementation of

Loggable::getClassName()
public
# rewind( )

Iterator interface

Iterator interface

See

Iterator::rewind()

Implementation of

Iterator::rewind()
public mixed
# current( )

Iterator interface

Iterator interface

Returns

mixed

See

Iterator::current()

Implementation of

Iterator::current()
public string
# key( )

Iterator interface

Iterator interface

Returns

string

See

Iterator::key()

Implementation of

Iterator::key()
public
# next( )

Iterator interface

Iterator interface

See

Iterator::next()

Implementation of

Iterator::next()
public boolean
# valid( )

Iterator interface

Iterator interface

Returns

boolean

See

Iterator::valid()

Implementation of

Iterator::valid()
public
# offsetSet( mixed $key, mixed $value )

Array access interface

Array access interface

Parameters

$key
mixed
$key Name
$value
mixed
$value Value

See

ArrayAccess::offsetSet()

Implementation of

ArrayAccess::offsetSet()
public mixed
# offsetGet( mixed $key )

Array access interface

Array access interface

Parameters

$key
mixed
$key Name

Returns

mixed

See

ArrayAccess::offsetGet()

Implementation of

ArrayAccess::offsetGet()
public
# offsetUnset( mixed $key )

Array access interface

Array access interface

Parameters

$key
mixed
$key Name

See

ArrayAccess::offsetUnset()

Implementation of

ArrayAccess::offsetUnset()
public integer
# offsetExists( integer $offset )

Array access interface

Array access interface

Parameters

$offset
integer
$offset Offset

Returns

integer

See

ArrayAccess::offsetExists()

Implementation of

ArrayAccess::offsetExists()
Methods inherited from Loggable
getObjectFromID(), getSubtype(), getSystemLogID(), getType()
Methods inherited from Exportable
export(), getExportableValues()
Properties summary
protected array $attributes array()
#

The main attributes of an entity. Holds attributes to save to database This contains the site's main properties (id, etc) Blank entries for all database fields should be created by the constructor. Subclasses should add to this in their constructors. Any field not appearing in this will be viewed as a

The main attributes of an entity. Holds attributes to save to database This contains the site's main properties (id, etc) Blank entries for all database fields should be created by the constructor. Subclasses should add to this in their constructors. Any field not appearing in this will be viewed as a

protected boolean $valid FALSE
#
Magic properties summary
public integer $owner_guid
#
public integer $time_created
#
API documentation generated by ApiGen 2.8.0