import { SodaProvider } from '../../common/providers/soda-provider.interface'; import * as i0 from "@angular/core"; export interface SodaFilter { id: string; value: unknown; valueParsed?: unknown; isDisabled?: boolean; } export declare class SodaCutoutService { private readonly sodaUrl; constructor(sodaProvider: SodaProvider); /** * Builds a SODA sync URL for the selected file. * * ID is always required. * POS is added only if a valid position-related filter is found. * BAND is added only if a valid spectral filter is found. * * If no usable POS/BAND filters exist, the service returns a URL with only ID, * which means the full file is requested. */ buildCutoutUrl(fitsFileId: string, freqResolutionKHz: number | undefined, filters: SodaFilter[]): string | null; /** * Builds the SODA POS parameter from the current active filters (source name resolver, RD/Dec, galactic, ecliptic) * If multiple position constraints are present, we keep only the smallest one. */ private buildPosParam; /** * RA/Dec parsing rules: * - single RA + single Dec => CIRCLE * - interval input (.., >, <) => RANGE */ private parseRaDecFilter; /** * Galactic parsing rules are the same as RA/Dec: * - single lon/lat => convert to RA/Dec and use CIRCLE * - interval lon/lat => convert box corners to RA/Dec and use RANGE */ private parseGalacticFilter; /** * Ecliptic behaves the same as galactic, only with a different coordinate transform. */ private parseEclipticFilter; /** * Converts a lon/lat rectangle to an RA/Dec bounding box by converting the 4 corners. */ private cornersToRangePos; /** * Used only to compare multiple position constraints and keep the smallest one. */ private posSize; /** * Formats the final SODA POS value. */ private formatPos; /** * Builds the SODA BAND parameter from spectral filters (frequency, band). * SODA BAND must be wavelength in meters, not frequency in GHz. * If multiple spectral constraints are present, we keep only the smallest one. */ private buildBandParam; /** * AQ frequency filter may contain multiple values separated by "|". * Each valid value is converted into a wavelength range. */ private freqStringToWavelengthRanges; /** * Converts one frequency expression to a SODA wavelength range. */ private parseSingleFreqToWavelength; /** * Converts a frequency interval in GHz to a wavelength interval in meters. */ private freqRangeToWavelength; /** * For a single frequency value, use a small interval around it based on resolution. * Resolution comes from the preview and is given in kHz. */ private freqSingleToWavelength; /** * Used to compare multiple wavelength ranges and keep the narrowest one. */ private waveRangeWidth; private formatWaveBound; /** * Parses RA either as decimal degrees or as sexagesimal hours. */ private parseRaValue; /** * Parses Dec either as decimal degrees or as sexagesimal degrees. */ private parseDecValue; private parseInterval; private parseSingleNumberStrict; /** * Extracts optional ", radius" suffix from coordinate input. * If no explicit radius is present, default to 10 arcmin. */ private extractCoordAndRadius; private extractTrailingRadiusArcmin; private formatNumber; /** * RA wraps around at 360 degrees, so normalize it before building ranges. */ private normalizeRa; private isValidRa; private isValidDec; private isValidLon; private isValidLat; private hasValue; private toSafeString; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; }