org.hibernate.tool.hbm2ddl.IndexMetadata Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of hibernate-ant Show documentation
Show all versions of hibernate-ant Show documentation
Annotation Processor to generate JPA 2 static metamodel classes
The newest version!
/*
* SPDX-License-Identifier: Apache-2.0
* Copyright Red Hat Inc. and Hibernate Authors
*/
package org.hibernate.tool.hbm2ddl;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.util.ArrayList;
import java.util.List;
/**
* JDBC index metadata
* @author Christoph Sturm
*
* @deprecated Everything in this package has been replaced with
* {@link org.hibernate.tool.schema.spi.SchemaManagementTool} and friends.
*/
@Deprecated
public class IndexMetadata {
private final String name;
private final List columns = new ArrayList();
IndexMetadata(ResultSet rs) throws SQLException {
name = rs.getString("INDEX_NAME");
}
public String getName() {
return name;
}
void addColumn(ColumnMetadata column) {
if (column != null) {
columns.add(column);
}
}
public ColumnMetadata[] getColumns() {
return (ColumnMetadata[]) columns.toArray(new ColumnMetadata[0]);
}
public String toString() {
return "IndexMatadata(" + name + ')';
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy