Examples of Port


Examples of edu.byu.ece.rapidSmith.design.Port

          }
          if(clkname.endsWith("_")){
            clkname = clkname.substring(0, clkname.length()-1);
          }
         
          Port newPort = new Port(clkname +"_inport",port);
          hardMacro.getPorts().add(newPort);
          port.setPort(newPort);
         
        }
View Full Code Here

Examples of edu.indiana.extreme.xbaya.graph.Port

    @Override
    protected void setPortPositions() {
        // inputs
        List<? extends Port> inputPorts = this.node.getInputPorts();
        for (int i = 0; i < inputPorts.size(); i++) {
            Port port = inputPorts.get(i);
            Point offset;
            if (i < inputPorts.size() / 2) {
                offset = new Point(PortGUI.DATA_PORT_SIZE / 2, this.headHeight
                        + PORT_INITIAL_GAP + PORT_GAP * i);
            } else {
                offset = new Point(PortGUI.DATA_PORT_SIZE / 2, this.headHeight
                        + PORT_INITIAL_GAP + PORT_GAP * (i + 1));
            }
            port.getGUI().setOffset(offset);
        }

        // outputs
        List<? extends Port> outputPorts = this.node.getOutputPorts();
        for (int i = 0; i < outputPorts.size(); i++) {
            Port port = outputPorts.get(i);
            Point offset = new Point(this.getBounds().width
                    - PortGUI.DATA_PORT_SIZE / 2, (int) (this.headHeight
                    + PORT_INITIAL_GAP + PORT_GAP
                    * (outputPorts.size() / 2.0 + i)));
            port.getGUI().setOffset(offset);
        }

        // control-in
        Port controlInPort = this.node.getControlInPort();
        if (controlInPort != null) {
            controlInPort.getGUI().setOffset(new Point(0, 0));
        }

        // control-out
        for (Port controlOutPort : this.node.getControlOutPorts()) {
            controlOutPort.getGUI().setOffset(
View Full Code Here

Examples of eu.scape_project.planning.services.myexperiment.domain.Port

    private void addMigrationMock(T2FlowExecutablePlanGenerator planGenerator) {
        WorkflowDescription wf = mock(WorkflowDescription.class);
        when(wf.getDataflowId()).thenReturn(MIGRATION_DATAFLOW_ID);

        List<Port> inputPorts = new ArrayList<Port>(1);
        inputPorts.add(new Port("source", "Description", ComponentConstants.VALUE_SOURCE_OBJECT));
        when(wf.getInputPorts()).thenReturn(inputPorts);

        List<Port> outputPorts = new ArrayList<Port>(1);
        outputPorts.add(new Port("target", "Description", ComponentConstants.VALUE_TARGET_OBJECT));
        when(wf.getOutputPorts()).thenReturn(outputPorts);

        List<MigrationPath> migrationPaths = new ArrayList<MigrationPath>(1);
        migrationPaths.add(new MigrationPath("image/tiff", "image/jp2"));
        when(wf.getMigrationPaths()).thenReturn(migrationPaths);
View Full Code Here

Examples of io.fabric8.docker.api.container.Port

        Dockers.getUsedPorts(docker);
    }

    @Test
    public void shouldRetrievePublicPort() {
        Port port = new Port();
        port.setPrivatePort(1);
        port.setPublicPort(2);
        Container container = new Container();
        container.setPorts(Arrays.asList(port));
        given(docker.containers(anyInt(), anyInt(), anyString(), anyString(), anyInt())).
                willReturn(Arrays.asList(container));

        // When
        Set<Integer> ports = Dockers.getUsedPorts(docker);

        // Then
        assertEquals(1, ports.size());
        assertEquals(port.getPublicPort(), ports.iterator().next());
    }
View Full Code Here

Examples of io.fabric8.kubernetes.api.model.Port

            for (Map.Entry<String, String> entry : containerPorts.entrySet()) {
                String name = entry.getKey();
                String portText = entry.getValue();
                Integer portNumber = parsePort(portText, FABRIC8_PORT_CONTAINER_PREFIX + name);
                if (portNumber != null) {
                    Port port = getOrCreatePort(portMap, name);
                    port.setContainerPort(portNumber);
                }
            }
            for (Map.Entry<String, String> entry : hostPorts.entrySet()) {
                String name = entry.getKey();
                String portText = entry.getValue();
                Integer portNumber = parsePort(portText, FABRIC8_PORT_HOST_PREFIX + name);
                if (portNumber != null) {
                    Port port = getOrCreatePort(portMap, name);
                    port.setHostPort(portNumber);

                    // if the container port isn't set, lets try default that using defaults
                    if (port.getContainerPort() == null) {
                        port.setContainerPort(getDefaultContainerPortMap().get(name));
                    }
                }
            }
            getLog().info("Generated port mappings: " + portMap);
            getLog().debug("from host ports: " + hostPorts);
View Full Code Here

Examples of javax.sound.sampled.Port

                String strMixerName = mixer.getMixerInfo().getName();
//System.out.println("Mixer: " + strMixerName);
    Port.Info[] infosToCheck = getPortInfo(mixer);
    for (int i = 0; i < infosToCheck.length; i++)
    {
                    Port port = null;
                    try
                    {
                            port = (Port) mixer.getLine(infosToCheck[i]);
                            port.open();
                    }
                    catch (LineUnavailableException e)
                    {
                         //   e.printStackTrace();
                    }
                    if (port != null)
                    {
                        String  strPortName = ((Port.Info) port.getLineInfo()).getName();
//System.out.println("Port: " + strPortName);
                        if (strPortName.toUpperCase().indexOf("MASTER") ==-1 ) continue;
                        Control[]  aControls = port.getControls();
                        for (int t = 0; t < aControls.length; t++)
                        {
                            if (aControls[t] instanceof FloatControl)
                            {
                                FloatControl control = (FloatControl) aControls[t];
View Full Code Here

Examples of javax.wsdl.Port

        Iterator ite = serviceMap.values().iterator();
        while (ite.hasNext()) {
            Service service = (Service)ite.next();
            Iterator portIte = service.getPorts().values().iterator();
            while (portIte.hasNext()) {
                Port port = (Port)portIte.next();
                Binding binding = port.getBinding();
                if (!bindingMap.containsKey(binding.getQName())) {
                    Node errNode = ErrNodeLocator.getNode(document, WSDLConstants.QNAME_SERVICE, service
                        .getQName().getLocalPart(), port.getName());
                    schemaWSDLValidator.addError(errNode, " port : " + port.getName()
                                                          + " reference binding is not defined");
                    isValid = false;
                }
            }
        }
View Full Code Here

Examples of javax.wsdl.Port

                portConfiguration = cb.buildConfiguration(PORT_CONFIGURATION_URI, id,
                                                          bus.getConfiguration());
            }

            // add the additional provider
            Port port = null;
            try  {
                port = EndpointReferenceUtils.getPort(bus.getWSDLManager(), ref);
            } catch (WSDLException ex) {
                throw new WebServiceException("Could not get port from wsdl", ex);
            }
View Full Code Here

Examples of javax.wsdl.Port

        }
       
    }
   
    private String getEndpointPortName() {
        Port port;
        String portName = null;
        try {
       
            port = EndpointReferenceUtils.getPort(endPoint.getBus().getWSDLManager(),
                                                  endPoint.getEndpointReferenceType());
            if (null != port) {
                portName = port.getName();
            } else {
                portName = "";
            }
       
        } catch (WSDLException e) {
View Full Code Here

Examples of javax.wsdl.Port

            portCfg = cb.buildConfiguration(PORT_CONFIGURATION_URI, id, bus.getConfiguration());
        }

        // add the additional provider

        Port port = null;
        try  {
            port = EndpointReferenceUtils.getPort(bus.getWSDLManager(), ref);
        } catch (WSDLException ex) {
            throw new WebServiceException("Could not get port from wsdl", ex);
        }
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.