View Javadoc

1   /*
2    * Copyright 2005 The Apache Software Foundation.
3    * 
4    * Licensed under the Apache License, Version 2.0 (the "License");
5    * you may not use this file except in compliance with the License.
6    * You may obtain a copy of the License at 
7    * 
8    *     http://www.apache.org/licenses/LICENSE-2.0
9    * 
10   * Unless required by applicable law or agreed to in writing, software 
11   * distributed under the License is distributed on an "AS IS" BASIS, 
12   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 
13   * See the License for the specific language governing permissions and 
14   * limitations under the License.
15   */
16  
17  package org.apache.jdo.impl.model.jdo;
18  
19  import java.util.*;
20  
21  import org.apache.jdo.model.jdo.JDOModel;
22  import org.apache.jdo.model.jdo.JDOPackage;
23  
24  /***
25   * A JDOPackage instance represents the JDO package metadata.
26   *
27   * @author Michael Bouschen
28   */
29  public class JDOPackageImpl 
30      extends JDOElementImpl
31      implements JDOPackage
32  {
33      /**</package-summary/html">The package name/ *//package-summary.html">em>* The package name. */
34      private String name;
35  
36      /*** Relationship JDOModel<->JDOPackage. Initialized during creation.*/
37      private JDOModel declaringModel;
38  
39      /***
40       * Returns the name of this JDOPackage.
41       * @return the name
42       */
43      public String getName()
44      {
45          return name;
46      }
47  
48      /***
49       * Sets the name of this JDOPackage.
50       * @param name the name
51       */
52      public void setName(String name)
53      {
54          this.name = name;
55      }
56  
57      /***
58       * Returns the declaring JDOModel of this JDOPackage.
59       * @return the JDOModel that owns this JDOPackage.
60       */
61      public JDOModel getDeclaringModel()
62      {
63          return declaringModel;
64      }
65  
66      /***
67       * Set the declaring JDOModel for this JDOPackage.
68       * @param model the declaring JDOModel of this JDOPackage.
69       */
70      public void setDeclaringModel(JDOModel model)
71      {
72          this.declaringModel = model;
73      }
74  }