Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#2034 Map Plotted Elements Timestamp Includes Date #2049

Merged
merged 1 commit into from
Oct 27, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 22 additions & 4 deletions src/main/java/io/github/dsheirer/map/TrackHistoryModel.java
Original file line number Diff line number Diff line change
@@ -1,21 +1,39 @@
/*
* *****************************************************************************
* Copyright (C) 2014-2024 Dennis Sheirer
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>
* ****************************************************************************
*/

package io.github.dsheirer.map;

import javax.swing.table.AbstractTableModel;
import java.text.DecimalFormat;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Comparator;
import java.util.List;
import java.util.function.ToLongFunction;

import javax.swing.table.AbstractTableModel;

/**
* Table model for track history.
*/
public class TrackHistoryModel extends AbstractTableModel
{
private static final String[] COLUMNS = new String[]{"Time", "Latitude", "Longitude"};
private SimpleDateFormat mSimpleDateFormat = new SimpleDateFormat("HH:mm:ss");
private SimpleDateFormat mSimpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
private DecimalFormat mDegreeFormat = new DecimalFormat("0.00000");
private List<TimestampedGeoPosition> mTimestampedGeoPositions = new ArrayList<>();
private PlottableEntityHistory mPlottableEntityHistory;
Expand Down
Loading