Search moodle.org's
Developer Documentation

See Release Notes
Long Term Support Release

  • Bug fixes for general core bugs in 4.1.x will end 13 November 2023 (12 months).
  • Bug fixes for security issues in 4.1.x will end 10 November 2025 (36 months).
  • PHP version: minimum PHP 7.4.0 Note: minimum PHP version has increased since Moodle 4.0. PHP 8.0.x is supported too.

Differences Between: [Versions 311 and 401] [Versions 400 and 401]

LICENSE This file is part of CFPropertyList.

Author: Rodney Rehm <rodney.rehm@medialize.de>
Author: Christian Kruse <cjk@wwwtech.de>
Copyright: Copyright © 2018 Teclib
License: MIT
File Size: 234 lines (8 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

CFDictionary:: (14 methods):
  __construct()
  setValue()
  add()
  get()
  __get()
  del()
  toXML()
  toBinary()
  toArray()
  rewind()
  current()
  key()
  next()
  valid()


Class: CFDictionary  - X-Ref

Array Type of CFPropertyList

__construct($value = array()   X-Ref
Create new CFType.

param: array $value Value of CFType

setValue($value)   X-Ref
Set the CFType's value
<b>Note:</b> this dummy does nothing

return: void

add($key, CFType $value = null)   X-Ref
Add CFType to collection.

param: string $key Key to add to collection
param: CFType $value CFType to add to collection, defaults to null which results in an empty {@link CFString}
return: void

get($key)   X-Ref
Get CFType from collection.

param: string $key Key of CFType to retrieve from collection
return: CFType CFType found at $key, null else

__get($key)   X-Ref
Generic getter (magic)

param: integer $key Key of CFType to retrieve from collection
author: Sean Coates <sean@php.net>
return: CFType CFType found at $key, null else

del($key)   X-Ref
Remove CFType from collection.

param: string $key Key of CFType to removes from collection
return: CFType removed CFType, null else

toXML(DOMDocument $doc, $nodeName = "")   X-Ref
Get XML-Node.

param: DOMDocument $doc DOMDocument to create DOMNode in
param: string $nodeName For compatibility reasons; just ignore it
return: DOMNode &lt;dict&gt;-Element

toBinary(CFBinaryPropertyList &$bplist)   X-Ref
convert value to binary representation

param: CFBinaryPropertyList The binary property list object
return: The offset in the object table

toArray()   X-Ref
Get CFType's value.

return: array primitive value

rewind()   X-Ref
Rewind {@link $iteratorPosition} to first position (being 0)

return: void

current()   X-Ref
Get Iterator's current {@link CFType} identified by {@link $iteratorPosition}

return: mixed current Item

key()   X-Ref
Get Iterator's current key identified by {@link $iteratorPosition}

return: mixed key of the current Item

next()   X-Ref
Increment {@link $iteratorPosition} to address next {@see CFType}

return: void

valid()   X-Ref
Test if {@link $iteratorPosition} addresses a valid element of {@link $value}

return: bool true if current position is valid, false else