src/eric7/Documentation/Source/eric7.Plugins.CheckerPlugins.CodeStyleChecker.Miscellaneous.DateTimeVisitor.html

branch
eric7
changeset 11150
73d80859079c
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/eric7/Documentation/Source/eric7.Plugins.CheckerPlugins.CodeStyleChecker.Miscellaneous.DateTimeVisitor.html	Thu Feb 27 14:42:39 2025 +0100
@@ -0,0 +1,134 @@
+<!DOCTYPE html>
+<html><head>
+<title>eric7.Plugins.CheckerPlugins.CodeStyleChecker.Miscellaneous.DateTimeVisitor</title>
+<meta charset="UTF-8">
+<link rel="stylesheet" href="styles.css">
+</head>
+<body>
+<a NAME="top" ID="top"></a>
+<h1>eric7.Plugins.CheckerPlugins.CodeStyleChecker.Miscellaneous.DateTimeVisitor</h1>
+<p>
+Module implementing a node visitor to check datetime function calls.
+</p>
+
+<h3>Global Attributes</h3>
+<table>
+<tr><td>None</td></tr>
+</table>
+
+<h3>Classes</h3>
+<table>
+<tr>
+<td><a href="#DateTimeVisitor">DateTimeVisitor</a></td>
+<td>Class implementing a node visitor to check datetime function calls.</td>
+</tr>
+</table>
+
+<h3>Functions</h3>
+<table>
+<tr><td>None</td></tr>
+</table>
+
+<hr />
+<hr />
+<a NAME="DateTimeVisitor" ID="DateTimeVisitor"></a>
+<h2>DateTimeVisitor</h2>
+<p>
+    Class implementing a node visitor to check datetime function calls.
+</p>
+<p>
+    Note: This class is modeled after flake8_datetimez v20.10.0 checker.
+</p>
+
+<h3>Derived from</h3>
+ast.NodeVisitor
+<h3>Class Attributes</h3>
+<table>
+<tr><td>None</td></tr>
+</table>
+
+<h3>Class Methods</h3>
+<table>
+<tr><td>None</td></tr>
+</table>
+
+<h3>Methods</h3>
+<table>
+<tr>
+<td><a href="#DateTimeVisitor.__init__">DateTimeVisitor</a></td>
+<td>Constructor</td>
+</tr>
+<tr>
+<td><a href="#DateTimeVisitor.__getFromKeywords">__getFromKeywords</a></td>
+<td>Private method to get a keyword node given its name.</td>
+</tr>
+<tr>
+<td><a href="#DateTimeVisitor.visit_Call">visit_Call</a></td>
+<td>Public method to handle a function call.</td>
+</tr>
+</table>
+
+<h3>Static Methods</h3>
+<table>
+<tr><td>None</td></tr>
+</table>
+
+
+<a NAME="DateTimeVisitor.__init__" ID="DateTimeVisitor.__init__"></a>
+<h4>DateTimeVisitor (Constructor)</h4>
+<b>DateTimeVisitor</b>(<i></i>)
+<p>
+        Constructor
+</p>
+
+<a NAME="DateTimeVisitor.__getFromKeywords" ID="DateTimeVisitor.__getFromKeywords"></a>
+<h4>DateTimeVisitor.__getFromKeywords</h4>
+<b>__getFromKeywords</b>(<i>keywords, name</i>)
+<p>
+        Private method to get a keyword node given its name.
+</p>
+
+<dl>
+
+<dt><i>keywords</i> (list of ast.AST)</dt>
+<dd>
+list of keyword argument nodes
+</dd>
+<dt><i>name</i> (str)</dt>
+<dd>
+name of the keyword node
+</dd>
+</dl>
+<dl>
+<dt>Return:</dt>
+<dd>
+keyword node
+</dd>
+</dl>
+<dl>
+<dt>Return Type:</dt>
+<dd>
+ast.AST
+</dd>
+</dl>
+<a NAME="DateTimeVisitor.visit_Call" ID="DateTimeVisitor.visit_Call"></a>
+<h4>DateTimeVisitor.visit_Call</h4>
+<b>visit_Call</b>(<i>node</i>)
+<p>
+        Public method to handle a function call.
+</p>
+<p>
+        Every datetime related function call is check for use of the naive
+        variant (i.e. use without TZ info).
+</p>
+
+<dl>
+
+<dt><i>node</i> (ast.Call)</dt>
+<dd>
+reference to the node to be processed
+</dd>
+</dl>
+<div align="right"><a href="#top">Up</a></div>
+<hr />
+</body></html>

eric ide

mercurial