Stud.IP  4.0
 All Data Structures Namespaces Files Functions Variables Groups
EvaluationObject Class Reference
Inheritance diagram for EvaluationObject:
StudipObject AuthorObject Evaluation EvaluationAnswer EvaluationGroup EvaluationQuestion

Public Member Functions

 __construct ($objectID="", $parentObject=NULL, $loadChildren=EVAL_LOAD_NO_CHILDREN)
 
 setTitle ($title)
 
 getTitle ()
 
 setText ($text)
 
 getText ()
 
 setPosition ($position)
 
 getPosition ()
 
 setParentObject (&$parentObject)
 
 getParentObject ()
 
 getParentID ()
 
 setParentID ($parentID)
 
 removeChildID ($childID)
 
 addChild (&$child)
 
getChild ($childID="")
 
getNextChild ()
 
 getChildren ()
 
 getNumberChildren ()
 
 save ()
 
 delete ()
 
duplicate ()
 
 duplicate_init ()
 
 init ($objectID="")
 
 load ()
 
 check ()
 
 getSpecialChildobjects (&$object, $instanceof, $reset=false)
 
 toString ()
 
- Public Member Functions inherited from StudipObject
 __construct ($objectID="")
 
 getObjectID ()
 
 setObjectID ($objectID)
 
 getAuthorID ()
 
 getAuthor ()
 
 getFullname ()
 
 setAuthorID ($authorID)
 
 getRangeID ()
 
 setRangeID ($rangeID)
 
- Public Member Functions inherited from AuthorObject
 __construct ()
 
 x_instanceof ()
 
 isError ()
 
 getErrors ()
 
 resetErrors ()
 
 throwError ($errcode, $errstring)
 
 throwErrorFromClass (AuthorObject $class)
 

Data Fields

 $parentObject
 
 $parentObjectID
 
 $childObjects
 
 $numberChildren
 
 $title
 
 $text
 
 $position
 
 $db
 
 $childNum
 
 $loadChildren
 
- Data Fields inherited from StudipObject
 $objectID
 
 $authorID
 
 $rangeID
 
- Data Fields inherited from AuthorObject
 $errorArray
 
 $instanceof
 

Additional Inherited Members

- Static Public Member Functions inherited from StudipObject
static createNewID ()
 

Constructor & Destructor Documentation

__construct (   $objectID = "",
  $parentObject = NULL,
  $loadChildren = EVAL_LOAD_NO_CHILDREN 
)

Constructor

Parameters
string$objectIDThe ID of an existing object
EvaluationObject$parentObjectThe parent object
integer$loadChildrenSee const EVAL_LOAD_*_CHILDREN public

Member Function Documentation

addChild ( $child)

Adds a child public

Parameters
objectEvaluationObject &$child The child object
check ( )

Checks if object is in a valid state private

delete ( )

Deletes the object from the database public

& duplicate ( )

Duplicates the evaluation object. WARNING: Stored childs will be modified :( public

duplicate_init ( )

Initialisation for duplicated objects private

& getChild (   $childID = "")

Gets the first child and removes it (if no id is given) public

Parameters
string$childIDThe child id
Returns
object The first object
getChildren ( )

Gets all the childs in the object public

Returns
array An array full of childObjects
& getNextChild ( )

Gets the next child public

Returns
object The next object, otherwise NULL
getNumberChildren ( )

Gets the number of children public

Returns
integer Number of children
getParentID ( )

Gets the parentObjectID public

Returns
string The parentObjectID
getParentObject ( )

Gets the parentObject public

Returns
object The parentObject.
getPosition ( )

Gets the position public

Returns
string The position
getSpecialChildobjects ( $object,
  $instanceof,
  $reset = false 
)

Gets all children of a special kind

Parameters
EvaluationObject&$objectthe parent object
string$instanceofinstance of the searched child
boolean$resetfor internal use public
getText ( )

Gets the text public

Returns
string The text
getTitle ( )

Gets the title public

Returns
string The title
init (   $objectID = "")

Initialisation for objects private

Parameters
string$objectIDThe object id
load ( )

Loads the Object from the database private

removeChildID (   $childID)

Removes a child from the object (not from the DB!) public

Parameters
string$childIDThe child id
save ( )

Saves the object into the database public

setParentID (   $parentID)

Sets the parentObjectID public

Parameters
string$parentIDThe parent id
setParentObject ( $parentObject)

Sets the parentObject public

Parameters
string&$parentObjectThe parentObject.
setPosition (   $position)

Sets the position public

Parameters
string$positionThe position.
setText (   $text)

Sets the text public

Parameters
string$textThe text.
Exceptions
error
setTitle (   $title)

Sets the title public

Parameters
string$titleThe title.
Exceptions
error
toString ( )

Debugfunction public

Field Documentation

integer $childNum

Is used as a counter for getNextChild ) private

array $childObjects

Array with all linked childobjects private

object DatabaseObject $db

Holds the DB object private

integer $loadChildren

Defines how many children to load. See EVAL_LOAD_*_CHILDREN private

integer $numberChildren

Counts the number of childs private

string $parentObject

The parent object private

$parentObjectID
integer $position

Position of this group in parent object private

integer $text

Text of the group private

integer $title

Title of the group private


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