repository_name
stringlengths
5
67
func_path_in_repository
stringlengths
4
234
func_name
stringlengths
0
314
whole_func_string
stringlengths
52
3.87M
language
stringclasses
6 values
func_code_string
stringlengths
52
3.87M
func_code_tokens
listlengths
15
672k
func_documentation_string
stringlengths
1
47.2k
func_documentation_tokens
listlengths
1
3.92k
split_name
stringclasses
1 value
func_code_url
stringlengths
85
339
koala-framework/koala-framework
Kwf/Component/Events/ViewCache.php
Kwf_Component_Events_ViewCache.onPageChanged
public function onPageChanged(Kwf_Component_Event_Component_Abstract $event) { $this->_updates[] = array( 'type' => 'componentLink', 'component_id' => $event->component->componentId ); $this->_log("type=componentLink component_id={$event->component->componentId}"); ...
php
public function onPageChanged(Kwf_Component_Event_Component_Abstract $event) { $this->_updates[] = array( 'type' => 'componentLink', 'component_id' => $event->component->componentId ); $this->_log("type=componentLink component_id={$event->component->componentId}"); ...
[ "public", "function", "onPageChanged", "(", "Kwf_Component_Event_Component_Abstract", "$", "event", ")", "{", "$", "this", "->", "_updates", "[", "]", "=", "array", "(", "'type'", "=>", "'componentLink'", ",", "'component_id'", "=>", "$", "event", "->", "compone...
namechanged and filnamechanged-events
[ "namechanged", "and", "filnamechanged", "-", "events" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Events/ViewCache.php#L154-L161
koala-framework/koala-framework
Kwf/Model/Row/Abstract.php
Kwf_Model_Row_Abstract._isDirty
protected function _isDirty($column = null) { if ($column) { return array_key_exists($column, $this->_cleanData); } return !empty($this->_cleanData); }
php
protected function _isDirty($column = null) { if ($column) { return array_key_exists($column, $this->_cleanData); } return !empty($this->_cleanData); }
[ "protected", "function", "_isDirty", "(", "$", "column", "=", "null", ")", "{", "if", "(", "$", "column", ")", "{", "return", "array_key_exists", "(", "$", "column", ",", "$", "this", "->", "_cleanData", ")", ";", "}", "return", "!", "empty", "(", "$...
Ob die Row seblst dirty ist
[ "Ob", "die", "Row", "seblst", "dirty", "ist" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Model/Row/Abstract.php#L228-L234
koala-framework/koala-framework
Kwf/Model/Row/Abstract.php
Kwf_Model_Row_Abstract.isDirty
public final function isDirty($column = null) { if ($this->_isDirty($column)) return true; foreach ($this->_getSiblingRows() as $r) { if ($r->_isDirty($column)) return true; } if (!$column) { foreach ($this->_childRows as $rule=>$rows) { foreac...
php
public final function isDirty($column = null) { if ($this->_isDirty($column)) return true; foreach ($this->_getSiblingRows() as $r) { if ($r->_isDirty($column)) return true; } if (!$column) { foreach ($this->_childRows as $rule=>$rows) { foreac...
[ "public", "final", "function", "isDirty", "(", "$", "column", "=", "null", ")", "{", "if", "(", "$", "this", "->", "_isDirty", "(", "$", "column", ")", ")", "return", "true", ";", "foreach", "(", "$", "this", "->", "_getSiblingRows", "(", ")", "as", ...
Ob die Row oder eine sibling row dirty ist
[ "Ob", "die", "Row", "oder", "eine", "sibling", "row", "dirty", "ist" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Model/Row/Abstract.php#L239-L253
koala-framework/koala-framework
Kwf/Model/Row/Abstract.php
Kwf_Model_Row_Abstract.getDirtyColumns
public function getDirtyColumns() { $ret = array_keys($this->_cleanData); foreach ($this->_getSiblingRows() as $r) { $ret = array_merge($ret, $r->getDirtyColumns()); } return $ret; }
php
public function getDirtyColumns() { $ret = array_keys($this->_cleanData); foreach ($this->_getSiblingRows() as $r) { $ret = array_merge($ret, $r->getDirtyColumns()); } return $ret; }
[ "public", "function", "getDirtyColumns", "(", ")", "{", "$", "ret", "=", "array_keys", "(", "$", "this", "->", "_cleanData", ")", ";", "foreach", "(", "$", "this", "->", "_getSiblingRows", "(", ")", "as", "$", "r", ")", "{", "$", "ret", "=", "array_m...
dirty columns der row und der sibling rows
[ "dirty", "columns", "der", "row", "und", "der", "sibling", "rows" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Model/Row/Abstract.php#L258-L265
koala-framework/koala-framework
Kwf/Model/Row/Abstract.php
Kwf_Model_Row_Abstract.getCleanValue
public function getCleanValue($name) { if (array_key_exists($name, $this->_cleanData)) { return $this->_cleanData[$name]; } foreach ($this->_getSiblingRows() as $r) { if (array_key_exists($name, $r->_cleanData)) { return $r->_cleanData[$name]; ...
php
public function getCleanValue($name) { if (array_key_exists($name, $this->_cleanData)) { return $this->_cleanData[$name]; } foreach ($this->_getSiblingRows() as $r) { if (array_key_exists($name, $r->_cleanData)) { return $r->_cleanData[$name]; ...
[ "public", "function", "getCleanValue", "(", "$", "name", ")", "{", "if", "(", "array_key_exists", "(", "$", "name", ",", "$", "this", "->", "_cleanData", ")", ")", "{", "return", "$", "this", "->", "_cleanData", "[", "$", "name", "]", ";", "}", "fore...
Returns the original value of a column, like it exists in the data source. After save() it will return the new value.
[ "Returns", "the", "original", "value", "of", "a", "column", "like", "it", "exists", "in", "the", "data", "source", "." ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Model/Row/Abstract.php#L272-L283
koala-framework/koala-framework
Kwf/Model/Row/Abstract.php
Kwf_Model_Row_Abstract._saveWithoutResetDirty
protected function _saveWithoutResetDirty() { foreach ($this->_getSiblingRowsForSave() as $k=>$r) { if (!$r->getModel() instanceof Kwf_Model_SubModel_Interface) { $ref = $r->getModel()->getReferenceByModelClass(get_class($this->_model), $k); if (!$r->{$ref['column...
php
protected function _saveWithoutResetDirty() { foreach ($this->_getSiblingRowsForSave() as $k=>$r) { if (!$r->getModel() instanceof Kwf_Model_SubModel_Interface) { $ref = $r->getModel()->getReferenceByModelClass(get_class($this->_model), $k); if (!$r->{$ref['column...
[ "protected", "function", "_saveWithoutResetDirty", "(", ")", "{", "foreach", "(", "$", "this", "->", "_getSiblingRowsForSave", "(", ")", "as", "$", "k", "=>", "$", "r", ")", "{", "if", "(", "!", "$", "r", "->", "getModel", "(", ")", "instanceof", "Kwf_...
TODO: investigate if it would make sense to move _afterSave also out to have it consistent across proxies&siblings
[ "TODO", ":", "investigate", "if", "it", "would", "make", "sense", "to", "move", "_afterSave", "also", "out", "to", "have", "it", "consistent", "across", "proxies&siblings" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Model/Row/Abstract.php#L301-L331
koala-framework/koala-framework
Kwf/Model/Row/Abstract.php
Kwf_Model_Row_Abstract._toArrayWithoutPrimaryKeys
protected function _toArrayWithoutPrimaryKeys() { $ret = $this->toArray(); unset($ret[$this->getModel()->getPrimaryKey()]); foreach ($this->_getSiblingRows() as $r) { $primaryKey = $r->getModel()->getPrimaryKey(); if ($primaryKey) { unset($ret[$primary...
php
protected function _toArrayWithoutPrimaryKeys() { $ret = $this->toArray(); unset($ret[$this->getModel()->getPrimaryKey()]); foreach ($this->_getSiblingRows() as $r) { $primaryKey = $r->getModel()->getPrimaryKey(); if ($primaryKey) { unset($ret[$primary...
[ "protected", "function", "_toArrayWithoutPrimaryKeys", "(", ")", "{", "$", "ret", "=", "$", "this", "->", "toArray", "(", ")", ";", "unset", "(", "$", "ret", "[", "$", "this", "->", "getModel", "(", ")", "->", "getPrimaryKey", "(", ")", "]", ")", ";"...
ist momentan nur fürs duplicate.
[ "ist", "momentan", "nur", "fürs", "duplicate", "." ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Model/Row/Abstract.php#L637-L648
koala-framework/koala-framework
Kwf/Model/Row/Abstract.php
Kwf_Model_Row_Abstract.hasColumn
public function hasColumn($col) { if (!$this->getModel()->getOwnColumns()) return true; if (in_array($col, $this->getModel()->getOwnColumns())) return true; if (in_array($col, $this->getModel()->getExprColumns())) return true; foreach ($this->_getSiblingRows() as $r) { if...
php
public function hasColumn($col) { if (!$this->getModel()->getOwnColumns()) return true; if (in_array($col, $this->getModel()->getOwnColumns())) return true; if (in_array($col, $this->getModel()->getExprColumns())) return true; foreach ($this->_getSiblingRows() as $r) { if...
[ "public", "function", "hasColumn", "(", "$", "col", ")", "{", "if", "(", "!", "$", "this", "->", "getModel", "(", ")", "->", "getOwnColumns", "(", ")", ")", "return", "true", ";", "if", "(", "in_array", "(", "$", "col", ",", "$", "this", "->", "g...
kopiert von model, da in row _getSiblingRows überschrieben sein kann
[ "kopiert", "von", "model", "da", "in", "row", "_getSiblingRows", "überschrieben", "sein", "kann" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Model/Row/Abstract.php#L651-L660
koala-framework/koala-framework
Kwf/Model/Row/Abstract.php
Kwf_Model_Row_Abstract._duplicateDependentModel
protected final function _duplicateDependentModel($newRow, $rule, $select = array()) { $rowset = $this->getChildRows($rule, $select); foreach ($rowset as $row) { $ref = $row->getModel()->getReferenceByModelClass(get_class($this->getModel()), null); $data = array(); ...
php
protected final function _duplicateDependentModel($newRow, $rule, $select = array()) { $rowset = $this->getChildRows($rule, $select); foreach ($rowset as $row) { $ref = $row->getModel()->getReferenceByModelClass(get_class($this->getModel()), null); $data = array(); ...
[ "protected", "final", "function", "_duplicateDependentModel", "(", "$", "newRow", ",", "$", "rule", ",", "$", "select", "=", "array", "(", ")", ")", "{", "$", "rowset", "=", "$", "this", "->", "getChildRows", "(", "$", "rule", ",", "$", "select", ")", ...
Hilfsfunktion die von duplicate aufgerufen werden kann
[ "Hilfsfunktion", "die", "von", "duplicate", "aufgerufen", "werden", "kann" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Model/Row/Abstract.php#L665-L674
koala-framework/koala-framework
Kwf/Controller/Action/Spam/SetController.php
Kwf_Controller_Action_Spam_SetController.sendSpammedMail
public static function sendSpammedMail($id, $key, $tranport = null) { $row = Kwf_Model_Abstract::getInstance('Kwf_Model_Mail')->getRow($id); if (!$row) return false; if (Kwf_Util_Check_Spam::getSpamKey($row) != $key) { return false; } if (!$row->mail_sent) { ...
php
public static function sendSpammedMail($id, $key, $tranport = null) { $row = Kwf_Model_Abstract::getInstance('Kwf_Model_Mail')->getRow($id); if (!$row) return false; if (Kwf_Util_Check_Spam::getSpamKey($row) != $key) { return false; } if (!$row->mail_sent) { ...
[ "public", "static", "function", "sendSpammedMail", "(", "$", "id", ",", "$", "key", ",", "$", "tranport", "=", "null", ")", "{", "$", "row", "=", "Kwf_Model_Abstract", "::", "getInstance", "(", "'Kwf_Model_Mail'", ")", "->", "getRow", "(", "$", "id", ")"...
Public only for testing!!!
[ "Public", "only", "for", "testing!!!" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Controller/Action/Spam/SetController.php#L22-L37
koala-framework/koala-framework
Kwf/Controller/Router/Route/Chain.php
Kwf_Controller_Router_Route_Chain.match
public function match($request, $partial = null) { $path = trim($request->getPathInfo(), self::URI_DELIMITER); $subPath = $path; $values = array(); $numRoutes = count($this->_routes); $matchedPath = null; foreach ($this->_routes as $key => $route) {...
php
public function match($request, $partial = null) { $path = trim($request->getPathInfo(), self::URI_DELIMITER); $subPath = $path; $values = array(); $numRoutes = count($this->_routes); $matchedPath = null; foreach ($this->_routes as $key => $route) {...
[ "public", "function", "match", "(", "$", "request", ",", "$", "partial", "=", "null", ")", "{", "$", "path", "=", "trim", "(", "$", "request", "->", "getPathInfo", "(", ")", ",", "self", "::", "URI_DELIMITER", ")", ";", "$", "subPath", "=", "$", "p...
zend implementation overridden to avoid pathInfo getting modified even if route didn't match
[ "zend", "implementation", "overridden", "to", "avoid", "pathInfo", "getting", "modified", "even", "if", "route", "didn", "t", "match" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Controller/Router/Route/Chain.php#L5-L61
koala-framework/koala-framework
Kwc/Root/Category/Generator.php
Kwc_Root_Category_Generator.getRecursivePageChildIds
public function getRecursivePageChildIds($parentId) { $select = new Kwf_Model_Select(); $ret = $this->_getChildPageIds($parentId); foreach ($ret as $i) { $ret = array_merge($ret, $this->getRecursivePageChildIds($i)); } return $ret; }
php
public function getRecursivePageChildIds($parentId) { $select = new Kwf_Model_Select(); $ret = $this->_getChildPageIds($parentId); foreach ($ret as $i) { $ret = array_merge($ret, $this->getRecursivePageChildIds($i)); } return $ret; }
[ "public", "function", "getRecursivePageChildIds", "(", "$", "parentId", ")", "{", "$", "select", "=", "new", "Kwf_Model_Select", "(", ")", ";", "$", "ret", "=", "$", "this", "->", "_getChildPageIds", "(", "$", "parentId", ")", ";", "foreach", "(", "$", "...
Returns all recursive children of a page
[ "Returns", "all", "recursive", "children", "of", "a", "page" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwc/Root/Category/Generator.php#L92-L100
koala-framework/koala-framework
Kwf/Cache.php
Kwf_Cache.getInstance
public static function getInstance($type) { if (!isset(self::$_instances[$type])) { static $config; if (!isset($config)) $config = Kwf_Registry::get('config')->caches->toArray(); if (!isset($config[$type])) { throw new Kwf_Exception("unknown type '$type'")...
php
public static function getInstance($type) { if (!isset(self::$_instances[$type])) { static $config; if (!isset($config)) $config = Kwf_Registry::get('config')->caches->toArray(); if (!isset($config[$type])) { throw new Kwf_Exception("unknown type '$type'")...
[ "public", "static", "function", "getInstance", "(", "$", "type", ")", "{", "if", "(", "!", "isset", "(", "self", "::", "$", "_instances", "[", "$", "type", "]", ")", ")", "{", "static", "$", "config", ";", "if", "(", "!", "isset", "(", "$", "conf...
@param string entweder aus config (caches.type) @return Kwf_Cache_Core ähnlich wie Kwf_Model_Abstract::getInstance()
[ "@param", "string", "entweder", "aus", "config", "(", "caches", ".", "type", ")", "@return", "Kwf_Cache_Core" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Cache.php#L29-L41
koala-framework/koala-framework
Kwf/Form/Container/FieldSet.php
Kwf_Form_Container_FieldSet.setCheckboxName
public function setCheckboxName($name) { $this->_checkboxHiddenField = new Kwf_Form_Container_FieldSet_Hidden($name); $this->fields->add($this->_checkboxHiddenField); return $this; }
php
public function setCheckboxName($name) { $this->_checkboxHiddenField = new Kwf_Form_Container_FieldSet_Hidden($name); $this->fields->add($this->_checkboxHiddenField); return $this; }
[ "public", "function", "setCheckboxName", "(", "$", "name", ")", "{", "$", "this", "->", "_checkboxHiddenField", "=", "new", "Kwf_Form_Container_FieldSet_Hidden", "(", "$", "name", ")", ";", "$", "this", "->", "fields", "->", "add", "(", "$", "this", "->", ...
Zusammen mit setCheckboxToggle(true)
[ "Zusammen", "mit", "setCheckboxToggle", "(", "true", ")" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Form/Container/FieldSet.php#L28-L33
koala-framework/koala-framework
Kwf/Form/Container/FieldSet.php
Kwf_Form_Container_FieldSet._processChildren
protected function _processChildren($method, $childField, $row, $postData) { if ($method == 'load') return true; if ($this->_checkboxHiddenField && $childField !== $this->_checkboxHiddenField) { $n = $this->_checkboxHiddenField->getFieldName(); if (isset($postData[$n]) && $po...
php
protected function _processChildren($method, $childField, $row, $postData) { if ($method == 'load') return true; if ($this->_checkboxHiddenField && $childField !== $this->_checkboxHiddenField) { $n = $this->_checkboxHiddenField->getFieldName(); if (isset($postData[$n]) && $po...
[ "protected", "function", "_processChildren", "(", "$", "method", ",", "$", "childField", ",", "$", "row", ",", "$", "postData", ")", "{", "if", "(", "$", "method", "==", "'load'", ")", "return", "true", ";", "if", "(", "$", "this", "->", "_checkboxHidd...
verhindert aufrufen von validate/prepareSave/save etc fuer kinder wenn checkbox nicht gesetzt
[ "verhindert", "aufrufen", "von", "validate", "/", "prepareSave", "/", "save", "etc", "fuer", "kinder", "wenn", "checkbox", "nicht", "gesetzt" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Form/Container/FieldSet.php#L49-L61
koala-framework/koala-framework
Kwf/Component/Abstract/ExtConfig/Abstract.php
Kwf_Component_Abstract_ExtConfig_Abstract.getEditAfterCreateConfigKey
public function getEditAfterCreateConfigKey() { $keys = array_keys($this->getConfig(self::TYPE_DEFAULT)); if (!$keys) return null; return $keys[0]; }
php
public function getEditAfterCreateConfigKey() { $keys = array_keys($this->getConfig(self::TYPE_DEFAULT)); if (!$keys) return null; return $keys[0]; }
[ "public", "function", "getEditAfterCreateConfigKey", "(", ")", "{", "$", "keys", "=", "array_keys", "(", "$", "this", "->", "getConfig", "(", "self", "::", "TYPE_DEFAULT", ")", ")", ";", "if", "(", "!", "$", "keys", ")", "return", "null", ";", "return", ...
Welche config direkt nach dem anlegen dieser Komponente geöffnet werden soll. Fragt der Paragraphs Controller ab.
[ "Welche", "config", "direkt", "nach", "dem", "anlegen", "dieser", "Komponente", "geöffnet", "werden", "soll", "." ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Abstract/ExtConfig/Abstract.php#L66-L71
koala-framework/koala-framework
Kwf/Util/Geocode.php
Kwf_Util_Geocode.getCoordinates
public static function getCoordinates($address) { $config = Kwf_Registry::get('config'); $q = $address; $q = str_replace(array('ä','ö','ü','Ä','Ö','Ü','ß'), array('ae','oe','ue','Ae','Oe','Ue','ss'), $q); $getParams = array( 'address' => $q, 'sensor' => 'false...
php
public static function getCoordinates($address) { $config = Kwf_Registry::get('config'); $q = $address; $q = str_replace(array('ä','ö','ü','Ä','Ö','Ü','ß'), array('ae','oe','ue','Ae','Oe','Ue','ss'), $q); $getParams = array( 'address' => $q, 'sensor' => 'false...
[ "public", "static", "function", "getCoordinates", "(", "$", "address", ")", "{", "$", "config", "=", "Kwf_Registry", "::", "get", "(", "'config'", ")", ";", "$", "q", "=", "$", "address", ";", "$", "q", "=", "str_replace", "(", "array", "(", "'ä',", ...
Gibt die Geokoordinaten anhand einer Adresse zurück @param string $address Die Adresse die geocodet werden woll @return array|null $geocode Ein Array mit key 'lat' und 'lng'
[ "Gibt", "die", "Geokoordinaten", "anhand", "einer", "Adresse", "zurück" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Util/Geocode.php#L10-L53
koala-framework/koala-framework
Kwf/Controller/Action/Cli/Web/ComponentDeepCopyController.php
Kwf_Controller_Action_Cli_Web_ComponentDeepCopyController.cleanAction
public function cleanAction() { set_time_limit(0); if (!$this->_getParam('id')) throw new Kwf_Exception_Client("required parameter --id"); $db = Zend_Registry::get('db'); $tables = array(); foreach ($db->query("SHOW TABLES")->fetchAll() as $table) { $table = arra...
php
public function cleanAction() { set_time_limit(0); if (!$this->_getParam('id')) throw new Kwf_Exception_Client("required parameter --id"); $db = Zend_Registry::get('db'); $tables = array(); foreach ($db->query("SHOW TABLES")->fetchAll() as $table) { $table = arra...
[ "public", "function", "cleanAction", "(", ")", "{", "set_time_limit", "(", "0", ")", ";", "if", "(", "!", "$", "this", "->", "_getParam", "(", "'id'", ")", ")", "throw", "new", "Kwf_Exception_Client", "(", "\"required parameter --id\"", ")", ";", "$", "db"...
attention: components with dbIdShortcut are NOT handled correctly
[ "attention", ":", "components", "with", "dbIdShortcut", "are", "NOT", "handled", "correctly" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Controller/Action/Cli/Web/ComponentDeepCopyController.php#L80-L122
koala-framework/koala-framework
Kwf/Component/Cache/Mysql.php
Kwf_Component_Cache_Mysql.saveIncludes
public function saveIncludes($componentId, $type, $includedComponents) { $m = $this->getModel('includes'); $s = $m->select() ->whereEquals('component_id', $componentId) ->whereEquals('type', $type); $existingTargetIds = array(); foreach ($m->export(Kwf_Model_A...
php
public function saveIncludes($componentId, $type, $includedComponents) { $m = $this->getModel('includes'); $s = $m->select() ->whereEquals('component_id', $componentId) ->whereEquals('type', $type); $existingTargetIds = array(); foreach ($m->export(Kwf_Model_A...
[ "public", "function", "saveIncludes", "(", "$", "componentId", ",", "$", "type", ",", "$", "includedComponents", ")", "{", "$", "m", "=", "$", "this", "->", "getModel", "(", "'includes'", ")", ";", "$", "s", "=", "$", "m", "->", "select", "(", ")", ...
For unit testing - DO NOT DELETE!
[ "For", "unit", "testing", "-", "DO", "NOT", "DELETE!" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Cache/Mysql.php#L391-L434
koala-framework/koala-framework
Kwf/Config/Ini.php
Kwf_Config_Ini._loadIniFile
protected function _loadIniFile($filename) { if (version_compare(PHP_VERSION, '5.3.0') >= 0) { $loaded = parse_ini_file($filename, true, INI_SCANNER_RAW); // Warnings and errors are suppressed $this->_fixValues($loaded); } else { $loaded = parse_ini_file($filename...
php
protected function _loadIniFile($filename) { if (version_compare(PHP_VERSION, '5.3.0') >= 0) { $loaded = parse_ini_file($filename, true, INI_SCANNER_RAW); // Warnings and errors are suppressed $this->_fixValues($loaded); } else { $loaded = parse_ini_file($filename...
[ "protected", "function", "_loadIniFile", "(", "$", "filename", ")", "{", "if", "(", "version_compare", "(", "PHP_VERSION", ",", "'5.3.0'", ")", ">=", "0", ")", "{", "$", "loaded", "=", "parse_ini_file", "(", "$", "filename", ",", "true", ",", "INI_SCANNER_...
im neuen zend gibts _parseIniFile - nur das sollte ?berschrieben werden
[ "im", "neuen", "zend", "gibts", "_parseIniFile", "-", "nur", "das", "sollte", "?berschrieben", "werden" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Config/Ini.php#L18-L51
koala-framework/koala-framework
Kwc/User/Register/Form/FrontendForm.php
Kwc_User_Register_Form_FrontendForm._setHidden
private function _setHidden($f) { if ($f->getHideInRegister()) { $this->_setHidden2($f); } foreach ($f as $i) { if (is_object($i)) { $this->_setHidden($i); } } }
php
private function _setHidden($f) { if ($f->getHideInRegister()) { $this->_setHidden2($f); } foreach ($f as $i) { if (is_object($i)) { $this->_setHidden($i); } } }
[ "private", "function", "_setHidden", "(", "$", "f", ")", "{", "if", "(", "$", "f", "->", "getHideInRegister", "(", ")", ")", "{", "$", "this", "->", "_setHidden2", "(", "$", "f", ")", ";", "}", "foreach", "(", "$", "f", "as", "$", "i", ")", "{"...
TODO: sollte mit Kwf_Collection_Iterator_Recursive einfacher funktionieren
[ "TODO", ":", "sollte", "mit", "Kwf_Collection_Iterator_Recursive", "einfacher", "funktionieren" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwc/User/Register/Form/FrontendForm.php#L11-L21
koala-framework/koala-framework
Kwf/Component/Generator/Events/Table.php
Kwf_Component_Generator_Events_Table._getComponentsFromRow
protected function _getComponentsFromRow($row, $select) { $idColumn = $this->_getGenerator()->getIdColumn(); if ($this->_getGenerator()->hasSetting('dbIdShortcut') && $this->_getGenerator()->getSetting('dbIdShortcut')) { $dbId = $this->_getGenerator()->getSetting('dbIdShortcut') . ...
php
protected function _getComponentsFromRow($row, $select) { $idColumn = $this->_getGenerator()->getIdColumn(); if ($this->_getGenerator()->hasSetting('dbIdShortcut') && $this->_getGenerator()->getSetting('dbIdShortcut')) { $dbId = $this->_getGenerator()->getSetting('dbIdShortcut') . ...
[ "protected", "function", "_getComponentsFromRow", "(", "$", "row", ",", "$", "select", ")", "{", "$", "idColumn", "=", "$", "this", "->", "_getGenerator", "(", ")", "->", "getIdColumn", "(", ")", ";", "if", "(", "$", "this", "->", "_getGenerator", "(", ...
overrridden in Kwc_Root_Category_GeneratorEvents
[ "overrridden", "in", "Kwc_Root_Category_GeneratorEvents" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Generator/Events/Table.php#L123-L147
koala-framework/koala-framework
Kwf/Util/Symfony.php
Kwf_Util_Symfony.getKernel
public static function getKernel() { if (!isset(self::$_instance)) { if ($cls = Kwf_Config::getValue('symfony.kernelClass')) { if (!class_exists('Symfony\Component\HttpKernel\Kernel')) return null; self::$_instance = new $cls(); self::$_instance->...
php
public static function getKernel() { if (!isset(self::$_instance)) { if ($cls = Kwf_Config::getValue('symfony.kernelClass')) { if (!class_exists('Symfony\Component\HttpKernel\Kernel')) return null; self::$_instance = new $cls(); self::$_instance->...
[ "public", "static", "function", "getKernel", "(", ")", "{", "if", "(", "!", "isset", "(", "self", "::", "$", "_instance", ")", ")", "{", "if", "(", "$", "cls", "=", "Kwf_Config", "::", "getValue", "(", "'symfony.kernelClass'", ")", ")", "{", "if", "(...
Don't use this method in Symfony context @return Kwf_SymfonyKernel
[ "Don", "t", "use", "this", "method", "in", "Symfony", "context" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Util/Symfony.php#L11-L24
koala-framework/koala-framework
Kwf/Component/Data/Root.php
Kwf_Component_Data_Root.getInstance
public static function getInstance() { if (is_null(self::$_instance)) { $c = self::getComponentClass(); if ($c) { self::$_instance = new self(array('componentClass' => $c)); } else { self::$_instance = false; } } ...
php
public static function getInstance() { if (is_null(self::$_instance)) { $c = self::getComponentClass(); if ($c) { self::$_instance = new self(array('componentClass' => $c)); } else { self::$_instance = false; } } ...
[ "public", "static", "function", "getInstance", "(", ")", "{", "if", "(", "is_null", "(", "self", "::", "$", "_instance", ")", ")", "{", "$", "c", "=", "self", "::", "getComponentClass", "(", ")", ";", "if", "(", "$", "c", ")", "{", "self", "::", ...
Returns the root component data instance @return Kwf_Component_Data_Root
[ "Returns", "the", "root", "component", "data", "instance" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Data/Root.php#L49-L60
koala-framework/koala-framework
Kwf/Component/Data/Root.php
Kwf_Component_Data_Root.freeMemory
public function freeMemory() { $this->_freeMemory(); foreach ($this->_dataCache as $id=>$c) { if (isset($this->_dataCacheIgnoreVisible[$id])) { unset($this->_dataCacheIgnoreVisible[$id]); } $c->_freeMemory(); } foreach ($this->_data...
php
public function freeMemory() { $this->_freeMemory(); foreach ($this->_dataCache as $id=>$c) { if (isset($this->_dataCacheIgnoreVisible[$id])) { unset($this->_dataCacheIgnoreVisible[$id]); } $c->_freeMemory(); } foreach ($this->_data...
[ "public", "function", "freeMemory", "(", ")", "{", "$", "this", "->", "_freeMemory", "(", ")", ";", "foreach", "(", "$", "this", "->", "_dataCache", "as", "$", "id", "=>", "$", "c", ")", "{", "if", "(", "isset", "(", "$", "this", "->", "_dataCacheI...
Tries to clear all cached data objects and row objects Usful when processing lot of components to avoid memory issues
[ "Tries", "to", "clear", "all", "cached", "data", "objects", "and", "row", "objects" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Data/Root.php#L122-L143
koala-framework/koala-framework
Kwf/Component/Data/Root.php
Kwf_Component_Data_Root.getPageByUrl
public function getPageByUrl($url, $acceptLanguage, &$exactMatch = true) { $parsedUrl = parse_url($url); if (!isset($parsedUrl['path'])) return null; if (!isset($parsedUrl['host'])) { throw new Kwf_Exception("Host is missing in url '$url'"); } foreach ($this->getP...
php
public function getPageByUrl($url, $acceptLanguage, &$exactMatch = true) { $parsedUrl = parse_url($url); if (!isset($parsedUrl['path'])) return null; if (!isset($parsedUrl['host'])) { throw new Kwf_Exception("Host is missing in url '$url'"); } foreach ($this->getP...
[ "public", "function", "getPageByUrl", "(", "$", "url", ",", "$", "acceptLanguage", ",", "&", "$", "exactMatch", "=", "true", ")", "{", "$", "parsedUrl", "=", "parse_url", "(", "$", "url", ")", ";", "if", "(", "!", "isset", "(", "$", "parsedUrl", "[",...
/* @return Kwf_Component_Data
[ "/", "*" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Data/Root.php#L172-L212
koala-framework/koala-framework
Kwf/Component/Data/Root.php
Kwf_Component_Data_Root.getComponentById
public function getComponentById($componentId, $select = array()) { if (!$componentId) return null; if (is_array($select)) { $partTypes = array_keys($select); } else { $partTypes = $select->getPartTypes(); } if (!$partTypes || $partTypes == array(Kwf_...
php
public function getComponentById($componentId, $select = array()) { if (!$componentId) return null; if (is_array($select)) { $partTypes = array_keys($select); } else { $partTypes = $select->getPartTypes(); } if (!$partTypes || $partTypes == array(Kwf_...
[ "public", "function", "getComponentById", "(", "$", "componentId", ",", "$", "select", "=", "array", "(", ")", ")", "{", "if", "(", "!", "$", "componentId", ")", "return", "null", ";", "if", "(", "is_array", "(", "$", "select", ")", ")", "{", "$", ...
Returns a component data by it's componentId @param string componentId @param array|Kwf_Component_Select additional contraint @return Kwf_Component_Data
[ "Returns", "a", "component", "data", "by", "it", "s", "componentId" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Data/Root.php#L235-L335
koala-framework/koala-framework
Kwf/Component/Data/Root.php
Kwf_Component_Data_Root.getPageGenerators
public function getPageGenerators() { if (!is_null($this->_pageGenerators)) return $this->_pageGenerators; $cacheId = $this->componentClass . '_pageGenerators'; $generators = Kwf_Cache_SimpleStatic::fetch($cacheId); if (!$generators) { $generators = array(); ...
php
public function getPageGenerators() { if (!is_null($this->_pageGenerators)) return $this->_pageGenerators; $cacheId = $this->componentClass . '_pageGenerators'; $generators = Kwf_Cache_SimpleStatic::fetch($cacheId); if (!$generators) { $generators = array(); ...
[ "public", "function", "getPageGenerators", "(", ")", "{", "if", "(", "!", "is_null", "(", "$", "this", "->", "_pageGenerators", ")", ")", "return", "$", "this", "->", "_pageGenerators", ";", "$", "cacheId", "=", "$", "this", "->", "componentClass", ".", ...
Returns all Kwc_Root_Category_Generators used. the name of this method is a bit missleading @return Kwc_Root_Category_Generator[]
[ "Returns", "all", "Kwc_Root_Category_Generators", "used", "." ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Data/Root.php#L344-L373
koala-framework/koala-framework
Kwf/Component/Data/Root.php
Kwf_Component_Data_Root.getComponentByDbId
public function getComponentByDbId($dbId, $select = array()) { $components = $this->getComponentsByDbId($dbId, $select); $this->_checkSingleComponent($components); if (isset($components[0])) { return $components[0]; } return null; }
php
public function getComponentByDbId($dbId, $select = array()) { $components = $this->getComponentsByDbId($dbId, $select); $this->_checkSingleComponent($components); if (isset($components[0])) { return $components[0]; } return null; }
[ "public", "function", "getComponentByDbId", "(", "$", "dbId", ",", "$", "select", "=", "array", "(", ")", ")", "{", "$", "components", "=", "$", "this", "->", "getComponentsByDbId", "(", "$", "dbId", ",", "$", "select", ")", ";", "$", "this", "->", "...
Searches for a component data by it's dbId As multiple can have the same dbId you will get an exception if mutiple are found. To avoid that pass 'limit'=>1 as select @param string @param array|Kwf_Component_Select @return Kwf_Component_Data
[ "Searches", "for", "a", "component", "data", "by", "it", "s", "dbId" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Data/Root.php#L403-L411
koala-framework/koala-framework
Kwf/Component/Data/Root.php
Kwf_Component_Data_Root.getComponentsByDbId
public function getComponentsByDbId($dbId, $select = array()) { if (is_array($select)) { $select = new Kwf_Component_Select($select); } $cacheId = $dbId.$select->getHash(); if (!isset($this->_componentsByDbIdCache[$cacheId])) { if (is_numeric(substr($dbId, 0...
php
public function getComponentsByDbId($dbId, $select = array()) { if (is_array($select)) { $select = new Kwf_Component_Select($select); } $cacheId = $dbId.$select->getHash(); if (!isset($this->_componentsByDbIdCache[$cacheId])) { if (is_numeric(substr($dbId, 0...
[ "public", "function", "getComponentsByDbId", "(", "$", "dbId", ",", "$", "select", "=", "array", "(", ")", ")", "{", "if", "(", "is_array", "(", "$", "select", ")", ")", "{", "$", "select", "=", "new", "Kwf_Component_Select", "(", "$", "select", ")", ...
Searches for component datas by it's dbId @param string @param array|Kwf_Component_Select @return Kwf_Component_Data[]
[ "Searches", "for", "component", "datas", "by", "it", "s", "dbId" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Data/Root.php#L420-L481
koala-framework/koala-framework
Kwf/Component/Data/Root.php
Kwf_Component_Data_Root.getComponentsByClass
public function getComponentsByClass($class, $select = array()) { if (is_array($select)) { $select = new Kwf_Component_Select($select); } $cacheId = (is_array($class) ? implode(',', $class) : $class).$select->getHash(); if (!isset($this->_componentsByClassCache[$cacheId])...
php
public function getComponentsByClass($class, $select = array()) { if (is_array($select)) { $select = new Kwf_Component_Select($select); } $cacheId = (is_array($class) ? implode(',', $class) : $class).$select->getHash(); if (!isset($this->_componentsByClassCache[$cacheId])...
[ "public", "function", "getComponentsByClass", "(", "$", "class", ",", "$", "select", "=", "array", "(", ")", ")", "{", "if", "(", "is_array", "(", "$", "select", ")", ")", "{", "$", "select", "=", "new", "Kwf_Component_Select", "(", "$", "select", ")",...
Returns all components matching a component class (including classes inheriting that class) Use with care, this is only efficient if a few components exist. @see getComponentsBySameClass @param string|array component class @param array|Kwf_Component_Select @return Kwf_Component_Data[]
[ "Returns", "all", "components", "matching", "a", "component", "class", "(", "including", "classes", "inheriting", "that", "class", ")" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Data/Root.php#L493-L507
koala-framework/koala-framework
Kwf/Component/Data/Root.php
Kwf_Component_Data_Root.getComponentsBySameClass
public function getComponentsBySameClass($lookingForChildClasses, $select = array()) { $ret = array(); if (!is_array($lookingForChildClasses)) { $lookingForChildClasses = array($lookingForChildClasses); } foreach ($lookingForChildClasses as $c) { if ($c == $t...
php
public function getComponentsBySameClass($lookingForChildClasses, $select = array()) { $ret = array(); if (!is_array($lookingForChildClasses)) { $lookingForChildClasses = array($lookingForChildClasses); } foreach ($lookingForChildClasses as $c) { if ($c == $t...
[ "public", "function", "getComponentsBySameClass", "(", "$", "lookingForChildClasses", ",", "$", "select", "=", "array", "(", ")", ")", "{", "$", "ret", "=", "array", "(", ")", ";", "if", "(", "!", "is_array", "(", "$", "lookingForChildClasses", ")", ")", ...
Returns all components exactly matching a component class Use with care, this is only efficient if a few components exist. @see getComponentsByClass @param string|array component class @param array|Kwf_Component_Select @return Kwf_Component_Data[]
[ "Returns", "all", "components", "exactly", "matching", "a", "component", "class" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Data/Root.php#L519-L555
koala-framework/koala-framework
Kwf/Component/Data/Root.php
Kwf_Component_Data_Root.getComponentByClass
public function getComponentByClass($class, $select = array()) { $components = $this->getComponentsByClass($class, $select); $this->_checkSingleComponent($components); if (isset($components[0])) { return $components[0]; } return null; }
php
public function getComponentByClass($class, $select = array()) { $components = $this->getComponentsByClass($class, $select); $this->_checkSingleComponent($components); if (isset($components[0])) { return $components[0]; } return null; }
[ "public", "function", "getComponentByClass", "(", "$", "class", ",", "$", "select", "=", "array", "(", ")", ")", "{", "$", "components", "=", "$", "this", "->", "getComponentsByClass", "(", "$", "class", ",", "$", "select", ")", ";", "$", "this", "->",...
Returns component by given component class If multiple are found you will get an exception, To avoid that pass 'limit'=>1 as select @see getComponentsByClass @param string component class @param array|Kwf_Component_Select @return Kwf_Component_Data
[ "Returns", "component", "by", "given", "component", "class" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Data/Root.php#L601-L609
koala-framework/koala-framework
Kwf/Component/Data/Root.php
Kwf_Component_Data_Root.getComponentBySameClass
public function getComponentBySameClass($class, $select = array()) { $components = $this->getComponentsBySameClass($class, $select); $this->_checkSingleComponent($components); if (isset($components[0])) { return $components[0]; } return null; }
php
public function getComponentBySameClass($class, $select = array()) { $components = $this->getComponentsBySameClass($class, $select); $this->_checkSingleComponent($components); if (isset($components[0])) { return $components[0]; } return null; }
[ "public", "function", "getComponentBySameClass", "(", "$", "class", ",", "$", "select", "=", "array", "(", ")", ")", "{", "$", "components", "=", "$", "this", "->", "getComponentsBySameClass", "(", "$", "class", ",", "$", "select", ")", ";", "$", "this",...
Returns component by given component class If multiple are found you will get an exception, To avoid that pass 'limit'=>1 as select @see getComponentsBySameClass @param string component class @param array|Kwf_Component_Select @return Kwf_Component_Data
[ "Returns", "component", "by", "given", "component", "class" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Data/Root.php#L622-L630
koala-framework/koala-framework
Kwf/Component/Data/Root.php
Kwf_Component_Data_Root.addToDataCache
public function addToDataCache(Kwf_Component_Data $d, $ignoreVisible) { if ($ignoreVisible) { $this->_dataCacheIgnoreVisible[$d->componentId] = $d; } else { $this->_dataCache[$d->componentId] = $d; } }
php
public function addToDataCache(Kwf_Component_Data $d, $ignoreVisible) { if ($ignoreVisible) { $this->_dataCacheIgnoreVisible[$d->componentId] = $d; } else { $this->_dataCache[$d->componentId] = $d; } }
[ "public", "function", "addToDataCache", "(", "Kwf_Component_Data", "$", "d", ",", "$", "ignoreVisible", ")", "{", "if", "(", "$", "ignoreVisible", ")", "{", "$", "this", "->", "_dataCacheIgnoreVisible", "[", "$", "d", "->", "componentId", "]", "=", "$", "d...
@internal siehe Kwf_Component_Generator_Abstract für getComponentById
[ "@internal", "siehe", "Kwf_Component_Generator_Abstract" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Data/Root.php#L677-L684
koala-framework/koala-framework
Kwf/Component/Data/Root.php
Kwf_Component_Data_Root.getFromDataCache
public function getFromDataCache($id) { if (isset($this->_dataCache[$id])) { return $this->_dataCache[$id]; } else if (isset($this->_dataCacheIgnoreVisible[$id])) { return $this->_dataCacheIgnoreVisible[$id]; } return null; }
php
public function getFromDataCache($id) { if (isset($this->_dataCache[$id])) { return $this->_dataCache[$id]; } else if (isset($this->_dataCacheIgnoreVisible[$id])) { return $this->_dataCacheIgnoreVisible[$id]; } return null; }
[ "public", "function", "getFromDataCache", "(", "$", "id", ")", "{", "if", "(", "isset", "(", "$", "this", "->", "_dataCache", "[", "$", "id", "]", ")", ")", "{", "return", "$", "this", "->", "_dataCache", "[", "$", "id", "]", ";", "}", "else", "i...
@internal siehe Kwf_Component_Generator_Abstract für Component_Data::kwfUnserialize
[ "@internal", "siehe", "Kwf_Component_Generator_Abstract" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Data/Root.php#L691-L699
koala-framework/koala-framework
Kwf/Component/PagesMetaModel.php
Kwf_Component_PagesMetaModel.indexRecursive
public function indexRecursive(Kwf_Component_Data $page) { if ($page->isPage) { $r = $this->getRow($page->componentId); if (!$r) { $r = $this->createRow(); $r->changed_date = date('Y-m-d H:i:s'); } $r->updateFromPage($page); ...
php
public function indexRecursive(Kwf_Component_Data $page) { if ($page->isPage) { $r = $this->getRow($page->componentId); if (!$r) { $r = $this->createRow(); $r->changed_date = date('Y-m-d H:i:s'); } $r->updateFromPage($page); ...
[ "public", "function", "indexRecursive", "(", "Kwf_Component_Data", "$", "page", ")", "{", "if", "(", "$", "page", "->", "isPage", ")", "{", "$", "r", "=", "$", "this", "->", "getRow", "(", "$", "page", "->", "componentId", ")", ";", "if", "(", "!", ...
in web ComponentPagesMetaController is used
[ "in", "web", "ComponentPagesMetaController", "is", "used" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/PagesMetaModel.php#L34-L58
koala-framework/koala-framework
Kwf/Form/Field/Select.php
Kwf_Form_Field_Select._addValidators
protected function _addValidators() { parent::_addValidators(); //if hideIfNoValues and there are no values remove empty validator if ($this->getHideIfNoValues() && isset($this->_validators['notEmpty'])) { $store = $this->_getStoreData(); if (!$store['data']) { ...
php
protected function _addValidators() { parent::_addValidators(); //if hideIfNoValues and there are no values remove empty validator if ($this->getHideIfNoValues() && isset($this->_validators['notEmpty'])) { $store = $this->_getStoreData(); if (!$store['data']) { ...
[ "protected", "function", "_addValidators", "(", ")", "{", "parent", "::", "_addValidators", "(", ")", ";", "//if hideIfNoValues and there are no values remove empty validator", "if", "(", "$", "this", "->", "getHideIfNoValues", "(", ")", "&&", "isset", "(", "$", "th...
setHideIfNoValues
[ "setHideIfNoValues" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Form/Field/Select.php#L21-L32
koala-framework/koala-framework
Kwf/Db/Table/Row.php
Kwf_Db_Table_Row.delete
public function delete() { $where = $this->_getWhereQuery(); /** * Execute the DELETE (this may throw an exception) */ $result = $this->_getTable()->delete($where); /** * Reset all fields to null to indicate that the row is not there */ $...
php
public function delete() { $where = $this->_getWhereQuery(); /** * Execute the DELETE (this may throw an exception) */ $result = $this->_getTable()->delete($where); /** * Reset all fields to null to indicate that the row is not there */ $...
[ "public", "function", "delete", "(", ")", "{", "$", "where", "=", "$", "this", "->", "_getWhereQuery", "(", ")", ";", "/**\n * Execute the DELETE (this may throw an exception)\n */", "$", "result", "=", "$", "this", "->", "_getTable", "(", ")", "->...
Deletes existing rows. @return int The number of rows deleted.
[ "Deletes", "existing", "rows", "." ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Db/Table/Row.php#L331-L349
koala-framework/koala-framework
Kwf/Db/Table/Row.php
Kwf_Db_Table_Row._getPrimaryKeyValues
protected function _getPrimaryKeyValues($useDirty = true) { $primary = array_flip($this->_table->getPrimaryKey()); if ($useDirty) { $array = array_intersect_key($this->_data, $primary); } else { $array = array_intersect_key($this->_cleanData, $primary); } ...
php
protected function _getPrimaryKeyValues($useDirty = true) { $primary = array_flip($this->_table->getPrimaryKey()); if ($useDirty) { $array = array_intersect_key($this->_data, $primary); } else { $array = array_intersect_key($this->_cleanData, $primary); } ...
[ "protected", "function", "_getPrimaryKeyValues", "(", "$", "useDirty", "=", "true", ")", "{", "$", "primary", "=", "array_flip", "(", "$", "this", "->", "_table", "->", "getPrimaryKey", "(", ")", ")", ";", "if", "(", "$", "useDirty", ")", "{", "$", "ar...
Retrieves an associative array of primary keys. @param bool $useDirty @return array
[ "Retrieves", "an", "associative", "array", "of", "primary", "keys", "." ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Db/Table/Row.php#L387-L399
koala-framework/koala-framework
Kwf/Db/Table/Row.php
Kwf_Db_Table_Row._getWhereQuery
protected function _getWhereQuery($useDirty = true) { $where = array(); $db = $this->_getTable()->getAdapter(); $primaryKey = $this->_getPrimaryKeyValues($useDirty); $info = $this->_getTable()->info(); $metadata = $info[Kwf_Db_Table::METADATA]; // retrieve recently u...
php
protected function _getWhereQuery($useDirty = true) { $where = array(); $db = $this->_getTable()->getAdapter(); $primaryKey = $this->_getPrimaryKeyValues($useDirty); $info = $this->_getTable()->info(); $metadata = $info[Kwf_Db_Table::METADATA]; // retrieve recently u...
[ "protected", "function", "_getWhereQuery", "(", "$", "useDirty", "=", "true", ")", "{", "$", "where", "=", "array", "(", ")", ";", "$", "db", "=", "$", "this", "->", "_getTable", "(", ")", "->", "getAdapter", "(", ")", ";", "$", "primaryKey", "=", ...
Constructs where statement for retrieving row(s). @param bool $useDirty @return array
[ "Constructs", "where", "statement", "for", "retrieving", "row", "(", "s", ")", "." ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Db/Table/Row.php#L407-L424
koala-framework/koala-framework
Kwf/Util/Fulltext/Lucene.php
Kwf_Util_Fulltext_Lucene.getInstance
public static function getInstance(Kwf_Component_Data $subroot) { while ($subroot) { if (Kwc_Abstract::getFlag($subroot->componentClass, 'subroot')) { break; } $subroot = $subroot->parent; } if (!$subroot) $subroot = Kwf_Component_Data_Root...
php
public static function getInstance(Kwf_Component_Data $subroot) { while ($subroot) { if (Kwc_Abstract::getFlag($subroot->componentClass, 'subroot')) { break; } $subroot = $subroot->parent; } if (!$subroot) $subroot = Kwf_Component_Data_Root...
[ "public", "static", "function", "getInstance", "(", "Kwf_Component_Data", "$", "subroot", ")", "{", "while", "(", "$", "subroot", ")", "{", "if", "(", "Kwc_Abstract", "::", "getFlag", "(", "$", "subroot", "->", "componentClass", ",", "'subroot'", ")", ")", ...
Returns Zend_Search_Lucene instance for given subroot every subroot has it's own instance @param Kwf_Component_Data for this index @return Zend_Search_Lucene_Interface
[ "Returns", "Zend_Search_Lucene", "instance", "for", "given", "subroot" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Util/Fulltext/Lucene.php#L12-L40
koala-framework/koala-framework
Kwf/Component/Generator/Abstract.php
Kwf_Component_Generator_Abstract.select
final public function select($parentData, array $select = array()) { $select = new Kwf_Component_Select($select); $select->whereGenerator($this->_settings['generator']); return $select; }
php
final public function select($parentData, array $select = array()) { $select = new Kwf_Component_Select($select); $select->whereGenerator($this->_settings['generator']); return $select; }
[ "final", "public", "function", "select", "(", "$", "parentData", ",", "array", "$", "select", "=", "array", "(", ")", ")", "{", "$", "select", "=", "new", "Kwf_Component_Select", "(", "$", "select", ")", ";", "$", "select", "->", "whereGenerator", "(", ...
wennn man das select anpassen will _formatSelect überschreiben
[ "wennn", "man", "das", "select", "anpassen", "will", "_formatSelect", "überschreiben" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Generator/Abstract.php#L577-L582
koala-framework/koala-framework
Kwf/Component/Generator/Abstract.php
Kwf_Component_Generator_Abstract._getPossibleIndirectDbIdShortcuts
protected function _getPossibleIndirectDbIdShortcuts($class) { $cacheId = '-poss-dbid-sc-'.$this->_class.'-'.$this->getGeneratorKey().'-'.$class; $ret = Kwf_Cache_SimpleStatic::fetch($cacheId, $success); if (!$success) { $ret = $this->_getPossibleIndirectDbIdShortcutsImpl($class)...
php
protected function _getPossibleIndirectDbIdShortcuts($class) { $cacheId = '-poss-dbid-sc-'.$this->_class.'-'.$this->getGeneratorKey().'-'.$class; $ret = Kwf_Cache_SimpleStatic::fetch($cacheId, $success); if (!$success) { $ret = $this->_getPossibleIndirectDbIdShortcutsImpl($class)...
[ "protected", "function", "_getPossibleIndirectDbIdShortcuts", "(", "$", "class", ")", "{", "$", "cacheId", "=", "'-poss-dbid-sc-'", ".", "$", "this", "->", "_class", ".", "'-'", ".", "$", "this", "->", "getGeneratorKey", "(", ")", ".", "'-'", ".", "$", "cl...
Helper function that returns the dbIdShortcuts that can be used below a componentClass (only across page) Static, fast and cached.
[ "Helper", "function", "that", "returns", "the", "dbIdShortcuts", "that", "can", "be", "used", "below", "a", "componentClass", "(", "only", "across", "page", ")" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Generator/Abstract.php#L944-L954
koala-framework/koala-framework
Kwc/Abstract/List/FormWithEditButton.php
Kwc_Abstract_List_FormWithEditButton._getMultiFieldsFieldset
protected function _getMultiFieldsFieldset() { $fs = new Kwf_Form_Container_FieldSet(trlKwf('Paragraph {0}')); $fs->add(new Kwf_Form_Field_Checkbox('visible', trlKwf('Visible'))); $fs->add(new Kwf_Form_Field_SimpleAbstract('edit')) ->setXtype('kwc.listeditbutton') ->s...
php
protected function _getMultiFieldsFieldset() { $fs = new Kwf_Form_Container_FieldSet(trlKwf('Paragraph {0}')); $fs->add(new Kwf_Form_Field_Checkbox('visible', trlKwf('Visible'))); $fs->add(new Kwf_Form_Field_SimpleAbstract('edit')) ->setXtype('kwc.listeditbutton') ->s...
[ "protected", "function", "_getMultiFieldsFieldset", "(", ")", "{", "$", "fs", "=", "new", "Kwf_Form_Container_FieldSet", "(", "trlKwf", "(", "'Paragraph {0}'", ")", ")", ";", "$", "fs", "->", "add", "(", "new", "Kwf_Form_Field_Checkbox", "(", "'visible'", ",", ...
MultiFields content fields. @return array $fields The fields that should be inserted.
[ "MultiFields", "content", "fields", "." ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwc/Abstract/List/FormWithEditButton.php#L27-L36
koala-framework/koala-framework
Kwf/Mail/Template.php
Kwf_Mail_Template.getMailContent
public function getMailContent($type = Kwf_Model_Mail_Row::MAIL_CONTENT_AUTO) { if ($type == Kwf_Model_Mail_Row::MAIL_CONTENT_AUTO) { $ret = $this->_getHtmlMailContent(); if (is_null($ret)) $ret = $this->_getTextMailContent(); return $ret; } else if ($type == Kwf_...
php
public function getMailContent($type = Kwf_Model_Mail_Row::MAIL_CONTENT_AUTO) { if ($type == Kwf_Model_Mail_Row::MAIL_CONTENT_AUTO) { $ret = $this->_getHtmlMailContent(); if (is_null($ret)) $ret = $this->_getTextMailContent(); return $ret; } else if ($type == Kwf_...
[ "public", "function", "getMailContent", "(", "$", "type", "=", "Kwf_Model_Mail_Row", "::", "MAIL_CONTENT_AUTO", ")", "{", "if", "(", "$", "type", "==", "Kwf_Model_Mail_Row", "::", "MAIL_CONTENT_AUTO", ")", "{", "$", "ret", "=", "$", "this", "->", "_getHtmlMail...
constants for type defined in Kwf_Model_Mail_Row
[ "constants", "for", "type", "defined", "in", "Kwf_Model_Mail_Row" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Mail/Template.php#L162-L175
koala-framework/koala-framework
Kwc/Mail/Recipient/Placeholders.php
Kwc_Mail_Recipient_Placeholders.getPlaceholders
public static function getPlaceholders(Kwc_Mail_Recipient_Interface $recipient, $language) { $ret = array(); $trl = Kwf_Trl::getInstance(); $ret['firstname'] = $recipient->getMailFirstname(); $ret['lastname'] = $recipient->getMailLastname(); if ($recipient instanceof Kwc_Mail...
php
public static function getPlaceholders(Kwc_Mail_Recipient_Interface $recipient, $language) { $ret = array(); $trl = Kwf_Trl::getInstance(); $ret['firstname'] = $recipient->getMailFirstname(); $ret['lastname'] = $recipient->getMailLastname(); if ($recipient instanceof Kwc_Mail...
[ "public", "static", "function", "getPlaceholders", "(", "Kwc_Mail_Recipient_Interface", "$", "recipient", ",", "$", "language", ")", "{", "$", "ret", "=", "array", "(", ")", ";", "$", "trl", "=", "Kwf_Trl", "::", "getInstance", "(", ")", ";", "$", "ret", ...
/* Returns Placeholders with different salutations $recipient contains recipient row $language contains in which lanuage the Placeholders should be translated
[ "/", "*", "Returns", "Placeholders", "with", "different", "salutations" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwc/Mail/Recipient/Placeholders.php#L10-L71
koala-framework/koala-framework
Kwc/Menu/Events.php
Kwc_Menu_Events._initSettings
protected function _initSettings() { parent::_initSettings(); $this->_emptyIfSingleEntry = $menuLevel = Kwc_Abstract::getSetting($this->_class, 'emptyIfSingleEntry'); }
php
protected function _initSettings() { parent::_initSettings(); $this->_emptyIfSingleEntry = $menuLevel = Kwc_Abstract::getSetting($this->_class, 'emptyIfSingleEntry'); }
[ "protected", "function", "_initSettings", "(", ")", "{", "parent", "::", "_initSettings", "(", ")", ";", "$", "this", "->", "_emptyIfSingleEntry", "=", "$", "menuLevel", "=", "Kwc_Abstract", "::", "getSetting", "(", "$", "this", "->", "_class", ",", "'emptyI...
overwritten in Kwc_Menu_Trl_Events
[ "overwritten", "in", "Kwc_Menu_Trl_Events" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwc/Menu/Events.php#L7-L11
koala-framework/koala-framework
Kwc/Menu/Events.php
Kwc_Menu_Events._onMenuChanged
protected function _onMenuChanged(Kwf_Events_Event_Abstract $event, Kwf_Component_Data $menu) { parent::_onMenuChanged($event, $menu); $newCount = count($menu->getComponent()->getMenuData()); if ($event instanceof Kwf_Component_Event_Page_Removed && $event->flag == Kwf_Component_Event_Page_...
php
protected function _onMenuChanged(Kwf_Events_Event_Abstract $event, Kwf_Component_Data $menu) { parent::_onMenuChanged($event, $menu); $newCount = count($menu->getComponent()->getMenuData()); if ($event instanceof Kwf_Component_Event_Page_Removed && $event->flag == Kwf_Component_Event_Page_...
[ "protected", "function", "_onMenuChanged", "(", "Kwf_Events_Event_Abstract", "$", "event", ",", "Kwf_Component_Data", "$", "menu", ")", "{", "parent", "::", "_onMenuChanged", "(", "$", "event", ",", "$", "menu", ")", ";", "$", "newCount", "=", "count", "(", ...
fire HasContentChanged here because hasContent is implemented in this component
[ "fire", "HasContentChanged", "here", "because", "hasContent", "is", "implemented", "in", "this", "component" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwc/Menu/Events.php#L14-L39
koala-framework/koala-framework
Kwf/Component/Generator/Model.php
Kwf_Component_Generator_Model.output
public static function output() { $componentClass = Kwf_Component_Data_Root::getComponentClass(); $model = new self(); $maxComponentLength = self::_maxComponentLength($componentClass, $model); self::_output(null, $model, $maxComponentLength); }
php
public static function output() { $componentClass = Kwf_Component_Data_Root::getComponentClass(); $model = new self(); $maxComponentLength = self::_maxComponentLength($componentClass, $model); self::_output(null, $model, $maxComponentLength); }
[ "public", "static", "function", "output", "(", ")", "{", "$", "componentClass", "=", "Kwf_Component_Data_Root", "::", "getComponentClass", "(", ")", ";", "$", "model", "=", "new", "self", "(", ")", ";", "$", "maxComponentLength", "=", "self", "::", "_maxComp...
Gibt den Komponenten-Baum aus (für CLI)
[ "Gibt", "den", "Komponenten", "-", "Baum", "aus", "(", "für", "CLI", ")" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Generator/Model.php#L64-L72
koala-framework/koala-framework
Kwf/Component/Generator/Model.php
Kwf_Component_Generator_Model._output
private static function _output($componentClass, $model, $maxComponentLength) { static $stack = array(); array_push($stack, $componentClass); $rows = $model->fetchAll(array('parent' => $componentClass)); foreach ($rows as $row) { echo str_repeat(' ', count($stack)*2).$row...
php
private static function _output($componentClass, $model, $maxComponentLength) { static $stack = array(); array_push($stack, $componentClass); $rows = $model->fetchAll(array('parent' => $componentClass)); foreach ($rows as $row) { echo str_repeat(' ', count($stack)*2).$row...
[ "private", "static", "function", "_output", "(", "$", "componentClass", ",", "$", "model", ",", "$", "maxComponentLength", ")", "{", "static", "$", "stack", "=", "array", "(", ")", ";", "array_push", "(", "$", "stack", ",", "$", "componentClass", ")", ";...
Gibt den Komponenten-Baum aus (für CLI)
[ "Gibt", "den", "Komponenten", "-", "Baum", "aus", "(", "für", "CLI", ")" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Generator/Model.php#L76-L93
koala-framework/koala-framework
Kwf/Component/Acl.php
Kwf_Component_Acl._isAllowedComponentClass
private function _isAllowedComponentClass($userRow, $componentClass) { if ($this->_isAllowedComponentClassByRole($this->_getRole($userRow), $componentClass)) { return true; } foreach ($this->_getAdditionalRoles($userRow) as $role) { if ($this->_isAllowedComponentClass...
php
private function _isAllowedComponentClass($userRow, $componentClass) { if ($this->_isAllowedComponentClassByRole($this->_getRole($userRow), $componentClass)) { return true; } foreach ($this->_getAdditionalRoles($userRow) as $role) { if ($this->_isAllowedComponentClass...
[ "private", "function", "_isAllowedComponentClass", "(", "$", "userRow", ",", "$", "componentClass", ")", "{", "if", "(", "$", "this", "->", "_isAllowedComponentClassByRole", "(", "$", "this", "->", "_getRole", "(", "$", "userRow", ")", ",", "$", "componentClas...
darum erstmal private gemacht
[ "darum", "erstmal", "private", "gemacht" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Acl.php#L75-L86
koala-framework/koala-framework
Kwf/Component/Acl.php
Kwf_Component_Acl.getAllowedRecursiveChildComponents
public function getAllowedRecursiveChildComponents($userRow) { $cacheId = is_object($userRow) ? $userRow->id : $userRow; if (!isset($this->_allowedRecursiveChildComponentsCache[$cacheId])) { $allowedComponentClasses = $this->_getAllowedComponentClasses($userRow); $ret = array...
php
public function getAllowedRecursiveChildComponents($userRow) { $cacheId = is_object($userRow) ? $userRow->id : $userRow; if (!isset($this->_allowedRecursiveChildComponentsCache[$cacheId])) { $allowedComponentClasses = $this->_getAllowedComponentClasses($userRow); $ret = array...
[ "public", "function", "getAllowedRecursiveChildComponents", "(", "$", "userRow", ")", "{", "$", "cacheId", "=", "is_object", "(", "$", "userRow", ")", "?", "$", "userRow", "->", "id", ":", "$", "userRow", ";", "if", "(", "!", "isset", "(", "$", "this", ...
Gibt alle Komponenten zurück die im Seitenbaum bearbeitet werden dürfen alles was unter einer seite liegt die im seitenbaum angezeigt wird Langsam
[ "Gibt", "alle", "Komponenten", "zurück", "die", "im", "Seitenbaum", "bearbeitet", "werden", "dürfen" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Acl.php#L195-L214
koala-framework/koala-framework
Kwf/Component/Acl.php
Kwf_Component_Acl.getAllowedChildComponents
public function getAllowedChildComponents($userRow, $component) { $allowedComponentClasses = $this->_getAllowedComponentClasses($userRow); return $component->getRecursiveChildComponents(array( 'componentClasses' => $allowedComponentClasses, 'ignoreVisible' => true, ...
php
public function getAllowedChildComponents($userRow, $component) { $allowedComponentClasses = $this->_getAllowedComponentClasses($userRow); return $component->getRecursiveChildComponents(array( 'componentClasses' => $allowedComponentClasses, 'ignoreVisible' => true, ...
[ "public", "function", "getAllowedChildComponents", "(", "$", "userRow", ",", "$", "component", ")", "{", "$", "allowedComponentClasses", "=", "$", "this", "->", "_getAllowedComponentClasses", "(", "$", "userRow", ")", ";", "return", "$", "component", "->", "getR...
Gibt alle Unterkomponenten einer Seite zurück die barbeitet werden dürfen d.h. alles *bis* zur pseudoPage oder showInPageTreeAdmin
[ "Gibt", "alle", "Unterkomponenten", "einer", "Seite", "zurück", "die", "barbeitet", "werden", "dürfen" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Acl.php#L221-L234
koala-framework/koala-framework
Kwf/Component/Acl.php
Kwf_Component_Acl.allowComponent
public function allowComponent($role, $componentClass, $privilege = null) { if ($privilege) throw new Kwf_Exception("Not yet implemented"); if (!is_null($role)) $role = $this->_roleRegistry->get($role); $rules =& $this->_getRules('Component', $componentClass, $role, true); $rules['ty...
php
public function allowComponent($role, $componentClass, $privilege = null) { if ($privilege) throw new Kwf_Exception("Not yet implemented"); if (!is_null($role)) $role = $this->_roleRegistry->get($role); $rules =& $this->_getRules('Component', $componentClass, $role, true); $rules['ty...
[ "public", "function", "allowComponent", "(", "$", "role", ",", "$", "componentClass", ",", "$", "privilege", "=", "null", ")", "{", "if", "(", "$", "privilege", ")", "throw", "new", "Kwf_Exception", "(", "\"Not yet implemented\"", ")", ";", "if", "(", "!",...
Allow Component plus child components on same page
[ "Allow", "Component", "plus", "child", "components", "on", "same", "page" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Acl.php#L275-L282
koala-framework/koala-framework
Kwf/Component/Generator/Events/Static.php
Kwf_Component_Generator_Events_Static._fireComponentEvent
protected function _fireComponentEvent($eventType, Kwf_Component_Event_Component_AbstractFlag $ev) { $cls = 'Kwf_Component_Event_Component_'.$eventType; $g = $this->_getGenerator(); foreach ($ev->component->getChildComponents(array('generator'=>$g->getGeneratorKey())) as $c) { $t...
php
protected function _fireComponentEvent($eventType, Kwf_Component_Event_Component_AbstractFlag $ev) { $cls = 'Kwf_Component_Event_Component_'.$eventType; $g = $this->_getGenerator(); foreach ($ev->component->getChildComponents(array('generator'=>$g->getGeneratorKey())) as $c) { $t...
[ "protected", "function", "_fireComponentEvent", "(", "$", "eventType", ",", "Kwf_Component_Event_Component_AbstractFlag", "$", "ev", ")", "{", "$", "cls", "=", "'Kwf_Component_Event_Component_'", ".", "$", "eventType", ";", "$", "g", "=", "$", "this", "->", "_getG...
overridden in Page_Events_Static
[ "overridden", "in", "Page_Events_Static" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Component/Generator/Events/Static.php#L21-L28
koala-framework/koala-framework
Kwc/Mail/PlaceholdersPlugin.php
Kwc_Mail_PlaceholdersPlugin.processMailOutput
public function processMailOutput($output, Kwc_Mail_Recipient_Interface $recipient = null) { $placeholders = Kwf_Component_Data_Root::getInstance() ->getComponentById($this->_componentId) ->getComponent()->getPlaceholders($recipient); foreach ($placeholders as $p=>$v) { ...
php
public function processMailOutput($output, Kwc_Mail_Recipient_Interface $recipient = null) { $placeholders = Kwf_Component_Data_Root::getInstance() ->getComponentById($this->_componentId) ->getComponent()->getPlaceholders($recipient); foreach ($placeholders as $p=>$v) { ...
[ "public", "function", "processMailOutput", "(", "$", "output", ",", "Kwc_Mail_Recipient_Interface", "$", "recipient", "=", "null", ")", "{", "$", "placeholders", "=", "Kwf_Component_Data_Root", "::", "getInstance", "(", ")", "->", "getComponentById", "(", "$", "th...
called by Kwc_Mail_Abstract_Component::getHtml and getText
[ "called", "by", "Kwc_Mail_Abstract_Component", "::", "getHtml", "and", "getText" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwc/Mail/PlaceholdersPlugin.php#L5-L14
koala-framework/koala-framework
Kwc/Mail/PlaceholdersPlugin.php
Kwc_Mail_PlaceholdersPlugin.processOutput
public function processOutput($output, $renderer) { $output = parent::processOutput($output, $renderer); $c = Kwf_Component_Data_Root::getInstance()->getComponentById($this->_componentId); $recipient = $c->getComponent()->getRecipient(); $redirectComponent = $c->getChildComponent('_...
php
public function processOutput($output, $renderer) { $output = parent::processOutput($output, $renderer); $c = Kwf_Component_Data_Root::getInstance()->getComponentById($this->_componentId); $recipient = $c->getComponent()->getRecipient(); $redirectComponent = $c->getChildComponent('_...
[ "public", "function", "processOutput", "(", "$", "output", ",", "$", "renderer", ")", "{", "$", "output", "=", "parent", "::", "processOutput", "(", "$", "output", ",", "$", "renderer", ")", ";", "$", "c", "=", "Kwf_Component_Data_Root", "::", "getInstance...
recipient is set when showing mail in browser, not when sending mail
[ "recipient", "is", "set", "when", "showing", "mail", "in", "browser", "not", "when", "sending", "mail" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwc/Mail/PlaceholdersPlugin.php#L18-L30
koala-framework/koala-framework
Kwf/View/Helper/HighlightTerms.php
Kwf_View_Helper_HighlightTerms.highlightTerms
public function highlightTerms($terms, $text, array $options = array()) { if (!is_array($terms)) $terms = array($terms); if (!isset($options['maxReturnLength'])) $options['maxReturnLength'] = 350; if (!isset($options['maxReturnBlocks'])) $options['maxReturnBlocks'] = 3; if (!isset($...
php
public function highlightTerms($terms, $text, array $options = array()) { if (!is_array($terms)) $terms = array($terms); if (!isset($options['maxReturnLength'])) $options['maxReturnLength'] = 350; if (!isset($options['maxReturnBlocks'])) $options['maxReturnBlocks'] = 3; if (!isset($...
[ "public", "function", "highlightTerms", "(", "$", "terms", ",", "$", "text", ",", "array", "$", "options", "=", "array", "(", ")", ")", "{", "if", "(", "!", "is_array", "(", "$", "terms", ")", ")", "$", "terms", "=", "array", "(", "$", "terms", "...
Highlights a term in a text and shorts it. The output then may look like the description of a web-search-engine result. @param string|array $terms The term(s) to highlight. Each must contain at least a char of: a-z A-Z 0-9 @param string $text The text to highlight the terms in. @param array $options Options for the hi...
[ "Highlights", "a", "term", "in", "a", "text", "and", "shorts", "it", ".", "The", "output", "then", "may", "look", "like", "the", "description", "of", "a", "web", "-", "search", "-", "engine", "result", "." ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/View/Helper/HighlightTerms.php#L19-L158
koala-framework/koala-framework
Kwf/Form/Field/FilterField.php
Kwf_Form_Field_FilterField.setNamePrefix
public function setNamePrefix($name) { $this->_namePrefix = $name; if ($this->getFilterField()) $this->getFilterField()->setNamePrefix($name); if ($this->getFilteredField()) $this->getFilteredField()->setNamePrefix($name); return $this; }
php
public function setNamePrefix($name) { $this->_namePrefix = $name; if ($this->getFilterField()) $this->getFilterField()->setNamePrefix($name); if ($this->getFilteredField()) $this->getFilteredField()->setNamePrefix($name); return $this; }
[ "public", "function", "setNamePrefix", "(", "$", "name", ")", "{", "$", "this", "->", "_namePrefix", "=", "$", "name", ";", "if", "(", "$", "this", "->", "getFilterField", "(", ")", ")", "$", "this", "->", "getFilterField", "(", ")", "->", "setNamePref...
Sets the name prefix for the filter/filtered fields
[ "Sets", "the", "name", "prefix", "for", "the", "filter", "/", "filtered", "fields" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Form/Field/FilterField.php#L20-L26
koala-framework/koala-framework
Kwf/Form/Field/FilterField.php
Kwf_Form_Field_FilterField.setFilterField
public function setFilterField(Kwf_Form_Field_Abstract $field) { $property = $this->setProperty('filterField', $field); $field->setNamePrefix($this->_namePrefix); return $property; }
php
public function setFilterField(Kwf_Form_Field_Abstract $field) { $property = $this->setProperty('filterField', $field); $field->setNamePrefix($this->_namePrefix); return $property; }
[ "public", "function", "setFilterField", "(", "Kwf_Form_Field_Abstract", "$", "field", ")", "{", "$", "property", "=", "$", "this", "->", "setProperty", "(", "'filterField'", ",", "$", "field", ")", ";", "$", "field", "->", "setNamePrefix", "(", "$", "this", ...
Sets the filter field (the one that filters the filtered field)
[ "Sets", "the", "filter", "field", "(", "the", "one", "that", "filters", "the", "filtered", "field", ")" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Form/Field/FilterField.php#L31-L36
koala-framework/koala-framework
Kwf/Form/Field/FilterField.php
Kwf_Form_Field_FilterField.setFilteredField
public function setFilteredField(Kwf_Form_Field_Abstract $field) { $property = $this->setProperty('filteredField', $field); $field->setNamePrefix($this->_namePrefix); return $property; }
php
public function setFilteredField(Kwf_Form_Field_Abstract $field) { $property = $this->setProperty('filteredField', $field); $field->setNamePrefix($this->_namePrefix); return $property; }
[ "public", "function", "setFilteredField", "(", "Kwf_Form_Field_Abstract", "$", "field", ")", "{", "$", "property", "=", "$", "this", "->", "setProperty", "(", "'filteredField'", ",", "$", "field", ")", ";", "$", "field", "->", "setNamePrefix", "(", "$", "thi...
Sets the filtered field (the one that's filtered by filter field)
[ "Sets", "the", "filtered", "field", "(", "the", "one", "that", "s", "filtered", "by", "filter", "field", ")" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Form/Field/FilterField.php#L41-L46
koala-framework/koala-framework
Kwf/Assets/Package/ComponentPackage.php
Kwf_Assets_Package_ComponentPackage._getFilteredUniqueDependencies
protected function _getFilteredUniqueDependencies($mimeType) { $ret = parent::_getFilteredUniqueDependencies($mimeType); $loadedDeps = $this->_loadedPackage->_getFilteredUniqueDependencies($mimeType); foreach ($ret as $k=>$i) { if (in_array($i, $loadedDeps, true)) { ...
php
protected function _getFilteredUniqueDependencies($mimeType) { $ret = parent::_getFilteredUniqueDependencies($mimeType); $loadedDeps = $this->_loadedPackage->_getFilteredUniqueDependencies($mimeType); foreach ($ret as $k=>$i) { if (in_array($i, $loadedDeps, true)) { ...
[ "protected", "function", "_getFilteredUniqueDependencies", "(", "$", "mimeType", ")", "{", "$", "ret", "=", "parent", "::", "_getFilteredUniqueDependencies", "(", "$", "mimeType", ")", ";", "$", "loadedDeps", "=", "$", "this", "->", "_loadedPackage", "->", "_get...
remove already loaded (in _loadedPackage = Frontend) dependencies dependencies
[ "remove", "already", "loaded", "(", "in", "_loadedPackage", "=", "Frontend", ")", "dependencies", "dependencies" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Assets/Package/ComponentPackage.php#L46-L61
koala-framework/koala-framework
Kwf/Assets/Package/ComponentPackage.php
Kwf_Assets_Package_ComponentPackage._getCommonJsData
protected function _getCommonJsData($mimeType) { $commonJsData = parent::_getCommonJsData($mimeType); if ($commonJsData) { $deps = array_merge( $this->_loadedPackage->_getFilteredUniqueDependencies('text/javascript'), $this->_loadedPackage->_getFilteredUni...
php
protected function _getCommonJsData($mimeType) { $commonJsData = parent::_getCommonJsData($mimeType); if ($commonJsData) { $deps = array_merge( $this->_loadedPackage->_getFilteredUniqueDependencies('text/javascript'), $this->_loadedPackage->_getFilteredUni...
[ "protected", "function", "_getCommonJsData", "(", "$", "mimeType", ")", "{", "$", "commonJsData", "=", "parent", "::", "_getCommonJsData", "(", "$", "mimeType", ")", ";", "if", "(", "$", "commonJsData", ")", "{", "$", "deps", "=", "array_merge", "(", "$", ...
remove already loaded (in _loadedPackage = Frontend) commonjs dependencies
[ "remove", "already", "loaded", "(", "in", "_loadedPackage", "=", "Frontend", ")", "commonjs", "dependencies" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Assets/Package/ComponentPackage.php#L72-L91
koala-framework/koala-framework
Kwf/Form/Field/ComboBox.php
Kwf_Form_Field_ComboBox.getMetaData
public function getMetaData($model) { $ret = parent::getMetaData($model); $ret['store'] = $this->_getStoreData(); if (isset($ret['fields'])) unset($ret['fields']); if (isset($ret['values'])) unset($ret['values']); if (isset($ret['select'])) unset($ret['select']); r...
php
public function getMetaData($model) { $ret = parent::getMetaData($model); $ret['store'] = $this->_getStoreData(); if (isset($ret['fields'])) unset($ret['fields']); if (isset($ret['values'])) unset($ret['values']); if (isset($ret['select'])) unset($ret['select']); r...
[ "public", "function", "getMetaData", "(", "$", "model", ")", "{", "$", "ret", "=", "parent", "::", "getMetaData", "(", "$", "model", ")", ";", "$", "ret", "[", "'store'", "]", "=", "$", "this", "->", "_getStoreData", "(", ")", ";", "if", "(", "isse...
setListWidth
[ "setListWidth" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Form/Field/ComboBox.php#L52-L63
koala-framework/koala-framework
Kwc/Basic/Text/StylesModel.php
Kwc_Basic_Text_StylesModel.parseMasterStyles
public static function parseMasterStyles($masterContent) { $styles = array(); $up = Kwf_Config::getValue('application.uniquePrefix'); if ($up) $up .= '-'; if (strpos($masterContent, ".{$up}webStandard")===false) return $styles; $up = str_replace('-', '\-', $up); preg...
php
public static function parseMasterStyles($masterContent) { $styles = array(); $up = Kwf_Config::getValue('application.uniquePrefix'); if ($up) $up .= '-'; if (strpos($masterContent, ".{$up}webStandard")===false) return $styles; $up = str_replace('-', '\-', $up); preg...
[ "public", "static", "function", "parseMasterStyles", "(", "$", "masterContent", ")", "{", "$", "styles", "=", "array", "(", ")", ";", "$", "up", "=", "Kwf_Config", "::", "getValue", "(", "'application.uniquePrefix'", ")", ";", "if", "(", "$", "up", ")", ...
public fuer test
[ "public", "fuer", "test" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwc/Basic/Text/StylesModel.php#L21-L42
koala-framework/koala-framework
Kwf/View/Helper/Truncate.php
Kwf_View_Helper_Truncate.truncate
public function truncate($string, $length = 80, $etc = '…', $break_words = false, $middle = false) { if ($length === false) return $string; if ($length == 0) return ''; if (is_array($string)) { if ($middle !== false) { throw new Kwf_Exception("Using the 'middle' ...
php
public function truncate($string, $length = 80, $etc = '…', $break_words = false, $middle = false) { if ($length === false) return $string; if ($length == 0) return ''; if (is_array($string)) { if ($middle !== false) { throw new Kwf_Exception("Using the 'middle' ...
[ "public", "function", "truncate", "(", "$", "string", ",", "$", "length", "=", "80", ",", "$", "etc", "=", "'…', ", "$", "r", "eak_words =", "f", "lse, ", "$", "i", "ddle =", "f", "lse)", "", "{", "if", "(", "$", "length", "===", "false", ")", "r...
The truncate method itself. @todo Possibility to put ready html into $string and act the way like it would be an array @param string|array $string The Input to be truncated (string) The string to be truncated (array) An array of strings to be truncated. Can be one of the following: array('String text 1', ' - String t...
[ "The", "truncate", "method", "itself", "." ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/View/Helper/Truncate.php#L29-L54
koala-framework/koala-framework
Kwf/Util/Rrd/File.php
Kwf_Util_Rrd_File.createFile
public function createFile($start = null) { if (file_exists($this->_fileName)) { throw new Kwf_Exception("$this->_fileName already exists"); } $initialValueDates = array(); if (is_null($start)) { $initialValueDates = $this->_getInitialValueDates(); ...
php
public function createFile($start = null) { if (file_exists($this->_fileName)) { throw new Kwf_Exception("$this->_fileName already exists"); } $initialValueDates = array(); if (is_null($start)) { $initialValueDates = $this->_getInitialValueDates(); ...
[ "public", "function", "createFile", "(", "$", "start", "=", "null", ")", "{", "if", "(", "file_exists", "(", "$", "this", "->", "_fileName", ")", ")", "{", "throw", "new", "Kwf_Exception", "(", "\"$this->_fileName already exists\"", ")", ";", "}", "$", "in...
erstellt rrd Datei wenn kein start-timestamp übergeben wird dieser automatisch ermittelt und per _getInitialValueDates die datei für die vergangenheit befüllt @param int start-timestamp, sollte normalerweise null sein
[ "erstellt", "rrd", "Datei" ]
train
https://github.com/koala-framework/koala-framework/blob/2131b9b10b6c368ea02ad448d5f8a4deef0fe971/Kwf/Util/Rrd/File.php#L100-L140
DeveloperCielo/API-3.0-PHP
src/Cielo/API30/Ecommerce/Request/QuerySaleRequest.php
QuerySaleRequest.execute
public function execute($paymentId) { $url = $this->environment->getApiQueryURL() . '1/sales/' . $paymentId; return $this->sendRequest('GET', $url); }
php
public function execute($paymentId) { $url = $this->environment->getApiQueryURL() . '1/sales/' . $paymentId; return $this->sendRequest('GET', $url); }
[ "public", "function", "execute", "(", "$", "paymentId", ")", "{", "$", "url", "=", "$", "this", "->", "environment", "->", "getApiQueryURL", "(", ")", ".", "'1/sales/'", ".", "$", "paymentId", ";", "return", "$", "this", "->", "sendRequest", "(", "'GET'"...
@param $paymentId @return null @throws \Cielo\API30\Ecommerce\Request\CieloRequestException @throws \RuntimeException
[ "@param", "$paymentId" ]
train
https://github.com/DeveloperCielo/API-3.0-PHP/blob/40dd1a00e32d1709db8ba0fd385a744d28b1ab3f/src/Cielo/API30/Ecommerce/Request/QuerySaleRequest.php#L39-L44
DeveloperCielo/API-3.0-PHP
src/Cielo/API30/Ecommerce/Sale.php
Sale.fromJson
public static function fromJson($json) { $object = json_decode($json); $sale = new Sale(); $sale->populate($object); return $sale; }
php
public static function fromJson($json) { $object = json_decode($json); $sale = new Sale(); $sale->populate($object); return $sale; }
[ "public", "static", "function", "fromJson", "(", "$", "json", ")", "{", "$", "object", "=", "json_decode", "(", "$", "json", ")", ";", "$", "sale", "=", "new", "Sale", "(", ")", ";", "$", "sale", "->", "populate", "(", "$", "object", ")", ";", "r...
@param $json @return Sale
[ "@param", "$json" ]
train
https://github.com/DeveloperCielo/API-3.0-PHP/blob/40dd1a00e32d1709db8ba0fd385a744d28b1ab3f/src/Cielo/API30/Ecommerce/Sale.php#L34-L42
DeveloperCielo/API-3.0-PHP
src/Cielo/API30/Ecommerce/Sale.php
Sale.payment
public function payment($amount, $installments = 1) { $payment = new Payment($amount, $installments); $this->setPayment($payment); return $payment; }
php
public function payment($amount, $installments = 1) { $payment = new Payment($amount, $installments); $this->setPayment($payment); return $payment; }
[ "public", "function", "payment", "(", "$", "amount", ",", "$", "installments", "=", "1", ")", "{", "$", "payment", "=", "new", "Payment", "(", "$", "amount", ",", "$", "installments", ")", ";", "$", "this", "->", "setPayment", "(", "$", "payment", ")...
@param $amount @param int $installments @return Payment
[ "@param", "$amount", "@param", "int", "$installments" ]
train
https://github.com/DeveloperCielo/API-3.0-PHP/blob/40dd1a00e32d1709db8ba0fd385a744d28b1ab3f/src/Cielo/API30/Ecommerce/Sale.php#L94-L101
DeveloperCielo/API-3.0-PHP
src/Cielo/API30/Ecommerce/CreditCard.php
CreditCard.fromJson
public static function fromJson($json) { $object = \json_decode($json); $cardToken = new CreditCard(); $cardToken->populate($object); return $cardToken; }
php
public static function fromJson($json) { $object = \json_decode($json); $cardToken = new CreditCard(); $cardToken->populate($object); return $cardToken; }
[ "public", "static", "function", "fromJson", "(", "$", "json", ")", "{", "$", "object", "=", "\\", "json_decode", "(", "$", "json", ")", ";", "$", "cardToken", "=", "new", "CreditCard", "(", ")", ";", "$", "cardToken", "->", "populate", "(", "$", "obj...
@param string $json @return CreditCard
[ "@param", "string", "$json" ]
train
https://github.com/DeveloperCielo/API-3.0-PHP/blob/40dd1a00e32d1709db8ba0fd385a744d28b1ab3f/src/Cielo/API30/Ecommerce/CreditCard.php#L89-L96
DeveloperCielo/API-3.0-PHP
src/Cielo/API30/Ecommerce/Request/AbstractRequest.php
AbstractRequest.readResponse
protected function readResponse($statusCode, $responseBody) { $unserialized = null; switch ($statusCode) { case 200: case 201: $unserialized = $this->unserialize($responseBody); break; case 400: $exception = null; ...
php
protected function readResponse($statusCode, $responseBody) { $unserialized = null; switch ($statusCode) { case 200: case 201: $unserialized = $this->unserialize($responseBody); break; case 400: $exception = null; ...
[ "protected", "function", "readResponse", "(", "$", "statusCode", ",", "$", "responseBody", ")", "{", "$", "unserialized", "=", "null", ";", "switch", "(", "$", "statusCode", ")", "{", "case", "200", ":", "case", "201", ":", "$", "unserialized", "=", "$",...
@param $statusCode @param $responseBody @return mixed @throws CieloRequestException
[ "@param", "$statusCode", "@param", "$responseBody" ]
train
https://github.com/DeveloperCielo/API-3.0-PHP/blob/40dd1a00e32d1709db8ba0fd385a744d28b1ab3f/src/Cielo/API30/Ecommerce/Request/AbstractRequest.php#L101-L128
DeveloperCielo/API-3.0-PHP
src/Cielo/API30/Ecommerce/Payment.php
Payment.creditCard
public function creditCard($securityCode, $brand) { $card = $this->newCard($securityCode, $brand); $this->setType(self::PAYMENTTYPE_CREDITCARD); $this->setCreditCard($card); return $card; }
php
public function creditCard($securityCode, $brand) { $card = $this->newCard($securityCode, $brand); $this->setType(self::PAYMENTTYPE_CREDITCARD); $this->setCreditCard($card); return $card; }
[ "public", "function", "creditCard", "(", "$", "securityCode", ",", "$", "brand", ")", "{", "$", "card", "=", "$", "this", "->", "newCard", "(", "$", "securityCode", ",", "$", "brand", ")", ";", "$", "this", "->", "setType", "(", "self", "::", "PAYMEN...
@param $securityCode @param $brand @return CreditCard
[ "@param", "$securityCode", "@param", "$brand" ]
train
https://github.com/DeveloperCielo/API-3.0-PHP/blob/40dd1a00e32d1709db8ba0fd385a744d28b1ab3f/src/Cielo/API30/Ecommerce/Payment.php#L213-L221
DeveloperCielo/API-3.0-PHP
src/Cielo/API30/Ecommerce/Payment.php
Payment.newCard
private function newCard($securityCode, $brand) { $card = new CreditCard(); $card->setSecurityCode($securityCode); $card->setBrand($brand); return $card; }
php
private function newCard($securityCode, $brand) { $card = new CreditCard(); $card->setSecurityCode($securityCode); $card->setBrand($brand); return $card; }
[ "private", "function", "newCard", "(", "$", "securityCode", ",", "$", "brand", ")", "{", "$", "card", "=", "new", "CreditCard", "(", ")", ";", "$", "card", "->", "setSecurityCode", "(", "$", "securityCode", ")", ";", "$", "card", "->", "setBrand", "(",...
@param $securityCode @param $brand @return CreditCard
[ "@param", "$securityCode", "@param", "$brand" ]
train
https://github.com/DeveloperCielo/API-3.0-PHP/blob/40dd1a00e32d1709db8ba0fd385a744d28b1ab3f/src/Cielo/API30/Ecommerce/Payment.php#L229-L236
DeveloperCielo/API-3.0-PHP
src/Cielo/API30/Ecommerce/Payment.php
Payment.debitCard
public function debitCard($securityCode, $brand) { $card = $this->newCard($securityCode, $brand); $this->setType(self::PAYMENTTYPE_DEBITCARD); $this->setDebitCard($card); return $card; }
php
public function debitCard($securityCode, $brand) { $card = $this->newCard($securityCode, $brand); $this->setType(self::PAYMENTTYPE_DEBITCARD); $this->setDebitCard($card); return $card; }
[ "public", "function", "debitCard", "(", "$", "securityCode", ",", "$", "brand", ")", "{", "$", "card", "=", "$", "this", "->", "newCard", "(", "$", "securityCode", ",", "$", "brand", ")", ";", "$", "this", "->", "setType", "(", "self", "::", "PAYMENT...
@param $securityCode @param $brand @return CreditCard
[ "@param", "$securityCode", "@param", "$brand" ]
train
https://github.com/DeveloperCielo/API-3.0-PHP/blob/40dd1a00e32d1709db8ba0fd385a744d28b1ab3f/src/Cielo/API30/Ecommerce/Payment.php#L244-L252
DeveloperCielo/API-3.0-PHP
src/Cielo/API30/Ecommerce/Payment.php
Payment.recurrentPayment
public function recurrentPayment($authorizeNow = true) { $recurrentPayment = new RecurrentPayment($authorizeNow); $this->setRecurrentPayment($recurrentPayment); return $recurrentPayment; }
php
public function recurrentPayment($authorizeNow = true) { $recurrentPayment = new RecurrentPayment($authorizeNow); $this->setRecurrentPayment($recurrentPayment); return $recurrentPayment; }
[ "public", "function", "recurrentPayment", "(", "$", "authorizeNow", "=", "true", ")", "{", "$", "recurrentPayment", "=", "new", "RecurrentPayment", "(", "$", "authorizeNow", ")", ";", "$", "this", "->", "setRecurrentPayment", "(", "$", "recurrentPayment", ")", ...
@param bool $authorizeNow @return RecurrentPayment
[ "@param", "bool", "$authorizeNow" ]
train
https://github.com/DeveloperCielo/API-3.0-PHP/blob/40dd1a00e32d1709db8ba0fd385a744d28b1ab3f/src/Cielo/API30/Ecommerce/Payment.php#L259-L266
DeveloperCielo/API-3.0-PHP
src/Cielo/API30/Ecommerce/RecurrentPayment.php
RecurrentPayment.fromJson
public static function fromJson($json) { $object = json_decode($json); $recurrentPayment = new RecurrentPayment(); if (isset($object->RecurrentPayment)) { $recurrentPayment->populate($object->RecurrentPayment); } return $recurrentPayment; }
php
public static function fromJson($json) { $object = json_decode($json); $recurrentPayment = new RecurrentPayment(); if (isset($object->RecurrentPayment)) { $recurrentPayment->populate($object->RecurrentPayment); } return $recurrentPayment; }
[ "public", "static", "function", "fromJson", "(", "$", "json", ")", "{", "$", "object", "=", "json_decode", "(", "$", "json", ")", ";", "$", "recurrentPayment", "=", "new", "RecurrentPayment", "(", ")", ";", "if", "(", "isset", "(", "$", "object", "->",...
@param $json @return RecurrentPayment
[ "@param", "$json" ]
train
https://github.com/DeveloperCielo/API-3.0-PHP/blob/40dd1a00e32d1709db8ba0fd385a744d28b1ab3f/src/Cielo/API30/Ecommerce/RecurrentPayment.php#L58-L69
DeveloperCielo/API-3.0-PHP
src/Cielo/API30/Ecommerce/Request/CreateSaleRequest.php
CreateSaleRequest.execute
public function execute($sale) { $url = $this->environment->getApiUrl() . '1/sales/'; return $this->sendRequest('POST', $url, $sale); }
php
public function execute($sale) { $url = $this->environment->getApiUrl() . '1/sales/'; return $this->sendRequest('POST', $url, $sale); }
[ "public", "function", "execute", "(", "$", "sale", ")", "{", "$", "url", "=", "$", "this", "->", "environment", "->", "getApiUrl", "(", ")", ".", "'1/sales/'", ";", "return", "$", "this", "->", "sendRequest", "(", "'POST'", ",", "$", "url", ",", "$",...
@param $sale @return null @throws \Cielo\API30\Ecommerce\Request\CieloRequestException @throws \RuntimeException
[ "@param", "$sale" ]
train
https://github.com/DeveloperCielo/API-3.0-PHP/blob/40dd1a00e32d1709db8ba0fd385a744d28b1ab3f/src/Cielo/API30/Ecommerce/Request/CreateSaleRequest.php#L39-L44
DeveloperCielo/API-3.0-PHP
src/Cielo/API30/Ecommerce/CieloEcommerce.php
CieloEcommerce.createSale
public function createSale(Sale $sale) { $createSaleRequest = new CreateSaleRequest($this->merchant, $this->environment); return $createSaleRequest->execute($sale); }
php
public function createSale(Sale $sale) { $createSaleRequest = new CreateSaleRequest($this->merchant, $this->environment); return $createSaleRequest->execute($sale); }
[ "public", "function", "createSale", "(", "Sale", "$", "sale", ")", "{", "$", "createSaleRequest", "=", "new", "CreateSaleRequest", "(", "$", "this", "->", "merchant", ",", "$", "this", "->", "environment", ")", ";", "return", "$", "createSaleRequest", "->", ...
Send the Sale to be created and return the Sale with tid and the status returned by Cielo. @param Sale $sale The preconfigured Sale @return Sale The Sale with authorization, tid, etc. returned by Cielo. @throws \Cielo\API30\Ecommerce\Request\CieloRequestException if anything gets wrong. @see <a href= "https://devel...
[ "Send", "the", "Sale", "to", "be", "created", "and", "return", "the", "Sale", "with", "tid", "and", "the", "status", "returned", "by", "Cielo", "." ]
train
https://github.com/DeveloperCielo/API-3.0-PHP/blob/40dd1a00e32d1709db8ba0fd385a744d28b1ab3f/src/Cielo/API30/Ecommerce/CieloEcommerce.php#L57-L62
DeveloperCielo/API-3.0-PHP
src/Cielo/API30/Ecommerce/CieloEcommerce.php
CieloEcommerce.getSale
public function getSale($paymentId) { $querySaleRequest = new QuerySaleRequest($this->merchant, $this->environment); return $querySaleRequest->execute($paymentId); }
php
public function getSale($paymentId) { $querySaleRequest = new QuerySaleRequest($this->merchant, $this->environment); return $querySaleRequest->execute($paymentId); }
[ "public", "function", "getSale", "(", "$", "paymentId", ")", "{", "$", "querySaleRequest", "=", "new", "QuerySaleRequest", "(", "$", "this", "->", "merchant", ",", "$", "this", "->", "environment", ")", ";", "return", "$", "querySaleRequest", "->", "execute"...
Query a Sale on Cielo by paymentId @param string $paymentId The paymentId to be queried @return Sale The Sale with authorization, tid, etc. returned by Cielo. @throws \Cielo\API30\Ecommerce\Request\CieloRequestException if anything gets wrong. @see <a href= "https://developercielo.github.io/Webservice-3.0/english.h...
[ "Query", "a", "Sale", "on", "Cielo", "by", "paymentId" ]
train
https://github.com/DeveloperCielo/API-3.0-PHP/blob/40dd1a00e32d1709db8ba0fd385a744d28b1ab3f/src/Cielo/API30/Ecommerce/CieloEcommerce.php#L78-L83
DeveloperCielo/API-3.0-PHP
src/Cielo/API30/Ecommerce/CieloEcommerce.php
CieloEcommerce.getRecurrentPayment
public function getRecurrentPayment($recurrentPaymentId) { $queryRecurrentPaymentRequest = new queryRecurrentPaymentRequest($this->merchant, $this->environment); return $queryRecurrentPaymentRequest->execute($recurrentPaymentId); }
php
public function getRecurrentPayment($recurrentPaymentId) { $queryRecurrentPaymentRequest = new queryRecurrentPaymentRequest($this->merchant, $this->environment); return $queryRecurrentPaymentRequest->execute($recurrentPaymentId); }
[ "public", "function", "getRecurrentPayment", "(", "$", "recurrentPaymentId", ")", "{", "$", "queryRecurrentPaymentRequest", "=", "new", "queryRecurrentPaymentRequest", "(", "$", "this", "->", "merchant", ",", "$", "this", "->", "environment", ")", ";", "return", "...
Query a RecurrentPayment on Cielo by RecurrentPaymentId @param string $recurrentPaymentId The RecurrentPaymentId to be queried @return \Cielo\API30\Ecommerce\RecurrentPayment The RecurrentPayment with authorization, tid, etc. returned by Cielo. @throws \Cielo\API30\Ecommerce\Request\CieloRequestException if anything...
[ "Query", "a", "RecurrentPayment", "on", "Cielo", "by", "RecurrentPaymentId" ]
train
https://github.com/DeveloperCielo/API-3.0-PHP/blob/40dd1a00e32d1709db8ba0fd385a744d28b1ab3f/src/Cielo/API30/Ecommerce/CieloEcommerce.php#L100-L105
DeveloperCielo/API-3.0-PHP
src/Cielo/API30/Ecommerce/CieloEcommerce.php
CieloEcommerce.cancelSale
public function cancelSale($paymentId, $amount = null) { $updateSaleRequest = new UpdateSaleRequest('void', $this->merchant, $this->environment); $updateSaleRequest->setAmount($amount); return $updateSaleRequest->execute($paymentId); }
php
public function cancelSale($paymentId, $amount = null) { $updateSaleRequest = new UpdateSaleRequest('void', $this->merchant, $this->environment); $updateSaleRequest->setAmount($amount); return $updateSaleRequest->execute($paymentId); }
[ "public", "function", "cancelSale", "(", "$", "paymentId", ",", "$", "amount", "=", "null", ")", "{", "$", "updateSaleRequest", "=", "new", "UpdateSaleRequest", "(", "'void'", ",", "$", "this", "->", "merchant", ",", "$", "this", "->", "environment", ")", ...
Cancel a Sale on Cielo by paymentId and speficying the amount @param string $paymentId The paymentId to be queried @param integer $amount Order value in cents @return Sale The Sale with authorization, tid, etc. returned by Cielo. @throws \Cielo\API30\Ecommerce\Request\CieloRequestException if anything gets wrong. ...
[ "Cancel", "a", "Sale", "on", "Cielo", "by", "paymentId", "and", "speficying", "the", "amount" ]
train
https://github.com/DeveloperCielo/API-3.0-PHP/blob/40dd1a00e32d1709db8ba0fd385a744d28b1ab3f/src/Cielo/API30/Ecommerce/CieloEcommerce.php#L123-L130
DeveloperCielo/API-3.0-PHP
src/Cielo/API30/Ecommerce/CieloEcommerce.php
CieloEcommerce.captureSale
public function captureSale($paymentId, $amount = null, $serviceTaxAmount = null) { $updateSaleRequest = new UpdateSaleRequest('capture', $this->merchant, $this->environment); $updateSaleRequest->setAmount($amount); $updateSaleRequest->setServiceTaxAmount($serviceTaxAmount); return...
php
public function captureSale($paymentId, $amount = null, $serviceTaxAmount = null) { $updateSaleRequest = new UpdateSaleRequest('capture', $this->merchant, $this->environment); $updateSaleRequest->setAmount($amount); $updateSaleRequest->setServiceTaxAmount($serviceTaxAmount); return...
[ "public", "function", "captureSale", "(", "$", "paymentId", ",", "$", "amount", "=", "null", ",", "$", "serviceTaxAmount", "=", "null", ")", "{", "$", "updateSaleRequest", "=", "new", "UpdateSaleRequest", "(", "'capture'", ",", "$", "this", "->", "merchant",...
Capture a Sale on Cielo by paymentId and specifying the amount and the serviceTaxAmount @param string $paymentId The paymentId to be captured @param integer $amount Amount of the authorization to be captured @param integer $serviceTaxAmount Amount of the authorization should be destined for the service charge @retur...
[ "Capture", "a", "Sale", "on", "Cielo", "by", "paymentId", "and", "specifying", "the", "amount", "and", "the", "serviceTaxAmount" ]
train
https://github.com/DeveloperCielo/API-3.0-PHP/blob/40dd1a00e32d1709db8ba0fd385a744d28b1ab3f/src/Cielo/API30/Ecommerce/CieloEcommerce.php#L153-L161
DeveloperCielo/API-3.0-PHP
src/Cielo/API30/Ecommerce/CieloEcommerce.php
CieloEcommerce.tokenizeCard
public function tokenizeCard(CreditCard $card) { $tokenizeCardRequest = new TokenizeCardRequest($this->merchant, $this->environment); return $tokenizeCardRequest->execute($card); }
php
public function tokenizeCard(CreditCard $card) { $tokenizeCardRequest = new TokenizeCardRequest($this->merchant, $this->environment); return $tokenizeCardRequest->execute($card); }
[ "public", "function", "tokenizeCard", "(", "CreditCard", "$", "card", ")", "{", "$", "tokenizeCardRequest", "=", "new", "TokenizeCardRequest", "(", "$", "this", "->", "merchant", ",", "$", "this", "->", "environment", ")", ";", "return", "$", "tokenizeCardRequ...
@param CreditCard $card @return CreditCard
[ "@param", "CreditCard", "$card" ]
train
https://github.com/DeveloperCielo/API-3.0-PHP/blob/40dd1a00e32d1709db8ba0fd385a744d28b1ab3f/src/Cielo/API30/Ecommerce/CieloEcommerce.php#L168-L173
DeveloperCielo/API-3.0-PHP
src/Cielo/API30/Ecommerce/Request/UpdateSaleRequest.php
UpdateSaleRequest.execute
public function execute($paymentId) { $url = $this->environment->getApiUrl() . '1/sales/' . $paymentId . '/' . $this->type; $params = []; if ($this->amount != null) { $params['amount'] = $this->amount; } if ($this->serviceTaxAmount != null) { $par...
php
public function execute($paymentId) { $url = $this->environment->getApiUrl() . '1/sales/' . $paymentId . '/' . $this->type; $params = []; if ($this->amount != null) { $params['amount'] = $this->amount; } if ($this->serviceTaxAmount != null) { $par...
[ "public", "function", "execute", "(", "$", "paymentId", ")", "{", "$", "url", "=", "$", "this", "->", "environment", "->", "getApiUrl", "(", ")", ".", "'1/sales/'", ".", "$", "paymentId", ".", "'/'", ".", "$", "this", "->", "type", ";", "$", "params"...
@param $paymentId @return null @throws \Cielo\API30\Ecommerce\Request\CieloRequestException @throws \RuntimeException
[ "@param", "$paymentId" ]
train
https://github.com/DeveloperCielo/API-3.0-PHP/blob/40dd1a00e32d1709db8ba0fd385a744d28b1ab3f/src/Cielo/API30/Ecommerce/Request/UpdateSaleRequest.php#L47-L63
ClassPreloader/ClassPreloader
src/Parser/FileVisitor.php
FileVisitor.enterNode
public function enterNode(Node $node) { if ($node instanceof FileNode) { if ($this->skip) { throw new FileConstantException(); } return new StringNode($this->getFilename()); } }
php
public function enterNode(Node $node) { if ($node instanceof FileNode) { if ($this->skip) { throw new FileConstantException(); } return new StringNode($this->getFilename()); } }
[ "public", "function", "enterNode", "(", "Node", "$", "node", ")", "{", "if", "(", "$", "node", "instanceof", "FileNode", ")", "{", "if", "(", "$", "this", "->", "skip", ")", "{", "throw", "new", "FileConstantException", "(", ")", ";", "}", "return", ...
Enter and modify the node. @param \PhpParser\Node $node @throws \ClassPreloader\Exceptions\FileConstantException @return \PhpParser\Node\Scalar\String_|null
[ "Enter", "and", "modify", "the", "node", "." ]
train
https://github.com/ClassPreloader/ClassPreloader/blob/4729e438e0ada350f91148e7d4bb9809342575ff/src/Parser/FileVisitor.php#L55-L64
ClassPreloader/ClassPreloader
src/ClassLoader.php
ClassLoader.getIncludes
public static function getIncludes($func) { $loader = new static(); call_user_func($func, $loader); $loader->unregister(); $config = new Config(); foreach ($loader->getFilenames() as $file) { $config->addFile($file); } return $config; }
php
public static function getIncludes($func) { $loader = new static(); call_user_func($func, $loader); $loader->unregister(); $config = new Config(); foreach ($loader->getFilenames() as $file) { $config->addFile($file); } return $config; }
[ "public", "static", "function", "getIncludes", "(", "$", "func", ")", "{", "$", "loader", "=", "new", "static", "(", ")", ";", "call_user_func", "(", "$", "func", ",", "$", "loader", ")", ";", "$", "loader", "->", "unregister", "(", ")", ";", "$", ...
Wrap a block of code in the autoloader and get a list of loaded classes. @param callable $func @return \ClassPreloader\Config
[ "Wrap", "a", "block", "of", "code", "in", "the", "autoloader", "and", "get", "a", "list", "of", "loaded", "classes", "." ]
train
https://github.com/ClassPreloader/ClassPreloader/blob/4729e438e0ada350f91148e7d4bb9809342575ff/src/ClassLoader.php#L60-L72
ClassPreloader/ClassPreloader
src/ClassLoader.php
ClassLoader.loadClass
public function loadClass($class) { foreach (spl_autoload_functions() as $func) { if (is_array($func) && $func[0] === $this) { continue; } $this->classList->push($class); if (call_user_func($func, $class)) { break; }...
php
public function loadClass($class) { foreach (spl_autoload_functions() as $func) { if (is_array($func) && $func[0] === $this) { continue; } $this->classList->push($class); if (call_user_func($func, $class)) { break; }...
[ "public", "function", "loadClass", "(", "$", "class", ")", "{", "foreach", "(", "spl_autoload_functions", "(", ")", "as", "$", "func", ")", "{", "if", "(", "is_array", "(", "$", "func", ")", "&&", "$", "func", "[", "0", "]", "===", "$", "this", ")"...
Loads the given class, interface or trait. We'll return true if it was loaded. @param string $class @return bool
[ "Loads", "the", "given", "class", "interface", "or", "trait", "." ]
train
https://github.com/ClassPreloader/ClassPreloader/blob/4729e438e0ada350f91148e7d4bb9809342575ff/src/ClassLoader.php#L103-L118
ClassPreloader/ClassPreloader
src/ClassLoader.php
ClassLoader.getFilenames
public function getFilenames() { $files = []; foreach ($this->classList->getClasses() as $class) { // Push interfaces before classes if not already loaded try { $r = new \ReflectionClass($class); foreach ($r->getInterfaces() as $inf) { ...
php
public function getFilenames() { $files = []; foreach ($this->classList->getClasses() as $class) { // Push interfaces before classes if not already loaded try { $r = new \ReflectionClass($class); foreach ($r->getInterfaces() as $inf) { ...
[ "public", "function", "getFilenames", "(", ")", "{", "$", "files", "=", "[", "]", ";", "foreach", "(", "$", "this", "->", "classList", "->", "getClasses", "(", ")", "as", "$", "class", ")", "{", "// Push interfaces before classes if not already loaded", "try",...
Get an array of loaded file names in order of loading. @return array
[ "Get", "an", "array", "of", "loaded", "file", "names", "in", "order", "of", "loading", "." ]
train
https://github.com/ClassPreloader/ClassPreloader/blob/4729e438e0ada350f91148e7d4bb9809342575ff/src/ClassLoader.php#L125-L149
ClassPreloader/ClassPreloader
src/Config.php
Config.getFilenames
public function getFilenames() { $filenames = []; foreach ($this->filenames as $f) { foreach ($this->inclusiveFilters as $filter) { if (!preg_match($filter, $f)) { continue 2; } } foreach ($this->exclusiveFilters...
php
public function getFilenames() { $filenames = []; foreach ($this->filenames as $f) { foreach ($this->inclusiveFilters as $filter) { if (!preg_match($filter, $f)) { continue 2; } } foreach ($this->exclusiveFilters...
[ "public", "function", "getFilenames", "(", ")", "{", "$", "filenames", "=", "[", "]", ";", "foreach", "(", "$", "this", "->", "filenames", "as", "$", "f", ")", "{", "foreach", "(", "$", "this", "->", "inclusiveFilters", "as", "$", "filter", ")", "{",...
Get an array of file names that satisfy any added filters. @return array
[ "Get", "an", "array", "of", "file", "names", "that", "satisfy", "any", "added", "filters", "." ]
train
https://github.com/ClassPreloader/ClassPreloader/blob/4729e438e0ada350f91148e7d4bb9809342575ff/src/Config.php#L60-L78
ClassPreloader/ClassPreloader
src/Parser/DirVisitor.php
DirVisitor.enterNode
public function enterNode(Node $node) { if ($node instanceof DirNode) { if ($this->skip) { throw new DirConstantException(); } return new StringNode($this->getDir()); } }
php
public function enterNode(Node $node) { if ($node instanceof DirNode) { if ($this->skip) { throw new DirConstantException(); } return new StringNode($this->getDir()); } }
[ "public", "function", "enterNode", "(", "Node", "$", "node", ")", "{", "if", "(", "$", "node", "instanceof", "DirNode", ")", "{", "if", "(", "$", "this", "->", "skip", ")", "{", "throw", "new", "DirConstantException", "(", ")", ";", "}", "return", "n...
Enter and modify the node. @param \PhpParser\Node $node @throws \ClassPreloader\Exceptions\DirConstantException @return \PhpParser\Node\Scalar\String_|null
[ "Enter", "and", "modify", "the", "node", "." ]
train
https://github.com/ClassPreloader/ClassPreloader/blob/4729e438e0ada350f91148e7d4bb9809342575ff/src/Parser/DirVisitor.php#L55-L64
ClassPreloader/ClassPreloader
src/Parser/StrictTypesVisitor.php
StrictTypesVisitor.enterNode
public function enterNode(Node $node) { if ($node instanceof DeclareDeclare && ($node->getLine() === 1 || $node->getLine() === 2)) { throw new StrictTypesException(); } }
php
public function enterNode(Node $node) { if ($node instanceof DeclareDeclare && ($node->getLine() === 1 || $node->getLine() === 2)) { throw new StrictTypesException(); } }
[ "public", "function", "enterNode", "(", "Node", "$", "node", ")", "{", "if", "(", "$", "node", "instanceof", "DeclareDeclare", "&&", "(", "$", "node", "->", "getLine", "(", ")", "===", "1", "||", "$", "node", "->", "getLine", "(", ")", "===", "2", ...
Enter and modify the node. @param \PhpParser\Node $node @throws \ClassPreloader\Exceptions\StrictTypesException @return null
[ "Enter", "and", "modify", "the", "node", "." ]
train
https://github.com/ClassPreloader/ClassPreloader/blob/4729e438e0ada350f91148e7d4bb9809342575ff/src/Parser/StrictTypesVisitor.php#L35-L40
ClassPreloader/ClassPreloader
src/Parser/NodeTraverser.php
NodeTraverser.traverseFile
public function traverseFile(array $nodes, $filename) { // Set the correct state on each visitor foreach ($this->visitors as $visitor) { if ($visitor instanceof AbstractNodeVisitor) { $visitor->setFilename($filename); } } return $this->travers...
php
public function traverseFile(array $nodes, $filename) { // Set the correct state on each visitor foreach ($this->visitors as $visitor) { if ($visitor instanceof AbstractNodeVisitor) { $visitor->setFilename($filename); } } return $this->travers...
[ "public", "function", "traverseFile", "(", "array", "$", "nodes", ",", "$", "filename", ")", "{", "// Set the correct state on each visitor", "foreach", "(", "$", "this", "->", "visitors", "as", "$", "visitor", ")", "{", "if", "(", "$", "visitor", "instanceof"...
Transverse the file. @param array $nodes @param string $filename @return \PhpParser\Node[]
[ "Transverse", "the", "file", "." ]
train
https://github.com/ClassPreloader/ClassPreloader/blob/4729e438e0ada350f91148e7d4bb9809342575ff/src/Parser/NodeTraverser.php#L32-L42
ClassPreloader/ClassPreloader
src/ClassList.php
ClassList.next
public function next() { if (isset($this->current->next)) { $this->current = $this->current->next; } else { $this->current->next = new ClassNode(null, $this->current); $this->current = $this->current->next; } }
php
public function next() { if (isset($this->current->next)) { $this->current = $this->current->next; } else { $this->current->next = new ClassNode(null, $this->current); $this->current = $this->current->next; } }
[ "public", "function", "next", "(", ")", "{", "if", "(", "isset", "(", "$", "this", "->", "current", "->", "next", ")", ")", "{", "$", "this", "->", "current", "=", "$", "this", "->", "current", "->", "next", ";", "}", "else", "{", "$", "this", ...
Traverse to the next node in the list. @return void
[ "Traverse", "to", "the", "next", "node", "in", "the", "list", "." ]
train
https://github.com/ClassPreloader/ClassPreloader/blob/4729e438e0ada350f91148e7d4bb9809342575ff/src/ClassList.php#L62-L70
ClassPreloader/ClassPreloader
src/ClassList.php
ClassList.push
public function push($value) { if (!$this->current->value) { $this->current->value = $value; } else { $temp = $this->current; $this->current = new ClassNode($value, $temp->prev); $this->current->next = $temp; $temp->prev = $this->current; ...
php
public function push($value) { if (!$this->current->value) { $this->current->value = $value; } else { $temp = $this->current; $this->current = new ClassNode($value, $temp->prev); $this->current->next = $temp; $temp->prev = $this->current; ...
[ "public", "function", "push", "(", "$", "value", ")", "{", "if", "(", "!", "$", "this", "->", "current", "->", "value", ")", "{", "$", "this", "->", "current", "->", "value", "=", "$", "value", ";", "}", "else", "{", "$", "temp", "=", "$", "thi...
Insert a value at the current position in the list. Any currently set value at this position will be pushed back in the list after the new value. @param mixed $value @return void
[ "Insert", "a", "value", "at", "the", "current", "position", "in", "the", "list", "." ]
train
https://github.com/ClassPreloader/ClassPreloader/blob/4729e438e0ada350f91148e7d4bb9809342575ff/src/ClassList.php#L82-L97
ClassPreloader/ClassPreloader
src/ClassList.php
ClassList.getClasses
public function getClasses() { $classes = []; $current = $this->head; while ($current && $current->value) { $classes[] = $current->value; $current = $current->next; } return array_filter($classes); }
php
public function getClasses() { $classes = []; $current = $this->head; while ($current && $current->value) { $classes[] = $current->value; $current = $current->next; } return array_filter($classes); }
[ "public", "function", "getClasses", "(", ")", "{", "$", "classes", "=", "[", "]", ";", "$", "current", "=", "$", "this", "->", "head", ";", "while", "(", "$", "current", "&&", "$", "current", "->", "value", ")", "{", "$", "classes", "[", "]", "="...
Traverse the ClassList and return a list of classes. @return array
[ "Traverse", "the", "ClassList", "and", "return", "a", "list", "of", "classes", "." ]
train
https://github.com/ClassPreloader/ClassPreloader/blob/4729e438e0ada350f91148e7d4bb9809342575ff/src/ClassList.php#L104-L114
ClassPreloader/ClassPreloader
src/Factory.php
Factory.create
public function create(array $options = []) { $printer = new PrettyPrinter(); $parser = $this->getParser(); $options = array_merge(['dir' => true, 'file' => true, 'skip' => false, 'strict' => false], $options); $traverser = $this->getTraverser($options['dir'], $options['file'], $o...
php
public function create(array $options = []) { $printer = new PrettyPrinter(); $parser = $this->getParser(); $options = array_merge(['dir' => true, 'file' => true, 'skip' => false, 'strict' => false], $options); $traverser = $this->getTraverser($options['dir'], $options['file'], $o...
[ "public", "function", "create", "(", "array", "$", "options", "=", "[", "]", ")", "{", "$", "printer", "=", "new", "PrettyPrinter", "(", ")", ";", "$", "parser", "=", "$", "this", "->", "getParser", "(", ")", ";", "$", "options", "=", "array_merge", ...
Create a new class preloader instance. Any options provided determine how the node traverser is setup. @param bool[] $options @return \ClassPreloader\ClassPreloader
[ "Create", "a", "new", "class", "preloader", "instance", "." ]
train
https://github.com/ClassPreloader/ClassPreloader/blob/4729e438e0ada350f91148e7d4bb9809342575ff/src/Factory.php#L40-L51
ClassPreloader/ClassPreloader
src/Factory.php
Factory.getTraverser
protected function getTraverser($dir, $file, $skip, $strict) { $traverser = new NodeTraverser(); if ($dir) { $traverser->addVisitor(new DirVisitor($skip)); } if ($file) { $traverser->addVisitor(new FileVisitor($skip)); } if (!$strict) { ...
php
protected function getTraverser($dir, $file, $skip, $strict) { $traverser = new NodeTraverser(); if ($dir) { $traverser->addVisitor(new DirVisitor($skip)); } if ($file) { $traverser->addVisitor(new FileVisitor($skip)); } if (!$strict) { ...
[ "protected", "function", "getTraverser", "(", "$", "dir", ",", "$", "file", ",", "$", "skip", ",", "$", "strict", ")", "{", "$", "traverser", "=", "new", "NodeTraverser", "(", ")", ";", "if", "(", "$", "dir", ")", "{", "$", "traverser", "->", "addV...
Get the node traverser to use. @param bool $dir @param bool $file @param bool $skip @param bool $strict @return \ClassPreloader\Parser\NodeTraverser
[ "Get", "the", "node", "traverser", "to", "use", "." ]
train
https://github.com/ClassPreloader/ClassPreloader/blob/4729e438e0ada350f91148e7d4bb9809342575ff/src/Factory.php#L77-L94
ClassPreloader/ClassPreloader
src/ClassPreloader.php
ClassPreloader.prepareOutput
public function prepareOutput($output, $strict = false) { if ($strict && version_compare(PHP_VERSION, '7') < 1) { throw new RuntimeException('Strict mode requires PHP 7 or greater.'); } $dir = dirname($output); if (!is_dir($dir) && !mkdir($dir, 0777, true)) { ...
php
public function prepareOutput($output, $strict = false) { if ($strict && version_compare(PHP_VERSION, '7') < 1) { throw new RuntimeException('Strict mode requires PHP 7 or greater.'); } $dir = dirname($output); if (!is_dir($dir) && !mkdir($dir, 0777, true)) { ...
[ "public", "function", "prepareOutput", "(", "$", "output", ",", "$", "strict", "=", "false", ")", "{", "if", "(", "$", "strict", "&&", "version_compare", "(", "PHP_VERSION", ",", "'7'", ")", "<", "1", ")", "{", "throw", "new", "RuntimeException", "(", ...
Prepare the output file and directory. @param string $output @param bool $strict @throws \RuntimeException @return resource
[ "Prepare", "the", "output", "file", "and", "directory", "." ]
train
https://github.com/ClassPreloader/ClassPreloader/blob/4729e438e0ada350f91148e7d4bb9809342575ff/src/ClassPreloader.php#L75-L100