Beispiel #1
0
        /// <summary>
        /// Create a GetServiceAuthorisation XML/SOAP request.
        /// </summary>
        /// <param name="PartnerId">The partner identification.</param>
        /// <param name="OperatorId">The operator identification.</param>
        /// <param name="EVSEId">The EVSE identification.</param>
        /// <param name="UserId">The user identification.</param>
        /// <param name="RequestedServiceId">The service identification for which an authorisation is requested.</param>
        /// <param name="TransactionId">An optional transaction identification.</param>
        /// <param name="PartnerServiceSessionId">An optional partner session identification.</param>
        ///
        /// <param name="HTTPRequest">The correlated HTTP request of this eMIP request.</param>
        /// <param name="Timestamp">The optional timestamp of the request.</param>
        /// <param name="CancellationToken">An optional token to cancel this request.</param>
        /// <param name="EventTrackingId">An optional event tracking identification for correlating this request with other events.</param>
        /// <param name="RequestTimeout">An optional timeout for this request.</param>
        public GetServiceAuthorisationRequest(Partner_Id PartnerId,
                                              Operator_Id OperatorId,
                                              EVSE_Id EVSEId,
                                              User_Id UserId,
                                              Service_Id RequestedServiceId,
                                              Transaction_Id?TransactionId = null,
                                              PartnerServiceSession_Id?PartnerServiceSessionId = null,

                                              HTTPRequest HTTPRequest             = null,
                                              DateTime?Timestamp                  = null,
                                              CancellationToken?CancellationToken = null,
                                              EventTracking_Id EventTrackingId    = null,
                                              TimeSpan?RequestTimeout             = null)

            : base(HTTPRequest,
                   PartnerId,
                   TransactionId,
                   Timestamp,
                   CancellationToken,
                   EventTrackingId,
                   RequestTimeout)

        {
            this.OperatorId              = OperatorId;
            this.EVSEId                  = EVSEId;
            this.UserId                  = UserId;
            this.RequestedServiceId      = RequestedServiceId;
            this.PartnerServiceSessionId = PartnerServiceSessionId;
        }
Beispiel #2
0
        /// <summary>
        /// Create a new MeterValues request.
        /// </summary>
        /// <param name="ChargeBoxId">The charge box identification.</param>
        /// <param name="ConnectorId">The connector identification at the charge point.</param>
        /// <param name="MeterValues">The sampled meter values with timestamps.</param>
        /// <param name="TransactionId">The charging transaction to which the given meter value samples are related to.</param>
        ///
        /// <param name="RequestId">An optional request identification.</param>
        /// <param name="RequestTimestamp">An optional request timestamp.</param>
        public MeterValuesRequest(ChargeBox_Id ChargeBoxId,
                                  Connector_Id ConnectorId,
                                  IEnumerable <MeterValue> MeterValues,
                                  Transaction_Id?TransactionId = null,

                                  Request_Id?RequestId             = null,
                                  DateTime?RequestTimestamp        = null,
                                  EventTracking_Id EventTrackingId = null)

            : base(ChargeBoxId,
                   "MeterValues",
                   RequestId,
                   EventTrackingId,
                   RequestTimestamp)

        {
            if (!MeterValues.SafeAny())
            {
                throw new ArgumentNullException(nameof(MeterValues), "The given MeterValues must not be null or empty!");
            }

            this.ConnectorId   = ConnectorId;
            this.TransactionId = TransactionId;
            this.MeterValues   = MeterValues;
        }
        /// <summary>
        /// Create a SetChargingStationAvailabilityStatus XML/SOAP request.
        /// </summary>
        /// <param name="PartnerId">The partner identification.</param>
        /// <param name="OperatorId">The operator identification.</param>
        /// <param name="ChargingStationId">The charging station identification.</param>
        /// <param name="StatusEventDate">The timestamp of the status change.</param>
        /// <param name="AvailabilityStatus">The charging station availability status.</param>
        /// <param name="TransactionId">An optional transaction identification.</param>
        /// <param name="AvailabilityStatusUntil">An optional timestamp until which the given availability status is valid.</param>
        /// <param name="AvailabilityStatusComment">An optional comment about the availability status.</param>
        ///
        /// <param name="HTTPRequest">The correlated HTTP request of this eMIP request.</param>
        /// <param name="Timestamp">The optional timestamp of the request.</param>
        /// <param name="CancellationToken">An optional token to cancel this request.</param>
        /// <param name="EventTrackingId">An optional event tracking identification for correlating this request with other events.</param>
        /// <param name="RequestTimeout">An optional timeout for this request.</param>
        public SetChargingStationAvailabilityStatusRequest(Partner_Id PartnerId,
                                                           Operator_Id OperatorId,
                                                           ChargingStation_Id ChargingStationId,
                                                           DateTime StatusEventDate,
                                                           ChargingStationAvailabilityStatusTypes AvailabilityStatus,
                                                           Transaction_Id?TransactionId     = null,
                                                           DateTime?AvailabilityStatusUntil = null,
                                                           String AvailabilityStatusComment = null,

                                                           HTTPRequest HTTPRequest             = null,
                                                           DateTime?Timestamp                  = null,
                                                           CancellationToken?CancellationToken = null,
                                                           EventTracking_Id EventTrackingId    = null,
                                                           TimeSpan?RequestTimeout             = null)

            : base(HTTPRequest,
                   PartnerId,
                   TransactionId,
                   Timestamp,
                   CancellationToken,
                   EventTrackingId,
                   RequestTimeout)

        {
            this.OperatorId                = OperatorId;
            this.ChargingStationId         = ChargingStationId;
            this.StatusEventDate           = StatusEventDate;
            this.AvailabilityStatus        = AvailabilityStatus;
            this.AvailabilityStatusUntil   = AvailabilityStatusUntil;
            this.AvailabilityStatusComment = AvailabilityStatusComment?.Trim();
        }
