geirm       2003/10/26 05:14:54

  Modified:    xdocs    developer-guide.xml
               docs     developer-guide.html
  Log:
  added FAQ entry re custom directives, and added links to each faq entry
  
  Revision  Changes    Path
  1.73      +31 -2     jakarta-velocity/xdocs/developer-guide.xml
  
  Index: developer-guide.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-velocity/xdocs/developer-guide.xml,v
  retrieving revision 1.72
  retrieving revision 1.73
  diff -u -r1.72 -r1.73
  --- developer-guide.xml       26 Oct 2003 11:22:03 -0000      1.72
  +++ developer-guide.xml       26 Oct 2003 13:14:54 -0000      1.73
  @@ -114,6 +114,11 @@
   
   <li>
   <a href="developer-guide.html#FAQ (Frequently Asked Questions)">FAQ (Frequently 
Asked Questions)</a>
  +<ul>
  +    <li><a href="#FAQ1">Why Can't I Access Class Members and Constants from 
VTL?</a></li>
  +    <li><a href="#FAQ2">Where does Velocity look for Templates?</a></li>
  +    <li><a href="#FAQ3">How to I tell Velocity to use my custom directive?</a></li>
  +</ul>
   </li>
   
   <li>
  @@ -2869,7 +2874,7 @@
   a separate document.
   </p>
   
  -<strong>Why Can't I Access Class Members and Constants from VTL?</strong>
  +<a name="FAQ1"><strong>Why Can't I Access Class Members and Constants from 
VTL?</strong></a>
   
    <p>
    The short answer is because we don't introspect for fields.  We don't do that
  @@ -2915,7 +2920,7 @@
        <code>FieldMethodizer</code> yourself. (And we still recommend you provide 
accessors....)
     </p>
   
  -  <strong>Where does Velocity look for Templates?</strong>
  +  <a name="FAQ2"><strong>Where does Velocity look for Templates?</strong></a>
   
     <p>
       By default, without any configuration on your part, Velocity will look
  @@ -2939,6 +2944,30 @@
         configuration keys, values and defaults</a>.
        </p>
   
  +
  +    <a name="FAQ3"><strong>How to I tell Velocity to use my custom 
directive?</strong></a>
  +
  +    <p>
  +        You can extend the functionality of Velocity by writing your own
  +        custom directives.  For example, see the <code>LocalDirective</code>
  +        in <code>contrib/temporary/LocalDirective</code>.  To get Velocity
  +        to load your directive, all you need to do is include the
  +        following property in your configuration of the Velocity engine :
  +    </p>
  +
  +    <source>
  +        <![CDATA[
  +        userdirective = LocalDirective
  +        ]]>
  +    <source>
  +
  +     <p>
  +        where you would of course replace <i>LocalDirective</i> above with your
  +        class name.  Then, ensure that your class is in the classpath, and
  +         all should be well.
  +     </p>
  +    </source>
  +    </source>
   </section>
   
   <section name="Summary">
  
  
  
  1.106     +39 -2     jakarta-velocity/docs/developer-guide.html
  
  Index: developer-guide.html
  ===================================================================
  RCS file: /home/cvs/jakarta-velocity/docs/developer-guide.html,v
  retrieving revision 1.105
  retrieving revision 1.106
  diff -u -r1.105 -r1.106
  --- developer-guide.html      26 Oct 2003 11:22:03 -0000      1.105
  +++ developer-guide.html      26 Oct 2003 13:14:54 -0000      1.106
  @@ -249,6 +249,11 @@
   
   <li>
   <a href="developer-guide.html#FAQ (Frequently Asked Questions)">FAQ (Frequently 
Asked Questions)</a>
  +<ul>
  +    <li><a href="#FAQ1">Why Can't I Access Class Members and Constants from 
VTL?</a></li>
  +    <li><a href="#FAQ2">Where does Velocity look for Templates?</a></li>
  +    <li><a href="#FAQ3">How to I tell Velocity to use my custom directive?</a></li>
  +</ul>
   </li>
   
   <li>
  @@ -3629,7 +3634,7 @@
   by developers using Velocity.  As we get more, we will move this out to
   a separate document.
   </p>
  -                                                <strong>Why Can't I Access Class 
Members and Constants from VTL?</strong>
  +                                                <a name="FAQ1"><strong>Why Can't I 
Access Class Members and Constants from VTL?</strong></a>
                                                   <p>
    The short answer is because we don't introspect for fields.  We don't do that
    because we wish to promote the idea that you hide your raw data in your
  @@ -3721,7 +3726,7 @@
        if you are so driven), then you would have to exend / modify the
        <code>FieldMethodizer</code> yourself. (And we still recommend you provide 
accessors....)
     </p>
  -                                                <strong>Where does Velocity look 
for Templates?</strong>
  +                                                <a name="FAQ2"><strong>Where does 
Velocity look for Templates?</strong></a>
                                                   <p>
       By default, without any configuration on your part, Velocity will look
       for templates in files, and look for them in the current directory
  @@ -3741,6 +3746,38 @@
         <a href="developer-guide.html#Velocity Configuration Keys and Values">
         configuration keys, values and defaults</a>.
        </p>
  +                                                <a name="FAQ3"><strong>How to I 
tell Velocity to use my custom directive?</strong></a>
  +                                                <p>
  +        You can extend the functionality of Velocity by writing your own
  +        custom directives.  For example, see the <code>LocalDirective</code>
  +        in <code>contrib/temporary/LocalDirective</code>.  To get Velocity
  +        to load your directive, all you need to do is include the
  +        following property in your configuration of the Velocity engine :
  +    </p>
  +                                                    <div align="left">
  +    <table cellspacing="4" cellpadding="0" border="0">
  +    <tr>
  +      <td bgcolor="#023264" width="1" height="1"><img src="/images/void.gif" 
width="1" height="1" vspace="0" hspace="0" border="0"/></td>
  +      <td bgcolor="#023264" height="1"><img src="/images/void.gif" width="1" 
height="1" vspace="0" hspace="0" border="0"/></td>
  +      <td bgcolor="#023264" width="1" height="1"><img src="/images/void.gif" 
width="1" height="1" vspace="0" hspace="0" border="0"/></td>
  +    </tr>
  +    <tr>
  +      <td bgcolor="#023264" width="1"><img src="/images/void.gif" width="1" 
height="1" vspace="0" hspace="0" border="0"/></td>
  +      <td bgcolor="#ffffff"><pre>
  +        
  +        userdirective = LocalDirective
  +        
  +    
  +    </pre></td>
  +      <td bgcolor="#023264" width="1"><img src="/images/void.gif" width="1" 
height="1" vspace="0" hspace="0" border="0"/></td>
  +    </tr>
  +    <tr>
  +      <td bgcolor="#023264" width="1" height="1"><img src="/images/void.gif" 
width="1" height="1" vspace="0" hspace="0" border="0"/></td>
  +      <td bgcolor="#023264" height="1"><img src="/images/void.gif" width="1" 
height="1" vspace="0" hspace="0" border="0"/></td>
  +      <td bgcolor="#023264" width="1" height="1"><img src="/images/void.gif" 
width="1" height="1" vspace="0" hspace="0" border="0"/></td>
  +    </tr>
  +    </table>
  +    </div>
                               </blockquote>
           </p>
         </td></tr>
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to