Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014aUaQeLnwbb1zTpN7kHeat
24 lines
738 B
ABAP
24 lines
738 B
ABAP
INTERFACE {{p}}if_park_fee PUBLIC.
|
|
TYPES ty_amount TYPE p LENGTH 8 DECIMALS 2.
|
|
TYPES ty_reason TYPE c LENGTH 10.
|
|
TYPES:
|
|
BEGIN OF ty_result,
|
|
reason TYPE ty_reason,
|
|
fee TYPE ty_amount,
|
|
END OF ty_result.
|
|
CONSTANTS:
|
|
BEGIN OF c_reason,
|
|
ok TYPE ty_reason VALUE 'OK',
|
|
bad_time TYPE ty_reason VALUE 'BAD_TIME',
|
|
too_long TYPE ty_reason VALUE 'TOO_LONG',
|
|
END OF c_reason.
|
|
METHODS calculate
|
|
IMPORTING iv_entry_date TYPE d
|
|
iv_entry_time TYPE t
|
|
iv_exit_date TYPE d
|
|
iv_exit_time TYPE t
|
|
iv_lost_ticket TYPE abap_bool
|
|
iv_discount TYPE abap_bool
|
|
RETURNING VALUE(rs_result) TYPE ty_result.
|
|
ENDINTERFACE.
|