Examples of lookup()


Examples of org.codehaus.plexus.DefaultPlexusContainer.lookup()

            {
                this.container = container;
            }
        }

        maven = container.lookup( Maven.class );

        executionRequestPopulator = container.lookup( MavenExecutionRequestPopulator.class );

        modelProcessor = createModelProcessor( container );

Examples of org.codehaus.plexus.MutablePlexusContainer.lookup()

            {
                // if the hint is not empty (and not default), we don't care about mapping type...
                // it's a single-value, not a collection.
                Object value;
                if (StringUtils.isNotEmpty(hint) && !hint.equals(PlexusConstants.PLEXUS_DEFAULT_HINT)) {
                    value = container.lookup(role, hint);
                } else if ("single".equals(mappingType)) {
                    value = container.lookup(role, hint);
                } else if ("map".equals(mappingType)) {
                    value = container.lookupMap(role);
                } else if ("set".equals(mappingType)) {

Examples of org.codehaus.plexus.PlexusContainer.lookup()

  // ------------------------------

  public final void contextualize(Context context) throws ContextException {
    PlexusContainer plexusContainer = (PlexusContainer) context.get(PlexusConstants.PLEXUS_KEY);
    try {
      archiverManager = (ArchiverManager) plexusContainer.lookup(ArchiverManager.ROLE);
    } catch (ComponentLookupException e) {
      throw new ContextException(e.getMessage(), e);
    }
  }

Examples of org.codehaus.plexus.embed.ArtifactEnabledEmbedder.lookup()

    {
        ArtifactEnabledEmbedder embedder = new ArtifactEnabledEmbedder();

        embedder.start();

        MavenRepository inRepository = (MavenRepository)embedder.lookup( MavenRepository.ROLE, "maven1" );

        MavenRepository outRepository = (MavenRepository)embedder.lookup( MavenRepository.ROLE, "maven2" );

        inRepository.setRepository( inbase );

Examples of org.codehaus.plexus.embed.Embedder.lookup()

            realmClassLoaderField.set(realm, realmClassLoader);
            // Evil hack for Tomcat classloader issue - ends

            embedder.start(classWorld);

            metadataSource = (ArtifactMetadataSource) embedder.lookup(ArtifactMetadataSource.ROLE);
            artifactFactory = (ArtifactFactory) embedder.lookup(ArtifactFactory.ROLE);
            artifactResolver = (ArtifactResolver) embedder.lookup(ArtifactResolver.ROLE);

            setUpRepositories(embedder);

Examples of org.codehaus.plexus.spring.PlexusContainerAdapter.lookup()

        PlexusFileSystemXmlApplicationContext fileSystemApplicationContext = new PlexusFileSystemXmlApplicationContext(
             (String[]) jars.toArray( new String[jars.size()] ), classPathApplicationContext );
        fileSystemApplicationContext.setClassLoader( newClassLoader );
        container.setApplicationContext( fileSystemApplicationContext );

        DatabaseFactoryConfigurator configurator = (DatabaseFactoryConfigurator) container.lookup(
                                DatabaseFactoryConfigurator.class.getName(), configRoleHint );
        configurator.configure( params );

        DataManagementTool manager =
            (DataManagementTool) container.lookup( DataManagementTool.class.getName(), toolRoleHint );

Examples of org.cytoscape.view.model.VisualLexicon.lookup()

      clusterStyle.setDefaultValue(EDGE_SELECTED_PAINT, Color.BLUE);
      clusterStyle.setDefaultValue(EDGE_STROKE_SELECTED_PAINT, Color.BLUE);
      clusterStyle.setDefaultValue(EDGE_STROKE_SELECTED_PAINT, Color.BLUE);

      VisualLexicon lexicon = applicationMgr.getCurrentRenderingEngine().getVisualLexicon();
      VisualProperty vp = lexicon.lookup(CyEdge.class, "edgeTargetArrowShape");

      if (vp != null) {
        Object arrowValue = vp.parseSerializableString("ARROW");
        if (arrowValue != null) clusterStyle.setDefaultValue(vp, arrowValue);
      }

Examples of org.dcm4che3.image.LookupTable.lookup()

            if (dParam.isAutoWindowing())
                lutParam.autoWindowing(imgAttrs, raster);
            lutParam.setPresentationLUT(imgAttrs);
        }
        LookupTable lut = lutParam.createLUT(outBits);
        lut.lookup(raster, destRaster);
        return destRaster;
    }

    private Attributes selectFctGroup(Attributes imgAttrs,
            Attributes sharedFctGroups,

Examples of org.drools.grid.service.directory.WhitePages.lookup()

        GridNode gnode = grid.createGridNode( "test1@local" );

        WhitePages pages = grid.get( WhitePages.class );
        GridServiceDescription<GridNode> gsd = pages.create( "test1@local", "grid0" );
       
        GridServiceDescription<GridNode> serviceDescription = pages.lookup( "test1@local" );

        GridConnection connection = grid.get( ConnectionFactoryService.class ).createConnection( gsd );
        assertSame( gnode,
                    connection.connect() );

Examples of org.drools.grid.service.directory.impl.CoreServicesLookupImpl.lookup()

                                      String id,
                                      String ip,
                                      int port) {
        CoreServicesLookupImpl coreServicesWP = (CoreServicesLookupImpl) grid.get( CoreServicesLookup.class );

        GridServiceDescriptionImpl gsd = (GridServiceDescriptionImpl) coreServicesWP.lookup( SchedulerService.class );
        if ( gsd == null ) {
            gsd = new GridServiceDescriptionImpl( WhitePages.class );
        }

        GridServiceDescription<WhitePages> service = coreServicesWP.getServices().get( SchedulerService.class.getName() );
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.