1
2
3 package org.melati.poem.generated;
4
5
6 import org.melati.poem.AccessPoemException;
7 import org.melati.poem.BooleanPoemType;
8 import org.melati.poem.Capability;
9 import org.melati.poem.Column;
10 import org.melati.poem.Database;
11 import org.melati.poem.DefinitionSource;
12 import org.melati.poem.DisplayLevel;
13 import org.melati.poem.Field;
14 import org.melati.poem.IntegerPoemType;
15 import org.melati.poem.JdbcPersistent;
16 import org.melati.poem.Persistent;
17 import org.melati.poem.PoemDatabaseTables;
18 import org.melati.poem.PoemException;
19 import org.melati.poem.PoemTable;
20 import org.melati.poem.ReferencePoemType;
21 import org.melati.poem.Searchability;
22 import org.melati.poem.StandardIntegrityFix;
23 import org.melati.poem.StringPoemType;
24 import org.melati.poem.TableCategory;
25 import org.melati.poem.TableInfo;
26 import org.melati.poem.TroidPoemType;
27 import org.melati.poem.ValidationPoemException;
28
29
30
31
32
33
34
35
36 public class TableInfoTableBase<T extends TableInfo> extends PoemTable<T> {
37
38 private Column<Integer> col_id = null;
39 private Column<String> col_name = null;
40 private Column<String> col_displayname = null;
41 private Column<String> col_description = null;
42 private Column<Integer> col_displayorder = null;
43 private Column<Integer> col_defaultcanread = null;
44 private Column<Integer> col_defaultcanwrite = null;
45 private Column<Integer> col_defaultcandelete = null;
46 private Column<Integer> col_cancreate = null;
47 private Column<Integer> col_cachelimit = null;
48 private Column<Boolean> col_seqcached = null;
49 private Column<Integer> col_category = null;
50
51
52
53
54
55
56
57
58
59
60
61 public TableInfoTableBase(
62 Database database, String name,
63 DefinitionSource definitionSource) throws PoemException {
64 super(database, name, definitionSource);
65 }
66
67
68
69
70
71
72
73
74 public PoemDatabaseTables getPoemDatabaseTables() {
75 return (PoemDatabaseTables)getDatabase();
76 }
77
78
79
80
81
82
83
84 public void init() throws PoemException {
85 super.init();
86 defineColumn(col_id =
87 new Column<Integer>(this, "id",
88 new TroidPoemType(),
89 DefinitionSource.dsd) {
90 public Object getCooked(Persistent g)
91 throws AccessPoemException, PoemException {
92 return ((TableInfo)g).getId();
93 }
94
95 public void setCooked(Persistent g, Object cooked)
96 throws AccessPoemException, ValidationPoemException {
97 ((TableInfo)g).setId((Integer)cooked);
98 }
99
100 public Field<Integer> asField(Persistent g) {
101 return ((TableInfo)g).getIdField();
102 }
103
104 public boolean defaultUserEditable() {
105 return false;
106 }
107
108 public boolean defaultUserCreateable() {
109 return false;
110 }
111
112 public DisplayLevel defaultDisplayLevel() {
113 return DisplayLevel.detail;
114 }
115
116 public int defaultDisplayOrder() {
117 return 0;
118 }
119
120 public String defaultDescription() {
121 return "The Table Row Object ID";
122 }
123
124 public Object getRaw_unsafe(Persistent g)
125 throws AccessPoemException {
126 return ((TableInfo)g).getId_unsafe();
127 }
128
129 public void setRaw_unsafe(Persistent g, Object raw)
130 throws AccessPoemException {
131 ((TableInfo)g).setId_unsafe((Integer)raw);
132 }
133
134 public Object getRaw(Persistent g)
135 throws AccessPoemException {
136 return ((TableInfo)g).getId();
137 }
138
139 public void setRaw(Persistent g, Object raw)
140 throws AccessPoemException {
141 ((TableInfo)g).setId((Integer)raw);
142 }
143 });
144
145 defineColumn(col_name =
146 new Column<String>(this, "name",
147 new StringPoemType(false, 50),
148 DefinitionSource.dsd) {
149 public Object getCooked(Persistent g)
150 throws AccessPoemException, PoemException {
151 return ((TableInfo)g).getName();
152 }
153
154 public void setCooked(Persistent g, Object cooked)
155 throws AccessPoemException, ValidationPoemException {
156 ((TableInfo)g).setName((String)cooked);
157 }
158
159 public Field<String> asField(Persistent g) {
160 return ((TableInfo)g).getNameField();
161 }
162
163 public boolean defaultUserEditable() {
164 return false;
165 }
166
167 public DisplayLevel defaultDisplayLevel() {
168 return DisplayLevel.record;
169 }
170
171 public Searchability defaultSearchability() {
172 return Searchability.no;
173 }
174
175 public int defaultDisplayOrder() {
176 return 1;
177 }
178
179 public String defaultDescription() {
180 return "A code-name for the table";
181 }
182
183 public boolean defaultUnique() {
184 return true;
185 }
186
187 public Object getRaw_unsafe(Persistent g)
188 throws AccessPoemException {
189 return ((TableInfo)g).getName_unsafe();
190 }
191
192 public void setRaw_unsafe(Persistent g, Object raw)
193 throws AccessPoemException {
194 ((TableInfo)g).setName_unsafe((String)raw);
195 }
196
197 public Object getRaw(Persistent g)
198 throws AccessPoemException {
199 return ((TableInfo)g).getName();
200 }
201
202 public void setRaw(Persistent g, Object raw)
203 throws AccessPoemException {
204 ((TableInfo)g).setName((String)raw);
205 }
206 });
207
208 defineColumn(col_displayname =
209 new Column<String>(this, "displayname",
210 new StringPoemType(false, 60),
211 DefinitionSource.dsd) {
212 public Object getCooked(Persistent g)
213 throws AccessPoemException, PoemException {
214 return ((TableInfo)g).getDisplayname();
215 }
216
217 public void setCooked(Persistent g, Object cooked)
218 throws AccessPoemException, ValidationPoemException {
219 ((TableInfo)g).setDisplayname((String)cooked);
220 }
221
222 public Field<String> asField(Persistent g) {
223 return ((TableInfo)g).getDisplaynameField();
224 }
225
226 public DisplayLevel defaultDisplayLevel() {
227 return DisplayLevel.primary;
228 }
229
230 public Integer defaultDisplayOrderPriority() {
231 return new Integer(1);
232 }
233
234 public String defaultDisplayName() {
235 return "Display name";
236 }
237
238 public int defaultDisplayOrder() {
239 return 2;
240 }
241
242 public String defaultDescription() {
243 return "A user-friendly name for the table";
244 }
245
246 public Object getRaw_unsafe(Persistent g)
247 throws AccessPoemException {
248 return ((TableInfo)g).getDisplayname_unsafe();
249 }
250
251 public void setRaw_unsafe(Persistent g, Object raw)
252 throws AccessPoemException {
253 ((TableInfo)g).setDisplayname_unsafe((String)raw);
254 }
255
256 public Object getRaw(Persistent g)
257 throws AccessPoemException {
258 return ((TableInfo)g).getDisplayname();
259 }
260
261 public void setRaw(Persistent g, Object raw)
262 throws AccessPoemException {
263 ((TableInfo)g).setDisplayname((String)raw);
264 }
265 });
266
267 defineColumn(col_description =
268 new Column<String>(this, "description",
269 new StringPoemType(true, -1),
270 DefinitionSource.dsd) {
271 public Object getCooked(Persistent g)
272 throws AccessPoemException, PoemException {
273 return ((TableInfo)g).getDescription();
274 }
275
276 public void setCooked(Persistent g, Object cooked)
277 throws AccessPoemException, ValidationPoemException {
278 ((TableInfo)g).setDescription((String)cooked);
279 }
280
281 public Field<String> asField(Persistent g) {
282 return ((TableInfo)g).getDescriptionField();
283 }
284
285 public DisplayLevel defaultDisplayLevel() {
286 return DisplayLevel.record;
287 }
288
289 public Searchability defaultSearchability() {
290 return Searchability.no;
291 }
292
293 public int defaultDisplayOrder() {
294 return 3;
295 }
296
297 public String defaultDescription() {
298 return "A brief description of the table's function";
299 }
300
301 public int defaultWidth() {
302 return 50;
303 }
304
305 public Object getRaw_unsafe(Persistent g)
306 throws AccessPoemException {
307 return ((TableInfo)g).getDescription_unsafe();
308 }
309
310 public void setRaw_unsafe(Persistent g, Object raw)
311 throws AccessPoemException {
312 ((TableInfo)g).setDescription_unsafe((String)raw);
313 }
314
315 public Object getRaw(Persistent g)
316 throws AccessPoemException {
317 return ((TableInfo)g).getDescription();
318 }
319
320 public void setRaw(Persistent g, Object raw)
321 throws AccessPoemException {
322 ((TableInfo)g).setDescription((String)raw);
323 }
324 });
325
326 defineColumn(col_displayorder =
327 new Column<Integer>(this, "displayorder",
328 new IntegerPoemType(false),
329 DefinitionSource.dsd) {
330 public Object getCooked(Persistent g)
331 throws AccessPoemException, PoemException {
332 return ((TableInfo)g).getDisplayorder();
333 }
334
335 public void setCooked(Persistent g, Object cooked)
336 throws AccessPoemException, ValidationPoemException {
337 ((TableInfo)g).setDisplayorder((Integer)cooked);
338 }
339
340 public Field<Integer> asField(Persistent g) {
341 return ((TableInfo)g).getDisplayorderField();
342 }
343
344 public DisplayLevel defaultDisplayLevel() {
345 return DisplayLevel.summary;
346 }
347
348 public Integer defaultDisplayOrderPriority() {
349 return new Integer(0);
350 }
351
352 public String defaultDisplayName() {
353 return "Display order";
354 }
355
356 public int defaultDisplayOrder() {
357 return 4;
358 }
359
360 public String defaultDescription() {
361 return "A rank determining where the table appears in the list of all tables";
362 }
363
364 public Object getRaw_unsafe(Persistent g)
365 throws AccessPoemException {
366 return ((TableInfo)g).getDisplayorder_unsafe();
367 }
368
369 public void setRaw_unsafe(Persistent g, Object raw)
370 throws AccessPoemException {
371 ((TableInfo)g).setDisplayorder_unsafe((Integer)raw);
372 }
373
374 public Object getRaw(Persistent g)
375 throws AccessPoemException {
376 return ((TableInfo)g).getDisplayorder();
377 }
378
379 public void setRaw(Persistent g, Object raw)
380 throws AccessPoemException {
381 ((TableInfo)g).setDisplayorder((Integer)raw);
382 }
383 });
384
385 defineColumn(col_defaultcanread =
386 new Column<Integer>(this, "defaultcanread",
387 new ReferencePoemType(getPoemDatabaseTables().
388 getCapabilityTable(), true),
389 DefinitionSource.dsd) {
390 public Object getCooked(Persistent g)
391 throws AccessPoemException, PoemException {
392 return ((TableInfo)g).getDefaultcanread();
393 }
394
395 public void setCooked(Persistent g, Object cooked)
396 throws AccessPoemException, ValidationPoemException {
397 ((TableInfo)g).setDefaultcanread((Capability)cooked);
398 }
399
400 public Field<Integer> asField(Persistent g) {
401 return ((TableInfo)g).getDefaultcanreadField();
402 }
403
404 public DisplayLevel defaultDisplayLevel() {
405 return DisplayLevel.record;
406 }
407
408 public Searchability defaultSearchability() {
409 return Searchability.no;
410 }
411
412 public String defaultDisplayName() {
413 return "Default `read' capability";
414 }
415
416 public int defaultDisplayOrder() {
417 return 5;
418 }
419
420 public String defaultDescription() {
421 return "The capability required, by default, for reading the table's records";
422 }
423
424 public Object getRaw_unsafe(Persistent g)
425 throws AccessPoemException {
426 return ((TableInfo)g).getDefaultcanread_unsafe();
427 }
428
429 public void setRaw_unsafe(Persistent g, Object raw)
430 throws AccessPoemException {
431 ((TableInfo)g).setDefaultcanread_unsafe((Integer)raw);
432 }
433
434 public Object getRaw(Persistent g)
435 throws AccessPoemException {
436 return ((TableInfo)g).getDefaultcanreadTroid();
437 }
438
439 public void setRaw(Persistent g, Object raw)
440 throws AccessPoemException {
441 ((TableInfo)g).setDefaultcanreadTroid((Integer)raw);
442 }
443
444 public StandardIntegrityFix defaultIntegrityFix() {
445 return StandardIntegrityFix.clear;
446 }
447 });
448
449 defineColumn(col_defaultcanwrite =
450 new Column<Integer>(this, "defaultcanwrite",
451 new ReferencePoemType(getPoemDatabaseTables().
452 getCapabilityTable(), true),
453 DefinitionSource.dsd) {
454 public Object getCooked(Persistent g)
455 throws AccessPoemException, PoemException {
456 return ((TableInfo)g).getDefaultcanwrite();
457 }
458
459 public void setCooked(Persistent g, Object cooked)
460 throws AccessPoemException, ValidationPoemException {
461 ((TableInfo)g).setDefaultcanwrite((Capability)cooked);
462 }
463
464 public Field<Integer> asField(Persistent g) {
465 return ((TableInfo)g).getDefaultcanwriteField();
466 }
467
468 public DisplayLevel defaultDisplayLevel() {
469 return DisplayLevel.record;
470 }
471
472 public Searchability defaultSearchability() {
473 return Searchability.no;
474 }
475
476 public String defaultDisplayName() {
477 return "Default `write' capability";
478 }
479
480 public int defaultDisplayOrder() {
481 return 6;
482 }
483
484 public String defaultDescription() {
485 return "The capability required, by default, for updating the table's records";
486 }
487
488 public Object getRaw_unsafe(Persistent g)
489 throws AccessPoemException {
490 return ((TableInfo)g).getDefaultcanwrite_unsafe();
491 }
492
493 public void setRaw_unsafe(Persistent g, Object raw)
494 throws AccessPoemException {
495 ((TableInfo)g).setDefaultcanwrite_unsafe((Integer)raw);
496 }
497
498 public Object getRaw(Persistent g)
499 throws AccessPoemException {
500 return ((TableInfo)g).getDefaultcanwriteTroid();
501 }
502
503 public void setRaw(Persistent g, Object raw)
504 throws AccessPoemException {
505 ((TableInfo)g).setDefaultcanwriteTroid((Integer)raw);
506 }
507
508 public StandardIntegrityFix defaultIntegrityFix() {
509 return StandardIntegrityFix.clear;
510 }
511 });
512
513 defineColumn(col_defaultcandelete =
514 new Column<Integer>(this, "defaultcandelete",
515 new ReferencePoemType(getPoemDatabaseTables().
516 getCapabilityTable(), true),
517 DefinitionSource.dsd) {
518 public Object getCooked(Persistent g)
519 throws AccessPoemException, PoemException {
520 return ((TableInfo)g).getDefaultcandelete();
521 }
522
523 public void setCooked(Persistent g, Object cooked)
524 throws AccessPoemException, ValidationPoemException {
525 ((TableInfo)g).setDefaultcandelete((Capability)cooked);
526 }
527
528 public Field<Integer> asField(Persistent g) {
529 return ((TableInfo)g).getDefaultcandeleteField();
530 }
531
532 public DisplayLevel defaultDisplayLevel() {
533 return DisplayLevel.record;
534 }
535
536 public Searchability defaultSearchability() {
537 return Searchability.no;
538 }
539
540 public String defaultDisplayName() {
541 return "Default `delete' capability";
542 }
543
544 public int defaultDisplayOrder() {
545 return 7;
546 }
547
548 public String defaultDescription() {
549 return "The capability required, by default, for deleting the table's records";
550 }
551
552 public Object getRaw_unsafe(Persistent g)
553 throws AccessPoemException {
554 return ((TableInfo)g).getDefaultcandelete_unsafe();
555 }
556
557 public void setRaw_unsafe(Persistent g, Object raw)
558 throws AccessPoemException {
559 ((TableInfo)g).setDefaultcandelete_unsafe((Integer)raw);
560 }
561
562 public Object getRaw(Persistent g)
563 throws AccessPoemException {
564 return ((TableInfo)g).getDefaultcandeleteTroid();
565 }
566
567 public void setRaw(Persistent g, Object raw)
568 throws AccessPoemException {
569 ((TableInfo)g).setDefaultcandeleteTroid((Integer)raw);
570 }
571
572 public StandardIntegrityFix defaultIntegrityFix() {
573 return StandardIntegrityFix.clear;
574 }
575 });
576
577 defineColumn(col_cancreate =
578 new Column<Integer>(this, "cancreate",
579 new ReferencePoemType(getPoemDatabaseTables().
580 getCapabilityTable(), true),
581 DefinitionSource.dsd) {
582 public Object getCooked(Persistent g)
583 throws AccessPoemException, PoemException {
584 return ((TableInfo)g).getCancreate();
585 }
586
587 public void setCooked(Persistent g, Object cooked)
588 throws AccessPoemException, ValidationPoemException {
589 ((TableInfo)g).setCancreate((Capability)cooked);
590 }
591
592 public Field<Integer> asField(Persistent g) {
593 return ((TableInfo)g).getCancreateField();
594 }
595
596 public DisplayLevel defaultDisplayLevel() {
597 return DisplayLevel.record;
598 }
599
600 public Searchability defaultSearchability() {
601 return Searchability.no;
602 }
603
604 public String defaultDisplayName() {
605 return "Default `create' capability";
606 }
607
608 public int defaultDisplayOrder() {
609 return 8;
610 }
611
612 public String defaultDescription() {
613 return "The capability required, by default, for creating records in the table";
614 }
615
616 public Object getRaw_unsafe(Persistent g)
617 throws AccessPoemException {
618 return ((TableInfo)g).getCancreate_unsafe();
619 }
620
621 public void setRaw_unsafe(Persistent g, Object raw)
622 throws AccessPoemException {
623 ((TableInfo)g).setCancreate_unsafe((Integer)raw);
624 }
625
626 public Object getRaw(Persistent g)
627 throws AccessPoemException {
628 return ((TableInfo)g).getCancreateTroid();
629 }
630
631 public void setRaw(Persistent g, Object raw)
632 throws AccessPoemException {
633 ((TableInfo)g).setCancreateTroid((Integer)raw);
634 }
635
636 public StandardIntegrityFix defaultIntegrityFix() {
637 return StandardIntegrityFix.clear;
638 }
639 });
640
641 defineColumn(col_cachelimit =
642 new Column<Integer>(this, "cachelimit",
643 new IntegerPoemType(true),
644 DefinitionSource.dsd) {
645 public Object getCooked(Persistent g)
646 throws AccessPoemException, PoemException {
647 return ((TableInfo)g).getCachelimit();
648 }
649
650 public void setCooked(Persistent g, Object cooked)
651 throws AccessPoemException, ValidationPoemException {
652 ((TableInfo)g).setCachelimit((Integer)cooked);
653 }
654
655 public Field<Integer> asField(Persistent g) {
656 return ((TableInfo)g).getCachelimitField();
657 }
658
659 public DisplayLevel defaultDisplayLevel() {
660 return DisplayLevel.record;
661 }
662
663 public Searchability defaultSearchability() {
664 return Searchability.no;
665 }
666
667 public String defaultDisplayName() {
668 return "Cache size limit";
669 }
670
671 public int defaultDisplayOrder() {
672 return 9;
673 }
674
675 public String defaultDescription() {
676 return "The maximum number of records from the table to keep in the cache";
677 }
678
679 public Object getRaw_unsafe(Persistent g)
680 throws AccessPoemException {
681 return ((TableInfo)g).getCachelimit_unsafe();
682 }
683
684 public void setRaw_unsafe(Persistent g, Object raw)
685 throws AccessPoemException {
686 ((TableInfo)g).setCachelimit_unsafe((Integer)raw);
687 }
688
689 public Object getRaw(Persistent g)
690 throws AccessPoemException {
691 return ((TableInfo)g).getCachelimit();
692 }
693
694 public void setRaw(Persistent g, Object raw)
695 throws AccessPoemException {
696 ((TableInfo)g).setCachelimit((Integer)raw);
697 }
698 });
699
700 defineColumn(col_seqcached =
701 new Column<Boolean>(this, "seqcached",
702 new BooleanPoemType(false),
703 DefinitionSource.dsd) {
704 public Object getCooked(Persistent g)
705 throws AccessPoemException, PoemException {
706 return ((TableInfo)g).getSeqcached();
707 }
708
709 public void setCooked(Persistent g, Object cooked)
710 throws AccessPoemException, ValidationPoemException {
711 ((TableInfo)g).setSeqcached((Boolean)cooked);
712 }
713
714 public Field<Boolean> asField(Persistent g) {
715 return ((TableInfo)g).getSeqcachedField();
716 }
717
718 public DisplayLevel defaultDisplayLevel() {
719 return DisplayLevel.record;
720 }
721
722 public Searchability defaultSearchability() {
723 return Searchability.no;
724 }
725
726 public String defaultDisplayName() {
727 return "Record sequence cached";
728 }
729
730 public int defaultDisplayOrder() {
731 return 10;
732 }
733
734 public String defaultDescription() {
735 return "Whether the display sequence for the table's records is cached";
736 }
737
738 public Object getRaw_unsafe(Persistent g)
739 throws AccessPoemException {
740 return ((TableInfo)g).getSeqcached_unsafe();
741 }
742
743 public void setRaw_unsafe(Persistent g, Object raw)
744 throws AccessPoemException {
745 ((TableInfo)g).setSeqcached_unsafe((Boolean)raw);
746 }
747
748 public Object getRaw(Persistent g)
749 throws AccessPoemException {
750 return ((TableInfo)g).getSeqcached();
751 }
752
753 public void setRaw(Persistent g, Object raw)
754 throws AccessPoemException {
755 ((TableInfo)g).setSeqcached((Boolean)raw);
756 }
757 });
758
759 defineColumn(col_category =
760 new Column<Integer>(this, "category",
761 new ReferencePoemType(getPoemDatabaseTables().
762 getTableCategoryTable(), false),
763 DefinitionSource.dsd) {
764 public Object getCooked(Persistent g)
765 throws AccessPoemException, PoemException {
766 return ((TableInfo)g).getCategory();
767 }
768
769 public void setCooked(Persistent g, Object cooked)
770 throws AccessPoemException, ValidationPoemException {
771 ((TableInfo)g).setCategory((TableCategory)cooked);
772 }
773
774 public Field<Integer> asField(Persistent g) {
775 return ((TableInfo)g).getCategoryField();
776 }
777
778 public DisplayLevel defaultDisplayLevel() {
779 return DisplayLevel.record;
780 }
781
782 public Searchability defaultSearchability() {
783 return Searchability.primary;
784 }
785
786 public int defaultDisplayOrder() {
787 return 11;
788 }
789
790 public String defaultDescription() {
791 return "Which category the table falls into";
792 }
793
794 public Object getRaw_unsafe(Persistent g)
795 throws AccessPoemException {
796 return ((TableInfo)g).getCategory_unsafe();
797 }
798
799 public void setRaw_unsafe(Persistent g, Object raw)
800 throws AccessPoemException {
801 ((TableInfo)g).setCategory_unsafe((Integer)raw);
802 }
803
804 public Object getRaw(Persistent g)
805 throws AccessPoemException {
806 return ((TableInfo)g).getCategoryTroid();
807 }
808
809 public void setRaw(Persistent g, Object raw)
810 throws AccessPoemException {
811 ((TableInfo)g).setCategoryTroid((Integer)raw);
812 }
813 });
814 }
815
816
817
818
819
820
821
822
823
824 public final Column<Integer> getIdColumn() {
825 return col_id;
826 }
827
828
829
830
831
832
833
834
835
836 public final Column<String> getNameColumn() {
837 return col_name;
838 }
839
840
841
842
843
844
845
846
847
848 public final Column<String> getDisplaynameColumn() {
849 return col_displayname;
850 }
851
852
853
854
855
856
857
858
859
860 public final Column<String> getDescriptionColumn() {
861 return col_description;
862 }
863
864
865
866
867
868
869
870
871
872 public final Column<Integer> getDisplayorderColumn() {
873 return col_displayorder;
874 }
875
876
877
878
879
880
881
882
883
884 public final Column<Integer> getDefaultcanreadColumn() {
885 return col_defaultcanread;
886 }
887
888
889
890
891
892
893
894
895
896 public final Column<Integer> getDefaultcanwriteColumn() {
897 return col_defaultcanwrite;
898 }
899
900
901
902
903
904
905
906
907
908 public final Column<Integer> getDefaultcandeleteColumn() {
909 return col_defaultcandelete;
910 }
911
912
913
914
915
916
917
918
919
920 public final Column<Integer> getCancreateColumn() {
921 return col_cancreate;
922 }
923
924
925
926
927
928
929
930
931
932 public final Column<Integer> getCachelimitColumn() {
933 return col_cachelimit;
934 }
935
936
937
938
939
940
941
942
943
944 public final Column<Boolean> getSeqcachedColumn() {
945 return col_seqcached;
946 }
947
948
949
950
951
952
953
954
955
956 public final Column<Integer> getCategoryColumn() {
957 return col_category;
958 }
959
960
961
962
963
964
965
966
967
968 public TableInfo getTableInfoObject(Integer troid) {
969 return (TableInfo)getObject(troid);
970 }
971
972
973
974
975
976
977
978
979
980 public TableInfo getTableInfoObject(int troid) {
981 return (TableInfo)getObject(troid);
982 }
983
984 protected JdbcPersistent _newPersistent() {
985 return new TableInfo();
986 }
987 public String defaultDisplayName() {
988 return "Table";
989 }
990
991 public String defaultDescription() {
992 return "Configuration information about a table in the database";
993 }
994
995 public boolean defaultRememberAllTroids() {
996 return true;
997 }
998
999 public Integer defaultCacheLimit() {
1000 return new Integer(999999999);
1001 }
1002
1003 public String defaultCategory() {
1004 return "System";
1005 }
1006
1007 public int defaultDisplayOrder() {
1008 return 3010;
1009 }
1010
1011
1012
1013
1014 public TableInfo ensure(String name, String displayname, Integer displayorder, Boolean seqcached, TableCategory category) {
1015 TableInfo p = (TableInfo)getNameColumn().firstWhereEq(name);
1016 if (p == null) {
1017 p = (TableInfo)newPersistent();
1018 p.setName(name);
1019 p.setDisplayname(displayname);
1020 p.setDisplayorder(displayorder);
1021 p.setSeqcached(seqcached);
1022 p.setCategory(category);
1023 }
1024 return (TableInfo)getNameColumn().ensure(p);
1025 }
1026 }
1027