Examples of clone()


Examples of org.geomajas.gwt.client.map.feature.FeatureTransaction.clone()

        && event.getNativeButton() != Event.BUTTON_RIGHT) {
      String targetId = getTargetId(event);
      if (TransactionGeomIndexUtil.isVertex(targetId)) {
        dragTargetId = targetId;
        if (dragTransaction == null) {
          dragTransaction = (FeatureTransaction) featureTransaction.clone();
        }
        mapWidget.render(featureTransaction, RenderGroup.VECTOR, RenderStatus.DELETE);
        mapWidget.render(dragTransaction, RenderGroup.VECTOR, RenderStatus.ALL);
        createTempLine(featureTransaction, event);
      }
View Full Code Here

Examples of org.geomajas.gwt.client.spatial.Bbox.clone()

      Bbox maxBounds = new Bbox(mapInfo.getMaxBounds());
      Bbox initialBounds = new Bbox(mapInfo.getInitialBounds());
      // if the max bounds was not configured, take the union of initial and layer bounds
      if (maxBounds.isAll()) {
        for (ClientLayerInfo layerInfo : mapInfo.getLayers()) {
          maxBounds = (Bbox) initialBounds.clone();
          maxBounds = maxBounds.union(new Bbox(layerInfo.getMaxExtent()));
        }
      }
      mapView.setMaxBounds(maxBounds);
      mapView.applyBounds(initialBounds, MapView.ZoomOption.LEVEL_CLOSEST);
View Full Code Here

Examples of org.geomajas.layer.feature.InternalFeature.clone()

    oldFeatures = layerService.getFeatures(LAYER_ID, crs, filter, null,
        VectorLayerService.FEATURE_INCLUDE_ATTRIBUTES);
    Assert.assertEquals(1, oldFeatures.size());
    feature = oldFeatures.get(0);
    newFeatures = new ArrayList<InternalFeature>();
    feature = feature.clone();
    newFeatures.add(feature);
    feature.getAttributes().put(STRING_ATTR, new StringAttribute("changed"));
    feature.getAttributes().put(INTEGER_ATTR, new IntegerAttribute(12345));
    layerService.saveOrUpdate(LAYER_ID, crs, oldFeatures, newFeatures);
    // check changes
View Full Code Here

Examples of org.geoserver.gwc.layer.GeoServerTileLayerInfo.clone()

             */
            final GWCConfig saneDefaults = defaultSettings.saneConfig();
            tileLayerInfo = TileLayerInfoUtil.loadOrCreate(layerInfo, saneDefaults);
        } else {
            GeoServerTileLayerInfo info = ((GeoServerTileLayer) tileLayer).getInfo();
            tileLayerInfo = info.clone();
        }

        tileLayerInfo.setEnabled(true);
        final boolean initWithTileLayer = (isNew && defaultSettings.isCacheLayersByDefault())
                || tileLayer != null;
View Full Code Here

Examples of org.geoserver.ows.ServiceStrategy.clone()

        }

        // clone the strategy since at the moment the strategies are marked as singletons
        // in the web.xml file.
        try {
            theStrategy = (ServiceStrategy) theStrategy.clone();
        } catch (CloneNotSupportedException e) {
            LOGGER.log(Level.SEVERE,
                "Programming error found, service strategies should be cloneable, " + e, e);
            throw new RuntimeException("Found a strategy that does not support cloning...", e);
        }
View Full Code Here

Examples of org.geotools.factory.Hints.clone()

   */
  public GeoTiffMetadata2CRSAdapter(Hints hints) {

    final Hints tempHints = hints != null ? new Hints(hints) : DEFAULT_HINTS;

    this.hints = (Hints) tempHints.clone();
    allAuthoritiesFactory = hints != null ? new AllAuthoritiesFactory(this.hints):
        DEFAULT_ALLAUTHORITIES_FACTORY;

    // factory = new ThreadedEpsgFactory(hints);
    datumObjFactory = ReferencingFactoryFinder.getDatumFactory(this.hints);
View Full Code Here

Examples of org.geotools.geometry.GeneralEnvelope.clone()


        ///////////////////////////////////////////////////////////////
        ///  Tests the creation when a CRS is available.
        ///
        envelope = envelope.clone();
        envelope.setCoordinateReferenceSystem(DefaultGeographicCRS.WGS84);
        mapper.setEnvelope(envelope);
        assertFalse(mapper.getSwapXY());
        assertTrue (Arrays.equals(new boolean[] {false, true}, mapper.getReverseAxis()));
        final AffineTransform tr2 = mapper.createAffineTransform();
View Full Code Here

Examples of org.geotools.geometry.iso.coordinate.DirectPositionImpl.clone()

  public static List<Position> toPositionList(
      CoordinateReferenceSystem crs, Coordinate[] coordArray) {
    List<Position> rList = new ArrayList<Position>();
    for (int i = 0; i < coordArray.length; i++) {
      DirectPositionImpl position = new DirectPositionImpl( crs, coordArray[i].getCoordinates() );
      rList.add( new PositionImpl((DirectPosition)position.clone()) );
      //rList.add(coordinateFactory.createPosition(coordArray[i].getCoordinates()));
    }
    return rList;
  }
 
View Full Code Here

Examples of org.geotools.validation.dto.ArgumentDTO.clone()

        }

        if (adto == null) {
            adto = new ArgumentDTO();
        } else {
            adto = (ArgumentDTO) adto.clone();
        }

        adto.setName(key);
        adto.setValue(val);
        adto.setFinal(_fixed);
View Full Code Here

Examples of org.gitective.core.filter.commit.AllCommitFilter.clone()

   */
  @Test
  public void cloneFilter() throws Exception {
    CommitCountFilter count = new CommitCountFilter();
    AllCommitFilter filter = new AllCommitFilter(count);
    RevFilter clone = filter.clone();
    assertNotNull(clone);
    assertNotSame(filter, clone);
    assertTrue(clone instanceof AllCommitFilter);
  }

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.