package com.blogspot.webster21.gpsmierniczy; /** * Created by bslowik on 2015-02-19. */ public class point_t { public point_t() { } private double x; private double y; public point_t(double xU92, double yU92) { this.x = xU92; this.y = yU92; } public double getX() { return x; } public void setX(double x) { this.x = x; } public double getY() { return y; } public void setY(double y) { this.y = y; } }
Wykorzystanie takiego kodu:
ArrayList<point_t> pkt = new ArrayList<point_t>(); pkt.add(new point_t(xU92,yU92));
Pobranie danych z tablicy:
System.out.println(pkt.get(0).getX());