using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace EVCB_OCPP.Packet20.DataTypes
{
    public class SignedMeterValueType
    {
        /// <summary>
        /// Base64 encoded, contains the signed data
        ///which might contain more then just the meter value.It
        ///  can contain information like timestamps, reference to a
        ///customer etc.
        /// </summary>
        [Required]
        [StringLength(2500, MinimumLength = 0)]
        public string SignedMeterData { set; get; }

        /// <summary>
        /// Method used to create the digital signature.
        /// </summary>
        [Required]
        [StringLength(50, MinimumLength = 0)]
        public string SigningMethod { set; get; }

        /// <summary>
        /// Method used to encode the meter values
        /// before applying the digital signature algorithm.
        /// </summary>
        [Required]
        [StringLength(50, MinimumLength = 0)]
        public string EncodingMethod { set; get; }



        /// <summary>
        /// Base64 encoded, sending depends on
        ///configuration variable PublicKeyWithSignedMeterValue.
        /// </summary>
        [Required]
        [StringLength(2500, MinimumLength = 0)]
        public string PublicKey { set; get; }

    }
}
