Package org.apache.derby.ui.properties

Examples of org.apache.derby.ui.properties.DerbyProperties


    String launchType="";
    String args="";
   
    //the above some times throws wrong 'create=true|false' errors
    String vmargs="";
    DerbyProperties dprop=new DerbyProperties(currentProject);
    if((dprop.getSystemHome()!=null)&& !(dprop.getSystemHome().equals(""))){
      vmargs+=CommonNames.D_SYSTEM_HOME+dprop.getSystemHome();
    }
   
    if(currentScript!=null){
      launchType=CommonNames.SQL_SCRIPT;
     
View Full Code Here


    String launchType="";
    String args="";
   
    //the above some times throws wrong 'create=true|false' errors
    String vmargs="";
    DerbyProperties dprop=new DerbyProperties(currentProject);
    if((dprop.getSystemHome()!=null)&& !(dprop.getSystemHome().equals(""))){
      vmargs+=CommonNames.D_SYSTEM_HOME+dprop.getSystemHome();
    }
   
    if(currentScript!=null){
      launchType=CommonNames.SQL_SCRIPT;
     
View Full Code Here

  }

  public void startDerbyServer( IProject proj) throws CoreException {
    String args = CommonNames.START_DERBY_SERVER;
    String vmargs="";
    DerbyProperties dprop=new DerbyProperties(proj);
    //Starts the server as a Java app
    args+=" -h "+dprop.getHost()+ " -p "+dprop.getPort();
   
    //Set Derby System Home from the Derby Properties
    if((dprop.getSystemHome()!=null)&& !(dprop.getSystemHome().equals(""))){
      vmargs=CommonNames.D_SYSTEM_HOME+dprop.getSystemHome();
    }
    String procName="["+proj.getName()+"] - "+CommonNames.DERBY_SERVER+" "+CommonNames.START_DERBY_SERVER+" ("+dprop.getHost()+ ", "+dprop.getPort()+")";
    ILaunch launch = DerbyUtils.launch(proj, procName ,   
    CommonNames.DERBY_SERVER_CLASS, args, vmargs, CommonNames.START_DERBY_SERVER);
    IProcess ip=launch.getProcesses()[0];
    //set a name to be seen in the Console list
    ip.setAttribute(IProcess.ATTR_PROCESS_LABEL,procName);
   
    // saves the mapping between (server) process and project
    //servers.put(launch.getProcesses()[0], proj);
    servers.put(ip, proj);
    // register a listener to listen, when this process is finished
    DebugPlugin.getDefault().addDebugEventListener(listener);
    //Add resource listener
    IWorkspace workspace = ResourcesPlugin.getWorkspace();
   
    workspace.addResourceChangeListener(rlistener);
    setRunning(proj, Boolean.TRUE);
    Shell shell = new Shell();
    MessageDialog.openInformation(
      shell,
      CommonNames.PLUGIN_NAME,
      Messages.D_NS_ATTEMPT_STARTED+dprop.getPort()+".");

  }
View Full Code Here

  }

  public void stopDerbyServer( IProject proj) throws CoreException, ClassNotFoundException, SQLException {
    String args = CommonNames.SHUTDOWN_DERBY_SERVER;
    String vmargs="";
    DerbyProperties dprop=new DerbyProperties(proj);
    args+=" -h "+dprop.getHost()+ " -p "+dprop.getPort();
   
    //  Set Derby System Home from the Derby Properties
    if((dprop.getSystemHome()!=null)&& !(dprop.getSystemHome().equals(""))){
      vmargs=CommonNames.D_SYSTEM_HOME+dprop.getSystemHome();
    }
    String procName="["+proj.getName()+"] - "+CommonNames.DERBY_SERVER+" "+CommonNames.SHUTDOWN_DERBY_SERVER+" ("+dprop.getHost()+ ", "+dprop.getPort()+")";
   
    // starts the server as a Java app
    ILaunch launch = DerbyUtils.launch(proj, procName,
    CommonNames.DERBY_SERVER_CLASS, args, vmargs,CommonNames.SHUTDOWN_DERBY_SERVER);
    IProcess ip=launch.getProcesses()[0];
   
    //set a name to be seen in the Console list
    ip.setAttribute(IProcess.ATTR_PROCESS_LABEL,procName);
   
    //update the objectState
    setRunning(proj, Boolean.FALSE);
    if(proj.isOpen()){
      Shell shell = new Shell();
      MessageDialog.openInformation(
      shell,
      CommonNames.PLUGIN_NAME,
      Messages.D_NS_ATTEMPT_STOPPED+dprop.getPort()+"." );
    }
  }
