Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'jpa/plugins/org.eclipse.jpt.db/src/org/eclipse/jpt/db/internal/NullDatabase.java')
-rw-r--r--jpa/plugins/org.eclipse.jpt.db/src/org/eclipse/jpt/db/internal/NullDatabase.java109
1 files changed, 0 insertions, 109 deletions
diff --git a/jpa/plugins/org.eclipse.jpt.db/src/org/eclipse/jpt/db/internal/NullDatabase.java b/jpa/plugins/org.eclipse.jpt.db/src/org/eclipse/jpt/db/internal/NullDatabase.java
deleted file mode 100644
index fa316b82ef..0000000000
--- a/jpa/plugins/org.eclipse.jpt.db/src/org/eclipse/jpt/db/internal/NullDatabase.java
+++ /dev/null
@@ -1,109 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006, 2007 Oracle. All rights reserved.
- * This program and the accompanying materials are made available under the
- * terms of the Eclipse Public License v1.0, which accompanies this distribution
- * and is available at http://www.eclipse.org/legal/epl-v10.html.
- *
- * Contributors:
- * Oracle - initial API and implementation
- ******************************************************************************/
-package org.eclipse.jpt.db.internal;
-
-import java.util.Collections;
-import java.util.Set;
-import org.eclipse.jpt.utility.internal.ClassTools;
-
-/**
- * NullDatabase
- */
-public final class NullDatabase extends Database {
-
- private static NullDatabase INSTANCE;
-
- /**
- * singleton support
- */
- static synchronized Database instance() {
- if( INSTANCE == null) {
- INSTANCE = new NullDatabase();
- }
- return INSTANCE;
- }
-
- private NullDatabase() {
- super();
- }
-
- // ********** behavior **********
-
- @Override
- void catalogChanged( Catalog catalog, int eventType) {
- // do nothing
- }
-
- @Override
- void schemaChanged( Schema schema, int eventType) {
- // do nothing
- }
-
- @Override
- void tableChanged( Table table, Schema schema,int eventType) {
- // do nothing
- }
-
- @Override
- void refresh() {
- // do nothing
- }
-
- @Override
- protected void dispose() {
- // do nothing
- }
-
- @Override
- protected boolean connectionIsOnline() {
- return false;
- }
-
- // ********** queries **********
-
- @Override
- public String getName() {
- return ClassTools.shortClassNameForObject( this);
- }
-
- @Override
- public String getVendor() {
- return this.getName();
- }
-
- @Override
- public String getVersion() {
- return "";
- }
-
- // ***** catalogs
-
- @Override
- public boolean supportsCatalogs() {
- return false;
- }
-
- @Override
- public String getDefaultCatalogName() {
- return "";
- }
-
- @Override
- Set<Catalog> getCatalogs() {
- return Collections.emptySet();
- }
-
- // ***** schemata
-
- @Override
- Set<Schema> getSchemata() {
- return Collections.emptySet();
- }
-}

Back to the top