| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208 |
- using DevExpress.Xpo;
- using Ips.Library.Basic;
- using Ips.Library.Entity;
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace Ips.Sps.Sigs
- {
- [NonPersistent]
- public class SignalBasic : XPObject
- {
- public SignalBasic() : base()
- {
- }
- public SignalBasic(Session session) : base(session)
- {
- }
- public override void AfterConstruction()
- {
- base.AfterConstruction();
- SigCategory = SignalCategory.TarSig;
- SigType = SignalType.NORMAL;
- }
- private SignalCategory _sigCategory;
- [DisplayName("信号类别")]
- public SignalCategory SigCategory
- {
- get => _sigCategory;
- set => SetPropertyValue(nameof(SigCategory), ref _sigCategory, value);
- }
- private SignalType _sigType;
- [DisplayName("信号类型")]
- public SignalType SigType
- {
- get => _sigType;
- set => SetPropertyValue(nameof(SigType), ref _sigType, value);
- }
- private double _sigFreq;
- [DisplayName("信号频点(MHz)")]
- public double SigFreq
- {
- get => _sigFreq;
- set => SetPropertyValue(nameof(SigFreq), ref _sigFreq, value);
- }
- private double _freqStart;
- [DisplayName("起始频点(MHz)")]
- public double FreqStart
- {
- get => _freqStart;
- set => SetPropertyValue(nameof(FreqStart), ref _freqStart, value);
- }
- private double _freqEnd;
- [DisplayName("结束频点(MHz)")]
- public double FreqEnd
- {
- get => _freqEnd;
- set => SetPropertyValue(nameof(FreqEnd), ref _freqEnd, value);
- }
- private double _freqStep;
- [DisplayName("频点步进(kHz)")]
- public double FreqStep
- {
- get => _freqStep;
- set => SetPropertyValue(nameof(FreqStep), ref _freqStep, value);
- }
- private double _bandWidth;
- [DisplayName("信号带宽(kHz)")]
- public double BandWidth
- {
- get => _bandWidth;
- set => SetPropertyValue(nameof(BandWidth), ref _bandWidth, value);
- }
- private int _sigLen;
- [DisplayName("信号时长(s)")]
- public int SigLen
- {
- get => _sigLen;
- set => SetPropertyValue(nameof(SigLen), ref _sigLen, value);
- }
- private int? _emtId;
- [DisplayName("信号目标")]
- public int? EmtId
- {
- get => _emtId;
- set => SetPropertyValue(nameof(EmtId), ref _emtId, value);
- }
- private int? _mainSatId;
- [DisplayName("通联主星")]
- public int? MainSatId
- {
- get => _mainSatId;
- set => SetPropertyValue(nameof(MainSatId), ref _mainSatId, value);
- }
- private string _adjaSatIds;
- [DisplayName("通联邻星")]
- public string AdjaSatIds
- {
- get => _adjaSatIds;
- set => SetPropertyValue(nameof(AdjaSatIds), ref _adjaSatIds, value);
- }
- private bool _hasRange;
- [DisplayName("包含范围")]
- [MemberDesignTimeVisibility(false)]
- public bool HasRange
- {
- get => _hasRange;
- set => SetPropertyValue(nameof(HasRange), ref _hasRange, value);
- }
- private double _sigLon;
- [DisplayName("信号经度")]
- [MemberDesignTimeVisibility(false)]
- public double SigLon
- {
- get => HasRange ? _sigLon : 0;
- set => SetPropertyValue(nameof(SigLon), ref _sigLon, value);
- }
- private double _sigLat;
- [DisplayName("信号纬度")]
- [MemberDesignTimeVisibility(false)]
- public double SigLat
- {
- get => HasRange ? _sigLat : 0;
- set => SetPropertyValue(nameof(SigLat), ref _sigLat, value);
- }
- private double _lonRange;
- [DisplayName("经度范围")]
- [MemberDesignTimeVisibility(false)]
- public double LonRange
- {
- get => HasRange ? _lonRange : 360;
- set => SetPropertyValue(nameof(LonRange), ref _lonRange, value);
- }
- private double _latRange;
- [DisplayName("纬度范围")]
- [MemberDesignTimeVisibility(false)]
- public double LatRange
- {
- get => HasRange ? _latRange : 180;
- set => SetPropertyValue(nameof(LatRange), ref _latRange, value);
- }
- private double _sigAlt;
- [DisplayName("信号高度")]
- [MemberDesignTimeVisibility(false)]
- public double SigAlt
- {
- get => _sigAlt;
- set => SetPropertyValue(nameof(SigAlt), ref _sigAlt, value);
- }
- [DisplayName("信号频点(MHz)"), NonPersistent]
- public string SigFreqText
- {
- get
- {
- string result;
- if (SigCategory == SignalCategory.SctSig)
- {
- result = $"{FreqStart}-{FreqEnd}[{FreqStep}kHz]";
- }
- else
- {
- result = SigFreq.ToString();
- }
- return result;
- }
- }
- [DisplayName("信号范围"), NonPersistent]
- public string SigRangText
- {
- get
- {
- string result;
- if (!HasRange)
- {
- result = $"({0},{0},{SigAlt})-[{360},{180}]";
- }
- else
- {
- result = $"({SigLon:F3},{SigLat:F3},{SigAlt:F1})-[{LonRange:F1},{LatRange:F1}]";
- }
- return result;
- }
- }
- }
- }
|