OcppModel.V20.Behaviours.ChargeSystem behaviour (ocpp_model v0.3.0) View Source

Behaviour of a ChargeSystem, allowing the module assuming the behaviour to be able to respond to messages send to it

Link to this section Summary

Functions

Main entrypoint, based on the action parameter, this function will call one of the callback functions with the payload

Link to this section Functions

Link to this function

handle(impl, action, payload, state)

View Source

Specs

handle(atom(), String.t(), map(), any()) ::
  {{:ok, map()}, any()} | {{:error, atom(), String.t()}, any()}

Main entrypoint, based on the action parameter, this function will call one of the callback functions with the payload

Link to this section Callbacks

Specs

authorize(OcppModel.V20.Messages.AuthorizeRequest.t(), any()) ::
  {{:ok, OcppModel.V20.Messages.AuthorizeResponse.t()}, any()}
  | {{:error, :authorize, String.t()}, any()}
Link to this callback

boot_notification(arg1, any)

View Source

Specs

boot_notification(OcppModel.V20.Messages.BootNotificationRequest.t(), any()) ::
  {{:ok, OcppModel.V20.Messages.BootNotificationResponse.t()}, any()}
  | {{:error, :boot_notification, String.t()}, any()}
Link to this callback

cleared_charging_limit(arg1, any)

View Source

Specs

cleared_charging_limit(
  OcppModel.V20.Messages.ClearedChargingLimitRequest.t(),
  any()
) ::
  {{:ok, OcppModel.V20.Messages.ClearedChargingLimitResponse.t()}, any()}
  | {{:error, :cleared_charging_limit, String.t()}, any()}
Link to this callback

data_transfer(arg1, any)

View Source

Specs

data_transfer(OcppModel.V20.Messages.DataTransferRequest.t(), any()) ::
  {{:ok, OcppModel.V20.Messages.DataTransferResponse.t()}, any()}
  | {{:error, :data_transfer, String.t()}, any()}
Link to this callback

firmware_status_notification(arg1, any)

View Source

Specs

firmware_status_notification(
  OcppModel.V20.Messages.FirmwareStatusNotificationRequest.t(),
  any()
) ::
  {{:ok, OcppModel.V20.Messages.FirmwareStatusNotificationResponse.t()}, any()}
  | {{:error, :firmware_status_notification, String.t()}, any()}
Link to this callback

get_15118_ev_certificate(arg1, any)

View Source

Specs

get_15118_ev_certificate(
  OcppModel.V20.Messages.Get15118EVCertificateRequest.t(),
  any()
) ::
  {{:ok, OcppModel.V20.Messages.Get15118EVCertificateResponse.t()}, any()}
  | {{:error, :get_15118_ev_certificate, String.t()}, any()}
Link to this callback

get_certificate_status(arg1, any)

View Source

Specs

get_certificate_status(
  OcppModel.V20.Messages.GetCertificateStatusRequest.t(),
  any()
) ::
  {{:ok, OcppModel.V20.Messages.GetCertificateStatusResponse.t()}, any()}
  | {{:error, :get_certificate_status, String.t()}, any()}

Specs

heartbeat(OcppModel.V20.Messages.HeartbeatRequest.t(), any()) ::
  {{:ok, OcppModel.V20.Messages.HeartbeatResponse.t()}, any()}
  | {{:error, :heartbeat, String.t()}, any()}
Link to this callback

log_status_notification(arg1, any)

View Source

Specs

log_status_notification(
  OcppModel.V20.Messages.LogStatusNotificationRequest.t(),
  any()
) ::
  {{:ok, OcppModel.V20.Messages.LogStatusNotificationResponse.t()}, any()}
  | {{:error, :log_status_notification, String.t()}, any()}

Specs

meter_values(OcppModel.V20.Messages.MeterValuesRequest.t(), any()) ::
  {{:ok, OcppModel.V20.Messages.MeterValuesResponse.t()}, any()}
  | {{:error, :meter_values, String.t()}, any()}
Link to this callback

notify_charging_limit(arg1, any)

View Source

Specs

notify_charging_limit(
  OcppModel.V20.Messages.NotifyChargingLimitRequest.t(),
  any()
) ::
  {{:ok, OcppModel.V20.Messages.NotifyChargingLimitResponse.t()}, any()}
  | {{:error, :notify_charging_limit, String.t()}, any()}
Link to this callback

notify_customer_information(arg1, any)

View Source

Specs

