Examples of MetadataReader


Examples of com.drew.metadata.MetadataReader

    }

    public void testDescription_City() throws Exception
    {
        File iptcFile = new File("src/com/drew/metadata/iptc/test/withIptc.jpg");
        MetadataReader reader = new IptcReader(iptcFile);
        Metadata metadata = reader.extract();
        assertTrue(metadata.containsDirectory(IptcDirectory.class));
        Directory directory = metadata.getDirectory(IptcDirectory.class);
        assertEquals("City", directory.getDescription(IptcDirectory.TAG_CITY));
    }
View Full Code Here

Examples of com.drew.metadata.MetadataReader

    }

    public void testDescription_Caption() throws Exception
    {
        File iptcFile = new File("src/com/drew/metadata/iptc/test/withIptc.jpg");
        MetadataReader reader = new IptcReader(iptcFile);
        Metadata metadata = reader.extract();
        assertTrue(metadata.containsDirectory(IptcDirectory.class));
        Directory directory = metadata.getDirectory(IptcDirectory.class);
        assertEquals("Caption", directory.getDescription(IptcDirectory.TAG_CAPTION));
    }
View Full Code Here

Examples of com.drew.metadata.MetadataReader

    }

    public void testDescription_Category() throws Exception
    {
        File iptcFile = new File("src/com/drew/metadata/iptc/test/withIptc.jpg");
        MetadataReader reader = new IptcReader(iptcFile);
        Metadata metadata = reader.extract();
        assertTrue(metadata.containsDirectory(IptcDirectory.class));
        Directory directory = metadata.getDirectory(IptcDirectory.class);
        assertEquals("Supl. Category2 Supl. Category1 Cat", directory.getDescription(IptcDirectory.TAG_CATEGORY));
    }
View Full Code Here

Examples of com.sun.xml.ws.api.databinding.MetadataReader

        EntityResolver resolver, boolean isTransportSynchronous, boolean isStandard) {

        if(implType ==null)
            throw new IllegalArgumentException();

        MetadataReader metadataReader = getExternalMetadatReader(implType, binding);

        if (isStandard) {
            verifyImplementorClass(implType, metadataReader);
        }
View Full Code Here

Examples of net.engio.mbassy.listener.MetadataReader

    }

    @Test
    public void testStrongListenerSubscription() throws Exception {
        ListenerFactory listeners = listeners(CustomInvocationListener.class);
        SubscriptionManager subscriptionManager = new SubscriptionManager(new MetadataReader(), new SubscriptionFactory(), mockedRuntime());
        ConcurrentExecutor.runConcurrent(TestUtil.subscriber(subscriptionManager, listeners), ConcurrentUnits);

        listeners.clear();
        runGC();
View Full Code Here

Examples of org.apache.felix.metatype.MetaDataReader

    }


    private MetaTypeInformationImpl fromDocuments( Bundle bundle )
    {
        MetaDataReader reader = new MetaDataReader();

        // get the descriptors, return nothing if none
        Enumeration docs = bundle.findEntries( METATYPE_DOCUMENTS_LOCATION, "*.xml", false );
        if ( docs == null || !docs.hasMoreElements() )
        {
            return null;
        }

        MetaTypeInformationImpl cmti = new MetaTypeInformationImpl( bundle );
        while ( docs.hasMoreElements() )
        {
            URL doc = ( URL ) docs.nextElement();
            try
            {
                MetaData metaData = reader.parse( doc );
                if ( metaData != null )
                {
                    cmti.addMetaData( metaData );
                }
            }
View Full Code Here

Examples of org.apache.felix.metatype.MetaDataReader

        synchronized (LOCK) {
            if (m_session == null) {
                throw new ResourceProcessorException(ResourceProcessorException.CODE_OTHER_ERROR, "Can not process resource without a Deployment Session");
            }
        }
        MetaDataReader reader = new MetaDataReader();
        MetaData data = null;
        try {
            data = reader.parse(stream);
        }
        catch (IOException e) {
            throw new ResourceProcessorException(ResourceProcessorException.CODE_OTHER_ERROR, "Unable to process resource.", e);
        }
        if (data == null) {
View Full Code Here

Examples of org.springframework.core.type.classreading.MetadataReader

           
            final Resource[] resources = resolver.getResources(packageSearchPath);   
           
           
            for (final Resource resource: resources) {
                final MetadataReader reader = factory.getMetadataReader(resource);
                final AnnotationMetadata metadata = reader.getAnnotationMetadata();
               
                if (scanAllPackages && shouldSkip(metadata.getClassName())) {
                    continue;
                }
               
View Full Code Here

Examples of org.springframework.core.type.classreading.MetadataReader

          Resource[] resources = this.resourcePatternResolver.getResources(pattern);
          MetadataReaderFactory readerFactory = new CachingMetadataReaderFactory(this.resourcePatternResolver);

          for( Resource resource : resources ) {
            if( resource.isReadable() ) {
              MetadataReader reader = readerFactory.getMetadataReader(resource);
              String className = reader.getClassMetadata().getClassName();
              if( matchesFilter(reader, readerFactory) ) {
                entities.add(className);
              }
            }
          }
View Full Code Here

Examples of org.springframework.core.type.classreading.MetadataReader

          Resource[] resources = this.resourcePatternResolver.getResources(pattern);
          MetadataReaderFactory readerFactory = new CachingMetadataReaderFactory(this.resourcePatternResolver);

          for (Resource resource : resources) {
            if (resource.isReadable()) {
              MetadataReader reader = readerFactory.getMetadataReader(resource);
              String className = reader.getClassMetadata().getClassName();
              if (matchesFilter(reader, readerFactory)) {
                entities.add(className);
              }
            }
          }
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.