01: /*
02: * Copyright 2002 (C) TJDO.
03: * All rights reserved.
04: *
05: * This software is distributed under the terms of the TJDO License version 1.0.
06: * See the terms of the TJDO License in the documentation provided with this software.
07: *
08: * $Id: TableIdentifier.java,v 1.3 2003/01/19 02:42:10 jackknifebarber Exp $
09: */
10:
11: package com.triactive.jdo.store;
12:
13: class TableIdentifier extends SQLIdentifier {
14: /**
15: * The maximum length in characters reserved at the end of table names
16: * for suffixes used to construct related names (such as _PK for a table's
17: * primary key).
18: */
19:
20: public static int MAX_TABLE_NAME_SUFFIX = 4;
21:
22: public TableIdentifier(DatabaseAdapter dba, String javaName) {
23: super (dba);
24:
25: setJavaName(javaName);
26: }
27:
28: protected int getMaxLength() {
29: return dba.getMaxTableNameLength() - MAX_TABLE_NAME_SUFFIX;
30: }
31: }
|