notify_customer_information(
  OcppModel.V20.Messages.NotifyCustomerInformationRequest.t(),
  any()
) ::
  {{:ok, OcppModel.V20.Messages.NotifyCustomerInformationResponse.t()}, any()}
  | {{:error, :notify_customer_information, String.t()}, any()}
Link to this callback

notify_display_messages(arg1, any)

View Source

Specs

notify_display_messages(
  OcppModel.V20.Messages.NotifyDisplayMessagesRequest.t(),
  any()
) ::
  {{:ok, OcppModel.V20.Messages.NotifyDisplayMessagesResponse.t()}, any()}
  | {{:error, :notify_display_messages, String.t()}, any()}
Link to this callback

notify_ev_charging_needs(arg1, any)

View Source

Specs

notify_ev_charging_needs(
  OcppModel.V20.Messages.NotifyEVChargingNeedsRequest.t(),
  any()
) ::
  {{:ok, OcppModel.V20.Messages.NotifyEVChargingNeedsResponse.t()}, any()}
  | {{:error, :notify_ev_charging_needs, String.t()}, any()}
Link to this callback

notify_ev_charging_schedule(arg1, any)

View Source

Specs

notify_ev_charging_schedule(
  OcppModel.V20.Messages.NotifyEVChargingScheduleRequest.t(),
  any()
) ::
  {{:ok, OcppModel.V20.Messages.NotifyEVChargingScheduleResponse.t()}, any()}
  | {{:error, :notify_ev_charging_needs, String.t()}, any()}

Specs

notify_event(OcppModel.V20.Messages.NotifyEventRequest.t(), any()) ::
  {{:ok, OcppModel.V20.Messages.NotifyEventResponse.t()}, any()}
  | {{:error, :notify_event, String.t()}, any()}
Link to this callback

notify_monitoring_report(arg1, any)

View Source

Specs

notify_monitoring_report(
  OcppModel.V20.Messages.NotifyMonitoringReportRequest.t(),
  any()
) ::
  {{:ok, OcppModel.V20.Messages.NotifyMonitoringReportResponse.t()}, any()}
  | {{:error, :notify_monitoring_report, String.t()}, any()}
Link to this callback

notify_report(arg1, any)

View Source

Specs

notify_report(OcppModel.V20.Messages.NotifyReportRequest.t(), any()) ::
  {{:ok, OcppModel.V20.Messages.NotifyReportResponse.t()}, any()}
  | {{:error, :notify_report, String.t()}, any()}
Link to this callback

publish_firmware_status_notification(arg1, any)

View Source

Specs

publish_firmware_status_notification(
  OcppModel.V20.Messages.PublishFirmwareStatusNotificationRequest.t(),
  any()
) ::
  {{:ok, OcppModel.V20.Messages.PublishFirmwareStatusNotificationResponse.t()},
   any()}
  | {{:error, :publish_firmware_status_notification, String.t()}, any()}
Link to this callback

report_charging_profiles(arg1, any)

View Source

Specs

report_charging_profiles(
  OcppModel.V20.Messages.ReportChargingProfilesRequest.t(),
  any()
) ::
  {{:ok, OcppModel.V20.Messages.ReportChargingProfilesResponse.t()}, any()}
  | {{:error, :report_charging_profiles, String.t()}, any()}
Link to this callback

reservation_status_update(arg1, any)

View Source

Specs

reservation_status_update(
  OcppModel.V20.Messages.ReservationStatusUpdateRequest.t(),
  any()
) ::
  {{:ok, OcppModel.V20.Messages.ReservationStatusUpdateResponse.t()}, any()}
  | {{:error, :reservation_status_update, String.t()}, any()}
Link to this callback

security_event_notification(arg1, any)

View Source

Specs

security_event_notification(
  OcppModel.V20.Messages.SecurityEventNotificationRequest.t(),
  any()
) ::
  {{:ok, OcppModel.V20.Messages.SecurityEventNotificationResponse.t()}, any()}
  | {{:error, :security_event_notification, String.t()}, any()}
Link to this callback

status_notification(arg1, any)

View Source

Specs

status_notification(OcppModel.V20.Messages.StatusNotificationRequest.t(), any()) ::
  {{:ok, OcppModel.V20.Messages.StatusNotificationResponse.t()}, any()}
  | {{:error, :status_notification, String.t()}, any()}
Link to this callback

transaction_event(arg1, any)

View Source

Specs

transaction_event(OcppModel.V20.Messages.TransactionEventRequest.t(), any()) ::
  {{:ok, OcppModel.V20.Messages.TransactionEventResponse.t()}, any()}
  | {{:error, :transaction_event, String.t()}, any()}