Package net.lucidviews.geoalgo.limb.refine.labelling

Examples of net.lucidviews.geoalgo.limb.refine.labelling.SimpleFeatureLabelFormatter


    Options options = new Options();
    options.setLabelFormat( TEXT_ATTRIBUTE_ID );
   
    this.feature.getProperty( TEXT_ATTRIBUTE_ID ).setValue( textAttribute );
   
    String label = new SimpleFeatureLabelFormatter().createLabel( this.feature, options );
   
    assertEquals( textAttribute, label );
  }
View Full Code Here


    Options options = new Options();
    options.setLabelFormat( TEXT_ATTRIBUTE_ID );
   
    this.feature.getProperty( TEXT_ATTRIBUTE_ID ).setValue( textAttribute );
   
    String label = new SimpleFeatureLabelFormatter().createLabel( this.feature, options );
   
    assertEquals( textAttribute, label );
  }
View Full Code Here

    Options options = new Options();
    options.setLabelFormat( NUMERIC_ATTRIBUTE_ID );
   
    this.feature.getProperty( NUMERIC_ATTRIBUTE_ID ).setValue( numericAttribute );
   
    String label = new SimpleFeatureLabelFormatter().createLabel( this.feature, options );
   
    assertEquals( numericAttribute.toString(), label );
  }
View Full Code Here

    Options options = new Options();
    options.setLabelFormat( NUMERIC_ATTRIBUTE_ID );
   
    this.feature.getProperty( NUMERIC_ATTRIBUTE_ID ).setValue( null );
   
    SimpleFeatureLabelFormatter testObj = new SimpleFeatureLabelFormatter();
    testObj.setUndefinedValueLabel( undefinedValueLabel );
    String label = testObj.createLabel( this.feature, options );
   
    assertEquals( undefinedValueLabel, label );
  }
View Full Code Here

    final String undefinedPropertyLabel = "Cannot find this property!";
   
    Options options = new Options();
    options.setLabelFormat( "invalidPropertyName" );
   
    SimpleFeatureLabelFormatter testObj = new SimpleFeatureLabelFormatter();
    testObj.setUndefinedPropertyLabel( undefinedPropertyLabel );
    String label = testObj.createLabel( this.feature, options );
   
    assertEquals( undefinedPropertyLabel, label );
  }
View Full Code Here

 
  public void testNoFormat()
  {
    Options options = new Options();
   
    String label = new SimpleFeatureLabelFormatter().createLabel( this.feature, options );
   
    assertEquals( FEATURE_ID, label );
  }
View Full Code Here

    assertEquals( FEATURE_ID, label );
  }
 
  public void testNoOptions()
  {
    String label = new SimpleFeatureLabelFormatter().createLabel( this.feature, null );
   
    assertEquals( FEATURE_ID, label );
  }
View Full Code Here

    LimbGenerator testObj = new LimbGenerator();
    testObj.setIntersectionGeneratorClass( SimpleIntersectionGenerator.class );
    testObj.setIntersectionProcessors( Arrays.asList( new DiscardNegligibleIntersectionProcessor(),
                                                      new DiscardSmallerLineSegmentsIntersectionProcessor() ) );
    testObj.setLimbRefiners( Arrays.asList( new EdgeAssigmentLimbRefiner(),
                                            new LabelAssignmentLimbRefiner().using( new SimpleFeatureLabelFormatter() ),
                                            new LeanBeanLimbRefiner() ) );
   
    List<Limb> limbs = testObj.computeLimbs( view, this.polygons, options );
    //System.out.println( limbs );
   
View Full Code Here

TOP

Related Classes of net.lucidviews.geoalgo.limb.refine.labelling.SimpleFeatureLabelFormatter

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.