-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpydbproperties.html
107 lines (81 loc) · 7.02 KB
/
pydbproperties.html
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html><head><title>Python: module pydbproperties</title>
</head><body bgcolor="#f0f0f8">
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="heading">
<tr bgcolor="#7799ee">
<td valign=bottom> <br>
<font color="#ffffff" face="helvetica, arial"> <br><big><big><strong>pydbproperties</strong></big></big></font></td
><td align=right valign=bottom
>
<font color="#ffffff" face="helvetica, arial">
<br>
</font></td></tr></table>
<p><tt>author: José Roberto Meza Cabrera<br>
mail: robertpro01@gmail.com<br>
<br>
With this script, you can use store properties into a<br>
MySQL table, you can change the name of the table, and<br>
list the properties into a output stream or file<br>
stream, etc.</tt></p>
<p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#aa55cc">
<td colspan=3 valign=bottom> <br>
<font color="#ffffff" face="helvetica, arial"><big><strong>Modules</strong></big></font></td></tr>
<tr><td bgcolor="#aa55cc"><tt> </tt></td><td> </td>
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top>myquerybuilder</a><br>
</td><td width="25%" valign=top>re</a><br>
</td><td width="25%" valign=top>sys</a><br>
</td><td width="25%" valign=top></td></tr></table></td></tr></table><p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#ee77aa">
<td colspan=3 valign=bottom> <br>
<font color="#ffffff" face="helvetica, arial"><big><strong>Classes</strong></big></font></td></tr>
<tr><td bgcolor="#ee77aa"><tt> </tt></td><td> </td>
<td width="100%"><dl>
<dt><font face="helvetica, arial">pydbproperties</a>
</font></dt></dl>
<p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#ffc8d8">
<td colspan=3 valign=bottom> <br>
<font color="#000000" face="helvetica, arial"><a name="pydbproperties">class <strong>pydbproperties</strong></a></font></td></tr>
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
<td colspan=2><tt>A Python implements of pyjavaproperties for database<br> </tt></td></tr>
<tr><td> </td>
<td width="100%">Methods defined here:<br>
<dl><dt><a name="pydbproperties-__getitem__"><strong>__getitem__</strong></a>(self, name)</dt><dd><tt>To support direct dictionary like access</tt></dd></dl>
<dl><dt><a name="pydbproperties-__init__"><strong>__init__</strong></a>(self)</dt></dl>
<dl><dt><a name="pydbproperties-__setitem__"><strong>__setitem__</strong></a>(self, name, value)</dt><dd><tt>To support direct dictionary like access</tt></dd></dl>
<dl><dt><a name="pydbproperties-conn"><strong>conn</strong></a>(self, **kwargs)</dt><dd><tt>Instance a connection with the database</tt></dd></dl>
<dl><dt><a name="pydbproperties-create_table"><strong>create_table</strong></a>(self)</dt><dd><tt>Create a table, if you don't use set_table_name</a>() method, the<br>
name of the table will be default( pydbproperties</a> )</tt></dd></dl>
<dl><dt><a name="pydbproperties-escape"><strong>escape</strong></a>(self, value)</dt></dl>
<dl><dt><a name="pydbproperties-get_property"><strong>get_property</strong></a>(self, key)</dt><dd><tt>Return a property for the given key</tt></dd></dl>
<dl><dt><a name="pydbproperties-get_property_dict"><strong>get_property_dict</strong></a>(self)</dt><dd><tt>Returns property dict</tt></dd></dl>
<dl><dt><a name="pydbproperties-get_property_names"><strong>get_property_names</strong></a>(self)</dt><dd><tt>Return an iterator over all the keys of the property<br>
dictionary, i.e the names of the properties</tt></dd></dl>
<dl><dt><a name="pydbproperties-get_table_name"><strong>get_table_name</strong></a>(self)</dt><dd><tt>Returns table name</tt></dd></dl>
<dl><dt><a name="pydbproperties-list"><strong>list</strong></a>(self, out<font color="#909090">=<open file '<stdout>', mode 'w'></font>)</dt><dd><tt>Prints a listing of the properties to the<br>
stream 'out' which defaults to the standard output</tt></dd></dl>
<dl><dt><a name="pydbproperties-load"><strong>load</strong></a>(self)</dt><dd><tt>Load properties from database</tt></dd></dl>
<dl><dt><a name="pydbproperties-process_pair"><strong>process_pair</strong></a>(self, key, value)</dt><dd><tt>Process a (key, value) pair</tt></dd></dl>
<dl><dt><a name="pydbproperties-remove_property"><strong>remove_property</strong></a>(self, property)</dt><dd><tt>Remove a property<br>
if property is None: remove all properties</tt></dd></dl>
<dl><dt><a name="pydbproperties-remove_property_db"><strong>remove_property_db</strong></a>(self, prop)</dt><dd><tt>Remove a property directly from a database<br>
if property is None: remove all properties directly from a database</tt></dd></dl>
<dl><dt><a name="pydbproperties-set_auto_load"><strong>set_auto_load</strong></a>(self, boolean)</dt><dd><tt>Set True for working directly with the database</tt></dd></dl>
<dl><dt><a name="pydbproperties-set_auto_store"><strong>set_auto_store</strong></a>(self, boolean)</dt><dd><tt>Set True for working directly with the database</tt></dd></dl>
<dl><dt><a name="pydbproperties-set_property"><strong>set_property</strong></a>(self, key, value)</dt><dd><tt>Set the property for the given key</tt></dd></dl>
<dl><dt><a name="pydbproperties-set_table_name"><strong>set_table_name</strong></a>(self, table_name)</dt><dd><tt>Sets table name</tt></dd></dl>
<dl><dt><a name="pydbproperties-store"><strong>store</strong></a>(self)</dt><dd><tt>Stores the dict to a database</tt></dd></dl>
<dl><dt><a name="pydbproperties-unescape"><strong>unescape</strong></a>(self, value)</dt></dl>
</td></tr></table></td></tr></table><p>
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
<tr bgcolor="#55aa55">
<td colspan=3 valign=bottom> <br>
<font color="#ffffff" face="helvetica, arial"><big><strong>Data</strong></big></font></td></tr>
<tr><td bgcolor="#55aa55"><tt> </tt></td><td> </td>
<td width="100%"><strong>NULL</strong> = ('', None, (), [], {})<br>
<strong>print_function</strong> = _Feature((2, 6, 0, 'alpha', 2), (3, 0, 0, 'alpha', 0), 65536)</td></tr></table>
</body></html>