Beispiel #4
0
        GetServiceAuthorisation(this ICPOClient CPOClient,
                                Partner_Id PartnerId,
                                Operator_Id OperatorId,
                                EVSE_Id EVSEId,
                                User_Id UserId,
                                Service_Id RequestedServiceId,
                                Transaction_Id?TransactionId = null,
                                PartnerServiceSession_Id?PartnerServiceSessionId = null,

                                HTTPRequest HTTPRequest             = null,
                                DateTime?Timestamp                  = null,
                                CancellationToken?CancellationToken = null,
                                EventTracking_Id EventTrackingId    = null,
                                TimeSpan?RequestTimeout             = null)


        => CPOClient.GetServiceAuthorisation(new GetServiceAuthorisationRequest(PartnerId,
                                                                                OperatorId,
                                                                                EVSEId,
                                                                                UserId,
                                                                                RequestedServiceId,
                                                                                TransactionId,
                                                                                PartnerServiceSessionId,

                                                                                HTTPRequest,
                                                                                Timestamp,
                                                                                CancellationToken,
                                                                                EventTrackingId,
                                                                                RequestTimeout ?? CPOClient.RequestTimeout));
        /// <summary>
        /// Create a SetEVSEBusyStatus XML/SOAP request.
        /// </summary>
        /// <param name="PartnerId">The partner identification.</param>
        /// <param name="OperatorId">The operator identification.</param>
        /// <param name="EVSEId">The EVSE identification.</param>
        /// <param name="StatusEventDate">The timestamp of the status change.</param>
        /// <param name="BusyStatus">The EVSE busy status.</param>
        /// <param name="TransactionId">An optional transaction identification.</param>
        /// <param name="BusyStatusUntil">An optional timestamp until which the given busy status is valid.</param>
        /// <param name="BusyStatusComment">An optional comment about the busy status.</param>
        ///
        /// <param name="HTTPRequest">The correlated HTTP request of this eMIP request.</param>
        /// <param name="Timestamp">The optional timestamp of the request.</param>
        /// <param name="CancellationToken">An optional token to cancel this request.</param>
        /// <param name="EventTrackingId">An optional event tracking identification for correlating this request with other events.</param>
        /// <param name="RequestTimeout">An optional timeout for this request.</param>
        public SetEVSEBusyStatusRequest(Partner_Id PartnerId,
                                        Operator_Id OperatorId,
                                        EVSE_Id EVSEId,
                                        DateTime StatusEventDate,
                                        EVSEBusyStatusTypes BusyStatus,
                                        Transaction_Id?TransactionId = null,
                                        DateTime?BusyStatusUntil     = null,
                                        String BusyStatusComment     = null,

                                        HTTPRequest HTTPRequest             = null,
                                        DateTime?Timestamp                  = null,
                                        CancellationToken?CancellationToken = null,
                                        EventTracking_Id EventTrackingId    = null,
                                        TimeSpan?RequestTimeout             = null)

            : base(HTTPRequest,
                   PartnerId,
                   TransactionId,
                   Timestamp,
                   CancellationToken,
                   EventTrackingId,
                   RequestTimeout)

        {
            this.OperatorId        = OperatorId;
            this.EVSEId            = EVSEId;
            this.StatusEventDate   = StatusEventDate;
            this.BusyStatus        = BusyStatus;
            this.BusyStatusUntil   = BusyStatusUntil;
            this.BusyStatusComment = BusyStatusComment?.Trim();
        }
        /// <summary>
        /// Create a SetSessionEventReportRequest XML/SOAP request.
        /// </summary>
        /// <param name="PartnerId">The partner identification.</param>
        /// <param name="OperatorId">The operator identification.</param>
        /// <param name="ServiceSessionId">The service session identification.</param>
        /// <param name="SessionEvent">The session event.</param>
        ///
        /// <param name="TransactionId">An optional transaction identification.</param>
        /// <param name="ExecPartnerSessionId">An optional partner service session identification.</param>
        ///
        /// <param name="HTTPRequest">The correlated HTTP request of this eMIP request.</param>
        /// <param name="Timestamp">The optional timestamp of the request.</param>
        /// <param name="CancellationToken">An optional token to cancel this request.</param>
        /// <param name="EventTrackingId">An optional event tracking identification for correlating this request with other events.</param>
        /// <param name="RequestTimeout">An optional timeout for this request.</param>
        public SetSessionEventReportRequest(Partner_Id PartnerId,
                                            Operator_Id OperatorId,
                                            ServiceSession_Id ServiceSessionId,
                                            SessionEvent SessionEvent,

                                            Transaction_Id?TransactionId = null,
                                            PartnerServiceSession_Id?ExecPartnerSessionId = null,

                                            HTTPRequest HTTPRequest             = null,
                                            DateTime?Timestamp                  = null,
                                            CancellationToken?CancellationToken = null,
                                            EventTracking_Id EventTrackingId    = null,
                                            TimeSpan?RequestTimeout             = null)

            : base(HTTPRequest,
                   PartnerId,
                   TransactionId,
                   Timestamp,
                   CancellationToken,
                   EventTrackingId,
                   RequestTimeout)

        {
            this.OperatorId           = OperatorId;
            this.ServiceSessionId     = ServiceSessionId;
            this.SessionEvent         = SessionEvent;
            this.ExecPartnerSessionId = ExecPartnerSessionId;
        }
