本文整理汇总了Java中org.insightech.er.db.impl.postgres.tablespace.PostgresTablespaceProperties类的典型用法代码示例。如果您正苦于以下问题:Java PostgresTablespaceProperties类的具体用法?Java PostgresTablespaceProperties怎么用?Java PostgresTablespaceProperties使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
PostgresTablespaceProperties类属于org.insightech.er.db.impl.postgres.tablespace包,在下文中一共展示了PostgresTablespaceProperties类的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getDDL
import org.insightech.er.db.impl.postgres.tablespace.PostgresTablespaceProperties; //导入依赖的package包/类
@Override
protected String getDDL(final Tablespace tablespace) {
final PostgresTablespaceProperties tablespaceProperties = (PostgresTablespaceProperties) tablespace.getProperties(environment, getDiagram());
final StringBuilder ddl = new StringBuilder();
ddl.append("CREATE TABLESPACE ");
ddl.append(filterName(tablespace.getName()));
ddl.append(LF());
if (!Check.isEmpty(tablespaceProperties.getOwner())) {
ddl.append(" OWNER ");
ddl.append(tablespaceProperties.getOwner());
ddl.append(LF());
}
ddl.append(" LOCATION '");
ddl.append(tablespaceProperties.getLocation());
ddl.append("'" + LF());
if (semicolon) {
ddl.append(";");
}
return ddl.toString();
}
示例2: checkTablespaceProperties
import org.insightech.er.db.impl.postgres.tablespace.PostgresTablespaceProperties; //导入依赖的package包/类
@Override
public TablespaceProperties checkTablespaceProperties(final TablespaceProperties tablespaceProperties) {
if (!(tablespaceProperties instanceof PostgresTablespaceProperties)) {
return new PostgresTablespaceProperties();
}
return tablespaceProperties;
}
示例3: createXML
import org.insightech.er.db.impl.postgres.tablespace.PostgresTablespaceProperties; //导入依赖的package包/类
private String createXML(final Tablespace tablespace, final PersistentContext context) {
final StringBuilder xml = new StringBuilder();
xml.append("<tablespace>\n");
if (context != null) {
xml.append("\t<id>").append(context.tablespaceMap.get(tablespace)).append("</id>\n");
}
xml.append("\t<name>").append(escape(tablespace.getName())).append("</name>\n");
for (final Map.Entry<Environment, TablespaceProperties> entry : tablespace.getPropertiesMap().entrySet()) {
final Environment environment = entry.getKey();
final TablespaceProperties tablespaceProperties = entry.getValue();
xml.append("\t<properties>\n");
xml.append("\t\t<environment_id>").append(context.environmentMap.get(environment)).append("</environment_id>\n");
if (tablespaceProperties instanceof DB2TablespaceProperties) {
xml.append(tab(tab(this.createXML((DB2TablespaceProperties) tablespaceProperties))));
} else if (tablespaceProperties instanceof MySQLTablespaceProperties) {
xml.append(tab(tab(this.createXML((MySQLTablespaceProperties) tablespaceProperties))));
} else if (tablespaceProperties instanceof OracleTablespaceProperties) {
xml.append(tab(tab(this.createXML((OracleTablespaceProperties) tablespaceProperties))));
} else if (tablespaceProperties instanceof PostgresTablespaceProperties) {
xml.append(tab(tab(this.createXML((PostgresTablespaceProperties) tablespaceProperties))));
}
xml.append("\t</properties>\n");
}
xml.append("</tablespace>\n");
return xml.toString();
}
示例4: loadTablespacePropertiesPostgres
import org.insightech.er.db.impl.postgres.tablespace.PostgresTablespaceProperties; //导入依赖的package包/类
private TablespaceProperties loadTablespacePropertiesPostgres(final Element element) {
final PostgresTablespaceProperties properties = new PostgresTablespaceProperties();
properties.setLocation(getStringValue(element, "location"));
properties.setOwner(getStringValue(element, "owner"));
return properties;
}
示例5: checkTablespaceProperties
import org.insightech.er.db.impl.postgres.tablespace.PostgresTablespaceProperties; //导入依赖的package包/类
public TablespaceProperties checkTablespaceProperties(
TablespaceProperties tablespaceProperties) {
if (!(tablespaceProperties instanceof PostgresTablespaceProperties)) {
return new PostgresTablespaceProperties();
}
return tablespaceProperties;
}
示例6: getDDL
import org.insightech.er.db.impl.postgres.tablespace.PostgresTablespaceProperties; //导入依赖的package包/类
@Override
protected String getDDL(Tablespace tablespace) {
PostgresTablespaceProperties tablespaceProperties = (PostgresTablespaceProperties) tablespace
.getProperties(this.environment, this.getDiagram());
StringBuilder ddl = new StringBuilder();
ddl.append("CREATE TABLESPACE ");
ddl.append(filterName(tablespace.getName()));
ddl.append(LF());
if (!Check.isEmpty(tablespaceProperties.getOwner())) {
ddl.append(" OWNER ");
ddl.append(tablespaceProperties.getOwner());
ddl.append(LF());
}
ddl.append(" LOCATION '");
ddl.append(tablespaceProperties.getLocation());
ddl.append("'" + LF());
if (this.semicolon) {
ddl.append(";");
}
return ddl.toString();
}
示例7: createXML
import org.insightech.er.db.impl.postgres.tablespace.PostgresTablespaceProperties; //导入依赖的package包/类
private String createXML(PostgresTablespaceProperties tablespace) {
StringBuilder xml = new StringBuilder();
xml.append("<location>").append(escape(tablespace.getLocation()))
.append("</location>\n");
xml.append("<owner>").append(escape(tablespace.getOwner()))
.append("</owner>\n");
return xml.toString();
}
示例8: loadTablespacePropertiesPostgres
import org.insightech.er.db.impl.postgres.tablespace.PostgresTablespaceProperties; //导入依赖的package包/类
private TablespaceProperties loadTablespacePropertiesPostgres(
Element element) {
PostgresTablespaceProperties properties = new PostgresTablespaceProperties();
properties.setLocation(this.getStringValue(element, "location"));
properties.setOwner(this.getStringValue(element, "owner"));
return properties;
}
示例9: createTablespaceProperties
import org.insightech.er.db.impl.postgres.tablespace.PostgresTablespaceProperties; //导入依赖的package包/类
@Override
public TablespaceProperties createTablespaceProperties() {
return new PostgresTablespaceProperties();
}
示例10: createTablespaceProperties
import org.insightech.er.db.impl.postgres.tablespace.PostgresTablespaceProperties; //导入依赖的package包/类
public TablespaceProperties createTablespaceProperties() {
return new PostgresTablespaceProperties();
}