| /******************************************************************************* |
| * Copyright (c) 2018 Agence spatiale canadienne / Canadian Space Agency |
| * All rights reserved. This program and the accompanying materials |
| * are made available under the terms of the Eclipse Public License v1.0 |
| * which accompanies this distribution, and is available at |
| * http://www.eclipse.org/legal/epl-v10.html |
| * |
| * Contributors: |
| * Pierre Allard, |
| * Regent L'Archeveque - initial API and implementation |
| * |
| * SPDX-License-Identifier: EPL-1.0 |
| * |
| *******************************************************************************/ |
| package org.eclipse.apogy.core.environment.orbit.earth.impl; |
| |
| import java.util.Date; |
| import java.util.List; |
| |
| import org.eclipse.apogy.core.environment.earth.EarthSurfaceLocation; |
| import org.eclipse.apogy.core.environment.orbit.ApogyCoreEnvironmentOrbitFacade; |
| import org.eclipse.apogy.core.environment.orbit.SpacecraftState; |
| import org.eclipse.apogy.core.environment.orbit.earth.ElevationMask; |
| import org.eclipse.apogy.core.environment.orbit.earth.GroundStation; |
| import org.eclipse.apogy.core.environment.orbit.earth.VisibilityPass; |
| |
| public class InitialOrbitBasedEarthOrbitModelCustomImpl extends InitialOrbitBasedEarthOrbitModelImpl { |
| |
| @Override |
| public org.orekit.propagation.Propagator getOreKitPropagator() { |
| if (getPropagator() != null) { |
| return getPropagator().getOreKitPropagator(); |
| } else { |
| return null; |
| } |
| } |
| |
| @Override |
| public List<VisibilityPass> getTargetPasses(EarthSurfaceLocation earthSurfaceLocation, Date startDate, Date endDate, |
| ElevationMask elevationMask) throws Exception { |
| return getPropagator().getTargetPasses(earthSurfaceLocation, startDate, endDate, elevationMask); |
| } |
| |
| @Override |
| public List<VisibilityPass> getGroundStationPasses(GroundStation groundStation, Date startDate, Date endDate) |
| throws Exception { |
| return getPropagator().getGroundStationPasses(groundStation, startDate, endDate); |
| } |
| |
| @Override |
| public List<SpacecraftState> getSpacecraftStates(Date startDate, Date endDate, double timeInterval) |
| throws Exception { |
| return getPropagator().getSpacecraftStates(startDate, endDate, timeInterval); |
| } |
| |
| @Override |
| public Date getFromValidDate() { |
| if (getPropagator() != null) { |
| return getPropagator().getFromValidDate(); |
| } else { |
| return null; |
| } |
| } |
| |
| @Override |
| public Date getToValidDate() { |
| if (getPropagator() != null) { |
| return getPropagator().getToValidDate(); |
| } else { |
| return null; |
| } |
| } |
| |
| @Override |
| public SpacecraftState propagate(Date targetDate) throws Exception { |
| if (getPropagator() != null) { |
| return getPropagator().propagate(targetDate); |
| } else { |
| return null; |
| } |
| } |
| |
| @Override |
| public boolean isDateInValidRange(Date date) { |
| return ApogyCoreEnvironmentOrbitFacade.INSTANCE.isDateInValidRange(getFromValidDate(), getToValidDate(), date); |
| } |
| } // InitialOrbitBasedEarthOrbitModelImpl |