Package org.opengis.feature

Examples of org.opengis.feature.Property


   */
  public BoundingBox getBounds() {

    ReferencedEnvelope bounds = new ReferencedEnvelope(getType().getCoordinateReferenceSystem());
    for (Iterator itr = getValue().iterator(); itr.hasNext();) {
      Property property = (Property) itr.next();
      if (property instanceof GeometryAttribute) {
         bounds.include(((GeometryAttribute)property).getBounds());
      }
    }

View Full Code Here


        GeometryType geometryType =
           (GeometryType) getType().getGeometryDescriptor().getType();
       
         if (geometryType != null) {
           for (Iterator itr = getValue().iterator(); itr.hasNext();) {
             Property property =  (Property) itr.next();
             if (property instanceof GeometryAttribute) {
               if (property.getType().equals(geometryType)) {
                 defaultGeometry = (GeometryAttribute)property;  
                 break;
               }
             }
           }
View Full Code Here

        if (attribute instanceof ComplexAttribute) {
            ComplexAttribute complex = (ComplexAttribute) attribute;
            Collection properties = (Collection) complex.getValue();
            for (Iterator itr = properties.iterator(); itr.hasNext();) {
                Property property = (Property) itr.next();
                if (property instanceof Attribute) {
                    Attribute att = (Attribute) property;
                    add(att.getIdentifier() == null ? null : att.getIdentifier().toString(), att
                            .getValue(), att.getName());
                } else if (property instanceof Association) {
View Full Code Here

        // If the value is nillable anyway then just default it to null:
        if (propertyDescriptor.isNillable()
            && AttributeDescriptor.class
                .isAssignableFrom(propertyDescriptor.getClass())) {
          do {
            Property nullProperty = new AttributeImpl(
                propertyDescriptor.getType().getBinding()
                    .cast(null),
                (AttributeDescriptor) propertyDescriptor, null);

            properties.add(nullProperty);
View Full Code Here

    }

    public Collection<Property> getProperties(Name name) {
        List<Property> matches = new ArrayList<Property>();
        for ( Iterator p = getValue().iterator(); p.hasNext(); ) {
            Property property = (Property) p.next();
            if ( property.getName().equals( name ) ) {
                matches.add( property );
            }
        }
       
        return matches;
View Full Code Here

    }

    public Collection<Property> getProperties(String name) {
        List<Property> matches = new ArrayList<Property>();
        for ( Iterator p = properties().iterator(); p.hasNext(); ) {
            Property property = (Property) p.next();
            if ( property.getName().getLocalPart().equals( name ) ) {
                matches.add( property );
            }
        }
       
        return matches;
View Full Code Here

        return matches;
    }

    public Property getProperty(Name name) {
        for ( Iterator p = properties().iterator(); p.hasNext(); ) {
            Property property = (Property) p.next();
            if ( property.getName().equals( name ) ) {
                return property;
            }
        }
       
        return null;
View Full Code Here

        return null;
    }

    public Property getProperty(String name) {
        for ( Iterator p = getValue().iterator(); p.hasNext(); ) {
            Property property = (Property) p.next();
            if ( property.getName().getLocalPart().equals( name ) ) {
                return property;
            }
        }
       
        return null;
View Full Code Here

        }
    }

    @Override
    public Object getAttribute(String eName) {
        Property p = getProperty(eName);
        return (p != null ? p.getValue() : null);
    }
View Full Code Here

        return (p != null ? p.getValue() : null);
    }

    @Override
    public void setAttribute(String eName, Object newValue) {
        Property p = getProperty(eName);
        if (p != null) {
            p.setValue(newValue);
        }
    }
View Full Code Here

TOP

Related Classes of org.opengis.feature.Property

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.