} else if (localName.equals("Placemark")) { this.in_placemarktag = true; navigationDataSet.setCurrentPlacemark(new Placemark()); } else if (localName.equals("name")) { this.in_nametag = true; public void characters(char ch[], int start, int length) { if(this.in_nametag){ if (navigationDataSet.getCurrentPlacemark()==null) navigationDataSet.setCurrentPlacemark(new Placemark()); navigationDataSet.getCurrentPlacemark().setTitle(new String(ch, start, length)); } else if(this.in_descriptiontag){ if (navigationDataSet.getCurrentPlacemark()==null) navigationDataSet.setCurrentPlacemark(new Placemark()); navigationDataSet.getCurrentPlacemark().setDescription(new String(ch, start, length)); } else if(this.in_coordinatestag){ if (navigationDataSet.getCurrentPlacemark()==null) navigationDataSet.setCurrentPlacemark(new Placemark());
/** * Create an instance of {@link Placemark} * */ public static Placemark createPlacemark() { return new Placemark(); }
/** * Create an instance of {@link Placemark} * */ public static Placemark createPlacemark() { return new Placemark(); }
/** * Creates a new instance of {@link Placemark} and adds it to feature. * This method is a short version for: * <code> * Placemark placemark = new Placemark(); * this.getFeature().add(placemark); </code> * * */ public Placemark createAndAddPlacemark() { Placemark newValue = new Placemark(); this.getFeature().add(newValue); return newValue; }
/** * Creates a new instance of {@link Placemark} and adds it to feature. * This method is a short version for: * <code> * Placemark placemark = new Placemark(); * this.getFeature().add(placemark); </code> * * */ public Placemark createAndAddPlacemark() { Placemark newValue = new Placemark(); this.getFeature().add(newValue); return newValue; }
/** * Creates a new instance of {@link Placemark} and adds it to feature. * This method is a short version for: * <code> * Placemark placemark = new Placemark(); * this.getFeature().add(placemark); </code> * * */ public Placemark createAndAddPlacemark() { Placemark newValue = new Placemark(); this.getFeature().add(newValue); return newValue; }
/** * Creates a new instance of {@link Placemark} and adds it to feature. * This method is a short version for: * <code> * Placemark placemark = new Placemark(); * this.getFeature().add(placemark); </code> * * */ public Placemark createAndAddPlacemark() { Placemark newValue = new Placemark(); this.getFeature().add(newValue); return newValue; }
/** * Creates a new instance of {@link Placemark} and adds it to feature. * This method is a short version for: * <code> * Placemark placemark = new Placemark(); * this.getFeature().add(placemark); </code> * * */ public Placemark createAndAddPlacemark() { Placemark newValue = new Placemark(); this.getFeature().add(newValue); return newValue; }
/** * Creates a new instance of {@link Placemark} and adds it to feature. * This method is a short version for: * <code> * Placemark placemark = new Placemark(); * this.getFeature().add(placemark); </code> * * */ public Placemark createAndAddPlacemark() { Placemark newValue = new Placemark(); this.getFeature().add(newValue); return newValue; }
/** * Creates a new instance of {@link Placemark} and set it to feature. * * This method is a short version for: * <code> * Placemark placemark = new Placemark(); * this.setFeature(placemark); </code> * * */ public Placemark createAndSetPlacemark() { Placemark newValue = new Placemark(); this.setFeature(newValue); return newValue; }
/** * Creates a new instance of {@link Placemark} and set it to feature. * * This method is a short version for: * <code> * Placemark placemark = new Placemark(); * this.setFeature(placemark); </code> * * */ public Placemark createAndSetPlacemark() { Placemark newValue = new Placemark(); this.setFeature(newValue); return newValue; }
final Kml kml = new Kml(); final Folder folder = new Folder(); kml.setFeature(folder); folder.setName("Folder.kml"); folder.setOpen(true); final Placemark placemark1 = new Placemark().withId("1") .withName("Folder object 1 (Placemark)"); folder.getFeature().add(placemark1); final Placemark placemark2 = new Placemark().withId("2") .withName("Folder object 2 (Placemark)"); folder.getFeature().add(placemark2); List<Feature> features = folder.getFeature(); System.out.println(features); // dumps two features for(int i=features.size()-1; i >= 0; i--) { Feature f = features.get(i); if("1".equals(f.getId())) { // this removes feature with id = "1" features.remove(i); break; } } System.out.println(features); // folder now only has one item
)); Placemark p = new Placemark() .withName(name) .withTimePrimitive(ts)
Placemark pm = new Placemark(); pm.setId(sf.getID());
Placemark pm = new Placemark(); pm.setId(sf.getID());
trackPlacemark = new Placemark() .withName( "Track" ) .withStyleUrl("#track")
/** * Test partial style transformation. * * <p>The YSLD parser is not supplying the same defaults as the SLD parser, producing styles * that violate some of the (perfectly sensible SLD 1.0) assumptions made by * PlacemarkStyleDecorator. */ @Test public void testYSLDTextSymbolizerEncoding() { TextSymbolizer text = text("text", "NAME", font("Arial Black", null, "bold", 8), fill(Color.white, null)); PlacemarkStyleDecoratorFactory.PlacemarkStyleDecorator decorator = new PlacemarkStyleDecorator(); KmlEncodingContext context = new FakeKmlEncodingContext(featureType); SimpleFeatureCollection collection = DataUtilities.collection(fieldIs1); context.setCurrentFeatureCollection(collection); context.setCurrentFeature(fieldIs1); context.setCurrentSymbolizers(Collections.singletonList(text)); Placemark placemark = new Placemark(); decorator.decorate(placemark, context); }