本文整理汇总了Java中org.hsqldb.lib.ArrayUtil.haveEqualSets方法的典型用法代码示例。如果您正苦于以下问题:Java ArrayUtil.haveEqualSets方法的具体用法?Java ArrayUtil.haveEqualSets怎么用?Java ArrayUtil.haveEqualSets使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.hsqldb.lib.ArrayUtil
的用法示例。
在下文中一共展示了ArrayUtil.haveEqualSets方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: isUniqueWithColumns
import org.hsqldb.lib.ArrayUtil; //导入方法依赖的package包/类
/**
* Compares this with another constraint column set. This is used only for
* UNIQUE constraints.
*/
boolean isUniqueWithColumns(int[] cols) {
switch (constType) {
case SchemaObject.ConstraintTypes.PRIMARY_KEY :
case SchemaObject.ConstraintTypes.UNIQUE :
if (core.mainCols.length == cols.length) {
return ArrayUtil.haveEqualSets(core.mainCols, cols,
cols.length);
}
}
return false;
}
示例2: setDistinctColumnsOnIndex
import org.hsqldb.lib.ArrayUtil; //导入方法依赖的package包/类
public boolean setDistinctColumnsOnIndex(int[] colMap) {
if (joinConditions.length != 1) {
return false;
}
int[] indexColMap = joinConditions[0].rangeIndex.getColumns();
if (colMap.length > indexColMap.length) {
return false;
}
if (colMap.length == indexColMap.length) {
if (ArrayUtil.haveEqualSets(colMap, indexColMap, colMap.length)) {
indexDistinctCount = colMap.length;
return true;
}
}
if (ArrayUtil.haveEqualArrays(colMap, indexColMap, colMap.length)) {
indexDistinctCount = colMap.length;
return true;
}
return false;
}
示例3: getIndexForColumns
import org.hsqldb.lib.ArrayUtil; //导入方法依赖的package包/类
/**
* Finds an existing index for an unordered full column group
*/
Index getIndexForColumns(int[] cols) {
for (int i = 0; i < indexList.length; i++) {
if (ArrayUtil.haveEqualSets(indexList[i].getColumns(), cols,
cols.length)) {
return indexList[i];
}
}
return null;
}
示例4: isUniqueWithColumns
import org.hsqldb.lib.ArrayUtil; //导入方法依赖的package包/类
/**
* Compares this with another constraint column set. This is used only for
* UNIQUE constraints.
*/
boolean isUniqueWithColumns(int[] cols) {
if (constType != UNIQUE || core.mainCols.length != cols.length) {
return false;
}
return ArrayUtil.haveEqualSets(core.mainCols, cols, cols.length);
}
示例5: isEquivalent
import org.hsqldb.lib.ArrayUtil; //导入方法依赖的package包/类
/**
* Compares this with another constraint column set. This implementation
* only checks UNIQUE constraints.
*/
boolean isEquivalent(int col[], int type) {
if (type != constType || constType != UNIQUE
|| core.colLen != col.length) {
return false;
}
return ArrayUtil.haveEqualSets(core.mainColArray, col, core.colLen);
}
示例6: isEquivalent
import org.hsqldb.lib.ArrayUtil; //导入方法依赖的package包/类
/**
* Compares this with another constraint column set. This implementation
* only checks UNIQUE constraints.
*/
boolean isEquivalent(int[] col, int type) {
if (type != constType || constType != UNIQUE
|| core.colLen != col.length) {
return false;
}
return ArrayUtil.haveEqualSets(core.mainColArray, col, core.colLen);
}