1 package com.daffodilwoods.daffodildb.server.sql99.expression; 2 3 import com.daffodilwoods.daffodildb.server.sql99.common.*; 4 import com.daffodilwoods.daffodildb.server.sql99.utils.*; 5 import com.daffodilwoods.database.resource.*; 6 7 public class columnnamelist implements com.daffodilwoods.daffodildb.utils.parser.StatementExecuter { 8 9 public columnname[] _OptRepScomma94843605columnname0; 10 11 public void setDefaultValues(_VariableValueOperations variableValueOperation) throws DException { 12 } 13 14 public boolean checkForSubQuery() throws DException { 15 return false; 16 } 17 18 public _Reference[] getReferences(TableDetails[] tableDetails) throws DException { 19 throw new DException("DSE565", new Object [] {"getReferences()"}); 20 } 21 22 public Object run(Object object) throws com.daffodilwoods.database.resource.DException { 23 int length = _OptRepScomma94843605columnname0.length; 24 String [] temp = new String [length]; 25 for (int i = 0; i < length; i++) { 26 temp[i] = (String ) _OptRepScomma94843605columnname0[i].run(object); 27 } 28 return temp; 29 } 30 31 public java.util.ArrayList get_columns() throws DException { 32 int length = _OptRepScomma94843605columnname0.length; 33 java.util.ArrayList list = new java.util.ArrayList (length); 34 for (int i = 0; i < length; i++) { 35 list.add( (String ) _OptRepScomma94843605columnname0[i].run(null)); 36 } 37 return list; 38 } 39 40 public ColumnDetails[] getColumnDetails() throws DException { 41 int length = _OptRepScomma94843605columnname0.length; 42 ColumnDetails[] result = new ColumnDetails[length]; 43 for (int i = 0; i < length; i++) { 44 result[i] = new ColumnDetails(); 45 result[i].setColumnName(new String [] { (String ) _OptRepScomma94843605columnname0[i].run(null)}); 46 } 47 return result; 48 } 49 50 public ColumnDetails[] getColumnDetailsFull() throws DException { 51 int length = _OptRepScomma94843605columnname0.length; 52 ColumnDetails[] result = new ColumnDetails[length]; 53 for (int i = 0; i < length; i++) { 54 result[i] = new ColumnDetails(); 55 result[i].setColumnName( (String []) _OptRepScomma94843605columnname0[i].getColumnName(null)); 56 result[i].setType(TypeConstants.REFERENCE); 57 } 58 return result; 59 } 60 61 public ParameterInfo[] getParameterInfo() throws DException { 62 int length = _OptRepScomma94843605columnname0.length; 63 ParameterInfo[] toReturn = new ParameterInfo[length]; 64 for (int i = 0; i < length; i++) { 65 String str = (String ) _OptRepScomma94843605columnname0[i].run(null); 66 toReturn[i] = new ParameterInfo(); 67 toReturn[i].setName(str); 68 } 69 return toReturn; 70 } 71 72 public String toString() { 73 StringBuffer sb = new StringBuffer (); 74 sb.append(" "); 75 sb.append(_OptRepScomma94843605columnname0[0]); 76 for (int i = 1; i < _OptRepScomma94843605columnname0.length; i++) { 77 sb.append(",").append(_OptRepScomma94843605columnname0[i]); 78 } 79 return sb.toString(); 80 } 81 82 public Object clone() throws CloneNotSupportedException { 83 columnnamelist tempClass = new columnnamelist(); 84 if (_OptRepScomma94843605columnname0 != null) { 85 columnname[] temp_OptRepScomma94843605columnname0 = new columnname[_OptRepScomma94843605columnname0.length]; 86 for (int i = 0; i < _OptRepScomma94843605columnname0.length; i++) { 87 temp_OptRepScomma94843605columnname0[i] = (columnname) _OptRepScomma94843605columnname0[i].clone(); 88 } 89 tempClass._OptRepScomma94843605columnname0 = temp_OptRepScomma94843605columnname0; 90 } 91 return tempClass; 92 } 93 } 94 | Popular Tags |