public override void Update(TLFileLocationBase fileLocation)
        {
            if (fileLocation is TLFileLocation location)
            {
                DCId = location.DCId;
            }

            base.Update(fileLocation);
        }
Example #2
0
        public override void Update(TLFileLocationBase baseFileLocation)
        {
            base.Update(baseFileLocation);

            var fileLocation = baseFileLocation as TLFileLocation;

            if (fileLocation != null)
            {
                DCId = fileLocation.DCId;
            }
        }
Example #3
0
        //public string SendingFileName { get; set; }
        //public byte[] Buffer { get; set; }
        //public byte[] Bytes { get; set; }
        #endregion

        public virtual void Update(TLFileLocationBase fileLocation)
        {
            if (fileLocation != null)
            {
                //if (Buffer == null || LocalId.Value != fileLocation.LocalId.Value)
                //{
                //    Buffer = fileLocation.Buffer;
                //}

                VolumeId = fileLocation.VolumeId;
                LocalId  = fileLocation.LocalId;
                Secret   = fileLocation.Secret;
            }
        }
Example #4
0
        public override void Update(TLPhotoBase photo)
        {
            var photoCommon = photo as TLPhotoCommon;

            if (photoCommon != null)
            {
                if (PhotoSmall != null)
                {
                    PhotoSmall.Update(photoCommon.PhotoSmall);
                }
                else
                {
                    PhotoSmall = photoCommon.PhotoSmall;
                }
                if (PhotoBig != null)
                {
                    PhotoBig.Update(photoCommon.PhotoBig);
                }
                else
                {
                    PhotoBig = photoCommon.PhotoBig;
                }
            }
        }