~ubuntu-branches/ubuntu/lucid/libstruts1.2-java/lucid

« back to all changes in this revision

Viewing changes to contrib/artimus/WEB-INF/src/java/org/apache/artimus/keys/Access.java

  • Committer: Bazaar Package Importer
  • Author(s): Arnaud Vandyck
  • Date: 2006-04-24 12:14:23 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20060424121423-naev53qigqgks0sa
Tags: 1.2.9-1
New upstream  release Fixes  three security  problems: CVE-2006-1546,
CVE-2006-1547,  CVE-2006-1548  (closes:  #360551),  thanks  to  Moritz
Muehlenhoff.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/*
2
 
 * $Header: /home/cvs/jakarta-struts/contrib/artimus/WEB-INF/src/java/org/apache/artimus/keys/Access.java,v 1.3 2004/03/14 07:15:06 sraeburn Exp $
3
 
 * $Revision: 1.3 $
4
 
 * $Date: 2004/03/14 07:15:06 $
5
 
 *
6
 
 * Copyright 2001-2004 The Apache Software Foundation.
7
 
 * 
8
 
 * Licensed under the Apache License, Version 2.0 (the "License");
9
 
 * you may not use this file except in compliance with the License.
10
 
 * 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.artimus.keys;
23
 
 
24
 
 
25
 
import java.sql.SQLException;
26
 
 
27
 
import org.apache.scaffold.model.ModelException;
28
 
import org.apache.scaffold.model.ModelResourceException;
29
 
 
30
 
import org.apache.scaffold.sql.StatementUtils;
31
 
 
32
 
import org.apache.artimus.keys.sql.Commands;
33
 
 
34
 
 
35
 
/**
36
 
 * Data access methods for Articles application.
37
 
 * <p>
38
 
 * @version $Revision: 1.3 $ $Date: 2004/03/14 07:15:06 $
39
 
 */
40
 
public final class Access {
41
 
 
42
 
 
43
 
// ---- KEYS ----
44
 
 
45
 
 
46
 
    /**
47
 
     * Creates KEYS table. This is a wrapper to pass
48
 
     * KEYS_TABLE and KEYS_CREATE to CreateTable(),
49
 
     * thereby encapsulating the implementation.
50
 
     * <p>
51
 
     * If create succeeds, will insert starter primary
52
 
     * keys for other tables (CollectionS and ARTICLE).
53
 
     * <p>
54
 
     * @exception SQL exception if SQL error occurs
55
 
     * @version $Revision: 1.3 $ $Date: 2004/03/14 07:15:06 $
56
 
     **/
57
 
    public static final void createTable() throws ModelException {
58
 
 
59
 
        try {
60
 
 
61
 
             int result = StatementUtils.createTable(null,
62
 
                Commands.KEYS_TABLE, Commands.KEYS_CREATE
63
 
             );
64
 
        }
65
 
        catch (SQLException e) {
66
 
            throw new ModelResourceException(e);
67
 
        }
68
 
 
69
 
    }
70
 
 
71
 
 
72
 
 
73
 
} // ---- End Data -----
 
 
b'\\ No newline at end of file'