예제 #1
0
        public PduUdSegment(IPduProfileSettings settings, PduDcsSegment dcs)
        {
            if (settings == null)
            {
                throw new ArgumentNullException("Profile settings not specified.");
            }

            if (dcs == null || dcs.GetCodingScheme() == DCS.Other)
            {
                throw new NotSupportedException("Data coding scheme not supported.");
            }

            _dcs    = dcs;
            _source = settings?.UserData?.Value ?? string.Empty;

            encode(_source, dcs.GetCoder());
        }
예제 #2
0
 public void SetUserData(string value)
 {
     _source = value ?? string.Empty;
     encode(_source, _dcs.GetCoder());
 }