SAP ABAP Class CL_RSDRS_WHERE_TREE (Tree with where conditions)
Hierarchy
SAP_BW (Software Component) SAP Business Warehouse
   BW-BEX-OT (Application Component) OLAP Technology
     RSDRS (Package) Data Manager SQL Interface
Meta Relationship - Used By
# Relationship type Used by Short Description Created on
1 Inheritance (c INHERITING FROM c_ref)  CL_RSDRS_WHERE_TREE_BRANCH Tree with branch where conditions 20031204
2 Inheritance (c INHERITING FROM c_ref)  CL_RSDRS_WHERE_TREE_FACT Tree with fact where conditions 20031204
Properties
Class CL_RSDRS_WHERE_TREE  
Short Description Tree with where conditions    
Super Class    
Instantiability of a Class 2  Public 
Final    
General Data
Message Class    
Program status     
Category 0   
Package RSDRS   Data Manager SQL Interface 
Created 20031204   SAP 
Last change 20130531   SAP 
Shared Memory-enabled    
Fixed point arithmetic    
Unicode checks active    
Forward declarations
# Type group / Object type Type Type Description
1 RS Type group use (TYPE-POOLS tp)  Type group use (TYPE-POOLS tp)
2 RSDRS Type group use (TYPE-POOLS tp)  Type group use (TYPE-POOLS tp)
Interfaces
Class CL_RSDRS_WHERE_TREE has no interface implemented.
Friends
Class CL_RSDRS_WHERE_TREE has no friend class.
Attributes
# Attribute Level Visibility Read only Typing Associated Type Initial Value Description Created on
1 N_ACT_ELEMENT Instance attribute Public Type reference (TYPE) I 0 last element inserted 20031204
2 N_C_BOOL_VAL Constant Public See coding 20031204
3 N_C_TABALIAS Constant Public See coding 20031204
4 N_DROP_EMPTY_NODES Instance attribute Public Type reference (TYPE) RS_BOOL If true, empty nodes are really dropped (reduce hash table) 20050308
5 N_TH_WHERE_TREE Instance attribute Public Type reference (TYPE) TN_TH_WH_ELEM binary tree with where conditions 20031204
6 N_T_ORG_WHERE Instance attribute Public Type reference (TYPE) RSDRS_T_WHERE original where conditions 20031204
7 O_COUNTER Instance attribute Protected Type reference (TYPE) I 1 unique number of new element 20031204
8 P_NORMALIZED Instance attribute Private Type reference (TYPE) RS_BOOL Is Tree already normalized ? 20050506
Methods
# Method Level Visibility Method type Description Created on
1 ADD_BOOLOP Instance method Public Method add a new boolean operator above the given element 20031204
2 ADD_CONDITION Instance method Public Method add a new condition w/o operator and level as right child 20031204
3 ADD_NODE Instance method Private Method add a new node to the tree 20031204
4 ADD_TREE Instance method Public Method add a new condition w/o operator and level as right child 20040316
5 BUILD_TREE Static method Public Method build a tree of where conditions 20031204
6 BUILD_T_WHERE Instance method Public Method a new t_where is built from the tree 20031204
7 CHANGE_BOOLOP Instance method Public Method Exchange the boolean operator of the actual element 20031204
8 CHANGE_CONDITION Instance method Public Method Exchange the logical condition of actual element 20031204
9 COPY Instance method Public Method build a tree of where conditions 20040316
10 CORRECT_SIGN_WITH_DS Instance method Private Method signs of all nodes are corrected, boolops changed to and/or 20031204
11 DET_OPERATOR_PRECEDENCE Static method Private Method determines the precedence of a booloean operator 20031204
12 DROP_BRANCH Instance method Public Method drops the complete branch starting with the actual element 20031204
13 DROP_NODE Instance method Public Method drops the actual element. It must only contain one child !! 20031204
14 GET_ROOT Instance method Public Method Returns the root element 20031204
15 IS_NEGATED Instance method Public Method Is the condition or boolop of the actual elem negated ? 20031204
16 NEGATE Instance method Public Method negate the actual element 20031204
17 NEGATE_BOOL_VAL Static method Protected Method negates a value rsdrw_bool_val. If undefined set to not_set 20031204
18 NORMALIZE Instance method Public Method always true conditions are removed where possible 20050310
19 NORMALIZE_CHECK_12 Instance method Private Method conditions that are always true are removed where possible 20050308
20 READ_WITH_DS Instance method Private Method tree is read with deep search, bracket levels are updated. 20031204
21 _ADD_TREE Instance method Private Method add a new condition w/o operator and level as right child 20040316
22 _BUILD_TREE Instance method Protected Method build a tree of where conditions 20040122
23 _NORMALIZE Instance method Private Method conditions that are always true are removed where possible 20050310
Events
Class CL_RSDRS_WHERE_TREE has no event.
Types
# Type Visibility Typing Associated Type Description Created on Type Source
1 TN_BOOL_VAL Public Type reference (TYPE) I see constants nc_bool_val 20031204
2 TN_SX_TABQUERY Public See coding Element of hashed table of query structures 20031204 BEGIN OF TN_sx_tabquery, tabalias TYPE rsdrs_s_table-tabalias, sx_query TYPE rsdrs_sx_query, END OF tn_sx_tabquery
3 TN_S_KEY_TAB Public See coding Element of key table for query structure key 20031204 BEGIN OF TN_S_KEY_TAB, tabalias TYPE rsdrs_s_table-tabalias, is_dim_tbl TYPE rs_bool, query_key TYPE rsdrs_s_table-tabalias, END OF TN_S_KEY_TAB
4 TN_S_WH_ELEM Public See coding 20031204 BEGIN OF tn_s_wh_elem, key_id TYPE i, "unique key for hash table left TYPE i, "unique key of left child right TYPE i, "unique key of right child parent TYPE i, "unique key of parent level TYPE i, "level in org. where list boolop TYPE rsdrs_boolop, "boolean operator if node "only and, or is_not TYPE rs_bool,"negation set ? is_fix TYPE rs_bool,"fix value set ? cond_idx TYPE i, "index of condition in original "wherelist query_tabalias TYPE rsdrs_s_table-tabalias, "tabalias of query the where "condition belongs to wherelist END OF tn_s_wh_elem
5 TN_THX_TABQUERY Public See coding query structure hash table 20031204 tn_thx_tabquery TYPE HASHED TABLE OF tn_sx_tabquery WITH UNIQUE KEY tabalias INITIAL SIZE 0
6 TN_TH_KEY_TAB Public See coding key table type for query structure keys 20031204 tn_th_key_tab TYPE HASHED TABLE OF tn_s_key_tab WITH UNIQUE KEY tabalias INITIAL SIZE 0
7 TN_TH_WH_ELEM Public See coding 20031204 TN_TH_WH_ELEM TYPE HASHED TABLE OF tn_s_wh_elem WITH UNIQUE KEY key_id INITIAL SIZE 0
Method Signatures

