Examples of Coordinate


Examples of ie.transportdublin.server.plugin.json.Coordinate

        return (String) this.underlyingNode.getProperty( STOPNAME );
    }

    public Coordinate getCoordinate()
    {
        return new Coordinate( this.getLat(), this.getLon() );
    }
View Full Code Here

Examples of it.freedomotic.plugins.Coordinate

    @Override
    public void run() {
        Iterator it = coord.iterator();

        while (it.hasNext()) {
            Coordinate c = (Coordinate) it.next();

            if (c != null) {
                //MUST BE REIMPLEMENTED
//                PersonLogic p = Freedom.people.get(c.getId());
//                if (p == null) {
View Full Code Here

Examples of jsprit.core.util.Coordinate

    int counter = 1;
    for(VehicleRoute route : routes){
      if(route.isEmpty()) continue;
      XYSeries series = new XYSeries(counter, false, true);
     
      Coordinate startCoord = locations.getCoord(route.getStart().getLocationId());
      series.add(startCoord.getX()*scalingFactor, startCoord.getY()*scalingFactor);
     
      for(TourActivity act : route.getTourActivities().getActivities()){
        Coordinate coord = locations.getCoord(act.getLocationId());
        series.add(coord.getX()*scalingFactor, coord.getY()*scalingFactor);
      }
     
      Coordinate endCoord = locations.getCoord(route.getEnd().getLocationId());
      series.add(endCoord.getX()*scalingFactor, endCoord.getY()*scalingFactor);
     
      coll.addSeries(series);
      counter++;
    }
    return coll;
View Full Code Here

Examples of juzu.impl.common.Coordinate

  /** . */
  public int endOffset;

  public Coordinate getBegin() {
    return new Coordinate(beginOffset, ((Token)this).beginColumn, ((Token)this).beginLine);
  }
View Full Code Here

Examples of model.Coordinate

  }
 
 
 
  private Coordinate randomizeStartCoordinates() {
    return new Coordinate(   (int)( Math.random() * GAME_BOARD_WIDTH) ,
                (int)( Math.random() * GAME_BOARD_HEIGHT ) );
  }
View Full Code Here

Examples of net.hearthstats.util.Coordinate

    if (width == PixelLocation.REFERENCE_SIZE.x() && height == PixelLocation.REFERENCE_SIZE.y()) {
      // The screen size is exactly what our reference pixels are based on, so
      // we can use their coordinates directly
      result = new HashMap<>();
      for (PixelLocation pixelLocation : PixelLocation.values()) {
        Coordinate coordinate = new Coordinate(pixelLocation.x(), pixelLocation.y());
        log.debug("Stored position of {} as {}", pixelLocation, coordinate);
        result.put(pixelLocation, coordinate);
      }

    } else {
      // The screen size is different to our reference pixels, so coordinates
      // need to be adjusted
      float ratioX = (float) width / (float) PixelLocation.REFERENCE_SIZE.x();
      float ratioY = (float) height / (float) PixelLocation.REFERENCE_SIZE.y();
      // ratioY is normally the correct ratio to use, but occasionally ratioX is
      // smaller (usually during screen resizing?)
      float ratio = Math.min(ratioX, ratioY);
      float screenRatio = (float) width / (float) height;

      int xOffset;
      if (screenRatio > 1.4) {
        xOffset = (int) (((float) width - (ratio * PixelLocation.REFERENCE_SIZE.x())) / 2);
      } else {
        xOffset = 0;
      }

      log.debug("ratio={} screenRatio={}, xOffset={}", ratio, screenRatio, xOffset);

      result = new HashMap<>();
      for (PixelLocation pixelLocation : PixelLocation.values()) {
        int x = (int) (pixelLocation.x() * ratio) + xOffset;
        int y = (int) (pixelLocation.y() * ratio);
        Coordinate coordinate = new Coordinate(x, y);
        log.debug("Calculated position of {} as {}", pixelLocation, coordinate);
        result.put(pixelLocation, coordinate);
      }
    }

View Full Code Here

Examples of net.lightstone.model.Coordinate

        buf.writeShort(item.getId());
        buf.writeByte(item.getCount());
        buf.writeShort(item.getDamage());
        break;
      case Parameter.TYPE_COORDINATE:
        Coordinate coord = ((Parameter<Coordinate>) parameter).getValue();
        buf.writeInt(coord.getX());
        buf.writeInt(coord.getY());
        buf.writeInt(coord.getZ());
        break;
      }
    }

    buf.writeByte(0x7F);
View Full Code Here

Examples of org.apache.abdera.ext.geo.Coordinate

   
    Abdera abdera = new Abdera();
    Entry entry = abdera.newEntry();
    entry.setTitle("Middle of the Ocean");
   
    Point point = new Point(new Coordinate(37.0625,-95.677068));
    GeoHelper.addPosition(entry, point);
   
    Position[] positions = GeoHelper.getPositions(entry);
    for (Position pos : positions) {
      if (pos instanceof Point) {
View Full Code Here

Examples of org.apache.cassandra.io.Coordinate

    public void seekTo(String seekKey)
    {
        try
        {
            Coordinate range = SSTable.getCoordinates(seekKey, reader, partitioner);
            reader.seek(range.end_);
            long position = reader.getPositionFromBlockIndex(seekKey);
            if (position == -1)
            {
                reader.seek(range.start_);
View Full Code Here

Examples of org.apache.jetspeed.layout.Coordinate

                {
                    success = false;
                    resultMap.put(REASON, "Failed to find fragment for portlet id: " + moveFragmentId );
                    return success;
                }
                Coordinate returnCoordinate = null;
                float oldX = 0f, oldY = 0f, oldZ = 0f, oldWidth = 0f, oldHeight = 0f;
                float x = -1f, y = -1f, z = -1f, width = -1f, height = -1f;
                boolean absHeightChanged = false;
               
                String posExtended = getActionParameter(requestContext, DESKTOP_EXTENDED);
                if ( posExtended != null )
                {
                    Map fragmentProperties = fragment.getProperties();
                    if ( fragmentProperties == null )
                    {
                        success = false;
                        resultMap.put(REASON, "Failed to acquire fragment properties map for portlet id: " + moveFragmentId );
                        return success;
                    }
                    String oldDeskExt = (String)fragmentProperties.get( DESKTOP_EXTENDED );
                    resultMap.put( OLD_DESKTOP_EXTENDED, ( (oldDeskExt != null) ? oldDeskExt : "" ) );
                    fragmentProperties.put( DESKTOP_EXTENDED, posExtended );
                }
               
                // Only required for moveabs
                if (iMoveType == ABS)
                {
                    Coordinate a_oCoordinate = getCoordinateFromParams(requestContext);
                    returnCoordinate = placement.moveAbsolute(fragment, a_oCoordinate);
                    String sHeight = getActionParameter(requestContext, HEIGHT);
                    if ( sHeight != null && sHeight.length() > 0 )
                    {
                        oldHeight = fragment.getLayoutHeight();
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.