本文整理汇总了Java中mondrian.util.ArrayStack类的典型用法代码示例。如果您正苦于以下问题:Java ArrayStack类的具体用法?Java ArrayStack怎么用?Java ArrayStack使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
ArrayStack类属于mondrian.util包,在下文中一共展示了ArrayStack类的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: lookupScopedNamedSet
import mondrian.util.ArrayStack; //导入依赖的package包/类
/**
* Looks up a named set defined by an alias.
*
* @param nameParts Multi-part identifier for set
* @param scopeList Parse tree node where name is used (last in list) and
*/
ScopedNamedSet lookupScopedNamedSet(
List<Id.Segment> nameParts,
ArrayStack<QueryPart> scopeList)
{
if (nameParts.size() != 1) {
return null;
}
if (!(nameParts.get(0) instanceof Id.NameSegment)) {
return null;
}
String name = ((Id.NameSegment) nameParts.get(0)).getName();
ScopedNamedSet bestScopedNamedSet = null;
int bestScopeOrdinal = -1;
for (ScopedNamedSet scopedNamedSet : scopedNamedSets) {
if (Util.equalName(scopedNamedSet.name, name)) {
int scopeOrdinal = scopeList.indexOf(scopedNamedSet.scope);
if (scopeOrdinal > bestScopeOrdinal) {
bestScopedNamedSet = scopedNamedSet;
bestScopeOrdinal = scopeOrdinal;
}
}
}
return bestScopedNamedSet;
}
示例2: lookupScopedNamedSet
import mondrian.util.ArrayStack; //导入依赖的package包/类
/**
* Looks up a named set defined by an alias.
*
* @param nameParts Multi-part identifier for set
* @param scopeList Parse tree node where name is used (last in list) and
*/
ScopedNamedSet lookupScopedNamedSet(
List<Id.Segment> nameParts,
ArrayStack<QueryPart> scopeList)
{
if (nameParts.size() != 1) {
return null;
}
String name = nameParts.get(0).name;
ScopedNamedSet bestScopedNamedSet = null;
int bestScopeOrdinal = -1;
for (ScopedNamedSet scopedNamedSet : scopedNamedSets) {
if (Util.equalName(scopedNamedSet.name, name)) {
int scopeOrdinal = scopeList.indexOf(scopedNamedSet.scope);
if (scopeOrdinal > bestScopeOrdinal) {
bestScopedNamedSet = scopedNamedSet;
bestScopeOrdinal = scopeOrdinal;
}
}
}
return bestScopedNamedSet;
}
示例3: initialValue
import mondrian.util.ArrayStack; //导入依赖的package包/类
protected ArrayStack<Locus> initialValue() {
return new ArrayStack<Locus>();
}
示例4: Walker
import mondrian.util.ArrayStack; //导入依赖的package包/类
public Walker(Walkable root)
{
stack = new ArrayStack();
currentFrame = null;
visit(null, root);
}
示例5: getScopeStack
import mondrian.util.ArrayStack; //导入依赖的package包/类
public ArrayStack<QueryPart> getScopeStack() {
return stack;
}