📄 DateUtilsCaller.sol
D-OPEN SOVEREIGN
1/*
2 * Copyright (c) 2026 DataPond D-Library Pty Ltd. ("The Sanctuary")
3 * Non-Profit Public Library — The World Library
4 *
5 * D-SAFE Certification issued by POND Enterprise.
6 * Published under the D-Open Code Sovereign Licence v1.0 framework
7 * DataPond D-Library All exclusive Right reserved on modifiying the code - CC Attribution to data pond, Non modifiable, Non Commercial.
8 * https://registry.world.bibliotech.com/licence
9 * Source code donated to DataPond D-Library by it's author: data pond.
10 *
11 * Technical Guardian ("The Shield"): Pond Enterprise Pty Ltd. (ACN 694 747 987)
12 * All liability claims about D-SAFE certification issues coming from the published D-Safe direction must be addressed with Pond Enterprise Pty Ltd.
13 * Code Modification automatically voids the certified liability protection provided by Pond Enterprise.
14 */
15
16// SPDX-License-Identifier: UNLICENSED
17pragma solidity ^0.8.24;
18import "./DateUtils.sol";
19
20contract DateUtilsCaller {
21 constructor() {}
22
23 function uintToString(uint256 value) public pure returns (string memory) {
24 return DateUtils.uintToString(value);
25 }
26
27 function uint16ToString(uint16 value) public pure returns (string memory) {
28 return DateUtils.uint16ToString(value);
29 }
30
31 function uint8ToString(uint8 value) public pure returns (string memory) {
32 return DateUtils.uint8ToString(value);
33 }
34
35 function getYearMonthString() public view returns (string memory) {
36 return DateUtils.getYearMonthString();
37 }
38
39 function getCurrentYearAndMonth()
40 public
41 view
42 returns (uint16 year, uint8 month)
43 {
44 return DateUtils.getCurrentYearAndMonth();
45 }
46
47 function isLeapYear(uint256 year) public pure returns (bool) {
48 return DateUtils.isLeapYear(year);
49 }
50
51 function calculateMonthFromDays(
52 uint16 dayInYear,
53 bool leapYear
54 ) public pure returns (uint8) {
55 return DateUtils.calculateMonthFromDays(dayInYear, leapYear);
56 }
57}
58