01: /*
02:
03: Derby - Class org.apache.derby.iapi.store.access.ConglomPropertyQueryable
04:
05: Licensed to the Apache Software Foundation (ASF) under one or more
06: contributor license agreements. See the NOTICE file distributed with
07: this work for additional information regarding copyright ownership.
08: The ASF licenses this file to you under the Apache License, Version 2.0
09: (the "License"); you may not use this file except in compliance with
10: the License. You may obtain a copy of the License at
11:
12: http://www.apache.org/licenses/LICENSE-2.0
13:
14: Unless required by applicable law or agreed to in writing, software
15: distributed under the License is distributed on an "AS IS" BASIS,
16: WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17: See the License for the specific language governing permissions and
18: limitations under the License.
19:
20: */
21:
22: package org.apache.derby.iapi.store.access;
23:
24: import org.apache.derby.iapi.error.StandardException;
25:
26: import java.util.Properties;
27:
28: /**
29:
30: ConglomPropertyable provides the interfaces to read properties from a
31: conglomerate.
32: <p>
33: RESOLVE - If language ever wants these interfaces on a ScanController it
34: should not be too difficult to add them.
35:
36: @see ConglomerateController
37:
38: **/
39:
40: public interface ConglomPropertyQueryable {
41: /**
42: * Request the system properties associated with a table.
43: * <p>
44: * Request the value of properties that are associated with a table. The
45: * following properties can be requested:
46: * derby.storage.pageSize
47: * derby.storage.pageReservedSpace
48: * derby.storage.minimumRecordSize
49: * derby.storage.initialPages
50: * <p>
51: * To get the value of a particular property add it to the property list,
52: * and on return the value of the property will be set to it's current
53: * value. For example:
54: *
55: * get_prop(ConglomerateController cc)
56: * {
57: * Properties prop = new Properties();
58: * prop.put("derby.storage.pageSize", "");
59: * cc.getTableProperties(prop);
60: *
61: * System.out.println(
62: * "table's page size = " +
63: * prop.getProperty("derby.storage.pageSize");
64: * }
65: *
66: * @param prop Property list to fill in.
67: *
68: * @exception StandardException Standard exception policy.
69: **/
70: void getTableProperties(Properties prop) throws StandardException;
71:
72: /**
73: * Request set of properties associated with a table.
74: * <p>
75: * Returns a property object containing all properties that the store
76: * knows about, which are stored persistently by the store. This set
77: * of properties may vary from implementation to implementation of the
78: * store.
79: * <p>
80: * This call is meant to be used only for internal query of the properties
81: * by jbms, for instance by language during bulk insert so that it can
82: * create a new conglomerate which exactly matches the properties that
83: * the original container was created with. This call should not be used
84: * by the user interface to present properties to users as it may contain
85: * properties that are meant to be internal to jbms. Some properties are
86: * meant only to be specified by jbms code and not by users on the command
87: * line.
88: * <p>
89: * Note that not all properties passed into createConglomerate() are stored
90: * persistently, and that set may vary by store implementation.
91: *
92: * @param prop Property list to add properties to. If null, routine will
93: * create a new Properties object, fill it in and return it.
94: *
95: * @exception StandardException Standard exception policy.
96: **/
97: Properties getInternalTablePropertySet(Properties prop)
98: throws StandardException;
99: }
|