Method ADD_BOOLOP Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Importing I_ACT_ELEMENT Call by reference Type reference (TYPE) I Element where to insert the boolop at 20031204
2 Importing I_BOOLOP Call by reference Type reference (TYPE) RSDRS_BOOLOP Boolean operator AND or OR 20031204
3 Returning R_ACT_ELEMENT Value transfer Type reference (TYPE) I Inserted Element 20031204

Method ADD_BOOLOP on class CL_RSDRS_WHERE_TREE has no exception.

Method ADD_CONDITION Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Importing I_ACT_ELEMENT Call by reference Type reference (TYPE) I Element where to insert the boolop at 20031204
2 Importing I_LEFT Value transfer Type reference (TYPE) RS_BOOL RS_C_FALSE Insert as left child (Only for emergency cases !!!) 20031204
3 Importing I_S_WHERE Call by reference Type reference (TYPE) RSDRS_S_WHERE Where condition 20031204
4 Returning R_ACT_ELEMENT Value transfer Type reference (TYPE) I Inserted Element 20031204

Method ADD_CONDITION on class CL_RSDRS_WHERE_TREE has no exception.

Method ADD_NODE Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Importing I_FLUSH Call by reference Type reference (TYPE) RS_BOOL last tree element contains a flush of parenthesises 20031204
2 Importing I_S_WHERE Call by reference Type reference (TYPE) RSDRS_S_WHERE condition to add to tree 20031204
3 Importing I_TABALIAS Call by reference Type reference (TYPE) RSDRS_S_TABLE-TABALIAS alias of branch query root table 20031204

Method ADD_NODE on class CL_RSDRS_WHERE_TREE has no exception.

