TableSchema { public static TableSchema deserialize(byte[] serializedTableSchema) { checkNotNull(serializedTableSchema); checkArgument(serializedTableSchema.length > 0); SchemaVersionUtils.processSchemaVersion(serializedTableSchema[0], TableSchemaInfo.VER_CURRENT); return new TableSchema(Util.deserializeAvroObject(serializedTableSchema, reader)); } TableSchema(Collection<ColumnSchema> columns, Collection<IndexSchema> indices); private  TableSchema(AvroTableSchema avroTableSchema); static TableSchema deserialize(byte[] serializedTableSchema); TableSchema schemaCopy(); byte[] serialize(); Collection<ColumnSchema> getColumns(); Collection<IndexSchema> getIndices(); void addIndices(Collection<IndexSchema> indices); void removeIndex(String indexName); boolean hasIndices(); boolean hasUniqueIndices(); ColumnSchema getColumnSchema(String columnName); IndexSchema getIndexSchema(String indexName); String getAutoIncrementColumn(); @Override boolean equals(Object o); @Override int hashCode(); @Override String toString();  }
@Test(expected = NullPointerException.class) public void testDeserializeNullSerializedSchema() { TableSchema.deserialize(null); }
@Test(expected = IllegalArgumentException.class) public void testDeserializeEmptySerializedSchema() { TableSchema.deserialize(new byte[0]); }