Examples of Descriptor


Examples of JDescriptors.fr.lip6.Descriptor

        listOfPatches = detector.getDescriptors(ColorVQFloatDescriptor.class, bfImg.getSubimage(0, move, bfImg.getWidth(), deltaMove));       
      }
      for(ColorVQFloatDescriptor i : listOfPatches)
      {
        //the descriptor
        Descriptor cvqfd = new ColorVQFloatDescriptor();
        cvqfd.setXmin(i.getXmin());
        cvqfd.setXmax(i.getXmax());
        cvqfd.setYmin(i.getYmin());
        cvqfd.setYmax(i.getYmax());
        cvqfd.setShape(i.getShape());
        float[] d = new float[quantizer.getBinNumber()];
     
        float surf = (i.getXmax() - i.getXmin())*(i.getYmax()-i.getYmin());
        for(int x = i.getXmin(); x < i.getXmax(); ++x)
          for(int y = i.getYmin(); y < i.getYmax(); ++y)
          {
            int[] color = r.getPixel(x, y, (int[])null);
            int index = quantizer.getBin(color);
            if(index >= 0 && index < d.length)
            {
              if(normalize)
                d[index] += 1.0f/surf;
              else
                d[index] += 1.0f;
            }
          }
     
        cvqfd.setD(d);
     
        list.add(cvqfd);
      }
    }
    if(DEBUG)
View Full Code Here

Examples of com.buschmais.jqassistant.core.model.api.descriptor.Descriptor

     */
    private void scanFile(ArtifactDescriptor artifactDescriptor, String name, InputStreamSource streamSource) throws IOException {
        for (ArtifactScannerPlugin plugin : this.plugins) {
            if (plugin.matches(name, false)) {
                LOGGER.info("Scanning file '{}'", name);
                Descriptor descriptor = plugin.scanFile(store, streamSource);
                artifactDescriptor.getContains().add(descriptor);
            }
        }
    }
View Full Code Here

Examples of com.buschmais.jqassistant.core.store.api.descriptor.Descriptor

        String javaHome = System.getProperty("java.home");
        Assume.assumeNotNull("java.home is not set.", javaHome);
        File runtimeJar = new File(javaHome + "/lib/rt.jar");
        Assume.assumeTrue("Java Runtime JAR not found: " + runtimeJar.getAbsolutePath(), runtimeJar.exists());
        Iterator<? extends FileDescriptor> iterator = getScanner().scan(runtimeJar, runtimeJar.getAbsolutePath(), JavaScope.CLASSPATH).iterator();
        Descriptor descriptor;
        do {
            int count = 0;
            store.beginTransaction();
            do {
                if (iterator.hasNext()) {
View Full Code Here

Examples of com.google.protobuf.Descriptors.Descriptor

      CodedInputStream input,
      UnknownFieldSet.Builder unknownFields,
      ExtensionRegistry extensionRegistry,
      Message.Builder builder,
      int tag) throws java.io.IOException {
    Descriptor type = builder.getDescriptorForType();

    if (type.getOptions().getMessageSetWireFormat() &&
        tag == WireFormat.MESSAGE_SET_ITEM_TAG) {
      mergeMessageSetExtensionFromCodedStream(
        input, unknownFields, extensionRegistry, builder);
      return true;
    }

    int wireType = WireFormat.getTagWireType(tag);
    int fieldNumber = WireFormat.getTagFieldNumber(tag);

    FieldDescriptor field;
    Message defaultInstance = null;

    if (type.isExtensionNumber(fieldNumber)) {
      ExtensionRegistry.ExtensionInfo extension =
        extensionRegistry.findExtensionByNumber(type, fieldNumber);
      if (extension == null) {
        field = null;
      } else {
        field = extension.descriptor;
        defaultInstance = extension.defaultInstance;
      }
    } else {
      field = type.findFieldByNumber(fieldNumber);
    }

    if (field == null ||
        wireType != WireFormat.getWireFormatForField(field)) {
      // Unknown field or wrong wire type.  Skip.
View Full Code Here

Examples of com.mucommander.ui.action.impl.BatchRenameAction.Descriptor

        }
    }

  @Override
  public ActionDescriptor getDescriptor() {
    return new Descriptor();
  }
View Full Code Here

Examples of com.subgraph.orchid.Descriptor

      if(status.hasFlag("Running") && status.hasFlag("Valid")) {
        final RouterImpl router = updateOrCreateRouter(status, oldRouterByIdentity);
        addRouter(router);
        classifyRouter(router);
      }
      final Descriptor d = getDescriptorForRouterStatus(status, consensus.getFlavor() == ConsensusFlavor.MICRODESC);
      if(d != null) {
        d.setLastListed(consensus.getValidAfterTime().getTime());
      }
    }
   
    logger.fine("Loaded "+ routersByIdentity.size() +" routers from consensus document");
    currentConsensus = consensus;
View Full Code Here

Examples of com.sun.enterprise.deployment.Descriptor

     */
    public String getModuleIDFromDD (File file) throws Exception {
        Archivist source = ArchivistFactory.getArchivistForArchive(file);
        InputJarArchive archive = new InputJarArchive();
        archive.open(file.getAbsolutePath());
        Descriptor descriptor = null;
        String moduleID = null;
        String displayName = null;
        try {
            descriptor = source.readStandardDeploymentDescriptor(archive);
        } catch (Exception ex) {
            //ignore
        }
        if (descriptor != null) {
            displayName = descriptor.getDisplayName();
        }
        if ((displayName != null) && (displayName.length() > 0)) {
            moduleID = displayName;
        } else {
            //We give up.  Use the uploaded file name instead
View Full Code Here

Examples of com.sun.tools.classfile.Descriptor

    private void writeDescriptor(int index, boolean resolveIndices) {
        if (resolveIndices) {
            try {
                ConstantPool constant_pool = classWriter.getClassFile().constant_pool;
                Descriptor d = new Descriptor(index);
                print(d.getFieldType(constant_pool));
                return;
            } catch (ConstantPoolException ignore) {
            } catch (InvalidDescriptor ignore) {
            }
        }
View Full Code Here

Examples of fitnesse.testsystems.Descriptor

    SlimClientBuilder.clearSlimPortOffset();
  }

  @Test
  public void portRotates() throws Exception {
    Descriptor descriptor = mock(Descriptor.class);
    when(descriptor.getVariable("SLIM_PORT")).thenReturn(null);
    for (int i = 0; i < 15; i++) {
      SlimClientBuilder clientBuilder = new SlimClientBuilder(descriptor);
      assertEquals(8085 + (i % 10), clientBuilder.getSlimPort());
    }
  }
View Full Code Here

Examples of flash.css.Descriptor

        Iterator<Entry<String, Descriptor>> propertyIterator = declaration.iterator();

        while (propertyIterator.hasNext())
        {
            Entry<String, Descriptor> entry = propertyIterator.next();
            Descriptor descriptor = entry.getValue();
            String propertyName = dehyphenize(descriptor.getName());

            try
            {
                if (propertyName.equals("fontFamily"))
                {
                    processFontFamily(properties, descriptor);
                }
                else
                {
                    processPropertyDescriptor(propertyName, descriptor, properties, effectsStyles);
                }
            }
            catch (CompilerError compilerError)
            {
                compilerError.setPath(descriptor.getPath());
                compilerError.setLine(descriptor.getLineNumber());
                ThreadLocalToolkit.log(compilerError);
            }
        }
    }
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.