Method ADD_TREE Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Importing I_ACT_ELEMENT Call by reference Type reference (TYPE) I Element where to insert the boolop at 20040316
2 Importing I_LEFT Value transfer Type reference (TYPE) RS_BOOL RS_C_FALSE Insert as left child (Only for emergency cases !!!) 20040316
3 Importing I_R_WHERE_TREE Call by reference Object reference (TYPE REF TO) CL_RSDRS_WHERE_TREE Where Tree to insert 20040316
4 Returning R_ACT_ELEMENT Value transfer Type reference (TYPE) I Inserted Element 20040316

Method ADD_TREE on class CL_RSDRS_WHERE_TREE has no exception.

Method BUILD_TREE Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Importing I_TH_KEY_TAB Call by reference Type reference (TYPE) TN_TH_KEY_TAB Query table aliases to use 20031204
2 Importing I_T_WHERE Call by reference Type reference (TYPE) RSDRS_T_WHERE where conditions to build tree for 20031204
3 Returning R_R_WHERE_TREE Value transfer Object reference (TYPE REF TO) CL_RSDRS_WHERE_TREE Reference to Tree object 20031209

Method BUILD_TREE on class CL_RSDRS_WHERE_TREE has no exception.

Method BUILD_T_WHERE Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Exporting E_T_WHERE Call by reference Type reference (TYPE) RSDRS_T_WHERE New where condition table 20031204
2 Importing I_NORMALIZE Call by reference Type reference (TYPE) RS_BOOL RS_C_TRUE Normalize tree before building t_where 20050506

Method BUILD_T_WHERE on class CL_RSDRS_WHERE_TREE has no exception.

Method CHANGE_BOOLOP Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Importing I_ACT_ELEMENT Call by reference Type reference (TYPE) I Element where to insert the boolop at 20031204
2 Importing I_BOOLOP Call by reference Type reference (TYPE) RSDRS_BOOLOP Boolean operator AND or OR 20031204
3 Returning R_ACT_ELEMENT Value transfer Type reference (TYPE) I Inserted Element 20031204

Method CHANGE_BOOLOP on class CL_RSDRS_WHERE_TREE has no exception.

Method CHANGE_CONDITION Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Importing I_ACT_ELEMENT Call by reference Type reference (TYPE) I Element where to insert the boolop at 20031204
2 Importing I_S_WHERE Call by reference Type reference (TYPE) RSDRS_S_WHERE Where condition 20031204
3 Returning R_ACT_ELEMENT Value transfer Type reference (TYPE) I Inserted Element 20031204

Method CHANGE_CONDITION on class CL_RSDRS_WHERE_TREE has no exception.

Method COPY Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Returning R_R_WHERE_TREE Value transfer Object reference (TYPE REF TO) CL_RSDRS_WHERE_TREE Reference to Tree object 20040316

Method COPY on class CL_RSDRS_WHERE_TREE has no exception.

Method CORRECT_SIGN_WITH_DS Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Importing I_ACT_ELEMENT Call by reference Type reference (TYPE) I key of actual element 20031204
2 Importing I_OP_NOT Call by reference Type reference (TYPE) RS_BOOL if true, set not-flag, if level > 0 or operand 20031204

Method CORRECT_SIGN_WITH_DS on class CL_RSDRS_WHERE_TREE has no exception.

Method DET_OPERATOR_PRECEDENCE Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Returning E_PRECEDENCE Value transfer Type reference (TYPE) I precedence of operator 20031204
2 Importing I_BOOLOP Call by reference Type reference (TYPE) RSDRS_BOOLOP operator 20031204

Method DET_OPERATOR_PRECEDENCE on class CL_RSDRS_WHERE_TREE has no exception.

Method DROP_BRANCH Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Importing I_ACT_ELEMENT Call by reference Type reference (TYPE) I Element to be dropped 20031204
2 Returning R_ACT_ELEMENT Value transfer Type reference (TYPE) I Parent of dropped branch 20031204

Method DROP_BRANCH on class CL_RSDRS_WHERE_TREE has no exception.

Method DROP_NODE Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Importing I_ACT_ELEMENT Call by reference Type reference (TYPE) I Element to be dropped 20031204
2 Returning R_ACT_ELEMENT Value transfer Type reference (TYPE) I Parent of dropped element 20031204

Method DROP_NODE on class CL_RSDRS_WHERE_TREE has no exception.

Method GET_ROOT Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Returning R_ROOT_ELEMENT Value transfer Type reference (TYPE) I Root Element 20031204

Method GET_ROOT on class CL_RSDRS_WHERE_TREE has no exception.

