|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eclipse.datatools.enablement.oda.xml.util.MappingPathElementTree
public class MappingPathElementTree
A tree constructed by table mapping path and its column mapping paths.
One path element is corresponding with a TreeNode.
This tree is mainly used to accelerate the following operations:
1. Whether a path generated during xml file parsing matches table mapping path,
see matchesTablePath method
2. What columns a path generated during xml file parsing can match
see getMatchedColumnIndex method
3. For a table path "tp", given a not nested column path "cp", what columns cp can match
see getMatchedButNotNestedColumnIndexes method
4. For a table path "tp", given a nested column path "cp", Whether cp is a valid nested column for tp
see isValidNestedColumn method
Notes: A nested column, generally contains "..", means this column cannot reachable just down from table path
| Field Summary | |
|---|---|
static java.lang.String |
ASTERISK
|
static java.lang.String |
ATTR_MARKER
|
static java.lang.String |
DOUBLE_SLASH
|
static java.lang.String |
DOUBLE_SLASH_REPLACEMENT
|
static java.lang.String |
FORWARD_SLASH
|
| Constructor Summary | |
|---|---|
MappingPathElementTree(java.lang.String tablePath,
java.lang.String[] relativeColumnPaths)
|
|
| Method Summary | |
|---|---|
int[] |
getMatchedButNotNestedColumnIndexs(XMLPath column,
XMLPath row)
return all the indexes of matched columns which path is column and is reachable down from row |
int[] |
getMatchedColumnIndexs(XMLPath path)
return all the possible matched column indexes for a XML path. |
int[] |
getNestedColumnIndexes()
|
boolean |
isNestedColumn(int index)
whether the column is a nested column |
boolean |
isValidNestedColumn(int index,
XMLPath row,
XMLPath column)
whether column is row's nested column, which index is index |
static boolean |
isValidTableMappingPath(java.lang.String tablePath)
Whether tablePath is a valid table mapping path |
boolean |
matchesTablePath(XMLPath path)
whether this xml path matches the table mapping path |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String DOUBLE_SLASH_REPLACEMENT
public static final java.lang.String FORWARD_SLASH
public static final java.lang.String DOUBLE_SLASH
public static final java.lang.String ASTERISK
public static final java.lang.String ATTR_MARKER
| Constructor Detail |
|---|
public MappingPathElementTree(java.lang.String tablePath,
java.lang.String[] relativeColumnPaths)
tablePath: - the mapping path of the table, the result of filter condition removing and needless parent axis removingrelativeColumnPaths: - the relative column paths, the result of filter condition removing and needless parent axis removing| Method Detail |
|---|
public boolean matchesTablePath(XMLPath path)
path - public int[] getMatchedColumnIndexs(XMLPath path)
path: -
public int[] getMatchedButNotNestedColumnIndexs(XMLPath column,
XMLPath row)
column and is reachable down from row
column: - row: -
public boolean isNestedColumn(int index)
index -
public int[] getNestedColumnIndexes()
public boolean isValidNestedColumn(int index,
XMLPath row,
XMLPath column)
index
index - row: - column: -
public static boolean isValidTableMappingPath(java.lang.String tablePath)
tablePath: - table mapping path
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||