diff --git a/src/main/java/eu/omp/irap/vespa/epntapclient/granule/Granule.java b/src/main/java/eu/omp/irap/vespa/epntapclient/granule/Granule.java index 2369ed2..29e121a 100644 --- a/src/main/java/eu/omp/irap/vespa/epntapclient/granule/Granule.java +++ b/src/main/java/eu/omp/irap/vespa/epntapclient/granule/Granule.java @@ -17,137 +17,110 @@ package eu.omp.irap.vespa.epntapclient.granule; import java.util.Date; +import java.util.HashMap; +import java.util.Map; /** * @author N. Jourdane */ public class Granule { - /** Internal table row index. Unique ID in data service, also in v2. Can be alphanum. */ - private String granuleUid; - - /** - * Common to granules of same type (e.g. same map projection, or geometry data products). Can be - * alphanum. - */ - private String granuleGid; - - /** - * Associates granules derived from the same data (e.g. various representations / processing - * levels). Can be alphanum., may be the ID of original observation. - */ - private String obsId; - - /** Organization of the data product, from enumerated list. */ - private String dataproductType; - - /** Standard IAU name of target (from a list related to target class), case sensitive. */ - private String targetName; - - /** Type of target, from enumerated list. */ - private String targetClass; - - /** - * Acquisition start time (in JD). UTC measured at time_origin location (default is observer's - * frame) - */ - private Double timeMin; - - /** - * Acquisition stop time (in JD). UTC measured at time_origin location (default is observer's - * frame). - */ - private Double timeMax; - - /** Min time sampling step. */ - private Double timeSamplingStepMin; - - /** Max time sampling step. */ - private Double timeSamplingStepMax; - - /** Min integration time. */ - private Double timeExpMin; - - /** Max integration time. */ - private Double timeExpMax; + /** Estimate file size in kbyte (with this spelling) */ + private int accessEstsize; - /** Min spectral range (frequency). */ - private Double spectralRangeMin; + /** */ + private String accessFormat; - /** Max spectral range (frequency). */ - private Double spectralRangeMax; + /** MD5 Hash for the file when available (real file) */ + private String accessMd5; - /** Min spectral sampling step. */ - private Double spectralSamplingStepMin; + /** */ + private String accessUrl; - /** Max spectral sampling step. */ - private Double spectralSamplingStepMax; + /** Provides alternative target name if more common (e.g. comets) */ + private String altTargetName; - /** Min spectral resolution. */ - private Double spectralResolutionMin; + /** Bibcode, doi, or other biblio id, URL */ + private String bibReference; - /** Max spectral resolution. */ - private Double spectralResolutionMax; + /** Max of first coordinate. */ + private Double c1Max; /** Min of first coordinate. */ private Double c1Min; - /** Max of first coordinate. */ - private Double c1Max; + /** Max resolution in first coordinate. */ + private Double c1ResolMax; - /** Min of second coordinate. */ - private Double c2Min; + /** Min resolution in first coordinate. */ + private Double c1ResolMin; /** Max of second coordinate. */ private Double c2Max; - /** Min of third coordinate. */ - private Double c3Min; - - /** Max of third coordinate. */ - private Double c3Max; - - /** ObsCore-like footprint, assume spatial_coordinate_description. */ - private String sRegion; - - /** Min resolution in first coordinate. */ - private Double c1ResolMin; + /** Min of second coordinate. */ + private Double c2Min; - /** Max resolution in first coordinate. */ - private Double c1ResolMax; + /** Max resolution in second coordinate. */ + private Double c2ResolMax; /** Min resolution in second coordinate. */ private Double c2ResolMin; - /** Max resolution in second coordinate. */ - private Double c2ResolMax; + /** Max of third coordinate. */ + private Double c3Max; - /** Min resolution in third coordinate. */ - private Double c3ResolMin; + /** Min of third coordinate. */ + private Double c3Min; /** Max resolution in third coordinate. */ private Double c3ResolMax; - /** Flavor of coordinate system, defines the nature of coordinates. From enumerated list. */ - private String spatialFrameType; + /** Min resolution in third coordinate. */ + private Double c3ResolMin; - /** Min incidence angle (solar zenithal angle). */ - private Double incidenceMin; + /** Date of first entry of this granule */ + private Date creationDate; - /** Max incidence angle (solar zenithal angle). */ - private Double incidenceMax; + /** + * If access_format indicates a detached label, this parameter is mandatory and points to the + * corresponding data file - both will be handled by the client before samping it to tools or + * downloading + */ + private String dataAccessUrl; - /** Min emergence angle. */ - private Double emergenceMin; + /** Organization of the data product, from enumerated list. */ + private String dataproductType; + + /** Declination */ + private double dec; /** Max emergence angle. */ private Double emergenceMax; - /** Min phase angle. */ - private Double phaseMin; + /** Min emergence angle. */ + private Double emergenceMin; - /** Max phase angle. */ - private Double phaseMax; + /** */ + private String featureName; + + /** Name of the data file only, case sensitive */ + private String fileName; + + /** + * Common to granules of same type (e.g. same map projection, or geometry data products). Can be + * alphanum. + */ + private String granuleGid; + + /** Internal table row index. Unique ID in data service, also in v2. Can be alphanum. */ + private String granuleUid; + + /** Max incidence angle (solar zenithal angle). */ + private Double incidenceMax; + + /** Min incidence angle (solar zenithal angle). */ + private Double incidenceMin; /** Standard name of the observatory or spacecraft. */ private String instrumentHostName; @@ -155,127 +128,156 @@ public class Granule { /** Standard name of instrument */ private String instrumentName; - /** UCD(s) defining the data */ - private String measurementType; + /** Local time at observed region */ + private double localTimeMax; - /** CODMAC calibration level in v1 */ - private Integer processingLevel; + /** Local time at observed region */ + private double localTimeMin; - /** Date of first entry of this granule */ - private Date creationDate; + /** UCD(s) defining the data */ + private String measurementType; /** Date of last modification (used to handle mirroring) */ private Date modificationDate; + /** + * Associates granules derived from the same data (e.g. various representations / processing + * levels). Can be alphanum., may be the ID of original observation. + */ + private String obsId; + /** */ - private Date releaseDate; + private double particleSpectralRangeMax; /** */ - private String serviceTitle; + private double particleSpectralRangeMin; /** */ - private String accessUrl; + private double particleSpectralResolutionMax; /** */ - private String accessFormat; + private double particleSpectralResolutionMin; - /** Estimate file size in kbyte (with this spelling) */ - private int accessEstsize; + /** */ + private double particleSpectralSamplingStepMax; - /** - * If access_format indicates a detached label, this parameter is mandatory and points to the - * corresponding data file - both will be handled by the client before samping it to tools or - * downloading - */ - private String dataAccessUrl; + /** */ + private double particleSpectralSamplingStepMin; - /** MD5 Hash for the file when available (real file) */ - private String accessMd5; + /** */ + private String particleSpectralType; - /** URL of a thumbnail image with predefined size (png ~200 pix, for use in a client only) */ - private String thumbnailUrl; + /** Max phase angle. */ + private Double phaseMax; - /** Name of the data file only, case sensitive */ - private String fileName; + /** Min phase angle. */ + private Double phaseMin; - /** Identifies a chemical species, case sensitive */ - private String species; + /** CODMAC calibration level in v1 */ + private Integer processingLevel; - /** Provides alternative target name if more common (e.g. comets) */ - private String altTargetName; + /** Resource publisher */ + private String publisher; /** */ - private String targetRegion; + private double ra; /** */ - private String featureName; - - /** Bibcode, doi, or other biblio id, URL */ - private String bibReference; + private Date releaseDate; /** */ - private double ra; + private String serviceTitle; - /** Declination */ - private double dec; + /** Max Solar longitude Ls (location on orbit / season) */ + private double solarLongitudeMax; /** Min Solar longitude Ls (location on orbit / season) */ private double solarLongitudeMin; - /** Max Solar longitude Ls (location on orbit / season) */ - private double solarLongitudeMax; + /** ID of specific coordinate system and version */ + private String spatialCoordinateDescription; - /** Local time at observed region */ - private double localTimeMin; + /** Flavor of coordinate system, defines the nature of coordinates. From enumerated list. */ + private String spatialFrameType; - /** Local time at observed region */ - private double localTimeMax; + /** Defines the frame origin */ + private String spatialOrigin; - /** Observer-target distance */ - private double targetDistanceMin; + /** Identifies a chemical species, case sensitive */ + private String species; - /** Observer-target distance */ - private double targetDistanceMax; + /** Max spectral range (frequency). */ + private Double spectralRangeMax; - /** */ - private double targetTimeMin; + /** Min spectral range (frequency). */ + private Double spectralRangeMin; - /** */ - private double targetTimeMax; + /** Max spectral resolution. */ + private Double spectralResolutionMax; + + /** Min spectral resolution. */ + private Double spectralResolutionMin; + + /** Max spectral sampling step. */ + private Double spectralSamplingStepMax; + + /** Min spectral sampling step. */ + private Double spectralSamplingStepMin; + + /** ObsCore-like footprint, assume spatial_coordinate_description. */ + private String sRegion; + + /** Type of target, from enumerated list. */ + private String targetClass; - /** */ - private String particleSpectralType; + /** Observer-target distance */ + private double targetDistanceMax; - /** */ - private double particleSpectralRangeMin; + /** Observer-target distance */ + private double targetDistanceMin; - /** */ - private double particleSpectralRangeMax; + /** Standard IAU name of target (from a list related to target class), case sensitive. */ + private String targetName; /** */ - private double particleSpectralSamplingStepMin; + private String targetRegion; /** */ - private double particleSpectralSamplingStepMax; + private double targetTimeMax; /** */ - private double particleSpectralResolutionMin; + private double targetTimeMin; - /** */ - private double particleSpectralResolutionMax; + /** URL of a thumbnail image with predefined size (png ~200 pix, for use in a client only) */ + private String thumbnailUrl; - /** Resource publisher */ - private String publisher; + /** Max integration time. */ + private Double timeExpMax; - /** ID of specific coordinate system and version */ - private String spatialCoordinateDescription; + /** Min integration time. */ + private Double timeExpMin; - /** Defines the frame origin */ - private String spatialOrigin; + /** + * Acquisition stop time (in JD). UTC measured at time_origin location (default is observer's + * frame). + */ + private Double timeMax; + + /** + * Acquisition start time (in JD). UTC measured at time_origin location (default is observer's + * frame) + */ + private Double timeMin; /** */ private String timeOrigin; + /** Max time sampling step. */ + private Double timeSamplingStepMax; + + /** Min time sampling step. */ + private Double timeSamplingStepMin; + /** */ private String timeScale; @@ -289,697 +291,802 @@ public class Granule { this.granuleUid = granuleUid; } + public Map asMap() { + Map map = new HashMap<>(); + map.put(GranuleEnum.GRANULE_UID.toString(), granuleUid); + map.put(GranuleEnum.GRANULE_GID.toString(), granuleGid); + map.put(GranuleEnum.OBS_ID.toString(), obsId); + map.put(GranuleEnum.DATAPRODUCT_TYPE.toString(), dataproductType); + map.put(GranuleEnum.TARGET_NAME.toString(), targetName); + map.put(GranuleEnum.TARGET_CLASS.toString(), targetClass); + map.put(GranuleEnum.TIME_MIN.toString(), timeMin); + map.put(GranuleEnum.TIME_MAX.toString(), timeMax); + map.put(GranuleEnum.TIME_SAMPLING_STEP_MIN.toString(), timeSamplingStepMin); + map.put(GranuleEnum.TIME_SAMPLING_STEP_MAX.toString(), timeSamplingStepMax); + map.put(GranuleEnum.TIME_EXP_MIN.toString(), timeExpMin); + map.put(GranuleEnum.TIME_EXP_MAX.toString(), timeExpMax); + map.put(GranuleEnum.SPECTRAL_RANGE_MIN.toString(), spectralRangeMin); + map.put(GranuleEnum.SPECTRAL_RANGE_MAX.toString(), spectralRangeMax); + map.put(GranuleEnum.TIME_SAMPLING_STEP_MIN.toString(), timeSamplingStepMin); + map.put(GranuleEnum.TIME_SAMPLING_STEP_MAX.toString(), timeSamplingStepMax); + map.put(GranuleEnum.SPECTRAL_RESOLUTION_MIN.toString(), spectralResolutionMin); + map.put(GranuleEnum.SPECTRAL_RESOLUTION_MAX.toString(), spectralResolutionMax); + map.put(GranuleEnum.C1MIN.toString(), c1Min); + map.put(GranuleEnum.C1MAX.toString(), c1Max); + map.put(GranuleEnum.C2MIN.toString(), c2Min); + map.put(GranuleEnum.C2MAX.toString(), c2Max); + map.put(GranuleEnum.C3MIN.toString(), c3Min); + map.put(GranuleEnum.C3MAX.toString(), c3Max); + map.put(GranuleEnum.S_REGION.toString(), sRegion); + map.put(GranuleEnum.C1_RESOL_MIN.toString(), c1ResolMin); + map.put(GranuleEnum.C1_RESOL_MAX.toString(), c1ResolMax); + map.put(GranuleEnum.C2_RESOL_MIN.toString(), c2ResolMin); + map.put(GranuleEnum.C2_RESOL_MAX.toString(), c2ResolMax); + map.put(GranuleEnum.C3_RESOL_MIN.toString(), c3ResolMin); + map.put(GranuleEnum.C3_RESOL_MAX.toString(), c3ResolMax); + map.put(GranuleEnum.SPATIAL_FRAME_TYPE.toString(), spatialFrameType); + map.put(GranuleEnum.INCIDENCE_MIN.toString(), incidenceMin); + map.put(GranuleEnum.INCIDENCE_MAX.toString(), incidenceMax); + map.put(GranuleEnum.EMERGENCE_MIN.toString(), emergenceMin); + map.put(GranuleEnum.EMERGENCE_MAX.toString(), emergenceMax); + map.put(GranuleEnum.PHASE_MIN.toString(), phaseMin); + map.put(GranuleEnum.PHASE_MAX.toString(), phaseMax); + map.put(GranuleEnum.INSTRUMENT_HOST_NAME.toString(), instrumentHostName); + map.put(GranuleEnum.INSTRUMENT_NAME.toString(), instrumentName); + map.put(GranuleEnum.MEASUREMENT_TYPE.toString(), measurementType); + map.put(GranuleEnum.PROCESSING_LEVEL.toString(), processingLevel); + map.put(GranuleEnum.CREATION_DATE.toString(), creationDate); + map.put(GranuleEnum.MODIFICATION_DATE.toString(), modificationDate); + map.put(GranuleEnum.RELEASE_DATE.toString(), releaseDate); + map.put(GranuleEnum.SERVICE_TITLE.toString(), serviceTitle); + return map; + } + + @Override + public boolean equals(Object that) { + if (this == that) { + return true; + } + + if (!(that instanceof Granule)) { + return false; + } + + Granule thatGranule = (Granule) that; + for (Map.Entry parameter : asMap().entrySet()) { + Object val1 = parameter.getValue(); + Object val2 = thatGranule.asMap().get(parameter.getKey()); + if (!val1.equals(val2)) { + return false; + } + } + return true; + } + /** - * @return the granuleUid + * @return the accessEstsize */ - public String getGranuleUid() { - return granuleUid; + public int getAccessEstsize() { + return accessEstsize; } /** - * @param granuleUid the granuleUid to set + * @return the accessFormat */ - public void setGranuleUid(String granuleUid) { - this.granuleUid = granuleUid; + public String getAccessFormat() { + return accessFormat; } /** - * @return the granuleGid + * @return the accessMd5 */ - public String getGranuleGid() { - return granuleGid; + public String getAccessMd5() { + return accessMd5; } /** - * @param granuleGid the granuleGid to set + * @return the accessUrl */ - public void setGranuleGid(String granuleGid) { - this.granuleGid = granuleGid; + public String getAccessUrl() { + return accessUrl; } /** - * @return the obsId + * @return the altTargetName */ - public String getObsId() { - return obsId; + public String getAltTargetName() { + return altTargetName; } /** - * @param obsId the obsId to set + * @return the bibReference */ - public void setObsId(String obsId) { - this.obsId = obsId; + public String getBibReference() { + return bibReference; } /** - * @return the dataproductType + * @return the c1Max */ - public String getDataproductType() { - return dataproductType; + public Double getC1Max() { + return c1Max; } /** - * @param dataproductType the dataproductType to set + * @return the c1Min */ - public void setDataproductType(String dataproductType) { - this.dataproductType = dataproductType; + public Double getC1Min() { + return c1Min; } /** - * @return the targetName + * @return the c1ResolMax */ - public String getTargetName() { - return targetName; + public Double getC1ResolMax() { + return c1ResolMax; } /** - * @param targetName the targetName to set + * @return the c1ResolMin */ - public void setTargetName(String targetName) { - this.targetName = targetName; + public Double getC1ResolMin() { + return c1ResolMin; } /** - * @return the targetClass + * @return the c2Max */ - public String getTargetClass() { - return targetClass; + public Double getC2Max() { + return c2Max; } /** - * @param targetClass the targetClass to set + * @return the c2Min */ - public void setTargetClass(String targetClass) { - this.targetClass = targetClass; + public Double getC2Min() { + return c2Min; } /** - * @return the timeMin + * @return the c2ResolMax */ - public Double getTimeMin() { - return timeMin; + public Double getC2ResolMax() { + return c2ResolMax; } /** - * @param timeMin the timeMin to set + * @return the c2ResolMin */ - public void setTimeMin(Double timeMin) { - this.timeMin = timeMin; + public Double getC2ResolMin() { + return c2ResolMin; } /** - * @return the timeMax + * @return the c3Max */ - public Double getTimeMax() { - return timeMax; + public Double getC3Max() { + return c3Max; } /** - * @param timeMax the timeMax to set + * @return the c3Min */ - public void setTimeMax(Double timeMax) { - this.timeMax = timeMax; + public Double getC3Min() { + return c3Min; } /** - * @return the timeSamplingStepMin + * @return the c3ResolMax */ - public Double getTimeSamplingStepMin() { - return timeSamplingStepMin; + public Double getC3ResolMax() { + return c3ResolMax; } /** - * @param timeSamplingStepMin the timeSamplingStepMin to set + * @return the c3ResolMin */ - public void setTimeSamplingStepMin(Double timeSamplingStepMin) { - this.timeSamplingStepMin = timeSamplingStepMin; + public Double getC3ResolMin() { + return c3ResolMin; } /** - * @return the timeSamplingStepMax + * @return the creationDate */ - public Double getTimeSamplingStepMax() { - return timeSamplingStepMax; + public Date getCreationDate() { + return creationDate; } /** - * @param timeSamplingStepMax the timeSamplingStepMax to set + * @return the dataAccessUrl */ - public void setTimeSamplingStepMax(Double timeSamplingStepMax) { - this.timeSamplingStepMax = timeSamplingStepMax; + public String getDataAccessUrl() { + return dataAccessUrl; } /** - * @return the timeExpMin + * @return the dataproductType */ - public Double getTimeExpMin() { - return timeExpMin; + public String getDataproductType() { + return dataproductType; } /** - * @param timeExpMin the timeExpMin to set + * @return the dec */ - public void setTimeExpMin(Double timeExpMin) { - this.timeExpMin = timeExpMin; + public double getDec() { + return dec; } /** - * @return the timeExpMax + * @return the emergenceMax */ - public Double getTimeExpMax() { - return timeExpMax; + public Double getEmergenceMax() { + return emergenceMax; } /** - * @param timeExpMax the timeExpMax to set + * @return the emergenceMin */ - public void setTimeExpMax(Double timeExpMax) { - this.timeExpMax = timeExpMax; + public Double getEmergenceMin() { + return emergenceMin; } /** - * @return the spectralRangeMin + * @return the featureName */ - public Double getSpectralRangeMin() { - return spectralRangeMin; + public String getFeatureName() { + return featureName; } /** - * @param spectralRangeMin the spectralRangeMin to set + * @return the fileName */ - public void setSpectralRangeMin(Double spectralRangeMin) { - this.spectralRangeMin = spectralRangeMin; + public String getFileName() { + return fileName; } /** - * @return the spectralRangeMax + * @return the granuleGid */ - public Double getSpectralRangeMax() { - return spectralRangeMax; + public String getGranuleGid() { + return granuleGid; } /** - * @param spectralRangeMax the spectralRangeMax to set + * @return the granuleUid */ - public void setSpectralRangeMax(Double spectralRangeMax) { - this.spectralRangeMax = spectralRangeMax; + public String getGranuleUid() { + return granuleUid; } /** - * @return the spectralSamplingStepMin + * @return the incidenceMax */ - public Double getSpectralSamplingStepMin() { - return spectralSamplingStepMin; + public Double getIncidenceMax() { + return incidenceMax; } /** - * @param spectralSamplingStepMin the spectralSamplingStepMin to set + * @return the incidenceMin */ - public void setSpectralSamplingStepMin(Double spectralSamplingStepMin) { - this.spectralSamplingStepMin = spectralSamplingStepMin; + public Double getIncidenceMin() { + return incidenceMin; } /** - * @return the spectralSamplingStepMax + * @return the instrumentHostName */ - public Double getSpectralSamplingStepMax() { - return spectralSamplingStepMax; + public String getInstrumentHostName() { + return instrumentHostName; + } + + /** + * @return the instrumentName + */ + public String getInstrumentName() { + return instrumentName; + } + + /** + * @return the localTimeMax + */ + public double getLocalTimeMax() { + return localTimeMax; } /** - * @param spectralSamplingStepMax the spectralSamplingStepMax to set + * @return the localTimeMin */ - public void setSpectralSamplingStepMax(Double spectralSamplingStepMax) { - this.spectralSamplingStepMax = spectralSamplingStepMax; + public double getLocalTimeMin() { + return localTimeMin; } /** - * @return the spectralResolutionMin + * @return the measurementType */ - public Double getSpectralResolutionMin() { - return spectralResolutionMin; + public String getMeasurementType() { + return measurementType; } /** - * @param spectralResolutionMin the spectralResolutionMin to set + * @return the modificationDate */ - public void setSpectralResolutionMin(Double spectralResolutionMin) { - this.spectralResolutionMin = spectralResolutionMin; + public Date getModificationDate() { + return modificationDate; } /** - * @return the spectralResolutionMax + * @return the obsId */ - public Double getSpectralResolutionMax() { - return spectralResolutionMax; + public String getObsId() { + return obsId; } /** - * @param spectralResolutionMax the spectralResolutionMax to set + * @return the particleSpectralRangeMax */ - public void setSpectralResolutionMax(Double spectralResolutionMax) { - this.spectralResolutionMax = spectralResolutionMax; + public double getParticleSpectralRangeMax() { + return particleSpectralRangeMax; } /** - * @return the c1Min + * @return the particleSpectralRangeMin */ - public Double getC1Min() { - return c1Min; + public double getParticleSpectralRangeMin() { + return particleSpectralRangeMin; } /** - * @param c1Min the c1Min to set + * @return the particleSpectralResolutionMax */ - public void setC1Min(Double c1Min) { - this.c1Min = c1Min; + public double getParticleSpectralResolutionMax() { + return particleSpectralResolutionMax; } /** - * @return the c1Max + * @return the particleSpectralResolutionMin */ - public Double getC1Max() { - return c1Max; + public double getParticleSpectralResolutionMin() { + return particleSpectralResolutionMin; } /** - * @param c1Max the c1Max to set + * @return the particleSpectralSamplingStepMax */ - public void setC1Max(Double c1Max) { - this.c1Max = c1Max; + public double getParticleSpectralSamplingStepMax() { + return particleSpectralSamplingStepMax; } /** - * @return the c2Min + * @return the particleSpectralSamplingStepMin */ - public Double getC2Min() { - return c2Min; + public double getParticleSpectralSamplingStepMin() { + return particleSpectralSamplingStepMin; } /** - * @param c2Min the c2Min to set + * @return the particleSpectralType */ - public void setC2Min(Double c2Min) { - this.c2Min = c2Min; + public String getParticleSpectralType() { + return particleSpectralType; } /** - * @return the c2Max + * @return the phaseMax */ - public Double getC2Max() { - return c2Max; + public Double getPhaseMax() { + return phaseMax; } /** - * @param c2Max the c2Max to set + * @return the phaseMin */ - public void setC2Max(Double c2Max) { - this.c2Max = c2Max; + public Double getPhaseMin() { + return phaseMin; } /** - * @return the c3Min + * @return the processingLevel */ - public Double getC3Min() { - return c3Min; + public Integer getProcessingLevel() { + return processingLevel; } /** - * @param c3Min the c3Min to set + * @return the publisher */ - public void setC3Min(Double c3Min) { - this.c3Min = c3Min; + public String getPublisher() { + return publisher; } /** - * @return the c3Max + * @return the ra */ - public Double getC3Max() { - return c3Max; + public double getRa() { + return ra; } /** - * @param c3Max the c3Max to set + * @return the releaseDate */ - public void setC3Max(Double c3Max) { - this.c3Max = c3Max; + public Date getReleaseDate() { + return releaseDate; } /** - * @return the sRegion + * @return the serviceTitle */ - public String getsRegion() { - return sRegion; + public String getServiceTitle() { + return serviceTitle; } /** - * @param sRegion the sRegion to set + * @return the solarLongitudeMax */ - public void setsRegion(String sRegion) { - this.sRegion = sRegion; + public double getSolarLongitudeMax() { + return solarLongitudeMax; } /** - * @return the c1ResolMin + * @return the solarLongitudeMin */ - public Double getC1ResolMin() { - return c1ResolMin; + public double getSolarLongitudeMin() { + return solarLongitudeMin; } /** - * @param c1ResolMin the c1ResolMin to set + * @return the spatialCoordinateDescription */ - public void setC1ResolMin(Double c1ResolMin) { - this.c1ResolMin = c1ResolMin; + public String getSpatialCoordinateDescription() { + return spatialCoordinateDescription; } /** - * @return the c1ResolMax + * @return the spatialFrameType */ - public Double getC1ResolMax() { - return c1ResolMax; + public String getSpatialFrameType() { + return spatialFrameType; } /** - * @param c1ResolMax the c1ResolMax to set + * @return the spatialOrigin */ - public void setC1ResolMax(Double c1ResolMax) { - this.c1ResolMax = c1ResolMax; + public String getSpatialOrigin() { + return spatialOrigin; } /** - * @return the c2ResolMin + * @return the species */ - public Double getC2ResolMin() { - return c2ResolMin; + public String getSpecies() { + return species; } /** - * @param c2ResolMin the c2ResolMin to set + * @return the spectralRangeMax */ - public void setC2ResolMin(Double c2ResolMin) { - this.c2ResolMin = c2ResolMin; + public Double getSpectralRangeMax() { + return spectralRangeMax; } /** - * @return the c2ResolMax + * @return the spectralRangeMin */ - public Double getC2ResolMax() { - return c2ResolMax; + public Double getSpectralRangeMin() { + return spectralRangeMin; } /** - * @param c2ResolMax the c2ResolMax to set + * @return the spectralResolutionMax */ - public void setC2ResolMax(Double c2ResolMax) { - this.c2ResolMax = c2ResolMax; + public Double getSpectralResolutionMax() { + return spectralResolutionMax; } /** - * @return the c3ResolMin + * @return the spectralResolutionMin */ - public Double getC3ResolMin() { - return c3ResolMin; + public Double getSpectralResolutionMin() { + return spectralResolutionMin; } /** - * @param c3ResolMin the c3ResolMin to set + * @return the spectralSamplingStepMax */ - public void setC3ResolMin(Double c3ResolMin) { - this.c3ResolMin = c3ResolMin; + public Double getSpectralSamplingStepMax() { + return spectralSamplingStepMax; } /** - * @return the c3ResolMax + * @return the spectralSamplingStepMin */ - public Double getC3ResolMax() { - return c3ResolMax; + public Double getSpectralSamplingStepMin() { + return spectralSamplingStepMin; } /** - * @param c3ResolMax the c3ResolMax to set + * @return the sRegion */ - public void setC3ResolMax(Double c3ResolMax) { - this.c3ResolMax = c3ResolMax; + public String getsRegion() { + return sRegion; } /** - * @return the spatialFrameType + * @return the targetClass */ - public String getSpatialFrameType() { - return spatialFrameType; + public String getTargetClass() { + return targetClass; } /** - * @param spatialFrameType the spatialFrameType to set + * @return the targetDistanceMax */ - public void setSpatialFrameType(String spatialFrameType) { - this.spatialFrameType = spatialFrameType; + public double getTargetDistanceMax() { + return targetDistanceMax; } /** - * @return the incidenceMin + * @return the targetDistanceMin */ - public Double getIncidenceMin() { - return incidenceMin; + public double getTargetDistanceMin() { + return targetDistanceMin; } /** - * @param incidenceMin the incidenceMin to set + * @return the targetName */ - public void setIncidenceMin(Double incidenceMin) { - this.incidenceMin = incidenceMin; + public String getTargetName() { + return targetName; } /** - * @return the incidenceMax + * @return the targetRegion */ - public Double getIncidenceMax() { - return incidenceMax; + public String getTargetRegion() { + return targetRegion; } /** - * @param incidenceMax the incidenceMax to set + * @return the targetTimeMax */ - public void setIncidenceMax(Double incidenceMax) { - this.incidenceMax = incidenceMax; + public double getTargetTimeMax() { + return targetTimeMax; } /** - * @return the emergenceMin + * @return the targetTimeMin */ - public Double getEmergenceMin() { - return emergenceMin; + public double getTargetTimeMin() { + return targetTimeMin; } /** - * @param emergenceMin the emergenceMin to set + * @return the thumbnailUrl */ - public void setEmergenceMin(Double emergenceMin) { - this.emergenceMin = emergenceMin; + public String getThumbnailUrl() { + return thumbnailUrl; } /** - * @return the emergenceMax + * @return the timeExpMax */ - public Double getEmergenceMax() { - return emergenceMax; + public Double getTimeExpMax() { + return timeExpMax; } /** - * @param emergenceMax the emergenceMax to set + * @return the timeExpMin */ - public void setEmergenceMax(Double emergenceMax) { - this.emergenceMax = emergenceMax; + public Double getTimeExpMin() { + return timeExpMin; } /** - * @return the phaseMin + * @return the timeMax */ - public Double getPhaseMin() { - return phaseMin; + public Double getTimeMax() { + return timeMax; } /** - * @param phaseMin the phaseMin to set + * @return the timeMin */ - public void setPhaseMin(Double phaseMin) { - this.phaseMin = phaseMin; + public Double getTimeMin() { + return timeMin; } /** - * @return the phaseMax + * @return the timeOrigin */ - public Double getPhaseMax() { - return phaseMax; + public String getTimeOrigin() { + return timeOrigin; } /** - * @param phaseMax the phaseMax to set + * @return the timeSamplingStepMax */ - public void setPhaseMax(Double phaseMax) { - this.phaseMax = phaseMax; + public Double getTimeSamplingStepMax() { + return timeSamplingStepMax; } /** - * @return the instrumentHostName + * @return the timeSamplingStepMin */ - public String getInstrumentHostName() { - return instrumentHostName; + public Double getTimeSamplingStepMin() { + return timeSamplingStepMin; } /** - * @param instrumentHostName the instrumentHostName to set + * @return the timeScale */ - public void setInstrumentHostName(String instrumentHostName) { - this.instrumentHostName = instrumentHostName; + public String getTimeScale() { + return timeScale; } - /** - * @return the instrumentName - */ - public String getInstrumentName() { - return instrumentName; + @Override + public int hashCode() { + final int salt = 31; + int hash = 1; + for (Map.Entry parameter : asMap().entrySet()) { + hash = salt * hash + + (parameter.getValue() == null ? 0 : parameter.getValue().hashCode()); + } + return hash; } /** - * @param instrumentName the instrumentName to set + * A granule is valid if all mandatory parameters are filled. + * + * @return true if the Granule is valid, false otherwise. */ - public void setInstrumentName(String instrumentName) { - this.instrumentName = instrumentName; + public boolean isValid() { + for (Map.Entry parameter : asMap().entrySet()) { + if (parameter.getValue() == null) { + return false; + } + } + return true; + } + + public String printAll() { + String s = ""; + for (Map.Entry parameter : asMap().entrySet()) { + s += parameter.getKey() + ": " + parameter.getValue() + "\n"; + } + return s; } /** - * @return the measurementType + * @param accessEstsize the accessEstsize to set */ - public String getMeasurementType() { - return measurementType; + public void setAccessEstsize(int accessEstsize) { + this.accessEstsize = accessEstsize; } /** - * @param measurementType the measurementType to set + * @param accessFormat the accessFormat to set */ - public void setMeasurementType(String measurementType) { - this.measurementType = measurementType; + public void setAccessFormat(String accessFormat) { + this.accessFormat = accessFormat; } /** - * @return the processingLevel + * @param accessMd5 the accessMd5 to set */ - public Integer getProcessingLevel() { - return processingLevel; + public void setAccessMd5(String accessMd5) { + this.accessMd5 = accessMd5; } /** - * @param processingLevel the processingLevel to set + * @param accessUrl the accessUrl to set */ - public void setProcessingLevel(Integer processingLevel) { - this.processingLevel = processingLevel; + public void setAccessUrl(String accessUrl) { + this.accessUrl = accessUrl; } /** - * @return the creationDate + * @param altTargetName the altTargetName to set */ - public Date getCreationDate() { - return creationDate; + public void setAltTargetName(String altTargetName) { + this.altTargetName = altTargetName; } /** - * @param creationDate the creationDate to set + * @param bibReference the bibReference to set */ - public void setCreationDate(Date creationDate) { - this.creationDate = creationDate; + public void setBibReference(String bibReference) { + this.bibReference = bibReference; } /** - * @return the modificationDate + * @param c1Max the c1Max to set */ - public Date getModificationDate() { - return modificationDate; + public void setC1Max(Double c1Max) { + this.c1Max = c1Max; } /** - * @param modificationDate the modificationDate to set + * @param c1Min the c1Min to set */ - public void setModificationDate(Date modificationDate) { - this.modificationDate = modificationDate; + public void setC1Min(Double c1Min) { + this.c1Min = c1Min; } /** - * @return the releaseDate + * @param c1ResolMax the c1ResolMax to set */ - public Date getReleaseDate() { - return releaseDate; + public void setC1ResolMax(Double c1ResolMax) { + this.c1ResolMax = c1ResolMax; } /** - * @param releaseDate the releaseDate to set + * @param c1ResolMin the c1ResolMin to set */ - public void setReleaseDate(Date releaseDate) { - this.releaseDate = releaseDate; + public void setC1ResolMin(Double c1ResolMin) { + this.c1ResolMin = c1ResolMin; } /** - * @return the serviceTitle + * @param c2Max the c2Max to set */ - public String getServiceTitle() { - return serviceTitle; + public void setC2Max(Double c2Max) { + this.c2Max = c2Max; } /** - * @param serviceTitle the serviceTitle to set + * @param c2Min the c2Min to set */ - public void setServiceTitle(String serviceTitle) { - this.serviceTitle = serviceTitle; + public void setC2Min(Double c2Min) { + this.c2Min = c2Min; } /** - * @return the accessUrl + * @param c2ResolMax the c2ResolMax to set */ - public String getAccessUrl() { - return accessUrl; + public void setC2ResolMax(Double c2ResolMax) { + this.c2ResolMax = c2ResolMax; } /** - * @param accessUrl the accessUrl to set + * @param c2ResolMin the c2ResolMin to set */ - public void setAccessUrl(String accessUrl) { - this.accessUrl = accessUrl; + public void setC2ResolMin(Double c2ResolMin) { + this.c2ResolMin = c2ResolMin; } /** - * @return the accessFormat + * @param c3Max the c3Max to set */ - public String getAccessFormat() { - return accessFormat; + public void setC3Max(Double c3Max) { + this.c3Max = c3Max; } /** - * @param accessFormat the accessFormat to set + * @param c3Min the c3Min to set */ - public void setAccessFormat(String accessFormat) { - this.accessFormat = accessFormat; + public void setC3Min(Double c3Min) { + this.c3Min = c3Min; } /** - * @return the accessEstsize + * @param c3ResolMax the c3ResolMax to set */ - public int getAccessEstsize() { - return accessEstsize; + public void setC3ResolMax(Double c3ResolMax) { + this.c3ResolMax = c3ResolMax; } /** - * @param accessEstsize the accessEstsize to set + * @param c3ResolMin the c3ResolMin to set */ - public void setAccessEstsize(int accessEstsize) { - this.accessEstsize = accessEstsize; + public void setC3ResolMin(Double c3ResolMin) { + this.c3ResolMin = c3ResolMin; } /** - * @return the dataAccessUrl + * @param creationDate the creationDate to set */ - public String getDataAccessUrl() { - return dataAccessUrl; + public void setCreationDate(Date creationDate) { + this.creationDate = creationDate; } /** @@ -990,38 +1097,38 @@ public class Granule { } /** - * @return the accessMd5 + * @param dataproductType the dataproductType to set */ - public String getAccessMd5() { - return accessMd5; + public void setDataproductType(String dataproductType) { + this.dataproductType = dataproductType; } /** - * @param accessMd5 the accessMd5 to set + * @param dec the dec to set */ - public void setAccessMd5(String accessMd5) { - this.accessMd5 = accessMd5; + public void setDec(double dec) { + this.dec = dec; } /** - * @return the thumbnailUrl + * @param emergenceMax the emergenceMax to set */ - public String getThumbnailUrl() { - return thumbnailUrl; + public void setEmergenceMax(Double emergenceMax) { + this.emergenceMax = emergenceMax; } /** - * @param thumbnailUrl the thumbnailUrl to set + * @param emergenceMin the emergenceMin to set */ - public void setThumbnailUrl(String thumbnailUrl) { - this.thumbnailUrl = thumbnailUrl; + public void setEmergenceMin(Double emergenceMin) { + this.emergenceMin = emergenceMin; } /** - * @return the fileName + * @param featureName the featureName to set */ - public String getFileName() { - return fileName; + public void setFeatureName(String featureName) { + this.featureName = featureName; } /** @@ -1032,360 +1139,353 @@ public class Granule { } /** - * @return the species - */ - public String getSpecies() { - return species; - } - - /** - * @param species the species to set + * @param granuleGid the granuleGid to set */ - public void setSpecies(String species) { - this.species = species; + public void setGranuleGid(String granuleGid) { + this.granuleGid = granuleGid; } /** - * @return the altTargetName + * @param granuleUid the granuleUid to set */ - public String getAltTargetName() { - return altTargetName; + public void setGranuleUid(String granuleUid) { + this.granuleUid = granuleUid; } /** - * @param altTargetName the altTargetName to set + * @param incidenceMax the incidenceMax to set */ - public void setAltTargetName(String altTargetName) { - this.altTargetName = altTargetName; + public void setIncidenceMax(Double incidenceMax) { + this.incidenceMax = incidenceMax; } /** - * @return the targetRegion + * @param incidenceMin the incidenceMin to set */ - public String getTargetRegion() { - return targetRegion; + public void setIncidenceMin(Double incidenceMin) { + this.incidenceMin = incidenceMin; } /** - * @param targetRegion the targetRegion to set + * @param instrumentHostName the instrumentHostName to set */ - public void setTargetRegion(String targetRegion) { - this.targetRegion = targetRegion; + public void setInstrumentHostName(String instrumentHostName) { + this.instrumentHostName = instrumentHostName; } /** - * @return the featureName + * @param instrumentName the instrumentName to set */ - public String getFeatureName() { - return featureName; + public void setInstrumentName(String instrumentName) { + this.instrumentName = instrumentName; } /** - * @param featureName the featureName to set + * @param localTimeMax the localTimeMax to set */ - public void setFeatureName(String featureName) { - this.featureName = featureName; + public void setLocalTimeMax(double localTimeMax) { + this.localTimeMax = localTimeMax; } /** - * @return the bibReference + * @param localTimeMin the localTimeMin to set */ - public String getBibReference() { - return bibReference; + public void setLocalTimeMin(double localTimeMin) { + this.localTimeMin = localTimeMin; } /** - * @param bibReference the bibReference to set + * @param measurementType the measurementType to set */ - public void setBibReference(String bibReference) { - this.bibReference = bibReference; + public void setMeasurementType(String measurementType) { + this.measurementType = measurementType; } /** - * @return the ra + * @param modificationDate the modificationDate to set */ - public double getRa() { - return ra; + public void setModificationDate(Date modificationDate) { + this.modificationDate = modificationDate; } /** - * @param ra the ra to set - */ - public void setRa(double ra) { - this.ra = ra; + * @param obsId the obsId to set + */ + public void setObsId(String obsId) { + this.obsId = obsId; } /** - * @return the dec + * @param particleSpectralRangeMax the particleSpectralRangeMax to set */ - public double getDec() { - return dec; + public void setParticleSpectralRangeMax(double particleSpectralRangeMax) { + this.particleSpectralRangeMax = particleSpectralRangeMax; } /** - * @param dec the dec to set + * @param particleSpectralRangeMin the particleSpectralRangeMin to set */ - public void setDec(double dec) { - this.dec = dec; + public void setParticleSpectralRangeMin(double particleSpectralRangeMin) { + this.particleSpectralRangeMin = particleSpectralRangeMin; } /** - * @return the solarLongitudeMin + * @param particleSpectralResolutionMax the particleSpectralResolutionMax to set */ - public double getSolarLongitudeMin() { - return solarLongitudeMin; + public void setParticleSpectralResolutionMax(double particleSpectralResolutionMax) { + this.particleSpectralResolutionMax = particleSpectralResolutionMax; } /** - * @param solarLongitudeMin the solarLongitudeMin to set + * @param particleSpectralResolutionMin the particleSpectralResolutionMin to set */ - public void setSolarLongitudeMin(double solarLongitudeMin) { - this.solarLongitudeMin = solarLongitudeMin; + public void setParticleSpectralResolutionMin(double particleSpectralResolutionMin) { + this.particleSpectralResolutionMin = particleSpectralResolutionMin; } /** - * @return the solarLongitudeMax + * @param particleSpectralSamplingStepMax the particleSpectralSamplingStepMax to set */ - public double getSolarLongitudeMax() { - return solarLongitudeMax; + public void setParticleSpectralSamplingStepMax(double particleSpectralSamplingStepMax) { + this.particleSpectralSamplingStepMax = particleSpectralSamplingStepMax; } /** - * @param solarLongitudeMax the solarLongitudeMax to set + * @param particleSpectralSamplingStepMin the particleSpectralSamplingStepMin to set */ - public void setSolarLongitudeMax(double solarLongitudeMax) { - this.solarLongitudeMax = solarLongitudeMax; + public void setParticleSpectralSamplingStepMin(double particleSpectralSamplingStepMin) { + this.particleSpectralSamplingStepMin = particleSpectralSamplingStepMin; } /** - * @return the localTimeMin + * @param particleSpectralType the particleSpectralType to set */ - public double getLocalTimeMin() { - return localTimeMin; + public void setParticleSpectralType(String particleSpectralType) { + this.particleSpectralType = particleSpectralType; } /** - * @param localTimeMin the localTimeMin to set + * @param phaseMax the phaseMax to set */ - public void setLocalTimeMin(double localTimeMin) { - this.localTimeMin = localTimeMin; + public void setPhaseMax(Double phaseMax) { + this.phaseMax = phaseMax; } /** - * @return the localTimeMax + * @param phaseMin the phaseMin to set */ - public double getLocalTimeMax() { - return localTimeMax; + public void setPhaseMin(Double phaseMin) { + this.phaseMin = phaseMin; } /** - * @param localTimeMax the localTimeMax to set + * @param processingLevel the processingLevel to set */ - public void setLocalTimeMax(double localTimeMax) { - this.localTimeMax = localTimeMax; + public void setProcessingLevel(Integer processingLevel) { + this.processingLevel = processingLevel; } /** - * @return the targetDistanceMin + * @param publisher the publisher to set */ - public double getTargetDistanceMin() { - return targetDistanceMin; + public void setPublisher(String publisher) { + this.publisher = publisher; } /** - * @param targetDistanceMin the targetDistanceMin to set + * @param ra the ra to set */ - public void setTargetDistanceMin(double targetDistanceMin) { - this.targetDistanceMin = targetDistanceMin; + public void setRa(double ra) { + this.ra = ra; } /** - * @return the targetDistanceMax + * @param releaseDate the releaseDate to set */ - public double getTargetDistanceMax() { - return targetDistanceMax; + public void setReleaseDate(Date releaseDate) { + this.releaseDate = releaseDate; } /** - * @param targetDistanceMax the targetDistanceMax to set + * @param serviceTitle the serviceTitle to set */ - public void setTargetDistanceMax(double targetDistanceMax) { - this.targetDistanceMax = targetDistanceMax; + public void setServiceTitle(String serviceTitle) { + this.serviceTitle = serviceTitle; } /** - * @return the targetTimeMin + * @param solarLongitudeMax the solarLongitudeMax to set */ - public double getTargetTimeMin() { - return targetTimeMin; + public void setSolarLongitudeMax(double solarLongitudeMax) { + this.solarLongitudeMax = solarLongitudeMax; } /** - * @param targetTimeMin the targetTimeMin to set + * @param solarLongitudeMin the solarLongitudeMin to set */ - public void setTargetTimeMin(double targetTimeMin) { - this.targetTimeMin = targetTimeMin; + public void setSolarLongitudeMin(double solarLongitudeMin) { + this.solarLongitudeMin = solarLongitudeMin; } /** - * @return the targetTimeMax + * @param spatialCoordinateDescription the spatialCoordinateDescription to set */ - public double getTargetTimeMax() { - return targetTimeMax; + public void setSpatialCoordinateDescription(String spatialCoordinateDescription) { + this.spatialCoordinateDescription = spatialCoordinateDescription; } /** - * @param targetTimeMax the targetTimeMax to set + * @param spatialFrameType the spatialFrameType to set */ - public void setTargetTimeMax(double targetTimeMax) { - this.targetTimeMax = targetTimeMax; + public void setSpatialFrameType(String spatialFrameType) { + this.spatialFrameType = spatialFrameType; } /** - * @return the particleSpectralType + * @param spatialOrigin the spatialOrigin to set */ - public String getParticleSpectralType() { - return particleSpectralType; + public void setSpatialOrigin(String spatialOrigin) { + this.spatialOrigin = spatialOrigin; } /** - * @param particleSpectralType the particleSpectralType to set + * @param species the species to set */ - public void setParticleSpectralType(String particleSpectralType) { - this.particleSpectralType = particleSpectralType; + public void setSpecies(String species) { + this.species = species; } /** - * @return the particleSpectralRangeMin + * @param spectralRangeMax the spectralRangeMax to set */ - public double getParticleSpectralRangeMin() { - return particleSpectralRangeMin; + public void setSpectralRangeMax(Double spectralRangeMax) { + this.spectralRangeMax = spectralRangeMax; } /** - * @param particleSpectralRangeMin the particleSpectralRangeMin to set + * @param spectralRangeMin the spectralRangeMin to set */ - public void setParticleSpectralRangeMin(double particleSpectralRangeMin) { - this.particleSpectralRangeMin = particleSpectralRangeMin; + public void setSpectralRangeMin(Double spectralRangeMin) { + this.spectralRangeMin = spectralRangeMin; } /** - * @return the particleSpectralRangeMax + * @param spectralResolutionMax the spectralResolutionMax to set */ - public double getParticleSpectralRangeMax() { - return particleSpectralRangeMax; + public void setSpectralResolutionMax(Double spectralResolutionMax) { + this.spectralResolutionMax = spectralResolutionMax; } /** - * @param particleSpectralRangeMax the particleSpectralRangeMax to set + * @param spectralResolutionMin the spectralResolutionMin to set */ - public void setParticleSpectralRangeMax(double particleSpectralRangeMax) { - this.particleSpectralRangeMax = particleSpectralRangeMax; + public void setSpectralResolutionMin(Double spectralResolutionMin) { + this.spectralResolutionMin = spectralResolutionMin; } /** - * @return the particleSpectralSamplingStepMin + * @param spectralSamplingStepMax the spectralSamplingStepMax to set */ - public double getParticleSpectralSamplingStepMin() { - return particleSpectralSamplingStepMin; + public void setSpectralSamplingStepMax(Double spectralSamplingStepMax) { + this.spectralSamplingStepMax = spectralSamplingStepMax; } /** - * @param particleSpectralSamplingStepMin the particleSpectralSamplingStepMin to set + * @param spectralSamplingStepMin the spectralSamplingStepMin to set */ - public void setParticleSpectralSamplingStepMin(double particleSpectralSamplingStepMin) { - this.particleSpectralSamplingStepMin = particleSpectralSamplingStepMin; + public void setSpectralSamplingStepMin(Double spectralSamplingStepMin) { + this.spectralSamplingStepMin = spectralSamplingStepMin; } /** - * @return the particleSpectralSamplingStepMax + * @param sRegion the sRegion to set */ - public double getParticleSpectralSamplingStepMax() { - return particleSpectralSamplingStepMax; + public void setSRegion(String sRegion) { + this.sRegion = sRegion; } /** - * @param particleSpectralSamplingStepMax the particleSpectralSamplingStepMax to set + * @param targetClass the targetClass to set */ - public void setParticleSpectralSamplingStepMax(double particleSpectralSamplingStepMax) { - this.particleSpectralSamplingStepMax = particleSpectralSamplingStepMax; + public void setTargetClass(String targetClass) { + this.targetClass = targetClass; } /** - * @return the particleSpectralResolutionMin + * @param targetDistanceMax the targetDistanceMax to set */ - public double getParticleSpectralResolutionMin() { - return particleSpectralResolutionMin; + public void setTargetDistanceMax(double targetDistanceMax) { + this.targetDistanceMax = targetDistanceMax; } /** - * @param particleSpectralResolutionMin the particleSpectralResolutionMin to set + * @param targetDistanceMin the targetDistanceMin to set */ - public void setParticleSpectralResolutionMin(double particleSpectralResolutionMin) { - this.particleSpectralResolutionMin = particleSpectralResolutionMin; + public void setTargetDistanceMin(double targetDistanceMin) { + this.targetDistanceMin = targetDistanceMin; } /** - * @return the particleSpectralResolutionMax + * @param targetName the targetName to set */ - public double getParticleSpectralResolutionMax() { - return particleSpectralResolutionMax; + public void setTargetName(String targetName) { + this.targetName = targetName; } /** - * @param particleSpectralResolutionMax the particleSpectralResolutionMax to set + * @param targetRegion the targetRegion to set */ - public void setParticleSpectralResolutionMax(double particleSpectralResolutionMax) { - this.particleSpectralResolutionMax = particleSpectralResolutionMax; + public void setTargetRegion(String targetRegion) { + this.targetRegion = targetRegion; } /** - * @return the publisher + * @param targetTimeMax the targetTimeMax to set */ - public String getPublisher() { - return publisher; + public void setTargetTimeMax(double targetTimeMax) { + this.targetTimeMax = targetTimeMax; } /** - * @param publisher the publisher to set + * @param targetTimeMin the targetTimeMin to set */ - public void setPublisher(String publisher) { - this.publisher = publisher; + public void setTargetTimeMin(double targetTimeMin) { + this.targetTimeMin = targetTimeMin; } /** - * @return the spatialCoordinateDescription + * @param thumbnailUrl the thumbnailUrl to set */ - public String getSpatialCoordinateDescription() { - return spatialCoordinateDescription; + public void setThumbnailUrl(String thumbnailUrl) { + this.thumbnailUrl = thumbnailUrl; } /** - * @param spatialCoordinateDescription the spatialCoordinateDescription to set + * @param timeExpMax the timeExpMax to set */ - public void setSpatialCoordinateDescription(String spatialCoordinateDescription) { - this.spatialCoordinateDescription = spatialCoordinateDescription; + public void setTimeExpMax(Double timeExpMax) { + this.timeExpMax = timeExpMax; } /** - * @return the spatialOrigin + * @param timeExpMin the timeExpMin to set */ - public String getSpatialOrigin() { - return spatialOrigin; + public void setTimeExpMin(Double timeExpMin) { + this.timeExpMin = timeExpMin; } /** - * @param spatialOrigin the spatialOrigin to set + * @param timeMax the timeMax to set */ - public void setSpatialOrigin(String spatialOrigin) { - this.spatialOrigin = spatialOrigin; + public void setTimeMax(Double timeMax) { + this.timeMax = timeMax; } /** - * @return the timeOrigin + * @param timeMin the timeMin to set */ - public String getTimeOrigin() { - return timeOrigin; + public void setTimeMin(Double timeMin) { + this.timeMin = timeMin; } /** @@ -1396,55 +1496,28 @@ public class Granule { } /** - * @return the timeScale + * @param timeSamplingStepMax the timeSamplingStepMax to set */ - public String getTimeScale() { - return timeScale; + public void setTimeSamplingStepMax(Double timeSamplingStepMax) { + this.timeSamplingStepMax = timeSamplingStepMax; } /** - * @param timeScale the timeScale to set + * @param timeSamplingStepMin the timeSamplingStepMin to set */ - public void setTimeScale(String timeScale) { - this.timeScale = timeScale; + public void setTimeSamplingStepMin(Double timeSamplingStepMin) { + this.timeSamplingStepMin = timeSamplingStepMin; } /** - * A granule is valid if all mandatory parameters are filled. - * - * @return true if the Granule is valid, false otherwise. + * @param timeScale the timeScale to set */ - public boolean isValid() { - boolean valid = granuleUid != null && granuleGid != null && obsId != null; - valid = valid && dataproductType != null && targetName != null && targetClass != null; - valid = valid && timeMin != null && timeMax != null; - valid = valid && timeSamplingStepMin != null && timeSamplingStepMax != null; - valid = valid && timeExpMin != null && timeExpMax != null; - valid = valid && spectralRangeMin != null && spectralRangeMax != null; - valid = valid && timeSamplingStepMin != null && timeSamplingStepMax != null; - valid = valid && spectralResolutionMin != null && spectralResolutionMax != null; - valid = valid && c1Min != null && c1Max != null; - valid = valid && c2Min != null && c2Max != null; - valid = valid && c3Min != null && c3Max != null; - valid = valid && sRegion != null; - valid = valid && c1ResolMin != null && c1ResolMax != null; - valid = valid && c2ResolMin != null && c2ResolMax != null; - valid = valid && c3ResolMin != null && c3ResolMax != null; - valid = valid && spatialFrameType != null; - valid = valid && incidenceMin != null && incidenceMax != null; - valid = valid && emergenceMin != null && emergenceMax != null; - valid = valid && phaseMin != null && phaseMax != null; - valid = valid && instrumentHostName != null && instrumentName != null; - valid = valid && measurementType != null && processingLevel != null; - valid = valid && creationDate != null && modificationDate != null; - valid = valid && releaseDate != null && serviceTitle != null; - - return valid; + public void setTimeScale(String timeScale) { + this.timeScale = timeScale; } @Override public String toString() { return granuleUid; } - } -- libgit2 0.21.2