Esempio n. 1
0
func (config *Config) ExcludedTables() []message.Table {
	var tables []message.Table
	for tableName, columns := range config.ExcludeRelations {
		table := message.TableFromFullName(tableName)
		if table != nil && (len(columns) != 0 || columns[0] != "*") {
			tables = append(tables, *table)
		}
	}
	return tables
}
Esempio n. 2
0
func (config *Config) IncludedTables() []message.Table {
	var tables []message.Table
	if len(config.IncludeRelations) > 0 {
		for tableName, _ := range config.IncludeRelations {
			table := message.TableFromFullName(tableName)
			if table != nil {
				tables = append(tables, *table)
			}

		}
	}
	return tables
}