Beispiel #7
0
        SetSessionAction(this IEMPClient EMPClient,
                         Partner_Id PartnerId,
                         Operator_Id OperatorId,
                         ServiceSession_Id ServiceSessionId,
                         SessionAction SessionAction,

                         Transaction_Id?TransactionId = null,
                         PartnerServiceSession_Id?SalePartnerSessionId = null,

                         HTTPRequest HTTPRequest             = null,
                         DateTime?Timestamp                  = null,
                         CancellationToken?CancellationToken = null,
                         EventTracking_Id EventTrackingId    = null,
                         TimeSpan?RequestTimeout             = null)


        => EMPClient.SetSessionAction(new SetSessionActionRequest(PartnerId,
                                                                  OperatorId,
                                                                  ServiceSessionId,
                                                                  SessionAction,

                                                                  TransactionId,
                                                                  SalePartnerSessionId,

                                                                  HTTPRequest,
                                                                  Timestamp,
                                                                  CancellationToken,
                                                                  EventTrackingId,
                                                                  RequestTimeout ?? EMPClient.RequestTimeout));
Beispiel #8
0
        /// <summary>
        /// Create an new OCPP charging profile.
        /// </summary>
        /// <param name="ChargingProfileId">The unique identification of this profile.</param>
        /// <param name="StackLevel">Value determining level in hierarchy stack of profiles. Higher values have precedence over lower values. Lowest level is 0.</param>
        /// <param name="ChargingProfilePurpose">Defines the purpose of the schedule transferred by this message.</param>
        /// <param name="ChargingProfileKind">Indicates the kind of schedule.</param>
        /// <param name="ChargingSchedule">Contains limits for the available power or current over time.</param>
        ///
        /// <param name="TransactionId">When the ChargingProfilePurpose is set to TxProfile, this value MAY be used to match the profile to a specific charging transaction.</param>
        /// <param name="RecurrencyKind">An optional indication of the start point of a recurrence.</param>
        /// <param name="ValidFrom">An optional timestamp at which the profile starts to be valid. If absent, the profile is valid as soon as it is received by the charge point. Not allowed to be used when ChargingProfilePurpose is TxProfile.</param>
        /// <param name="ValidTo">An optional timestamp at which the profile stops to be valid. If absent, the profile is valid until it is replaced by another profile. Not allowed to be used when ChargingProfilePurpose is TxProfile.</param>
        public ChargingProfile(ChargingProfile_Id ChargingProfileId,
                               UInt32 StackLevel,
                               ChargingProfilePurposes ChargingProfilePurpose,
                               ChargingProfileKinds ChargingProfileKind,
                               ChargingSchedule ChargingSchedule,

                               Transaction_Id?TransactionId   = null,
                               RecurrencyKinds?RecurrencyKind = null,
                               DateTime?ValidFrom             = null,
                               DateTime?ValidTo = null)

        {
            #region Initial checks

            if (ChargingSchedule == null)
            {
                throw new ArgumentNullException(nameof(ChargingSchedule), "The given charging schedule must not be null!");
            }

            #endregion

            this.ChargingProfileId      = ChargingProfileId;
            this.StackLevel             = StackLevel;
            this.ChargingProfilePurpose = ChargingProfilePurpose;
            this.ChargingProfileKind    = ChargingProfileKind;
            this.ChargingSchedule       = ChargingSchedule;

            this.TransactionId  = TransactionId ?? new Transaction_Id?();
            this.RecurrencyKind = RecurrencyKind ?? new RecurrencyKinds?();
            this.ValidFrom      = ValidFrom ?? new DateTime?();
            this.ValidTo        = ValidTo ?? new DateTime?();
        }
Beispiel #9
0
        SetEVSEBusyStatus(this ICPOClient CPOClient,
                          Partner_Id PartnerId,
                          Operator_Id OperatorId,
                          EVSE_Id EVSEId,
                          DateTime StatusEventDate,
                          EVSEBusyStatusTypes BusyStatus,
                          Transaction_Id?TransactionId = null,
                          DateTime?BusyStatusUntil     = null,
                          String BusyStatusComment     = null,

                          HTTPRequest HTTPRequest             = null,
                          DateTime?Timestamp                  = null,
                          CancellationToken?CancellationToken = null,
                          EventTracking_Id EventTrackingId    = null,
                          TimeSpan?RequestTimeout             = null)


        => CPOClient.SetEVSEBusyStatus(new SetEVSEBusyStatusRequest(PartnerId,
                                                                    OperatorId,
                                                                    EVSEId,
                                                                    StatusEventDate,
                                                                    BusyStatus,
                                                                    TransactionId,
                                                                    BusyStatusUntil,
                                                                    BusyStatusComment,

                                                                    HTTPRequest,
                                                                    Timestamp,
                                                                    CancellationToken,
                                                                    EventTrackingId,
                                                                    RequestTimeout ?? CPOClient.RequestTimeout));
 /// <summary>
 /// Create an OCPP MeterValues XML/SOAP request.
 /// </summary>
 /// <param name="ConnectorId">The connector identification at the charge point.</param>
 /// <param name="TransactionId">The charging transaction to which the given meter value samples are related to.</param>
 /// <param name="MeterValues">The sampled meter values with timestamps.</param>
 public MeterValuesRequest(Connector_Id ConnectorId,
                           Transaction_Id?TransactionId         = null,
                           IEnumerable <MeterValue> MeterValues = null)
 {
     this.ConnectorId   = ConnectorId;
     this.TransactionId = TransactionId;
     this.MeterValues   = MeterValues;
 }
        /// <summary>
        /// Create a SetServiceAuthorisationRequest XML/SOAP request.
        /// </summary>
        /// <param name="PartnerId">The partner identification.</param>
        /// <param name="OperatorId">The operator identification.</param>
        /// <param name="TargetOperatorId">The target operator identification.</param>
        /// <param name="EVSEId">The EVSE identification.</param>
        /// <param name="UserId">The user identification.</param>
        /// <param name="RequestedServiceId">The service identification for which an authorisation is requested.</param>
        /// <param name="ServiceSessionId">The service session identification.</param>
        /// <param name="AuthorisationValue">Whether to start or stop the charging process.</param>
        /// <param name="IntermediateCDRRequested">Whether the eMSP wishes to receive intermediate charging session records.</param>
        /// 
        /// <param name="TransactionId">An optional transaction identification.</param>
        /// <param name="UserContractIdAlias">Anonymized alias of the contract id between the end-user and the eMSP.</param>
        /// <param name="MeterLimits">Meter limits for this authorisation: The eMSP can authorise the charge but for less than x Wh or y minutes, or z euros.</param>
        /// <param name="Parameter">eMSP parameter string (reserved for future use).</param>
        /// <param name="BookingId"></param>
        /// 
        /// <param name="HTTPRequest">The correlated HTTP request of this eMIP request.</param>
        /// <param name="Timestamp">The optional timestamp of the request.</param>
        /// <param name="CancellationToken">An optional token to cancel this request.</param>
        /// <param name="EventTrackingId">An optional event tracking identification for correlating this request with other events.</param>
        /// <param name="RequestTimeout">An optional timeout for this request.</param>
        public SetServiceAuthorisationRequest(HTTPRequest                HTTPRequest,
                                              Partner_Id                 PartnerId,
                                              Operator_Id                OperatorId,
                                              Operator_Id                TargetOperatorId,
                                              EVSE_Id                    EVSEId,
                                              User_Id                    UserId,
                                              Service_Id                 RequestedServiceId,
                                              ServiceSession_Id          ServiceSessionId,
                                              RemoteStartStopValues      AuthorisationValue,
                                              Boolean                    IntermediateCDRRequested,

                                              Transaction_Id?            TransactionId             = null,
                                              Contract_Id?               UserContractIdAlias       = null,
                                              IEnumerable<MeterReport>   MeterLimits               = null,
                                              String                     Parameter                 = null,
                                              Booking_Id?                BookingId                 = null,

                                              DateTime?                  Timestamp                 = null,
                                              CancellationToken?         CancellationToken         = null,
                                              EventTracking_Id           EventTrackingId           = null,
                                              TimeSpan?                  RequestTimeout            = null)

            : base(HTTPRequest,
                   PartnerId,
                   TransactionId,
                   Timestamp,
                   CancellationToken,
                   EventTrackingId,
                   RequestTimeout)

        {

            this.OperatorId                = OperatorId;
            this.TargetOperatorId          = TargetOperatorId;
            this.EVSEId                    = EVSEId;
            this.UserId                    = UserId;
            this.RequestedServiceId        = RequestedServiceId;
            this.ServiceSessionId          = ServiceSessionId;
            this.AuthorisationValue        = AuthorisationValue;
            this.IntermediateCDRRequested  = IntermediateCDRRequested;

            this.UserContractIdAlias       = UserContractIdAlias;
            this.MeterLimits               = MeterLimits;
            this.Parameter                 = Parameter;
            this.BookingId                 = BookingId;

        }
