Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:Ledest:erlang:26
erlang
2830-snmp-Types-and-specs-for-snmp-local_time_t...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 2830-snmp-Types-and-specs-for-snmp-local_time_to_date_and.patch of Package erlang
From b432f516a71f99c0e8b9aab02384ecc42e48b1e5 Mon Sep 17 00:00:00 2001 From: Micael Karlberg <bmk@erlang.org> Date: Wed, 10 Jan 2024 10:58:26 +0100 Subject: [PATCH 10/67] [snmp] Types and specs for snmp:local_time_to_date_and_time_dst/1 --- lib/snmp/doc/src/snmp.xml | 11 ++++------- lib/snmp/src/app/snmp.erl | 5 +++++ 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/lib/snmp/doc/src/snmp.xml b/lib/snmp/doc/src/snmp.xml index e92aaa0c1f..a7ee72c7c4 100644 --- a/lib/snmp/doc/src/snmp.xml +++ b/lib/snmp/doc/src/snmp.xml @@ -289,20 +289,17 @@ "minutes from UTC" = 0. </p> <marker id="lt2dat_dst"></marker> + <marker id="local_time_to_date_and_time_dst"></marker> </desc> </func> <func> - <name since="">local_time_to_date_and_time_dst(Local) -> [DateAndTime]</name> + <name name="local_time_to_date_and_time_dst" arity="1" clause_i="1" since=""/> <fsummary>Convert a Local time value to a list of possible DateAndTime(s)</fsummary> - <type> - <v>Local = {{Y,Mo,D},{H,M,S}}</v> - <v>DateAndTime = [int()]</v> - </type> <desc> <p>Converts a local time value to a list of possible DateAndTime - list(s). The local time value on the same format as defined in - calendar(3).</p> + list(s). The local time value on the same format as defined in + calendar(3).</p> <marker id="ut2dat"></marker> </desc> diff --git a/lib/snmp/src/app/snmp.erl b/lib/snmp/src/app/snmp.erl index f78abd2b89..03c4e6695d 100644 --- a/lib/snmp/src/app/snmp.erl +++ b/lib/snmp/src/app/snmp.erl @@ -794,6 +794,11 @@ diff(Secs) -> universal_time_to_date_and_time(UTC) -> short_time(UTC) ++ [$+, 0, 0]. + +-spec local_time_to_date_and_time_dst(Local) -> DATs when + Local :: calendar:datetime1970(), + DATs :: [rfc1903_date_and_time()]. + local_time_to_date_and_time_dst(Local) -> case calendar:local_time_to_universal_time_dst(Local) of [] -> -- 2.35.3
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor