Contact: fumanchu@aminus.org

Log in as guest/dejavu to create tickets

I think I've seen this ORM somewhere before...

Changeset 22

Show
Ignore:
Timestamp:
10/30/04 20:43:26
Author:
fumanchu
Message:

1. Moved xray, recur into dejavu.
2. Doc updates.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/__init__.py

    r21 r22  
    11import ConfigParser 
    22import datetime 
    3 import xray 
    43 
    54from dejavu.containers import * 
    65from dejavu.analysis import * 
    76from dejavu.readme import * 
    8 from dejavu import logic 
     7from dejavu import logic, xray 
    98 
    109 
  • trunk/codewalk.py

    r21 r22  
    742742        self.newcode = [] 
    743743         
    744         # Add a list of 'and' and 'or' mappings {target: [(previous TOS, and_or_or)...]} 
     744        # Add a list of 'and' and 'or' mappings {target: [(previous TOS, and/or)...]} 
    745745        self.targets = {} 
    746746        b = self._bytecode 
  • trunk/doc/dejavu.css

    r21 r22  
    5959} 
    6060 
     61li { 
     62    margin-top: 0.35em; 
     63    margin-bottom: 0.35em; 
     64} 
    6165 
    6266/*, table { border: 2px dotted red } 
  • trunk/doc/index.html

    r21 r22  
    7272        <li>Loading Stores</li> 
    7373        <li>Registering Unit Classes</li> 
    74         <li></li> 
    7574        </ul> 
    7675    </li> 
     
    9493            </ul> 
    9594        </li> 
     95        <li>Recurrence Values</li> 
    9696        </ul> 
    9797    </li> 
     
    104104    <li>Custom Storage Managers 
    105105        <ul> 
    106         <li>Generic Database Wrappers</li> 
     106        <li>Generic Database Wrappers 
     107            <ul> 
     108            <li>Adapters</li> 
     109            <li>Decompiler</li> 
     110            <li>StorageManager</li> 
     111            </ul> 
     112        </li> 
    107113        <li>ODBC</li> 
    108114        <li>Other Serialization Mechanisms</li> 
  • trunk/doc/intro.html

    r21 r22  
    201201In addition, the bytecode of Python may change from one version of Python 
    202202to another; if you find your version of Python does not work with Dejavu's 
    203 <tt>codewalk</tt> and <tt>logic</tt> modules, please let us know.<br /> 
     203<tt>codewalk</tt> and <tt>logic</tt> modules, please let me know.<br /> 
    204204</p> 
    205205 
  • trunk/doc/storage.html

    r21 r22  
    8282 
    8383<h5>Microsoft Access (Jet)</h5> 
    84 <p>This class was developed against ADO 2.7.</p> 
     84<p>This class was developed against ADO 2.7. Configuration entries:</p> 
    8585<ul> 
    8686    <li><b>Class:</b> <tt>dejavu.storage.storeado.StorageManagerADO_MSAccess</tt></li> 
     
    104104 
    105105<h5>Microsoft SQL Server</h5> 
    106 <p>This class was developed against ADO 2.7.</p> 
     106<p>This class was developed against ADO 2.7. Configuration entries:</p> 
    107107<ul> 
    108108    <li><b>Class:</b> <tt>dejavu.storage.storeado.StorageManagerADO_SQLServer</tt></li> 
     
    126126 
    127127<h5>ODBC</h5> 
    128 <p>This class doesn't currently work. It needs some updating.</p> 
     128<p>This class doesn't currently work. It needs some updating. Configuration 
     129entries:</p> 
    129130<ul> 
    130131    <li><b>Class:</b> <tt>dejavu.storage.storeodbc.StorageManagerODBC</tt></li> 
     
    153154<h5>Caching Proxy</h5> 
    154155<p>Use this class to persist Units between client connections. It needs 
    155 another Storage Manager to proxy.</p> 
     156another Storage Manager to proxy. Configuration entries:</p> 
    156157<ul> 
    157158    <li><b>Class:</b> <tt>dejavu.storage.CachingProxy</tt></li> 
    158     <li><b>Next Store:</b> Required. The next Storage Manager in the 
    159         chain.</li> 
     159    <li><b>Next Store:</b> Required. The name of the next Storage Manager 
     160        in the chain.</li> 
    160161    <li><b>Lifetime:</b> Optional. The recurrence string which declares 
    161162        how often to sweep Units out of the in-memory cache.</li> 
     
    167168Storage Manager recalls all Units at once upon the first request, and won't 
    168169recall them again from storage. They are "burned" into memory for the 
    169 lifetime of the application.</p> 
     170lifetime of the application. Configuration entries:</p> 
    170171<ul> 
    171172    <li><b>Class:</b> <tt>dejavu.storage.BurnedProxy</tt></li> 
    172     <li><b>Next Store:</b> Required. The next Storage Manager in the 
    173         chain.</li> 
     173    <li><b>Next Store:</b> Required. The name of the next Storage Manager 
     174        in the chain.</li> 
    174175    <li><b>Lifetime:</b> Optional. The recurrence string which declares 
    175176        how often to sweep Units out of the in-memory cache. In general, 
     
    177178</ul> 
    178179 
     180<h4>Recurrence Values</h4> 
     181<p>In the above Storage Managers, you might be asked to supply a "recurrence 
     182string", which specifies a schedule for a given action. The string you 
     183supply should be one of the following types:</p> 
     184<ul> 
     185    <li><b>By units (intervals):</b> "3 hours" will run every 3 hours. 
     186        "7 days" or "1 week" will run once each week.</li> 
     187    <li><b>Daily:</b> "14:00 each day" will run at 2:00 P.M. every day.</li> 
     188    <li><b>Weekly:</b> "Mon", "Monday", or "Mondays" will run once each 
     189        Monday.</li> 
     190    <li><b>Monthly:</b> "20 each month" will run on the 20th of each month. 
     191        "0 every month" will run on the <i>last</i> day of each month.</li> 
     192</ul> 
     193 
    179194 
    180195</body> 
  • trunk/engines.py

    r21 r22  
    1414    import pickle 
    1515import dejavu 
    16 from dejavu import logic 
     16from dejavu import logic, xray 
    1717import sets 
    18 import xray 
    1918 
    2019 
  • trunk/storage/__init__.py

    r21 r22  
    44import threading 
    55import thread 
    6 import recur 
     6from dejavu import recur 
    77try: 
    88    import cPickle as pickle 
     
    3636     
    3737    def create_storage(self, unitClass): 
    38         raise NotImplementedError 
     38        pass 
    3939     
    4040    def reserve(self, unit): 
  • trunk/storage/storeado.py

    r21 r22  
    1212except ImportError: 
    1313    import pickle 
    14 import recur 
    1514from types import FunctionType 
    1615 
     
    2120 
    2221import dejavu 
    23 from dejavu import storage, codewalk, logic 
     22from dejavu import storage, codewalk, logic, recur 
    2423 
    2524adOpenForwardOnly = 0 
     
    329328     
    330329    def visit_target(self, terms): 
    331 ##        terms.reverse() 
     330        """A target is an AND or OR test.""" 
    332331        comp = self.stack.pop() 
    333332        while terms: 
     
    656655        self.reserve_lock = threading.Lock() 
    657656     
    658     def __del__(self): 
     657    def shutdown(self): 
    659658        if self._connection is not None: 
    660659            self._connection.Close() 
     
    822821                    raise x 
    823822            anRS.Update() 
    824             # Explicitly close here, or save_collection fails on BeginTrans. 
     823            # Need to explicitly close here, or save_collection 
     824            # will fail on BeginTrans. 
    825825            anRS.Close() 
    826826            if cls.__name__ == u'UnitCollection':