Spaces:
Sleeping
Sleeping
File size: 1,862 Bytes
5cee033 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 |
//========================================================================
//
// DateInfo.h
//
// Copyright (C) 2008, 2018, 2019 Albert Astals Cid <[email protected]>
// Copyright (C) 2009 Carlos Garcia Campos <[email protected]>
// Copyright (C) 2015 André Guerreiro <[email protected]>
// Copyright (C) 2015 André Esser <[email protected]>
// Copyright (C) 2016, 2021 Adrian Johnson <[email protected]>
// Copyright (C) 2024 Erich E. Hoover <[email protected]>
//
// To see a description of the changes please see the Changelog file that
// came with your tarball or type make ChangeLog if you are building from git
//
//========================================================================
//========================================================================
//
// Based on code from pdfinfo.cc
//
// Copyright 1998-2003 Glyph & Cog, LLC
//
//========================================================================
#ifndef DATE_INFO_H
#define DATE_INFO_H
#include "goo/GooString.h"
#include "poppler_private_export.h"
#include <ctime>
bool POPPLER_PRIVATE_EXPORT parseDateString(const GooString *date, int *year, int *month, int *day, int *hour, int *minute, int *second, char *tz, int *tzHour, int *tzMinute);
/* Converts the time_t into a PDF Date format string.
* If timeA is NULL, current time is used.
* Returns new GooString. Free with delete.
*/
GooString POPPLER_PRIVATE_EXPORT *timeToDateString(const time_t *timeA);
/* Converts the time_t into a string with the specified format.
* If timeA is NULL, current time is used.
* Returns std::string
*/
std::string POPPLER_PRIVATE_EXPORT timeToStringWithFormat(const time_t *timeA, const char *format);
/* Convert PDF date string to time.
* Returns -1 if conversion fails.
*/
time_t POPPLER_PRIVATE_EXPORT dateStringToTime(const GooString *dateString);
#endif
|