Expando Node for a Conditional Date. More...
#include "config.h"#include <limits.h>#include <stdio.h>#include <string.h>#include <time.h>#include "mutt/lib.h"#include "node_conddate.h"#include "helpers.h"#include "node.h"#include "parse.h"#include "render.h"
Include dependency graph for node_conddate.c:Go to the source code of this file.
Functions | |
| struct NodeCondDatePrivate * | node_conddate_private_new (int count, char period) |
| Create new CondDate private data. | |
| void | node_conddate_private_free (void **ptr) |
| Free CondDate private data - Implements ExpandoNode::ndata_free() | |
| time_t | cutoff_number (char period, int count) |
| Calculate the cutoff time for n units. | |
| time_t | cutoff_this (char period) |
| Calculate the cutoff time of this unit. | |
| int | node_conddate_render (const struct ExpandoNode *node, const struct ExpandoRenderCallback *erc, struct Buffer *buf, int max_cols, void *data, MuttFormatFlags flags) |
| Render a CondDate Node - Implements ExpandoNode::render() -. | |
| struct ExpandoNode * | node_conddate_new (int count, char period, int did, int uid) |
| Create a new CondDate ExpandoNode. | |
| struct ExpandoNode * | node_conddate_parse (const char *str, int did, int uid, const char **parsed_until, struct ExpandoParseError *err) |
| Parse a CondDate format string. | |
Expando Node for a Conditional Date.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.
Definition in file node_conddate.c.
| struct NodeCondDatePrivate * node_conddate_private_new | ( | int | count, |
| char | period ) |
Create new CondDate private data.
| count | Number of 'units' to count |
| period | Units, e.g. 'd' Day or 'm' Month |
| ptr | New CondDate private data |
Definition at line 48 of file node_conddate.c.
Here is the caller graph for this function:| void node_conddate_private_free | ( | void ** | ptr | ) |
Free CondDate private data - Implements ExpandoNode::ndata_free()
| ptr | Data to free |
Definition at line 62 of file node_conddate.c.
Here is the caller graph for this function:| time_t cutoff_number | ( | char | period, |
| int | count ) |
Calculate the cutoff time for n units.
| period | Time period, from [ymwdHM] |
| count | Number of time periods |
| num | Cutoff time |
Calculate the cutoff time for, say, 3 months, or 2 hours.
Definition at line 78 of file node_conddate.c.
Here is the call graph for this function:
Here is the caller graph for this function:| time_t cutoff_this | ( | char | period | ) |
Calculate the cutoff time of this unit.
| period | Time period, from [ymwdHM] |
| num | Cutoff time |
Calculate the cutoff time of, say, this day (today), this month.
Definition at line 121 of file node_conddate.c.
Here is the call graph for this function:
Here is the caller graph for this function:| struct ExpandoNode * node_conddate_new | ( | int | count, |
| char | period, | ||
| int | did, | ||
| int | uid ) |
Create a new CondDate ExpandoNode.
| count | Number of 'units' to count |
| period | Units, e.g. 'd' Day or 'm' Month |
| did | Domain ID |
| uid | Unique ID |
| ptr | New CondDate ExpandoNode |
Definition at line 198 of file node_conddate.c.
Here is the call graph for this function:
Here is the caller graph for this function:| struct ExpandoNode * node_conddate_parse | ( | const char * | str, |
| int | did, | ||
| int | uid, | ||
| const char ** | parsed_until, | ||
| struct ExpandoParseError * | err ) |
Parse a CondDate format string.
| [in] | str | String to parse |
| [in] | did | Domain ID |
| [in] | uid | Unique ID |
| [out] | parsed_until | First character after parsed string |
| [out] | err | Buffer for errors |
Definition at line 220 of file node_conddate.c.
Here is the call graph for this function:
Here is the caller graph for this function: