Examples of Environment


Examples of org.apache.sshd.server.Environment

    super();
  }

  @Override
  public int getWidth() {
    Environment environment = retrieveEnvironment();
    try {
      return parseInt(environment.getEnv().get("COLUMNS"));
    } catch (NumberFormatException e) {
      return DEFAULT_WIDTH;
    }
  }
View Full Code Here

Examples of org.apache.tapestry.services.Environment

    {
        ComponentResources resources = mockComponentResources();
        ComponentResources containerResources = mockComponentResources();
        BeanModelSource source = mockBeanModelSource();
        BeanModel model = mockBeanModel();
        Environment environment = mockEnvironment();

        expect(resources.triggerEvent(Form.PREPARE, null, null)).andReturn(false);

        train_push(environment, PropertyEditContext.class);
View Full Code Here

Examples of org.apache.tapestry5.services.Environment

public class EnvironmentImplTest extends TapestryTestCase
{
    @Test
    public void peek_when_empty_returns_null()
    {
        Environment e = new EnvironmentImpl();

        assertNull(e.peek(Runnable.class));
        assertNull(e.peek(Map.class));
    }
View Full Code Here

Examples of org.apache.tools.ant.types.Environment

        // native CVS stuff around (SM)

        // We can't do it ourselves as jCVS is GPLed, a third party task
        // outside of jakarta repositories would be possible though (SB).

        Environment env = new Environment();

        if (port > 0) {
            Environment.Variable var = new Environment.Variable();
            var.setKey("CVS_CLIENT_PORT");
            var.setValue(String.valueOf(port));
            env.addVariable(var);
        }

        /**
         * Need a better cross platform integration with <cvspass>, so
         * use the same filename.
         */
        if (passFile == null) {

            File defaultPassFile = new File(
                System.getProperty("cygwin.user.home",
                    System.getProperty("user.home"))
                + File.separatorChar + ".cvspass");

            if (defaultPassFile.exists()) {
                this.setPassfile(defaultPassFile);
            }
        }

        if (passFile != null) {
            if (passFile.isFile() && passFile.canRead()) {
                Environment.Variable var = new Environment.Variable();
                var.setKey("CVS_PASSFILE");
                var.setValue(String.valueOf(passFile));
                env.addVariable(var);
                log("Using cvs passfile: " + String.valueOf(passFile),
                    Project.MSG_VERBOSE);
            } else if (!passFile.canRead()) {
                log("cvs passfile: " + String.valueOf(passFile)
                    + " ignored as it is not readable",
                    Project.MSG_WARN);
            } else {
                log("cvs passfile: " + String.valueOf(passFile)
                    + " ignored as it is not a file",
                    Project.MSG_WARN);
            }
        }

        if (cvsRsh != null) {
            Environment.Variable var = new Environment.Variable();
            var.setKey("CVS_RSH");
            var.setValue(String.valueOf(cvsRsh));
            env.addVariable(var);
        }

        //
        // Just call the getExecuteStreamHandler() and let it handle
        //     the semantics of instantiation or retrieval.
        //
        Execute exe = new Execute(getExecuteStreamHandler(), null);

        exe.setAntRun(getProject());
        if (dest == null) {
            dest = getProject().getBaseDir();
        }

        if (!dest.exists()) {
            dest.mkdirs();
        }

        exe.setWorkingDirectory(dest);
        exe.setCommandline(toExecute.getCommandline());
        exe.setEnvironment(env.getVariables());

        try {
            String actualCommandLine = executeToString(exe);

            log(actualCommandLine, Project.MSG_VERBOSE);
View Full Code Here

Examples of org.apache.ws.util.jndi.tools.Environment

      if ( environmentArray != null )
      {
         for ( int i = 0; i < environmentArray.length; i++ )
         {
            EnvironmentDocument.Environment environment = environmentArray[i];
            Environment                     env = new Environment(  );
            env.setDescription( environment.getDescription(  ) );
            env.setName( environment.getName(  ) );
            env.setType( environment.getType(  ) );
            env.setValue( environment.getValue(  ) );
            envList.add( env );
         }
      }

      return (Environment[]) envList.toArray( new Environment[0] );
View Full Code Here

Examples of org.araneaframework.Environment

 
  //*******************************************************************
  // PROTECTED METHODS
  //*******************************************************************
  protected void init() throws Exception {
    child._getComponent().init(new Environment() {
      public Object getEntry(Object key) {
        return getEnvironment().getEntry(key);
      }
    });
  }
View Full Code Here

Examples of org.bukkit.World.Environment

  }

  @Override
  public Environment select(String arg, CommandSender sender)
  {
    Environment ret = null;
   
    // "THE_END" --> "end"
    arg = arg.toLowerCase();
    arg = arg.replace("_", "");
    arg = arg.replace("the", "");
View Full Code Here

Examples of org.candlepin.model.Environment

    @GET
    @Path("/{env_id}")
    @Produces(MediaType.APPLICATION_JSON)
    public Environment getEnv(
        @PathParam("env_id") @Verify(Environment.class) String envId) {
        Environment e = envCurator.find(envId);
        if (e == null) {
            throw new NotFoundException(i18n.tr("No such environment: {0}", envId));
        }
        return e;
    }
View Full Code Here

Examples of org.constretto.spring.annotation.Environment

     *
     * @param description
     * @return an array with the specified values or null
     */
    public static String[] extractEnvironmentValue(final Description description) {
        final Environment environment = description.getTestClass().getAnnotation(Environment.class);
        return environment == null ? null : environment.value();
    }
View Full Code Here

Examples of org.drools.runtime.Environment

  public void testLogger1() throws Exception {
        // load the process
        KnowledgeBase kbase = createKnowledgeBase();
        // create a new session
        EntityManagerFactory emf = Persistence.createEntityManagerFactory( "org.jbpm.persistence.jpa" );
        Environment env = KnowledgeBaseFactory.newEnvironment();
        env.set( EnvironmentName.ENTITY_MANAGER_FACTORY,
                 emf );
        env.set( EnvironmentName.TRANSACTION_MANAGER,
                 TransactionManagerServices.getTransactionManager() );
        Properties properties = new Properties();
    properties.put("drools.processInstanceManagerFactory", "org.jbpm.persistence.processinstance.JPAProcessInstanceManagerFactory");
    properties.put("drools.processSignalManagerFactory", "org.jbpm.persistence.processinstance.JPASignalManagerFactory");
    KnowledgeSessionConfiguration config = KnowledgeBaseFactory.newKnowledgeSessionConfiguration(properties);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.