Back to project page sqlite-provider.
The source code is released under:
Apache License
If you think the Android project sqlite-provider listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package novoda.rest.database; //from w w w .j av a 2s .co m public class SQLiteTableCreatorWrapper implements SQLiteTableCreator { private String[] appendColumns = new String[]{}; private final SQLiteTableCreator wrapped; public SQLiteTableCreatorWrapper(SQLiteTableCreator original) { this.wrapped = original; } @Override public String getParentColumnName() { return wrapped.getParentColumnName(); } @Override public String getParentPrimaryKey() { return wrapped.getParentPrimaryKey(); } @Override public String getParentTableName() { return wrapped.getParentTableName(); } @Override public SQLiteType getParentType() { return wrapped.getParentType(); } @Override public String getPrimaryKey() { return wrapped.getPrimaryKey(); } @Override public String[] getTableFields() { String[] cursor = new String[wrapped.getTableFields().length + appendColumns.length]; System.arraycopy(wrapped.getTableFields(), 0, cursor, 0, wrapped.getTableFields().length); System.arraycopy(appendColumns, 0, cursor, wrapped.getTableFields().length, appendColumns.length); return cursor; } @Override public String getTableName() { return wrapped.getTableName(); } @Override public String[] getTriggers() { return wrapped.getTriggers(); } @Override public SQLiteType getType(String field) { return wrapped.getType(field); } @Override public boolean isNullAllowed(String field) { return wrapped.isNullAllowed(field); } @Override public boolean isOneToMany() { return wrapped.isOneToMany(); } @Override public boolean isUnique(String field) { return wrapped.isUnique(field); } @Override public SQLiteConflictClause onConflict(String field) { return wrapped.onConflict(field); } @Override public boolean shouldIndex(String field) { return wrapped.shouldIndex(field); } @Override public boolean shouldPKAutoIncrement() { return wrapped.shouldPKAutoIncrement(); } public void appendColumns(String[] columns) { this.appendColumns = (columns != null) ? columns.clone() : new String[]{}; } }