Examples of Projection


Examples of org.openrdf.query.algebra.Projection

        if (!var.isAnonymous() && !var.hasValue()) {
          projElemList.addElement(new ProjectionElem(var.getName()));
        }
      }

      result = new Projection(result, projElemList);

      // Filter the duplicates from these projected bindings
      result = new Distinct(result);
    }

    // Create BNodeGenerator's for all anonymous variables
    Map<Var, ExtensionElem> extElemMap = new HashMap<Var, ExtensionElem>();

    for (Var var : constructVars) {
      if (var.isAnonymous() && !extElemMap.containsKey(var)) {
        ValueExpr valueExpr = null;

        if (var.hasValue()) {
          valueExpr = new ValueConstant(var.getValue());
        }
        else if (explicit) {
          // only generate bnodes in case of an explicit constructor
          valueExpr = new BNodeGenerator();
        }

        if (valueExpr != null) {
          extElemMap.put(var, new ExtensionElem(valueExpr, var.getName()));
        }
      }
    }

    if (!extElemMap.isEmpty()) {
      result = new Extension(result, extElemMap.values());
    }

    // Create a Projection for each StatementPattern in the constructor
    List<ProjectionElemList> projections = new ArrayList<ProjectionElemList>();

    for (StatementPattern sp : statementPatterns) {
      ProjectionElemList projElemList = new ProjectionElemList();

      projElemList.addElement(new ProjectionElem(sp.getSubjectVar().getName(), "subject"));
      projElemList.addElement(new ProjectionElem(sp.getPredicateVar().getName(), "predicate"));
      projElemList.addElement(new ProjectionElem(sp.getObjectVar().getName(), "object"));

      projections.add(projElemList);
    }

    if (projections.size() == 1) {
      result = new Projection(result, projections.get(0));

      // Note: no need to apply the second duplicate elimination step if
      // there's just one projection
    }
    else if (projections.size() > 1) {
View Full Code Here

Examples of org.openstreetmap.josm.data.projection.Projection

        selectedProjectionChanged(pc);
    }

    private void updateMeta(ProjectionChoice pc) {
        pc.setPreferences(pc.getPreferences(projSubPrefPanel));
        Projection proj = pc.getProjection();
        projectionCode.setText(proj.toCode());
        projectionName.setText(proj.toString());
        Bounds b = proj.getWorldBoundsLatLon();
        CoordinateFormat cf = CoordinateFormat.getDefaultFormat();
        bounds.setText(b.getMin().lonToString(cf)+", "+b.getMin().latToString(cf)+" : "+b.getMax().lonToString(cf)+", "+b.getMax().latToString(cf));
        boolean showCode = true;
        boolean showName = false;
        if (pc instanceof SubPrefsOptions) {
View Full Code Here

Examples of org.osgeo.proj4j.proj.Projection

     * @return a geographic CoordinateReferenceSystem based on the datum of this CRS
     */
    public CoordinateReferenceSystem createGeographic()
    {
        Datum datum = getDatum();
        Projection geoProj = new LongLatProjection();
        geoProj.setEllipsoid(getProjection().getEllipsoid());
        geoProj.setUnits(Units.DEGREES);
        geoProj.initialize();
        return new CoordinateReferenceSystem("GEO-" + datum.getCode(), null, datum, geoProj);
    }
View Full Code Here

Examples of org.osm2world.core.target.common.rendering.Projection

    ImageExporter exporter = null;
   
    for (CLIArguments args : argumentsGroup.getCLIArgumentsList()) {
     
      Camera camera = null;
      Projection projection = null;
     
      if (args.isOviewTiles()) {
       
        camera = OrthoTilesUtil.cameraForTiles(
            results.getMapProjection(),
            args.getOviewTiles(),
            args.getOviewAngle(),
            args.getOviewFrom());
        projection = OrthoTilesUtil.projectionForTiles(
            results.getMapProjection(),
            args.getOviewTiles(),
            args.getOviewAngle(),
            args.getOviewFrom());
       
      } else if (args.isOviewBoundingBox()) {
       
        double angle = args.getOviewAngle();
        CardinalDirection from = args.getOviewFrom();
       
        Collection<VectorXZ> pointsXZ = new ArrayList<VectorXZ>();
        for (LatLonEle l : args.getOviewBoundingBox()) {
          pointsXZ.add(results.getMapProjection().calcPos(l.lat, l.lon));
        }
        AxisAlignedBoundingBoxXZ bounds =
          new AxisAlignedBoundingBoxXZ(pointsXZ);
             
        camera = OrthoTilesUtil.cameraForBounds(bounds, angle, from);
        projection = OrthoTilesUtil.projectionForBounds(bounds, angle, from);
       
      } else if (args.isPviewPos()) {
       
        MapProjection proj = results.getMapProjection();
       
        LatLonEle pos = args.getPviewPos();
        LatLonEle lookAt = args.getPviewLookat();
       
        camera = new Camera();
        VectorXYZ posV = proj.calcPos(pos.lat, pos.lon).xyz(pos.ele);
        VectorXYZ laV =  proj.calcPos(lookAt.lat, lookAt.lon).xyz(lookAt.ele);
        camera.setCamera(posV.x, posV.y, posV.z, laV.x, laV.y, laV.z);
       
        projection = new Projection(false,
            args.isPviewAspect() ? args.getPviewAspect() :
              (double)args.getResolution().x / args.getResolution().y,
              args.getPviewFovy(),
            0,
            1, 50000);
View Full Code Here

Examples of org.rascalmpl.library.vis.figure.keys.Projection

    case PROJECTION:
      PropertyValue<String> projectOn = Properties.produceMaybeComputedValue(Types.STR,c.get(1),properties,env);
      Figure projectFrom = makeChild(0,env,c,properties,childPropsNext);
      Figure projection = makeChild(2,env,c,properties,childPropsNext);
      return new Projection(projectFrom,projectOn,projection,properties);
    case ROTATE:
      //TODO
//      child =  makeChild(1,env,c,properties,childPropsNext);
      //double angle = PropertyParsers.parseNum(c.get(0));
      throw new Error("Rotate out of order..");
View Full Code Here

Examples of org.springframework.expression.spel.ast.Projection

    if (!peekToken(TokenKind.PROJECT,true)) {
      return false;
    }
    SpelNodeImpl expr = eatExpression();
    eatToken(TokenKind.RSQUARE);
    constructedNodes.push(new Projection(nullSafeNavigation, toPos(t), expr));
    return true;
  }
View Full Code Here

Examples of org.wicketstuff.openlayers3.api.proj.Projection

                                        new DefaultGeoJsonLoader(
                                                "http://mhc-macris.net:8080/geoserver/MHC/ows?service=WFS"
                                                        + "&version=1.0.0&request=GetFeature&typeName=MHC:in_pts"
                                                        + "&outputFormat=json",
                                                "EPSG:3857"),
                                        new Projection("EPSG:3857", "degress", "nue")), style)),

                        // list of overlays
                        Arrays.<Overlay>asList(

                                // overlay with the popover
View Full Code Here

Examples of org.zkoss.openlayers.base.Projection

    map.addLayer(new Bing(toMap(pair("key", apiKey),
        pair("type", "AerialWithLabels"),
        pair("name", "Bing Aerial With Labels"))));

    map.addControl(new LayerSwitcher());
    map.setCenter(new LonLat(-71.147, 42.472).transform(new Projection(
        "EPSG:4326"), map.getProjection()), 11);

  }
View Full Code Here

Examples of ucar.unidata.geoloc.Projection

    latVar.addAttribute( new Attribute("units", "degrees_north"));

    projVar = latVar;
    String projName = ds.findAttValueIgnoreCase(projVar, "projectionType", null);
    if (projName.equals("LAMBERT_CONFORMAL")) {
      Projection proj = makeLCProjection( ds);
      makeXYcoords( ds, proj, latVar, lonVar);
    }

    // figure out the time coordinate for each data variable
    // LOOK : always seperate; could try to discover if they are the same
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.