|
Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference 11g Release 1 (11.1.1.4.0) E13403-05 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object oracle.javatools.db.extension.DatabaseMatcher
public class DatabaseMatcher
Immutable class used to match a database release by type and version(s).
Example 1: Match any Oracle database
DatabaseMatcher dm = new DatabaseMatcher( OracleDatabase.ORACLE_DATABASE_TYPE );
Example 2: Match Oracle databases 10gR1 and above
DatabaseMatcher dm = new DatabaseMatcher( OracleDatabase.ORACLE_DATABASE_TYPE, OracleDatabase.ORACLE10g_TYPE, DatabaseMatcher.Comparison.MINIMUM );
Example 3: Match only Oracle 11gR2
DatabaseMatcher dm = new DatabaseMatcher( OracleDatabase.ORACLE_DATABASE_TYPE, OracleDatabase.ORACLE11gR2_TYPE, DatabaseMatcher.Comparison.EXACT );
Nested Class Summary | |
---|---|
static class |
DatabaseMatcher.Comparison
Used to indicate how the version should be matched. |
Constructor Summary | |
---|---|
DatabaseMatcher(java.lang.String dbType)
Matches all database of the given database type. |
|
DatabaseMatcher(java.lang.String dbType,
int version,
DatabaseMatcher.Comparison comparison)
Matches database of the given database type, by comparing the version number using the given comparison type. |
Method Summary | |
---|---|
boolean |
equals(java.lang.Object obj)
Tests that the other object is a DatabaseMatcher with exactly the same criteria as this matcher. |
java.lang.String |
getDatabaseType()
Gets the type of database this will match. |
int |
hashCode()
|
boolean |
matches(java.lang.String dbType,
int version)
|
protected boolean |
matchesType(java.lang.String dbType)
|
protected boolean |
matchesVersion(int version)
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DatabaseMatcher(java.lang.String dbType)
public DatabaseMatcher(java.lang.String dbType, int version, DatabaseMatcher.Comparison comparison)
Method Detail |
---|
public java.lang.String getDatabaseType()
protected boolean matchesType(java.lang.String dbType)
protected boolean matchesVersion(int version)
public boolean matches(java.lang.String dbType, int version)
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
|
Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference 11g Release 1 (11.1.1.4.0) E13403-05 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |