1 13 14 package com.tonbeller.jpivot.olap.query; 15 16 import mondrian.olap.Exp; 17 18 import java.util.List ; 19 20 import com.tonbeller.jpivot.olap.model.Dimension; 21 import com.tonbeller.jpivot.olap.model.Hierarchy; 22 import com.tonbeller.jpivot.olap.model.Level; 23 import com.tonbeller.jpivot.olap.model.Member; 24 25 public interface QuaxUti { 26 static final int FUNTYPE_FUNCTION = 0; 27 static final int FUNTYPE_PROPERTY = 1; 28 static final int FUNTYPE_BRACES = 2; 29 static final int FUNTYPE_TUPLE = 3; 30 static final int FUNTYPE_INFIX = 4; 31 32 36 boolean isMember(Object oExp); 37 38 42 boolean isFunCall(Object oExp); 43 44 49 boolean equalMember(Object oExp, Member member); 50 51 56 boolean isFunCallTo(Object oExp, String function); 57 58 64 boolean checkParent(Member pMember, Object cMembObj); 65 66 72 boolean checkChild(Member cMember, Object pMembObj); 73 74 80 boolean checkDescendantM(Member aMember, Member dMember); 81 82 83 89 boolean checkDescendantO(Member aMember, Object oMember); 90 91 97 boolean isMemberInFunCall(Object oExp, Member member) throws Quax.CannotHandleException; 98 99 106 boolean isChildOfMemberInFunCall(Object oExp, Member member) throws Quax.CannotHandleException; 107 108 114 boolean isDescendantOfMemberInFunCall(Object oExp, Member member) 115 throws Quax.CannotHandleException; 116 117 122 boolean isFunCallNotTopLevel(Object oExp) throws Quax.CannotHandleException; 123 124 129 boolean isMemberOnToplevel(Object oMem); 130 131 136 boolean canHandle(Object oExp); 137 138 Member getParentMember(Object oExp); 139 Member memberForObj(Object oExp); 140 141 Hierarchy hierForMember(Member member); 142 Dimension dimForMember(Member member); 143 StringBuffer funString(Object oExp); 144 String getMemberUniqueName(Object oExp); 145 146 151 Object objForMember(Member member); 152 153 158 Object objForDim(Dimension dim); 159 160 String memberString(Member[] mPath); 161 162 167 Object createMemberSet(List mList); 168 169 170 175 int levelDepthForMember(Object oExp); 176 177 182 Hierarchy hierForExp(Object oExp) throws Quax.CannotHandleException; 183 184 189 Object topLevelMembers(Hierarchy hier, boolean expandAllMember ); 190 191 198 Object createFunCall(String function, Object [] args, int funType); 199 200 205 int funCallArgCount(Object oFun); 206 207 212 String funCallName (Object oFun); 213 214 220 Object funCallArg(Object oExp, int index); 221 222 227 Object [] getChildren(Object oMember); 228 229 232 Object [] getLevelMembers(Level level); 233 234 void addMemberUncles(List list, Member m, int[] maxLevel); 235 void addMemberSiblings(List list, Member m, int[] maxLevel); 236 void addMemberChildren(List list, Member m, int[] maxLevel); 237 void addMemberDescendants(List list, Member m, Level lev, int[] maxLevel); 238 void addLevelMembers(List list, Level lev, int[] maxLevel); 239 Level LevelForObj(Object oLevel); 240 Level getParentLevel(Level lev); 241 242 250 Exp toExp(Object o); 251 252 } | Popular Tags |