summaryrefslogtreecommitdiff
path: root/framework/TComponent.php
diff options
context:
space:
mode:
Diffstat (limited to 'framework/TComponent.php')
-rw-r--r--framework/TComponent.php26
1 files changed, 26 insertions, 0 deletions
diff --git a/framework/TComponent.php b/framework/TComponent.php
index 7564edff..21a62abd 100644
--- a/framework/TComponent.php
+++ b/framework/TComponent.php
@@ -415,6 +415,32 @@ class TComponent
throw new TInvalidOperationException('component_statements_invalid',get_class($this),$statements,$e->getMessage());
}
}
+
+ /**
+ * This method is invoked after the component is instantiated by a template.
+ * When this method is invoked, the component's properties have been initialized.
+ * The default implementation of this method will invoke
+ * the potential parent component's {@link addParsedObject}.
+ * This method can be overriden.
+ * @param TComponent potential parent of this control
+ * @see addParsedObject
+ */
+ public function createdOnTemplate($parent)
+ {
+ $parent->addParsedObject($this);
+ }
+
+ /**
+ * Processes an object that is created during parsing template.
+ * The object can be either a component or a static text string.
+ * This method can be overriden to customize the handling of newly created objects in template.
+ * Only framework developers and control developers should use this method.
+ * @param string|TComponent text string or component parsed and instantiated in template
+ * @see createdOnTemplate
+ */
+ public function addParsedObject($object)
+ {
+ }
}
/**