org.modeshape.jdbc.ModeShapeMetaData Maven / Gradle / Ivy
Show all versions of modeshape-jdbc-local
/*
* ModeShape (http://www.modeshape.org)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.modeshape.jdbc;
/**
* Specialized implementation for ModeShape-specific features.
*/
public class ModeShapeMetaData extends JcrMetaData {
public ModeShapeMetaData( JcrConnection connection ) {
super(connection);
}
/**
* {@inheritDoc}
*
* ModeShape does support FULL OUTER JOIN
, so this method returns true when this driver connects to a ModeShape
* JCR repository.
*
*
* @see java.sql.DatabaseMetaData#supportsFullOuterJoins()
*/
@Override
public boolean supportsFullOuterJoins() {
return true;
}
/**
* {@inheritDoc}
*
* ModeShape does support UNION
, so this method returns true when this driver connects to a ModeShape JCR
* repository.
*
*
* @see java.sql.DatabaseMetaData#supportsUnion()
*/
@Override
public boolean supportsUnion() {
return true;
}
/**
* {@inheritDoc}
*
* ModeShape does support UNION ALL
, so this method returns true when this driver connects to a ModeShape JCR
* repository.
*
*
* @see java.sql.DatabaseMetaData#supportsUnionAll()
*/
@Override
public boolean supportsUnionAll() {
return true;
}
/**
* {@inheritDoc}
*
* ModeShape uses arithmetic operations in criteria, and in the current implementation if one operand is null then the
* operations returns the other. Therefore, 'null + X = X', so this method returns false
.
*
*
* @see java.sql.DatabaseMetaData#nullPlusNonNullIsNull()
*/
@Override
public boolean nullPlusNonNullIsNull() {
return false;
}
/**
* {@inheritDoc}
*
* ModeShape definitely uses sort order. Therefore, this method always returns false
.
*
*
* @see java.sql.DatabaseMetaData#nullsAreSortedAtEnd()
*/
@Override
public boolean nullsAreSortedAtEnd() {
return false;
}
/**
* {@inheritDoc}
*
* ModeShape definitely uses sort order. Therefore, this method always returns false
.
*
*
* @see java.sql.DatabaseMetaData#nullsAreSortedAtStart()
*/
@Override
public boolean nullsAreSortedAtStart() {
return false;
}
/**
* {@inheritDoc}
*
* ModeShape sorts null values to be lower than non-null values. Therefore, this method returns false
.
*
*
* @see java.sql.DatabaseMetaData#nullsAreSortedHigh()
*/
@Override
public boolean nullsAreSortedHigh() {
return false;
}
/**
* {@inheritDoc}
*
* ModeShape sorts null values to be lower than non-null values. Therefore, this method returns true
.
*
*
* @see java.sql.DatabaseMetaData#nullsAreSortedLow()
*/
@Override
public boolean nullsAreSortedLow() {
return true;
}
}