1 /* JJT: 0.2.2 */ 2 3 package mobisnap.mobile_trx; 4 5 /*** 6 * Creates snapshot 7 * 8 */ 9 public class ASTUpdateSnapshot extends mobisnap.mobile_trx.SimpleNode { 10 ASTTableReference tablename; 11 ASTQueryStatement query; 12 13 public ASTUpdateSnapshot(int id) { 14 super(id); 15 } 16 17 public ASTUpdateSnapshot( MobisnapSQL p, int i) { 18 super( p, i); 19 id = i; 20 } 21 22 /*** Accept the visitor. **/ 23 public Object jjtAccept(MobisnapSQLVisitor visitor, Object data) { 24 return visitor.visit(this, data); 25 } 26 27 public void process( int msql_type) throws Exception { 28 throw new mobisnap.MobisnapException( "Not defined"); 29 } 30 31 public String snapshotName( int msql_type) throws Exception { 32 StringBuffer buffer = new StringBuffer(); 33 tablename.sourceCode( msql_type, buffer); 34 return buffer.toString().trim(); 35 } 36 37 public String queryStatement( int msql_type) throws Exception { 38 StringBuffer buffer = new StringBuffer(); 39 query.sourceCode( msql_type, buffer); 40 return buffer.toString().trim(); 41 } 42 43 public String whereQueryExpression( int msql_type) throws Exception { 44 StringBuffer buffer = new StringBuffer(); 45 if (query.where == null) 46 return null; 47 query.where.sourceCode( msql_type, buffer); 48 return buffer.toString().trim(); 49 } 50 }

This page was automatically generated by Maven