Coverage Report - liquibase.sqlgenerator.core.GetViewDefinitionGeneratorFirebird
 
Classes in this File Line Coverage Branch Coverage Complexity
GetViewDefinitionGeneratorFirebird
50%
2/4
N/A
1
 
 1  
 package liquibase.sqlgenerator.core;
 2  
 
 3  
 import liquibase.database.Database;
 4  
 import liquibase.database.core.FirebirdDatabase;
 5  
 import liquibase.sql.Sql;
 6  
 import liquibase.sql.UnparsedSql;
 7  
 import liquibase.sqlgenerator.SqlGeneratorChain;
 8  
 import liquibase.statement.core.GetViewDefinitionStatement;
 9  
 
 10  10
 public class GetViewDefinitionGeneratorFirebird extends GetViewDefinitionGenerator {
 11  
     @Override
 12  
     public int getPriority() {
 13  1
         return PRIORITY_DATABASE;
 14  
     }
 15  
 
 16  
     @Override
 17  
     public boolean supports(GetViewDefinitionStatement statement, Database database) {
 18  0
         return database instanceof FirebirdDatabase;
 19  
     }
 20  
 
 21  
     @Override
 22  
     public Sql[] generateSql(GetViewDefinitionStatement statement, Database database,
 23  
             SqlGeneratorChain sqlGeneratorChain) {
 24  0
         return new Sql[] { new UnparsedSql("select rdb$view_source from rdb$relations where upper(rdb$relation_name)='"
 25  
                 + statement.getViewName() + "'") };
 26  
     }
 27  
 }