Package org.opengis.metadata.citation

Examples of org.opengis.metadata.citation.Citation


                     final Ellipsoid ellipsoid)
            throws FactoryException
    {
        assert Thread.holdsLock(this);
        final Map      properties = new HashMap();
        final Citation authority  = getAuthority();
        final String   text       = String.valueOf(code);
        properties.put(IdentifiedObject.NAME_KEY, name);
        properties.put(Identifier.AUTHORITY_KEY, authority);
        final GeodeticDatum datum = factories.getDatumFactory().createGeodeticDatum(
                                    properties, ellipsoid, DefaultPrimeMeridian.GREENWICH);
View Full Code Here


             * appears in the GenericName's scope below (as an alias).
             */
            final OperationDescriptor op = (OperationDescriptor) operation;
            final ResourceBundle bundle = op.getResourceBundle(Locale.getDefault());
            String vendor = op.getResourceBundle(Locale.US).getString("Vendor");
            Citation authority = null;
            if (vendor != null) {
                vendor = vendor.trim();
                name = ImagingParameterDescription.trimPrefix(name, vendor);
                for (int i=0; i<AUTHORITIES.length; i+=2) {
                    if (vendor.equalsIgnoreCase((String) AUTHORITIES[i])) {
View Full Code Here

    /**
     * Makes sure that the authority factory has the proper name.
     */
    public void testAuthority() {
        CRSAuthorityFactory factory;
        Citation authority;

        // Tests the official factory.
        factory   = ReferencingFactoryFinder.getCRSAuthorityFactory("EPSG", null);
        authority = factory.getAuthority();
        assertNotNull(authority);
        assertEquals("European Petroleum Survey Group", authority.getTitle().toString(Locale.US));
        assertTrue(Citations.identifierMatches(authority, "EPSG"));

        // Tests the modified factory.
        factory   = new OrderedAxisAuthorityFactory("EPSG", null, null);
        authority = factory.getAuthority();
View Full Code Here

    /**
     * Tests the vendor name.
     */
    public void testVendor() {
        CRSAuthorityFactory factory;
        Citation vendor;

        factory = new OrderedAxisAuthorityFactory("EPSG", null, null);
        vendor  = factory.getVendor();
        assertNotNull(vendor);
        assertEquals("Geotools", vendor.getTitle().toString(Locale.US));
        assertFalse(Citations.identifierMatches(vendor, "EPSG"));
    }
View Full Code Here

     */
    private DefaultMutableTreeNode createNode(final Factory factory) {
        final StringBuilder buffer =
                new StringBuilder(Classes.getShortClassName(factory)).append('[');
        if (factory instanceof AuthorityFactory) {
            final Citation authority = ((AuthorityFactory) factory).getAuthority();
            if (authority != null) {
                final Collection<? extends Identifier> identifiers = authority.getIdentifiers();
                if (identifiers != null && !identifiers.isEmpty()) {
                    boolean next = false;
                    for (final Identifier id : identifiers) {
                        if (next) {
                            buffer.append(", ");
                        }
                        appendIdentifier(buffer, id.getCode());
                        next = true;
                    }
                } else {
                    appendIdentifier(buffer, authority.getTitle());
                }
            }
        } else {
            if (colorEnabled) buffer.append(X364.RED);
            buffer.append("direct");
View Full Code Here

            if (code == null) {
              int codeNumber = element.pullInteger("code");
              code = String.valueOf(codeNumber);
            }
            element.close();
            final Citation authority = Citations.fromName(auth);
            properties = new HashMap<String,Object>(4);
            properties.put(IdentifiedObject.       NAME_KEY, new NamedIdentifier(authority, name));
            properties.put(IdentifiedObject.IDENTIFIERS_KEY, new NamedIdentifier(authority, code));
        }
        if (isRoot) {
View Full Code Here

                authorities.add(factory.getAuthority());
            }
searchNews: for (final CRSAuthorityFactory factory :
                    ReferencingFactoryFinder.getCRSAuthorityFactories(hints))
            {
                final Citation authority = factory.getAuthority();
                if (authorities.contains(authority)) {
                    continue;
                }
                for (final Citation check : authorities) {
                    if (Citations.identifierMatches(authority, check)) {
View Full Code Here

                    table          .write ('\n');
                    vendors        .append('\n');
                    implementations.append('\n');
                }
                final Factory provider = (Factory) providers.next();
                final Citation vendor = provider.getVendor();
                vendors.append(vendor.getTitle().toString(locale));
                implementations.append(Classes.getShortClassName(provider));
                if (provider instanceof AuthorityFactory) {
                    final Citation authority = ((AuthorityFactory) provider).getAuthority();
                    final Iterator<? extends Identifier> identifiers =
                            authority.getIdentifiers().iterator();
                    final String identifier = identifiers.hasNext()
                            ? identifiers.next().getCode().toString()
                            : authority.getTitle().toString(locale);
                    table.write(identifier);
                }
            }
            /*
             * Writes the vendors.
View Full Code Here

TOP

Related Classes of org.opengis.metadata.citation.Citation

Copyright © 2018 www.massapicom. 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.