|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectmondrian.rolap.aggmatcher.Recognizer
mondrian.rolap.aggmatcher.DefaultRecognizer
class DefaultRecognizer
This is the default Recognizer. It uses the rules found in the file DefaultRules.xml to find aggregate tables and there columns.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class mondrian.rolap.aggmatcher.Recognizer |
|---|
Recognizer.Matcher |
| Field Summary |
|---|
| Fields inherited from class mondrian.rolap.aggmatcher.Recognizer |
|---|
aggTable, dbFactTable, msgRecorder, returnValue, star |
| Constructor Summary | |
|---|---|
DefaultRecognizer(DefaultRules aggDefault,
RolapStar star,
JdbcSchema.Table dbFactTable,
JdbcSchema.Table aggTable,
MessageRecorder msgRecorder)
|
|
| Method Summary | |
|---|---|
protected int |
checkMeasures()
Create measures for an aggregate table. |
protected Recognizer.Matcher |
getFactCountMatcher()
Get the Matcher to be used to match the column which is the fact count column. |
protected Recognizer.Matcher |
getIgnoreMatcher()
Get the Matcher to be used to match columns to be ignored. |
protected Recognizer.Matcher |
getMeasureMatcher(JdbcSchema.Table.Column.Usage factUsage)
Get the Match used to identify columns that are measures. |
(package private) DefaultRules |
getRules()
Get the DefaultRules instance associated with this object. |
protected int |
matchForeignKey(JdbcSchema.Table.Column.Usage factUsage)
This creates a foreign key usage. |
protected void |
matchLevels(Hierarchy hierarchy,
HierarchyUsage hierarchyUsage)
Create level usages. |
| Methods inherited from class mondrian.rolap.aggmatcher.Recognizer |
|---|
check, checkFactCount, checkForeignKeys, checkIgnores, checkLevels, checkNosMeasures, checkUnusedColumns, convertAggregator, convertAggregator, findCubes, generateImpliedMeasures, getColumnName, inNotSeenForeignKeys, lookupInChildren, makeFactCount, makeForeignKey, makeIgnore, makeLevel, makeMeasure, makeMeasure |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
DefaultRecognizer(DefaultRules aggDefault,
RolapStar star,
JdbcSchema.Table dbFactTable,
JdbcSchema.Table aggTable,
MessageRecorder msgRecorder)
| Method Detail |
|---|
DefaultRules getRules()
protected Recognizer.Matcher getIgnoreMatcher()
getIgnoreMatcher in class Recognizerprotected Recognizer.Matcher getFactCountMatcher()
getFactCountMatcher in class Recognizerprotected Recognizer.Matcher getMeasureMatcher(JdbcSchema.Table.Column.Usage factUsage)
protected int checkMeasures()
First, iterator through all fact table measure usages. Create a Matcher for each such usage. Iterate through all aggregate table columns. For each column that matches create a measure usage.
Per fact table measure usage, at most only one aggregate measure should be created.
checkMeasures in class Recognizerprotected int matchForeignKey(JdbcSchema.Table.Column.Usage factUsage)
Using the foreign key Matcher with the fact usage's column name the aggregate table's columns are searched for one that matches. For each that matches a foreign key usage is created (thought if more than one is created its is an error which is handled in the calling code.
matchForeignKey in class Recognizer
protected void matchLevels(Hierarchy hierarchy,
HierarchyUsage hierarchyUsage)
A Matcher is created using the Hierarchy's name, the RolapLevel name, and the column name associated with the RolapLevel's key expression. The aggregate table columns are search for the first match and, if found, a level usage is created for that column.
matchLevels in class Recognizer
|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||