View Javadoc

1   // Do not edit this file!  It was generated by Melati POEM's DSD preprocessor.
2   
3   package org.paneris.melati.site.model.generated;
4   
5   
6   import java.sql.Timestamp;
7   import org.melati.poem.AccessPoemException;
8   import org.melati.poem.Column;
9   import org.melati.poem.Field;
10  import org.melati.poem.JdbcPersistent;
11  import org.melati.poem.NoSuchRowPoemException;
12  import org.melati.poem.ValidationPoemException;
13  import org.paneris.melati.site.model.Page;
14  import org.paneris.melati.site.model.PageTable;
15  import org.paneris.melati.site.model.SiteDatabaseTables;
16  import org.paneris.melati.site.model.Style;
17  import org.paneris.melati.site.model.Template;
18  
19  
20  /**
21   * Melati POEM generated abstract base class for a <code>Persistent</code> 
22   * <code>Page</code> Object.
23   *
24   * @see org.melati.poem.prepro.TableDef#generatePersistentBaseJava 
25   */
26  public abstract class PageBase extends JdbcPersistent {
27  
28  
29   /**
30    * Retrieves the Database object.
31    * 
32    * @see org.melati.poem.prepro.TableDef#generatePersistentBaseJava 
33    * @return the database
34    */
35    public SiteDatabaseTables getSiteDatabaseTables() {
36      return (SiteDatabaseTables)getDatabase();
37    }
38  
39  
40   /**
41    * Retrieves the  <code>PageTable</code> table 
42    * which this <code>Persistent</code> is from.
43    * 
44    * @see org.melati.poem.prepro.TableDef#generatePersistentBaseJava 
45    * @return the PageTable
46    */
47    public PageTable getPageTable() {
48      return (PageTable)getTable();
49    }
50  
51    private PageTable _getPageTable() {
52      return (PageTable)getTable();
53    }
54  
55    // Fields in this table 
56   /**
57    * id 
58    */
59    protected Integer id;
60   /**
61    * name - A file system name, no spaces or special characters 
62    */
63    protected String name;
64   /**
65    * Display Name - The full name used in the TITLE. 
66    */
67    protected String displayname;
68   /**
69    * Display order - A rank determining where the page appears in a list 
70    */
71    protected Integer displayorder;
72   /**
73    * display - Whether to display this page 
74    */
75    protected Boolean display;
76   /**
77    * deleted - Soft delete 
78    */
79    protected Boolean deleted;
80   /**
81    * Last encached - When the page was encached; cleared when the page is 
82    * updated 
83    */
84    protected Timestamp lastencached;
85   /**
86    * parent - The parent page (empty for Home).  
87    */
88    protected Integer parent;
89   /**
90    * template - The name of the layout for this page 
91    */
92    protected Integer template;
93   /**
94    * style - The name of the CSS class for this page 
95    */
96    protected Integer style;
97  
98  
99   /**
100   * Retrieves the <code>Id</code> value, without locking, 
101   * for this <code>Page</code> <code>Persistent</code>.
102   *
103   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
104   * @return the Integer id
105   */
106   public Integer getId_unsafe() {
107     return id;
108   }
109 
110 
111  /**
112   * Sets the <code>Id</code> value directly, without checking, 
113   * for this Page <code>Persistent</code>.
114   * 
115   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
116   * @param cooked  the pre-validated value to set
117   */
118   public void setId_unsafe(Integer cooked) {
119     id = cooked;
120   }
121 
122  /**
123   * Retrieves the Id value, with locking, for this 
124   * <code>Page</code> <code>Persistent</code>.
125   * 
126   * @generator org.melati.poem.prepro.AtomFieldDef#generateBaseMethods 
127   * @throws AccessPoemException 
128   *         if the current <code>AccessToken</code> 
129   *         does not confer write access rights 
130   * @return the value of the field <code>Id</code> for this 
131   *         <code>Page</code> <code>Persistent</code>  
132   */
133 
134   public Integer getId()
135       throws AccessPoemException {
136     readLock();
137     return getId_unsafe();
138   }
139 
140 
141  /**
142   * Sets the <code>Id</code> value, with checking, for this 
143   * <code>Page</code> <code>Persistent</code>.
144   * 
145   * @generator org.melati.poem.prepro.AtomFieldDef#generateBaseMethods  
146   * @param cooked  a validated <code>int</code> 
147   * @throws AccessPoemException 
148   *         if the current <code>AccessToken</code> 
149   *         does not confer write access rights
150   * @throws ValidationPoemException 
151   *         if the value is not valid
152   */
153   public void setId(Integer cooked)
154       throws AccessPoemException, ValidationPoemException {
155     _getPageTable().getIdColumn().
156       getType().assertValidCooked(cooked);
157     writeLock();
158     setId_unsafe(cooked);
159   }
160 
161  /**
162   * Sets the <code>Id</code> value, with checking, for this 
163   * <code>Page</code> <code>Persistent</code>.
164   * 
165   * @generator org.melati.poem.prepro.IntegerFieldDef#generateBaseMethods 
166   * @param cooked  a validated <code>int</code>
167   * @throws AccessPoemException 
168   *         if the current <code>AccessToken</code> 
169   *         does not confer write access rights
170   * @throws ValidationPoemException 
171   *         if the value is not valid
172   */
173 
174   public final void setId(int cooked)
175       throws AccessPoemException, ValidationPoemException {
176     setId(new Integer(cooked));
177   }
178 
179 
180  /**
181   * Retrieves the <code>Id</code> value as a <code>Field</code>
182   * from this <code>Page</code> <code>Persistent</code>.
183   * 
184   * @see org.melati.poem.prepro.FieldDef#generateFieldCreator 
185   * @throws AccessPoemException 
186   *         if the current <code>AccessToken</code> 
187   *         does not confer write access rights
188   * @return the Integer id
189   */
190   public Field getIdField() throws AccessPoemException {
191     Column c = _getPageTable().getIdColumn();
192     return new Field(c.getRaw(this), c);
193   }
194 
195 
196  /**
197   * Retrieves the <code>Name</code> value, without locking, 
198   * for this <code>Page</code> <code>Persistent</code>.
199   *
200   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
201   * @return the String name
202   */
203   public String getName_unsafe() {
204     return name;
205   }
206 
207 
208  /**
209   * Sets the <code>Name</code> value directly, without checking, 
210   * for this Page <code>Persistent</code>.
211   * 
212   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
213   * @param cooked  the pre-validated value to set
214   */
215   public void setName_unsafe(String cooked) {
216     name = cooked;
217   }
218 
219  /**
220   * Retrieves the Name value, with locking, for this 
221   * <code>Page</code> <code>Persistent</code>.
222   * Field description: 
223   *   A file system name, no spaces or special characters 
224   * 
225   * @generator org.melati.poem.prepro.AtomFieldDef#generateBaseMethods 
226   * @throws AccessPoemException 
227   *         if the current <code>AccessToken</code> 
228   *         does not confer write access rights 
229   * @return the value of the field <code>Name</code> for this 
230   *         <code>Page</code> <code>Persistent</code>  
231   */
232 
233   public String getName()
234       throws AccessPoemException {
235     readLock();
236     return getName_unsafe();
237   }
238 
239 
240  /**
241   * Sets the <code>Name</code> value, with checking, for this 
242   * <code>Page</code> <code>Persistent</code>.
243   * Field description: 
244   *   A file system name, no spaces or special characters 
245   * 
246   * @generator org.melati.poem.prepro.AtomFieldDef#generateBaseMethods  
247   * @param cooked  a validated <code>int</code> 
248   * @throws AccessPoemException 
249   *         if the current <code>AccessToken</code> 
250   *         does not confer write access rights
251   * @throws ValidationPoemException 
252   *         if the value is not valid
253   */
254   public void setName(String cooked)
255       throws AccessPoemException, ValidationPoemException {
256     _getPageTable().getNameColumn().
257       getType().assertValidCooked(cooked);
258     writeLock();
259     setName_unsafe(cooked);
260   }
261 
262 
263  /**
264   * Retrieves the <code>Name</code> value as a <code>Field</code>
265   * from this <code>Page</code> <code>Persistent</code>.
266   * 
267   * @see org.melati.poem.prepro.FieldDef#generateFieldCreator 
268   * @throws AccessPoemException 
269   *         if the current <code>AccessToken</code> 
270   *         does not confer write access rights
271   * @return the String name
272   */
273   public Field getNameField() throws AccessPoemException {
274     Column c = _getPageTable().getNameColumn();
275     return new Field(c.getRaw(this), c);
276   }
277 
278 
279  /**
280   * Retrieves the <code>Displayname</code> value, without locking, 
281   * for this <code>Page</code> <code>Persistent</code>.
282   *
283   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
284   * @return the String displayname
285   */
286   public String getDisplayname_unsafe() {
287     return displayname;
288   }
289 
290 
291  /**
292   * Sets the <code>Displayname</code> value directly, without checking, 
293   * for this Page <code>Persistent</code>.
294   * 
295   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
296   * @param cooked  the pre-validated value to set
297   */
298   public void setDisplayname_unsafe(String cooked) {
299     displayname = cooked;
300   }
301 
302  /**
303   * Retrieves the Displayname value, with locking, for this 
304   * <code>Page</code> <code>Persistent</code>.
305   * Field description: 
306   *   The full name used in the TITLE. 
307   * 
308   * @generator org.melati.poem.prepro.AtomFieldDef#generateBaseMethods 
309   * @throws AccessPoemException 
310   *         if the current <code>AccessToken</code> 
311   *         does not confer write access rights 
312   * @return the value of the field <code>Displayname</code> for this 
313   *         <code>Page</code> <code>Persistent</code>  
314   */
315 
316   public String getDisplayname()
317       throws AccessPoemException {
318     readLock();
319     return getDisplayname_unsafe();
320   }
321 
322 
323  /**
324   * Sets the <code>Displayname</code> value, with checking, for this 
325   * <code>Page</code> <code>Persistent</code>.
326   * Field description: 
327   *   The full name used in the TITLE. 
328   * 
329   * @generator org.melati.poem.prepro.AtomFieldDef#generateBaseMethods  
330   * @param cooked  a validated <code>int</code> 
331   * @throws AccessPoemException 
332   *         if the current <code>AccessToken</code> 
333   *         does not confer write access rights
334   * @throws ValidationPoemException 
335   *         if the value is not valid
336   */
337   public void setDisplayname(String cooked)
338       throws AccessPoemException, ValidationPoemException {
339     _getPageTable().getDisplaynameColumn().
340       getType().assertValidCooked(cooked);
341     writeLock();
342     setDisplayname_unsafe(cooked);
343   }
344 
345 
346  /**
347   * Retrieves the <code>Displayname</code> value as a <code>Field</code>
348   * from this <code>Page</code> <code>Persistent</code>.
349   * 
350   * @see org.melati.poem.prepro.FieldDef#generateFieldCreator 
351   * @throws AccessPoemException 
352   *         if the current <code>AccessToken</code> 
353   *         does not confer write access rights
354   * @return the String displayname
355   */
356   public Field getDisplaynameField() throws AccessPoemException {
357     Column c = _getPageTable().getDisplaynameColumn();
358     return new Field(c.getRaw(this), c);
359   }
360 
361 
362  /**
363   * Retrieves the <code>Displayorder</code> value, without locking, 
364   * for this <code>Page</code> <code>Persistent</code>.
365   *
366   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
367   * @return the Integer displayorder
368   */
369   public Integer getDisplayorder_unsafe() {
370     return displayorder;
371   }
372 
373 
374  /**
375   * Sets the <code>Displayorder</code> value directly, without checking, 
376   * for this Page <code>Persistent</code>.
377   * 
378   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
379   * @param cooked  the pre-validated value to set
380   */
381   public void setDisplayorder_unsafe(Integer cooked) {
382     displayorder = cooked;
383   }
384 
385  /**
386   * Retrieves the Displayorder value, with locking, for this 
387   * <code>Page</code> <code>Persistent</code>.
388   * Field description: 
389   *   A rank determining where the page appears in a list 
390   * 
391   * @generator org.melati.poem.prepro.AtomFieldDef#generateBaseMethods 
392   * @throws AccessPoemException 
393   *         if the current <code>AccessToken</code> 
394   *         does not confer write access rights 
395   * @return the value of the field <code>Displayorder</code> for this 
396   *         <code>Page</code> <code>Persistent</code>  
397   */
398 
399   public Integer getDisplayorder()
400       throws AccessPoemException {
401     readLock();
402     return getDisplayorder_unsafe();
403   }
404 
405 
406  /**
407   * Sets the <code>Displayorder</code> value, with checking, for this 
408   * <code>Page</code> <code>Persistent</code>.
409   * Field description: 
410   *   A rank determining where the page appears in a list 
411   * 
412   * @generator org.melati.poem.prepro.AtomFieldDef#generateBaseMethods  
413   * @param cooked  a validated <code>int</code> 
414   * @throws AccessPoemException 
415   *         if the current <code>AccessToken</code> 
416   *         does not confer write access rights
417   * @throws ValidationPoemException 
418   *         if the value is not valid
419   */
420   public void setDisplayorder(Integer cooked)
421       throws AccessPoemException, ValidationPoemException {
422     _getPageTable().getDisplayorderColumn().
423       getType().assertValidCooked(cooked);
424     writeLock();
425     setDisplayorder_unsafe(cooked);
426   }
427 
428  /**
429   * Sets the <code>Displayorder</code> value, with checking, for this 
430   * <code>Page</code> <code>Persistent</code>.
431   * Field description: 
432   *   A rank determining where the page appears in a list 
433   * 
434   * 
435   * @generator org.melati.poem.prepro.IntegerFieldDef#generateBaseMethods 
436   * @param cooked  a validated <code>int</code>
437   * @throws AccessPoemException 
438   *         if the current <code>AccessToken</code> 
439   *         does not confer write access rights
440   * @throws ValidationPoemException 
441   *         if the value is not valid
442   */
443 
444   public final void setDisplayorder(int cooked)
445       throws AccessPoemException, ValidationPoemException {
446     setDisplayorder(new Integer(cooked));
447   }
448 
449 
450  /**
451   * Retrieves the <code>Displayorder</code> value as a <code>Field</code>
452   * from this <code>Page</code> <code>Persistent</code>.
453   * 
454   * @see org.melati.poem.prepro.FieldDef#generateFieldCreator 
455   * @throws AccessPoemException 
456   *         if the current <code>AccessToken</code> 
457   *         does not confer write access rights
458   * @return the Integer displayorder
459   */
460   public Field getDisplayorderField() throws AccessPoemException {
461     Column c = _getPageTable().getDisplayorderColumn();
462     return new Field(c.getRaw(this), c);
463   }
464 
465 
466  /**
467   * Retrieves the <code>Display</code> value, without locking, 
468   * for this <code>Page</code> <code>Persistent</code>.
469   *
470   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
471   * @return the Boolean display
472   */
473   public Boolean getDisplay_unsafe() {
474     return display;
475   }
476 
477 
478  /**
479   * Sets the <code>Display</code> value directly, without checking, 
480   * for this Page <code>Persistent</code>.
481   * 
482   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
483   * @param cooked  the pre-validated value to set
484   */
485   public void setDisplay_unsafe(Boolean cooked) {
486     display = cooked;
487   }
488 
489  /**
490   * Retrieves the Display value, with locking, for this 
491   * <code>Page</code> <code>Persistent</code>.
492   * Field description: 
493   *   Whether to display this page 
494   * 
495   * @generator org.melati.poem.prepro.AtomFieldDef#generateBaseMethods 
496   * @throws AccessPoemException 
497   *         if the current <code>AccessToken</code> 
498   *         does not confer write access rights 
499   * @return the value of the field <code>Display</code> for this 
500   *         <code>Page</code> <code>Persistent</code>  
501   */
502 
503   public Boolean getDisplay()
504       throws AccessPoemException {
505     readLock();
506     return getDisplay_unsafe();
507   }
508 
509 
510  /**
511   * Sets the <code>Display</code> value, with checking, for this 
512   * <code>Page</code> <code>Persistent</code>.
513   * Field description: 
514   *   Whether to display this page 
515   * 
516   * @generator org.melati.poem.prepro.AtomFieldDef#generateBaseMethods  
517   * @param cooked  a validated <code>int</code> 
518   * @throws AccessPoemException 
519   *         if the current <code>AccessToken</code> 
520   *         does not confer write access rights
521   * @throws ValidationPoemException 
522   *         if the value is not valid
523   */
524   public void setDisplay(Boolean cooked)
525       throws AccessPoemException, ValidationPoemException {
526     _getPageTable().getDisplayColumn().
527       getType().assertValidCooked(cooked);
528     writeLock();
529     setDisplay_unsafe(cooked);
530   }
531 
532  /**
533   * Sets the <code>Display</code> value, with checking, 
534   * from a <code>boolean</code>, for this 
535   * <code>Page</code> <code>Persistent</code>.
536   * Field description: 
537   *   Whether to display this page 
538   * 
539   * 
540   * @generator org.melati.poem.prepro.BooleanFieldDef#generateBaseMethods 
541   * @param cooked  a <code>boolean</code> 
542   * @throws AccessPoemException 
543   *         if the current <code>AccessToken</code> 
544   *         does not confer write access rights
545   * @throws ValidationPoemException 
546   *         if the value is not valid
547   */
548 
549   public final void setDisplay(boolean cooked)
550       throws AccessPoemException, ValidationPoemException {
551     setDisplay(cooked ? Boolean.TRUE : Boolean.FALSE);
552   }
553 
554 
555  /**
556   * Retrieves the <code>Display</code> value as a <code>Field</code>
557   * from this <code>Page</code> <code>Persistent</code>.
558   * 
559   * @see org.melati.poem.prepro.FieldDef#generateFieldCreator 
560   * @throws AccessPoemException 
561   *         if the current <code>AccessToken</code> 
562   *         does not confer write access rights
563   * @return the Boolean display
564   */
565   public Field getDisplayField() throws AccessPoemException {
566     Column c = _getPageTable().getDisplayColumn();
567     return new Field(c.getRaw(this), c);
568   }
569 
570 
571  /**
572   * Retrieves the <code>Deleted</code> value, without locking, 
573   * for this <code>Page</code> <code>Persistent</code>.
574   *
575   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
576   * @return the Boolean deleted
577   */
578   public Boolean getDeleted_unsafe() {
579     return deleted;
580   }
581 
582 
583  /**
584   * Sets the <code>Deleted</code> value directly, without checking, 
585   * for this Page <code>Persistent</code>.
586   * 
587   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
588   * @param cooked  the pre-validated value to set
589   */
590   public void setDeleted_unsafe(Boolean cooked) {
591     deleted = cooked;
592   }
593 
594  /**
595   * Retrieves the Deleted value, with locking, for this 
596   * <code>Page</code> <code>Persistent</code>.
597   * Field description: 
598   *   Soft delete 
599   * 
600   * @generator org.melati.poem.prepro.AtomFieldDef#generateBaseMethods 
601   * @throws AccessPoemException 
602   *         if the current <code>AccessToken</code> 
603   *         does not confer write access rights 
604   * @return the value of the field <code>Deleted</code> for this 
605   *         <code>Page</code> <code>Persistent</code>  
606   */
607 
608   public Boolean getDeleted()
609       throws AccessPoemException {
610     readLock();
611     return getDeleted_unsafe();
612   }
613 
614 
615  /**
616   * Sets the <code>Deleted</code> value, with checking, for this 
617   * <code>Page</code> <code>Persistent</code>.
618   * Field description: 
619   *   Soft delete 
620   * 
621   * @generator org.melati.poem.prepro.AtomFieldDef#generateBaseMethods  
622   * @param cooked  a validated <code>int</code> 
623   * @throws AccessPoemException 
624   *         if the current <code>AccessToken</code> 
625   *         does not confer write access rights
626   * @throws ValidationPoemException 
627   *         if the value is not valid
628   */
629   public void setDeleted(Boolean cooked)
630       throws AccessPoemException, ValidationPoemException {
631     _getPageTable().getDeletedColumn().
632       getType().assertValidCooked(cooked);
633     writeLock();
634     setDeleted_unsafe(cooked);
635   }
636 
637  /**
638   * Sets the <code>Deleted</code> value, with checking, 
639   * from a <code>boolean</code>, for this 
640   * <code>Page</code> <code>Persistent</code>.
641   * Field description: 
642   *   Soft delete 
643   * 
644   * 
645   * @generator org.melati.poem.prepro.BooleanFieldDef#generateBaseMethods 
646   * @param cooked  a <code>boolean</code> 
647   * @throws AccessPoemException 
648   *         if the current <code>AccessToken</code> 
649   *         does not confer write access rights
650   * @throws ValidationPoemException 
651   *         if the value is not valid
652   */
653 
654   public final void setDeleted(boolean cooked)
655       throws AccessPoemException, ValidationPoemException {
656     setDeleted(cooked ? Boolean.TRUE : Boolean.FALSE);
657   }
658 
659 
660  /**
661   * Retrieves the <code>Deleted</code> value as a <code>Field</code>
662   * from this <code>Page</code> <code>Persistent</code>.
663   * 
664   * @see org.melati.poem.prepro.FieldDef#generateFieldCreator 
665   * @throws AccessPoemException 
666   *         if the current <code>AccessToken</code> 
667   *         does not confer write access rights
668   * @return the Boolean deleted
669   */
670   public Field getDeletedField() throws AccessPoemException {
671     Column c = _getPageTable().getDeletedColumn();
672     return new Field(c.getRaw(this), c);
673   }
674 
675 
676  /**
677   * Retrieves the <code>Lastencached</code> value, without locking, 
678   * for this <code>Page</code> <code>Persistent</code>.
679   *
680   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
681   * @return the Timestamp lastencached
682   */
683   public Timestamp getLastencached_unsafe() {
684     return lastencached;
685   }
686 
687 
688  /**
689   * Sets the <code>Lastencached</code> value directly, without checking, 
690   * for this Page <code>Persistent</code>.
691   * 
692   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
693   * @param cooked  the pre-validated value to set
694   */
695   public void setLastencached_unsafe(Timestamp cooked) {
696     lastencached = cooked;
697   }
698 
699  /**
700   * Retrieves the Lastencached value, with locking, for this 
701   * <code>Page</code> <code>Persistent</code>.
702   * Field description: 
703   *   When the page was encached; cleared when the page is updated 
704   * 
705   * @generator org.melati.poem.prepro.AtomFieldDef#generateBaseMethods 
706   * @throws AccessPoemException 
707   *         if the current <code>AccessToken</code> 
708   *         does not confer write access rights 
709   * @return the value of the field <code>Lastencached</code> for this 
710   *         <code>Page</code> <code>Persistent</code>  
711   */
712 
713   public Timestamp getLastencached()
714       throws AccessPoemException {
715     readLock();
716     return getLastencached_unsafe();
717   }
718 
719 
720  /**
721   * Sets the <code>Lastencached</code> value, with checking, for this 
722   * <code>Page</code> <code>Persistent</code>.
723   * Field description: 
724   *   When the page was encached; cleared when the page is updated 
725   * 
726   * @generator org.melati.poem.prepro.AtomFieldDef#generateBaseMethods  
727   * @param cooked  a validated <code>int</code> 
728   * @throws AccessPoemException 
729   *         if the current <code>AccessToken</code> 
730   *         does not confer write access rights
731   * @throws ValidationPoemException 
732   *         if the value is not valid
733   */
734   public void setLastencached(Timestamp cooked)
735       throws AccessPoemException, ValidationPoemException {
736     _getPageTable().getLastencachedColumn().
737       getType().assertValidCooked(cooked);
738     writeLock();
739     setLastencached_unsafe(cooked);
740   }
741 
742 
743  /**
744   * Retrieves the <code>Lastencached</code> value as a <code>Field</code>
745   * from this <code>Page</code> <code>Persistent</code>.
746   * 
747   * @see org.melati.poem.prepro.FieldDef#generateFieldCreator 
748   * @throws AccessPoemException 
749   *         if the current <code>AccessToken</code> 
750   *         does not confer write access rights
751   * @return the Timestamp lastencached
752   */
753   public Field getLastencachedField() throws AccessPoemException {
754     Column c = _getPageTable().getLastencachedColumn();
755     return new Field(c.getRaw(this), c);
756   }
757 
758 
759  /**
760   * Retrieves the <code>Parent</code> value, without locking, 
761   * for this <code>Page</code> <code>Persistent</code>.
762   *
763   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
764   * @return the Integer parent
765   */
766   public Integer getParent_unsafe() {
767     return parent;
768   }
769 
770 
771  /**
772   * Sets the <code>Parent</code> value directly, without checking, 
773   * for this Page <code>Persistent</code>.
774   * 
775   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
776   * @param cooked  the pre-validated value to set
777   */
778   public void setParent_unsafe(Integer cooked) {
779     parent = cooked;
780   }
781 
782  /**
783   * Retrieves the Table Row Object ID. 
784   *
785   * @generator org.melati.poem.prepro.ReferenceFieldDef#generateBaseMethods 
786   * @throws AccessPoemException  
787   *         if the current <code>AccessToken</code> 
788   *         does not confer read access rights 
789   * @return the TROID as an <code>Integer</code> 
790   */
791 
792   public Integer getParentTroid()
793       throws AccessPoemException {
794     readLock();
795     return getParent_unsafe();
796   }
797 
798 
799  /**
800   * Sets the Table Row Object ID. 
801   * 
802   * @generator org.melati.poem.prepro.ReferenceFieldDef#generateBaseMethods 
803   * @param raw  a Table Row Object Id 
804   * @throws AccessPoemException  
805   *         if the current <code>AccessToken</code> 
806   *         does not confer write access rights
807   */
808   public void setParentTroid(Integer raw)
809       throws AccessPoemException {
810     setParent(raw == null ? null : 
811         getSiteDatabaseTables().getPageTable().getPageObject(raw));
812   }
813 
814 
815  /**
816   * Retrieves the <code>Parent</code> object referred to.
817   *  
818   * @generator org.melati.poem.prepro.ReferenceFieldDef#generateBaseMethods 
819   * @throws AccessPoemException  
820   *         if the current <code>AccessToken</code> 
821   *         does not confer read access rights 
822   * @throws NoSuchRowPoemException  
823   *         if the <code>Persistent</code> has yet to be allocated a TROID 
824   * @return the <code>Parent</code> as a <code>Page</code> 
825   */
826   public Page getParent()
827       throws AccessPoemException, NoSuchRowPoemException {
828     Integer troid = getParentTroid();
829     return troid == null ? null :
830         getSiteDatabaseTables().getPageTable().getPageObject(troid);
831   }
832 
833 
834  /**
835   * Set the Parent.
836   * 
837   * @generator org.melati.poem.prepro.ReferenceFieldDef#generateBaseMethods 
838   * @param cooked  a validated <code>Page</code>
839   * @throws AccessPoemException  
840   *         if the current <code>AccessToken</code> 
841   *         does not confer write access rights 
842   */
843   public void setParent(Page cooked)
844       throws AccessPoemException {
845     _getPageTable().
846       getParentColumn().
847         getType().assertValidCooked(cooked);
848     writeLock();
849     if (cooked == null)
850       setParent_unsafe(null);
851     else {
852       cooked.existenceLock();
853       setParent_unsafe(cooked.troid());
854     }
855   }
856 
857 
858  /**
859   * Retrieves the <code>Parent</code> value as a <code>Field</code>
860   * from this <code>Page</code> <code>Persistent</code>.
861   * 
862   * @see org.melati.poem.prepro.FieldDef#generateFieldCreator 
863   * @throws AccessPoemException 
864   *         if the current <code>AccessToken</code> 
865   *         does not confer write access rights
866   * @return the Integer parent
867   */
868   public Field getParentField() throws AccessPoemException {
869     Column c = _getPageTable().getParentColumn();
870     return new Field(c.getRaw(this), c);
871   }
872 
873 
874  /**
875   * Retrieves the <code>Template</code> value, without locking, 
876   * for this <code>Page</code> <code>Persistent</code>.
877   *
878   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
879   * @return the Integer template
880   */
881   public Integer getTemplate_unsafe() {
882     return template;
883   }
884 
885 
886  /**
887   * Sets the <code>Template</code> value directly, without checking, 
888   * for this Page <code>Persistent</code>.
889   * 
890   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
891   * @param cooked  the pre-validated value to set
892   */
893   public void setTemplate_unsafe(Integer cooked) {
894     template = cooked;
895   }
896 
897  /**
898   * Retrieves the Table Row Object ID. 
899   *
900   * @generator org.melati.poem.prepro.ReferenceFieldDef#generateBaseMethods 
901   * @throws AccessPoemException  
902   *         if the current <code>AccessToken</code> 
903   *         does not confer read access rights 
904   * @return the TROID as an <code>Integer</code> 
905   */
906 
907   public Integer getTemplateTroid()
908       throws AccessPoemException {
909     readLock();
910     return getTemplate_unsafe();
911   }
912 
913 
914  /**
915   * Sets the Table Row Object ID. 
916   * 
917   * @generator org.melati.poem.prepro.ReferenceFieldDef#generateBaseMethods 
918   * @param raw  a Table Row Object Id 
919   * @throws AccessPoemException  
920   *         if the current <code>AccessToken</code> 
921   *         does not confer write access rights
922   */
923   public void setTemplateTroid(Integer raw)
924       throws AccessPoemException {
925     setTemplate(raw == null ? null : 
926         (Template)getSiteDatabaseTables().getTemplateTable().getTemplateObject(raw));
927   }
928 
929 
930  /**
931   * Retrieves the <code>Template</code> object referred to.
932   *  
933   * @generator org.melati.poem.prepro.ReferenceFieldDef#generateBaseMethods 
934   * @throws AccessPoemException  
935   *         if the current <code>AccessToken</code> 
936   *         does not confer read access rights 
937   * @throws NoSuchRowPoemException  
938   *         if the <code>Persistent</code> has yet to be allocated a TROID 
939   * @return the <code>Template</code> as a <code>Template</code> 
940   */
941   public Template getTemplate()
942       throws AccessPoemException, NoSuchRowPoemException {
943     Integer troid = getTemplateTroid();
944     return troid == null ? null :
945         (Template)getSiteDatabaseTables().getTemplateTable().getTemplateObject(troid);
946   }
947 
948 
949  /**
950   * Set the Template.
951   * 
952   * @generator org.melati.poem.prepro.ReferenceFieldDef#generateBaseMethods 
953   * @param cooked  a validated <code>Template</code>
954   * @throws AccessPoemException  
955   *         if the current <code>AccessToken</code> 
956   *         does not confer write access rights 
957   */
958   public void setTemplate(Template cooked)
959       throws AccessPoemException {
960     _getPageTable().
961       getTemplateColumn().
962         getType().assertValidCooked(cooked);
963     writeLock();
964     if (cooked == null)
965       setTemplate_unsafe(null);
966     else {
967       cooked.existenceLock();
968       setTemplate_unsafe(cooked.troid());
969     }
970   }
971 
972 
973  /**
974   * Retrieves the <code>Template</code> value as a <code>Field</code>
975   * from this <code>Page</code> <code>Persistent</code>.
976   * 
977   * @see org.melati.poem.prepro.FieldDef#generateFieldCreator 
978   * @throws AccessPoemException 
979   *         if the current <code>AccessToken</code> 
980   *         does not confer write access rights
981   * @return the Integer template
982   */
983   public Field getTemplateField() throws AccessPoemException {
984     Column c = _getPageTable().getTemplateColumn();
985     return new Field(c.getRaw(this), c);
986   }
987 
988 
989  /**
990   * Retrieves the <code>Style</code> value, without locking, 
991   * for this <code>Page</code> <code>Persistent</code>.
992   *
993   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
994   * @return the Integer style
995   */
996   public Integer getStyle_unsafe() {
997     return style;
998   }
999 
1000 
1001  /**
1002   * Sets the <code>Style</code> value directly, without checking, 
1003   * for this Page <code>Persistent</code>.
1004   * 
1005   * @see org.melati.poem.prepro.FieldDef#generateBaseMethods 
1006   * @param cooked  the pre-validated value to set
1007   */
1008   public void setStyle_unsafe(Integer cooked) {
1009     style = cooked;
1010   }
1011 
1012  /**
1013   * Retrieves the Table Row Object ID. 
1014   *
1015   * @generator org.melati.poem.prepro.ReferenceFieldDef#generateBaseMethods 
1016   * @throws AccessPoemException  
1017   *         if the current <code>AccessToken</code> 
1018   *         does not confer read access rights 
1019   * @return the TROID as an <code>Integer</code> 
1020   */
1021 
1022   public Integer getStyleTroid()
1023       throws AccessPoemException {
1024     readLock();
1025     return getStyle_unsafe();
1026   }
1027 
1028 
1029  /**
1030   * Sets the Table Row Object ID. 
1031   * 
1032   * @generator org.melati.poem.prepro.ReferenceFieldDef#generateBaseMethods 
1033   * @param raw  a Table Row Object Id 
1034   * @throws AccessPoemException  
1035   *         if the current <code>AccessToken</code> 
1036   *         does not confer write access rights
1037   */
1038   public void setStyleTroid(Integer raw)
1039       throws AccessPoemException {
1040     setStyle(raw == null ? null : 
1041         getSiteDatabaseTables().getStyleTable().getStyleObject(raw));
1042   }
1043 
1044 
1045  /**
1046   * Retrieves the <code>Style</code> object referred to.
1047   *  
1048   * @generator org.melati.poem.prepro.ReferenceFieldDef#generateBaseMethods 
1049   * @throws AccessPoemException  
1050   *         if the current <code>AccessToken</code> 
1051   *         does not confer read access rights 
1052   * @throws NoSuchRowPoemException  
1053   *         if the <code>Persistent</code> has yet to be allocated a TROID 
1054   * @return the <code>Style</code> as a <code>Style</code> 
1055   */
1056   public Style getStyle()
1057       throws AccessPoemException, NoSuchRowPoemException {
1058     Integer troid = getStyleTroid();
1059     return troid == null ? null :
1060         getSiteDatabaseTables().getStyleTable().getStyleObject(troid);
1061   }
1062 
1063 
1064  /**
1065   * Set the Style.
1066   * 
1067   * @generator org.melati.poem.prepro.ReferenceFieldDef#generateBaseMethods 
1068   * @param cooked  a validated <code>Style</code>
1069   * @throws AccessPoemException  
1070   *         if the current <code>AccessToken</code> 
1071   *         does not confer write access rights 
1072   */
1073   public void setStyle(Style cooked)
1074       throws AccessPoemException {
1075     _getPageTable().
1076       getStyleColumn().
1077         getType().assertValidCooked(cooked);
1078     writeLock();
1079     if (cooked == null)
1080       setStyle_unsafe(null);
1081     else {
1082       cooked.existenceLock();
1083       setStyle_unsafe(cooked.troid());
1084     }
1085   }
1086 
1087 
1088  /**
1089   * Retrieves the <code>Style</code> value as a <code>Field</code>
1090   * from this <code>Page</code> <code>Persistent</code>.
1091   * 
1092   * @see org.melati.poem.prepro.FieldDef#generateFieldCreator 
1093   * @throws AccessPoemException 
1094   *         if the current <code>AccessToken</code> 
1095   *         does not confer write access rights
1096   * @return the Integer style
1097   */
1098   public Field getStyleField() throws AccessPoemException {
1099     Column c = _getPageTable().getStyleColumn();
1100     return new Field(c.getRaw(this), c);
1101   }
1102 }
1103