Beispiel #12
0
        /// <summary>
        /// Create a new meter values request.
        /// </summary>
        /// <param name="ConnectorId">The connector identification at the charge point.</param>
        /// <param name="TransactionId">The charging transaction to which the given meter value samples are related to.</param>
        /// <param name="MeterValues">The sampled meter values with timestamps.</param>
        public MeterValuesRequest(Connector_Id ConnectorId,
                                  Transaction_Id?TransactionId         = null,
                                  IEnumerable <MeterValue> MeterValues = null)
        {
            #region Initial checks

            if (!MeterValues.SafeAny())
            {
                throw new ArgumentNullException(nameof(MeterValues), "The given meter values must not be null or empty!");
            }

            #endregion

            this.ConnectorId   = ConnectorId;
            this.TransactionId = TransactionId;
            this.MeterValues   = MeterValues;
        }
Beispiel #13
0
        SetServiceAuthorisation(this IEMPClient EMPClient,
                                Partner_Id PartnerId,
                                Operator_Id OperatorId,
                                EVSE_Id EVSEId,
                                User_Id UserId,
                                Service_Id RequestedServiceId,
                                RemoteStartStopValues AuthorisationValue,
                                Boolean IntermediateCDRRequested,

                                Transaction_Id?TransactionId = null,
                                PartnerServiceSession_Id?PartnerServiceSessionId = null,
                                Contract_Id?UserContractIdAlias       = null,
                                IEnumerable <MeterReport> MeterLimits = null,
                                String Parameter                = null,
                                Booking_Id?BookingId            = null,
                                Booking_Id?SalePartnerBookingId = null,

                                HTTPRequest HTTPRequest             = null,
                                DateTime?Timestamp                  = null,
                                CancellationToken?CancellationToken = null,
                                EventTracking_Id EventTrackingId    = null,
                                TimeSpan?RequestTimeout             = null)


        => EMPClient.SetServiceAuthorisation(new SetServiceAuthorisationRequest(PartnerId,
                                                                                OperatorId,
                                                                                EVSEId,
                                                                                UserId,
                                                                                RequestedServiceId,
                                                                                AuthorisationValue,
                                                                                IntermediateCDRRequested,

                                                                                TransactionId,
                                                                                PartnerServiceSessionId,
                                                                                UserContractIdAlias,
                                                                                MeterLimits,
                                                                                Parameter,
                                                                                BookingId,
                                                                                SalePartnerBookingId,

                                                                                HTTPRequest,
                                                                                Timestamp,
                                                                                CancellationToken,
                                                                                EventTrackingId,
                                                                                RequestTimeout ?? EMPClient.RequestTimeout));