View Full Code Here

  }

  public void startDerbyServer( IProject proj) throws CoreException {
    String args = CommonNames.START_DERBY_SERVER;
    String vmargs="";
    DerbyProperties dprop=new DerbyProperties(proj);
    //Starts the server as a Java app
    args+=" -h "+dprop.getHost()+ " -p "+dprop.getPort();
   
    //Set Derby System Home from the Derby Properties
    if((dprop.getSystemHome()!=null)&& !(dprop.getSystemHome().equals(""))){
      vmargs=CommonNames.D_SYSTEM_HOME+dprop.getSystemHome();
    }
    String procName="["+proj.getName()+"] - "+CommonNames.DERBY_SERVER+" "+CommonNames.START_DERBY_SERVER+" ("+dprop.getHost()+ ", "+dprop.getPort()+")";
    ILaunch launch = DerbyUtils.launch(proj, procName ,   
    CommonNames.DERBY_SERVER_CLASS, args, vmargs, CommonNames.START_DERBY_SERVER);
    IProcess ip=launch.getProcesses()[0];
    //set a name to be seen in the Console list
    ip.setAttribute(IProcess.ATTR_PROCESS_LABEL,procName);
   
    // saves the mapping between (server) process and project
    //servers.put(launch.getProcesses()[0], proj);
    servers.put(ip, proj);
    // register a listener to listen, when this process is finished
    DebugPlugin.getDefault().addDebugEventListener(listener);
    //Add resource listener
    IWorkspace workspace = ResourcesPlugin.getWorkspace();
   
    workspace.addResourceChangeListener(rlistener);
    setRunning(proj, Boolean.TRUE);
    Shell shell = new Shell();
    MessageDialog.openInformation(
      shell,
      CommonNames.PLUGIN_NAME,
      Messages.D_NS_ATTEMPT_STARTED+dprop.getPort()+".");

  }
View Full Code Here

  }

  public void stopDerbyServer( IProject proj) throws CoreException, ClassNotFoundException, SQLException {
    String args = CommonNames.SHUTDOWN_DERBY_SERVER;
    String vmargs="";
    DerbyProperties dprop=new DerbyProperties(proj);
    args+=" -h "+dprop.getHost()+ " -p "+dprop.getPort();
   
    //  Set Derby System Home from the Derby Properties
    if((dprop.getSystemHome()!=null)&& !(dprop.getSystemHome().equals(""))){
      vmargs=CommonNames.D_SYSTEM_HOME+dprop.getSystemHome();
    }
    String procName="["+proj.getName()+"] - "+CommonNames.DERBY_SERVER+" "+CommonNames.SHUTDOWN_DERBY_SERVER+" ("+dprop.getHost()+ ", "+dprop.getPort()+")";
   
    // starts the server as a Java app
    ILaunch launch = DerbyUtils.launch(proj, procName,
    CommonNames.DERBY_SERVER_CLASS, args, vmargs,CommonNames.SHUTDOWN_DERBY_SERVER);
    IProcess ip=launch.getProcesses()[0];
   
    //set a name to be seen in the Console list
    ip.setAttribute(IProcess.ATTR_PROCESS_LABEL,procName);
   
    //update the objectState
    setRunning(proj, Boolean.FALSE);
    if(proj.isOpen()){
      Shell shell = new Shell();
      MessageDialog.openInformation(
      shell,
      CommonNames.PLUGIN_NAME,
      Messages.D_NS_ATTEMPT_STOPPED+dprop.getPort()+"." );
    }
  }
View Full Code Here

    String launchType="";
    String args="";
   
    //the above some times throws wrong 'create=true|false' errors
    String vmargs="";
    DerbyProperties dprop=new DerbyProperties(currentProject);
    if((dprop.getSystemHome()!=null)&& !(dprop.getSystemHome().equals(""))){
      vmargs+=CommonNames.D_SYSTEM_HOME+dprop.getSystemHome();
    }
   
    if(currentScript!=null){
      launchType=CommonNames.SQL_SCRIPT;
     
View Full Code Here

    String launchType="";
    String args="";
   
    //the above some times throws wrong 'create=true|false' errors
    String vmargs="";
    DerbyProperties dprop=new DerbyProperties(currentProject);
    if((dprop.getSystemHome()!=null)&& !(dprop.getSystemHome().equals(""))){
      vmargs+=CommonNames.D_SYSTEM_HOME+dprop.getSystemHome();
    }
   
    if(currentScript!=null){
      launchType=CommonNames.SQL_SCRIPT;
     
View Full Code Here

TOP

Related Classes of org.apache.derby.ui.properties.DerbyProperties

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.