fluid-documentation-en.diff

Irene Höppner, 2008-12-22 10:17

Download (4.96 KB)

View differences:

Administration.xml (working copy)
17 17
  <section>
18 18
    <title>Design Decisions</title>
19 19

  
20
    <para>BEER3 was born in the context of FLOW3, but from the beginning, we
20
    <para>Fluid was born in the context of FLOW3, but from the beginning, we
21 21
    saw the needs for such a templating system in other contexts - namely
22
    TYPO3 v4, or stand-alone usage. That's why the core design of BEER3
22
    TYPO3 v4, or stand-alone usage. That's why the core design of Fluid
23 23
    reflects this thinking.</para>
24 24

  
25
    <para>We are using a layered architecture for BEER3, shown below:</para>
25
    <para>We are using a layered architecture for Fluid (formerly known as
26
    BEER3), shown below:</para>
26 27

  
27 28
    <para><mediaobject>
28 29
        <imageobject>
29 30
          <imagedata fileref="layered-architecture.png"></imagedata>
30 31
        </imageobject>
31
      </mediaobject>BEER3 Core consists of the parts which do not change
32
      </mediaobject>Fluid Core consists of the parts which do not change
32 33
    depending on the environment, such as the template parser.</para>
33 34

  
34 35
    <para>The upper layer, consisting of the Standard View Helpers and the
35 36
    TemplateView, are currently FLOW3-specific, but there will be separate
36 37
    layers for different contexts (like TYPO3 v4) which provide standard view
37
    helpers adjusted to the different platforms, different BEER3
38
    helpers adjusted to the different platforms, different Fluid
38 39
    initialization code, etc.</para>
39 40
  </section>
40 41

  
41 42
  <section>
42 43
    <title>The Core</title>
43 44

  
44
    <para>BEER3 Core consists of the following components:</para>
45
    <para>Fluid Core consists of the following components:</para>
45 46

  
46 47
    <para><itemizedlist>
47 48
        <listitem>
......
71 72
          <para>The SyntaxTree is implemented using a
72 73
          <emphasis>Composite</emphasis> design pattern, with all syntax tree
73 74
          nodes extending
74
          <classname>F3::Fluid::Core::SyntaxTree::AbstractNode</classname>.</para>
75
          <classname>F3\Fluid\Core\SyntaxTree\AbstractNode</classname>.</para>
75 76
        </listitem>
76 77

  
77 78
        <listitem>
78
          <para>Call the <methodname>render(F3::Fluid::Core::VariableContainer
79
          <para>Call the <methodname>render(\F3\Fluid\Core\VariableContainer
79 80
          $variableContainer)</methodname> method. This method needs a
80 81
          <classname>VariableContainer</classname> as argument - this means
81 82
          all bound variables which should be rendered.</para>
UserManual.xml (working copy)
33 33
    each page. Usually, there are common templates, menu structures,
34 34
    ...</para>
35 35

  
36
    <para>To make this possible in BEER3, we created a layout system, which we
36
    <para>To make this possible in Fluid, we created a layout system, which we
37 37
    will introduce in this chapter.</para>
38 38

  
39 39
    <section>
......
41 41

  
42 42
      <para>Every layout is placed in the
43 43
      <filename>Resources/Template/layout</filename> directory, and has the
44
      file ending <filename>.xhtml</filename>. A layout is a normal BEER3
44
      file ending <filename>.xhtml</filename>. A layout is a normal Fluid
45 45
      template file, except there are some parts where the actual content of
46 46
      the target page should be inserted.</para>
47 47

  
48 48
      <para>Below is an example layout:</para>
49 49

  
50
      <para><programlisting>{namespace F3=F3::Fluid::ViewHelpers}
50
      <para><programlisting>{namespace f3=F3\Fluid\ViewHelpers}
51 51
&lt;html&gt;
52 52
&lt;head&gt;&lt;title&gt;My fancy web application&lt;/title&gt;&lt;/head&gt;
53 53
&lt;body&gt;
......
86 86
    <title>Writing your own view helper</title>
87 87

  
88 88
    <para>View Helpers are standard PHP classes, each extending
89
    <classname>F3::Fluid::Core::AbstractViewHelper</classname>. You need to
89
    <classname>F3\Fluid\Core\AbstractViewHelper</classname>. You need to
90 90
    implement at least two methods to write a view helper:</para>
91 91

  
92 92
    <para><itemizedlist>
......
140 140

  
141 141
          <listitem>
142 142
            <para><code>$this-&gt;variableContainer</code> is an instance of
143
            <classname>F3::Fluid::Core::VariableContainer</classname>, so you
143
            <classname>F3\Fluid\Core\VariableContainer</classname>, so you
144 144
            have access to all variables registered in the template at the
145 145
            given point.</para>
146 146

  
......
218 218

  
219 219
        <para>To make this work, the <code>&lt;f3:if&gt;</code>-tag implements
220 220
        the
221
        <interfacename>F3::Fluid::Core::Facets::SubNodeAccessInterface</interfacename>,
221
        <interfacename>F3\Fluid\Core\Facets\SubNodeAccessInterface</interfacename>,
222 222
        which consists of a <methodname>setChildren(array
223 223
        $childNodes)</methodname> method being called before the
224 224
        <methodname>render()</methodname> method is triggered. Then, it can