Package javax.jdo.metadata
Interface JDOMetadata
- All Superinterfaces:
Metadata
Represents the top-level JDO metadata.
- Since:
- 3.0
-
Method Summary
Modifier and TypeMethodDescriptionAccessor for the catalog (ORM) that all classes in this JDO Metadata default to.Accessor for any fetch plans defined on the JDO Metadata.int
Accessor for the number of fetch plans defined in this JDO Metadata.int
Accessor for the number of packages defined in this JDO Metadata.int
Accessor for the number of named queries defined in this JDO Metadata.Accessor for all packages defined on the JDO Metadata.Accessor for any named queries defined on the JDO Metadata.Accessor for the schema (ORM) that all classes in this JDO Metadata default to.newClassMetadata
(Class cls) Add a new class to this JDO Metadata.newFetchPlanMetadata
(String name) Add a new fetch plan to this JDO Metadata.Add a new interface to this JDO Metadata.Add a new package to this JDO Metadata.newPackageMetadata
(String pkgName) Add a new package to this JDO Metadata.newQueryMetadata
(String name) Add a new named query to this JDO Metadata.setCatalog
(String catalog) Method to set the catalog (ORM) to apply to all classes in this JDO Metadata.Method to set the schema (ORM) to apply to all classes in this JDO Metadata.Methods inherited from interface javax.jdo.metadata.Metadata
getExtensions, getNumberOfExtensions, getParent, newExtensionMetadata
-
Method Details
-
setCatalog
Method to set the catalog (ORM) to apply to all classes in this JDO Metadata.- Parameters:
catalog
- Catalog name- Returns:
- This metadata object
-
getCatalog
String getCatalog()Accessor for the catalog (ORM) that all classes in this JDO Metadata default to.- Returns:
- The catalog
-
setSchema
Method to set the schema (ORM) to apply to all classes in this JDO Metadata.- Parameters:
schema
- Schema name- Returns:
- This metadata object
-
getSchema
String getSchema()Accessor for the schema (ORM) that all classes in this JDO Metadata default to.- Returns:
- The schema
-
getPackages
PackageMetadata[] getPackages()Accessor for all packages defined on the JDO Metadata.- Returns:
- The packages
-
newPackageMetadata
Add a new package to this JDO Metadata.- Parameters:
pkgName
- Name of the package- Returns:
- The PackageMetadata
-
newPackageMetadata
Add a new package to this JDO Metadata.- Parameters:
pkg
- The package- Returns:
- The PackageMetadata
-
getNumberOfPackages
int getNumberOfPackages()Accessor for the number of packages defined in this JDO Metadata.- Returns:
- The number of packages.
-
newClassMetadata
Add a new class to this JDO Metadata. Adds its package also if not yet existing.- Parameters:
cls
- Class to add- Returns:
- The ClassMetadata
-
newInterfaceMetadata
Add a new interface to this JDO Metadata. Adds its package also if not yet existing.- Parameters:
cls
- Class to add- Returns:
- The InterfaceMetadata
-
getQueries
QueryMetadata[] getQueries()Accessor for any named queries defined on the JDO Metadata.- Returns:
- The queries
-
newQueryMetadata
Add a new named query to this JDO Metadata.- Parameters:
name
- Name of the query- Returns:
- The QueryMetadata
-
getNumberOfQueries
int getNumberOfQueries()Accessor for the number of named queries defined in this JDO Metadata.- Returns:
- The number of queries.
-
getFetchPlans
FetchPlanMetadata[] getFetchPlans()Accessor for any fetch plans defined on the JDO Metadata.- Returns:
- The fetch plans
-
newFetchPlanMetadata
Add a new fetch plan to this JDO Metadata.- Parameters:
name
- Name of the query- Returns:
- The FetchPlanMetadata
-
getNumberOfFetchPlans
int getNumberOfFetchPlans()Accessor for the number of fetch plans defined in this JDO Metadata.- Returns:
- The number of fetch plans.
-