Beispiel #14
0
        /// <summary>
        /// Create a new generic eMIP request message.
        /// </summary>
        /// <param name="PartnerId">The partner identification.</param>
        /// <param name="TransactionId">An optional eMIP transaction identification.</param>
        ///
        /// <param name="HTTPRequest">The correlated HTTP request of this eMIP request.</param>
        /// <param name="Timestamp">The optional timestamp of the request.</param>
        /// <param name="CancellationToken">An optional token to cancel this request.</param>
        /// <param name="EventTrackingId">An optional event tracking identification for correlating this request with other events.</param>
        /// <param name="RequestTimeout">An optional timeout for this request.</param>
        public ARequest(HTTPRequest HTTPRequest,
                        Partner_Id PartnerId,
                        Transaction_Id?TransactionId = null,

                        DateTime?Timestamp = null,
                        CancellationToken?CancellationToken = null,
                        EventTracking_Id EventTrackingId    = null,
                        TimeSpan?RequestTimeout             = null)
        {
            this.HTTPRequest   = HTTPRequest;
            this.PartnerId     = PartnerId;
            this.TransactionId = TransactionId;

            this.Timestamp = Timestamp ?? DateTime.UtcNow;
            this.CancellationTokenSource = CancellationToken == null  ? new CancellationTokenSource() : null;
            this.CancellationToken       = CancellationToken ?? CancellationTokenSource.Token;
            this.EventTrackingId         = EventTrackingId ?? EventTracking_Id.New;
            this.RequestTimeout          = RequestTimeout ?? DefaultRequestTimeout;
        }
        /// <summary>
        /// Create a Heartbeat XML/SOAP request.
        /// </summary>
        /// <param name="PartnerId">The partner identification.</param>
        /// <param name="OperatorId">The operator identification.</param>
        /// <param name="TransactionId">An optional transaction identification.</param>
        ///
        /// <param name="HTTPRequest">The correlated HTTP request of this eMIP request.</param>
        /// <param name="Timestamp">The optional timestamp of the request.</param>
        /// <param name="CancellationToken">An optional token to cancel this request.</param>
        /// <param name="EventTrackingId">An optional event tracking identification for correlating this request with other events.</param>
        /// <param name="RequestTimeout">An optional timeout for this request.</param>
        public HeartbeatRequest(Partner_Id PartnerId,
                                Operator_Id OperatorId,
                                Transaction_Id?TransactionId = null,

                                HTTPRequest HTTPRequest             = null,
                                DateTime?Timestamp                  = null,
                                CancellationToken?CancellationToken = null,
                                EventTracking_Id EventTrackingId    = null,
                                TimeSpan?RequestTimeout             = null)

            : base(HTTPRequest,
                   PartnerId,
                   TransactionId,
                   Timestamp,
                   CancellationToken,
                   EventTrackingId,
                   RequestTimeout)

        {
            this.OperatorId = OperatorId;
        }
Beispiel #16
0
        SendHeartbeat(this IEMPClient EMPClient,
                      Partner_Id PartnerId,
                      Operator_Id OperatorId,
                      Transaction_Id?TransactionId = null,

                      HTTPRequest HTTPRequest             = null,
                      DateTime?Timestamp                  = null,
                      CancellationToken?CancellationToken = null,
                      EventTracking_Id EventTrackingId    = null,
                      TimeSpan?RequestTimeout             = null)


        => EMPClient.SendHeartbeat(new HeartbeatRequest(PartnerId,
                                                        OperatorId,
                                                        TransactionId,

                                                        HTTPRequest,
                                                        Timestamp,
                                                        CancellationToken,
                                                        EventTrackingId,
                                                        RequestTimeout ?? EMPClient.RequestTimeout));
Beispiel #17
0
        /// <summary>
        /// Create a SetChargeDetailRecord XML/SOAP request.
        /// </summary>
        /// <param name="PartnerId">The partner identification.</param>
        /// <param name="OperatorId">The operator identification.</param>
        /// <param name="ChargeDetailRecord">The charge detail record.</param>
        /// <param name="TransactionId">An optional transaction identification.</param>
        ///
        /// <param name="HTTPRequest">The correlated HTTP request of this eMIP request.</param>
        /// <param name="Timestamp">The optional timestamp of the request.</param>
        /// <param name="CancellationToken">An optional token to cancel this request.</param>
        /// <param name="EventTrackingId">An optional event tracking identification for correlating this request with other events.</param>
        /// <param name="RequestTimeout">An optional timeout for this request.</param>
        public SetChargeDetailRecordRequest(Partner_Id PartnerId,
                                            Operator_Id OperatorId,
                                            ChargeDetailRecord ChargeDetailRecord,
                                            Transaction_Id?TransactionId = null,

                                            HTTPRequest HTTPRequest             = null,
                                            DateTime?Timestamp                  = null,
                                            CancellationToken?CancellationToken = null,
                                            EventTracking_Id EventTrackingId    = null,
                                            TimeSpan?RequestTimeout             = null)

            : base(HTTPRequest,
                   PartnerId,
                   TransactionId,
                   Timestamp,
                   CancellationToken,
                   EventTrackingId,
                   RequestTimeout)

        {
            this.OperatorId         = OperatorId;
            this.ChargeDetailRecord = ChargeDetailRecord;
        }
Beispiel #18
0
        SetChargeDetailRecord(this ICPOClient CPOClient,
                              Partner_Id PartnerId,
                              Operator_Id OperatorId,
                              ChargeDetailRecord ChargeDetailRecord,
                              Transaction_Id?TransactionId = null,

                              HTTPRequest HTTPRequest             = null,
                              DateTime?Timestamp                  = null,
                              CancellationToken?CancellationToken = null,
                              EventTracking_Id EventTrackingId    = null,
                              TimeSpan?RequestTimeout             = null)


        => CPOClient.SetChargeDetailRecord(new SetChargeDetailRecordRequest(PartnerId,
                                                                            OperatorId,
                                                                            ChargeDetailRecord,
                                                                            TransactionId,

                                                                            HTTPRequest,
                                                                            Timestamp,
                                                                            CancellationToken,
                                                                            EventTrackingId,
                                                                            RequestTimeout ?? CPOClient.RequestTimeout));
 /// <summary>
 /// Indicates whether this transaction identification is null or empty.
 /// </summary>
 /// <param name="TransactionId">A transaction identification.</param>
 public static Boolean IsNullOrEmpty(this Transaction_Id?TransactionId)
 => !TransactionId.HasValue || TransactionId.Value.IsNullOrEmpty;
 /// <summary>
 /// Indicates whether this transaction identification is null or empty.
 /// </summary>
 /// <param name="TransactionId">A transaction identification.</param>
 public static Boolean IsNotNullOrEmpty(this Transaction_Id?TransactionId)
 => TransactionId.HasValue && TransactionId.Value.IsNotNullOrEmpty;