Package model

Examples of model.SQLData$ForiegnKeyData


        SQLGenerator sqlGenerator = new SQLGenerator();
        System.out.println(sqlGenerator.generateSQLCreateQuery(data));
    }

    public static void testJPAClassGen() {
        SQLData data = createSQLData();
        JPAClassGenerator jpaClassGenerator = new JPAClassGenerator();
        jpaClassGenerator.setJpaClassPackageName("org.apache.aiaravata.application.catalog.data.model");
        JPAClassModel model = jpaClassGenerator.createJPAClassModel(data);
        System.out.println(jpaClassGenerator.generateJPAClass(model));
        System.out.println(jpaClassGenerator.generateJPAPKClass(model.pkClassModel));
View Full Code Here


        System.out.println(jpaClassGenerator.generateJPAPKClass(model.pkClassModel));
        System.out.println(jpaClassGenerator.generatePersistenceXmlEntry(model));
    }

    public static void testJPAResourceClassGen() {
        SQLData data = createSQLData();
        JPAClassGenerator jpaClassGenerator = new JPAClassGenerator();
        JPAClassModel model = jpaClassGenerator.createJPAClassModel(data);
        JPAResourceClassGenerator jpaResourceClassGenerator = new JPAResourceClassGenerator();
        jpaResourceClassGenerator.setExceptionClassName("AppCatalogException");
        jpaResourceClassGenerator.setJpaUtilsClassName("AppCatalogJPAUtils");
View Full Code Here

import model.JPAResourceClassModel;
import model.SQLData;

public class LocalSubmissionGenerator {
  private static SQLData createSQLData() {
    SQLData data = new SQLData();
    data.setTableName("LOCAL_SUBMISSION");
    data.getFieldData().put("JOB_SUBMISSION_INTERFACE_ID", Arrays.asList(new String[]{"VARCHAR", "(255)", "NOT", "NULL"}));
    data.getFieldData().put("RESOURCE_JOB_MANAGER_ID", Arrays.asList(new String[]{"VARCHAR", "(255)", "NOT", "NULL"}));
    data.getPrimaryKeys().add("JOB_SUBMISSION_INTERFACE_ID");
    data.getForiegnKeys().put("RESOURCE_JOB_MANAGER_ID", new SQLData.ForiegnKeyData("RESOURCE_JOB_MANAGER(RESOURCE_JOB_MANAGER_ID)","ResourceJobManager","ResourceJobManagerResource"));
    return data;
  }
View Full Code Here

    data.getPrimaryKeys().add("JOB_SUBMISSION_INTERFACE_ID");
    data.getForiegnKeys().put("RESOURCE_JOB_MANAGER_ID", new SQLData.ForiegnKeyData("RESOURCE_JOB_MANAGER(RESOURCE_JOB_MANAGER_ID)","ResourceJobManager","ResourceJobManagerResource"));
    return data;
  }
  public static void testSqlGen() {
    SQLData data = createSQLData();
    SQLGenerator sqlGenerator = new SQLGenerator();
    System.out.println(sqlGenerator.generateSQLCreateQuery(data));
  }
View Full Code Here

    SQLGenerator sqlGenerator = new SQLGenerator();
    System.out.println(sqlGenerator.generateSQLCreateQuery(data));
  }
 
  public static void testJPAClassGen() {
    SQLData data = createSQLData();
    JPAClassGenerator jpaClassGenerator = new JPAClassGenerator();
    jpaClassGenerator.setJpaClassPackageName("org.apache.aiaravata.application.catalog.data.model");
    JPAClassModel model = jpaClassGenerator.createJPAClassModel(data);
    System.out.println(jpaClassGenerator.generateJPAClass(model));
    System.out.println(jpaClassGenerator.generateJPAPKClass(model.pkClassModel));
View Full Code Here

    System.out.println(jpaClassGenerator.generateJPAPKClass(model.pkClassModel));
    System.out.println(jpaClassGenerator.generatePersistenceXmlEntry(model));
  }
 
  public static void testJPAResourceClassGen() {
    SQLData data = createSQLData();
    JPAClassGenerator jpaClassGenerator = new JPAClassGenerator();
    JPAClassModel model = jpaClassGenerator.createJPAClassModel(data);
    JPAResourceClassGenerator jpaResourceClassGenerator = new JPAResourceClassGenerator();
    jpaResourceClassGenerator.setExceptionClassName("AppCatalogException");
    jpaResourceClassGenerator.setJpaUtilsClassName("AppCatalogJPAUtils");
View Full Code Here

public class Test {


  private static SQLData createSQLData() {
    SQLData data = new SQLData();
    data.setTableName("COMMUNITY_USER");
    data.getFieldData().put("GATEWAY_NAME", Arrays.asList(new String[]{"VARCHAR", "256", "NOT", "NULL"}));
    data.getFieldData().put("COMMUNITY_USER_NAME", Arrays.asList(new String[]{"VARCHAR", "256", "NOT", "NULL"}));
    data.getFieldData().put("TOKEN_ID", Arrays.asList(new String[]{"VARCHAR", "256", "NOT", "NULL"}));
    data.getFieldData().put("COMMUNITY_USER_EMAIL", Arrays.asList(new String[]{"VARCHAR", "256", "NOT", "NULL"}));
    data.getFieldData().put("CREATION_TIME", Arrays.asList(new String[]{"TIMESTAMP", "DEFAULT", "NOW()"}));
    data.getFieldData().put("CPU_COUNT", Arrays.asList(new String[]{"INTEGER"}));
    data.getPrimaryKeys().add("GATEWAY_NAME");
    data.getPrimaryKeys().add("COMMUNITY_USER_NAME");
    data.getPrimaryKeys().add("TOKEN_ID");
    data.getForiegnKeys().put("EXPERIMENT_ID", new SQLData.ForiegnKeyData("EXPERIMENT(EXPERIMENT_ID)","Experiment","ExperimentResource"));
    return data;
  }
View Full Code Here

import model.JPAResourceClassModel;
import model.SQLData;

public class SSHJobSubmissionGenerator {
  private static SQLData createSQLData() {
    SQLData data = new SQLData();
    data.setTableName("SSH_JOB_SUBMISSION");
    data.getFieldData().put("JOB_SUBMISSION_INTERFACE_ID", Arrays.asList(new String[]{"VARCHAR", "(255)", "NOT", "NULL"}));
    data.getFieldData().put("SECURITY_PROTOCOL", Arrays.asList(new String[]{"VARCHAR", "(255)", "NOT", "NULL"}));
    data.getFieldData().put("RESOURCE_JOB_MANAGER_ID", Arrays.asList(new String[]{"VARCHAR", "(255)","NOT", "NULL"}));
    data.getFieldData().put("ALTERNATIVE_SSH_HOSTNAME", Arrays.asList(new String[]{"VARCHAR", "(255)"}));
    data.getFieldData().put("SSH_PORT", Arrays.asList(new String[]{"INTEGER"}));
    data.getPrimaryKeys().add("JOB_SUBMISSION_INTERFACE_ID");
    data.getForiegnKeys().put("RESOURCE_JOB_MANAGER_ID", new SQLData.ForiegnKeyData("RESOURCE_JOB_MANAGER(RESOURCE_JOB_MANAGER_ID)","ResourceJobManager","ResourceJobManagerResource"));
    return data;
  }
View Full Code Here

    data.getPrimaryKeys().add("TOKEN_ID");
    data.getForiegnKeys().put("EXPERIMENT_ID", new SQLData.ForiegnKeyData("EXPERIMENT(EXPERIMENT_ID)","Experiment","ExperimentResource"));
    return data;
  }
  public static void testSqlGen() {
    SQLData data = createSQLData();
    SQLGenerator sqlGenerator = new SQLGenerator();
    System.out.println(sqlGenerator.generateSQLCreateQuery(data));
  }
View Full Code Here

    SQLGenerator sqlGenerator = new SQLGenerator();
    System.out.println(sqlGenerator.generateSQLCreateQuery(data));
  }
 
  public static void testJPAClassGen() {
    SQLData data = createSQLData();
    JPAClassGenerator jpaClassGenerator = new JPAClassGenerator();
    JPAClassModel model = jpaClassGenerator.createJPAClassModel(data);
    System.out.println(jpaClassGenerator.generateJPAClass(model));
    System.out.println(jpaClassGenerator.generateJPAPKClass(model.pkClassModel));
  }
View Full Code Here

TOP

Related Classes of model.SQLData$ForiegnKeyData

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.