Method IS_NEGATED Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Importing I_ACT_ELEMENT Call by reference Type reference (TYPE) I Element to check 20031204
2 Returning R_IS_NEGATED Value transfer Type reference (TYPE) RS_BOOL True: Element is negated 20031204

Method IS_NEGATED on class CL_RSDRS_WHERE_TREE has no exception.

Method NEGATE Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Importing I_ACT_ELEMENT Call by reference Type reference (TYPE) I Element to be negated 20031204

Method NEGATE on class CL_RSDRS_WHERE_TREE has no exception.

Method NEGATE_BOOL_VAL Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Changing C_VALUE Call by reference Type reference (TYPE) TN_BOOL_VAL value to negate 20031204

Method NEGATE_BOOL_VAL on class CL_RSDRS_WHERE_TREE has no exception.

Method NORMALIZE Signature

Method NORMALIZE on class CL_RSDRS_WHERE_TREE has no parameter.
Method NORMALIZE on class CL_RSDRS_WHERE_TREE has no exception.

Method NORMALIZE_CHECK_12 Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Changing C_ACT_ELEM Call by reference Type reference (TYPE) I key of actual element 20050308
2 Exporting E_BOOL_VALUE Call by reference Type reference (TYPE) TN_BOOL_VAL Boolean value of actual element 20050308
3 Exporting E_CHECKED Call by reference Type reference (TYPE) RS_BOOL Check has matched 20050308
4 Importing I_ACT_ELEM Call by reference Type reference (TYPE) TN_S_WH_ELEM 20050308
5 Importing I_BOOL_VALUE Call by reference Type reference (TYPE) TN_BOOL_VAL Bool value of fixed child 20050308

Method NORMALIZE_CHECK_12 on class CL_RSDRS_WHERE_TREE has no exception.

Method READ_WITH_DS Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Changing C_COND_LEVEL Call by reference Type reference (TYPE) I bracket level of last condition 20031204
2 Changing C_T_WHERE Call by reference Type reference (TYPE) RSDRS_T_WHERE new where conditions 20031204
3 Importing I_ACT_ELEM Call by reference Type reference (TYPE) I key of actual element 20031204
4 Importing I_LEVEL Call by reference Type reference (TYPE) I bracket level of actual element 20031204
5 Importing I_OPERATOR Call by reference Type reference (TYPE) I key of operator portion 20031204
6 Importing I_OP_NOT Call by reference Type reference (TYPE) RS_BOOL additional not operator ? 20031204
7 Importing I_PARENT_OP Call by reference Type reference (TYPE) RSDRS_BOOLOP parent operator (for level check) 20031204

Method READ_WITH_DS on class CL_RSDRS_WHERE_TREE has no exception.

Method _ADD_TREE Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Importing I_ACT_ELEMENT Call by reference Type reference (TYPE) I Element where to insert the boolop at 20040316
2 Importing I_LEFT Call by reference Type reference (TYPE) RS_BOOL Insert as left child (Only for emergency cases !!!) 20040316
3 Importing I_R_WHERE_TREE Call by reference Object reference (TYPE REF TO) CL_RSDRS_WHERE_TREE Where Tree to insert 20040316
4 Importing I_TREE_ACT_ELEM Call by reference Type reference (TYPE) I Actual Element in inserted tree 20040316

Method _ADD_TREE on class CL_RSDRS_WHERE_TREE has no exception.

Method _BUILD_TREE Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Importing I_TH_KEY_TAB Call by reference Type reference (TYPE) TN_TH_KEY_TAB Query table aliases to use 20040122
2 Importing I_T_WHERE Call by reference Type reference (TYPE) RSDRS_T_WHERE where conditions to build tree for 20040122

Method _BUILD_TREE on class CL_RSDRS_WHERE_TREE has no exception.

Method _NORMALIZE Signature

# Type Parameter Pass Value Optional Typing Method Associated Type Default value Description Created on
1 Changing C_ACT_ELEM Call by reference Type reference (TYPE) I key of actual element 20050310
2 Exporting E_BOOL_VALUE Call by reference Type reference (TYPE) TN_BOOL_VAL Boolean value of actual element 20050310
3 Importing I_NOT_COUNT Call by reference Type reference (TYPE) I number of not-ops for this node 20050310

Method _NORMALIZE on class CL_RSDRS_WHERE_TREE has no exception.
History
Last changed by/on SAP  20130531 
SAP Release Created in 400