- Minor changes to comments

git-svn-id: http://galileo.dmi.unict.it/svn/relational/trunk@313 014f5005-505e-4b48-8d0a-63407b615a7c
master
LtWorf 2011-10-08 17:04:07 +07:00
parent 5f764152c8
commit 4c5915e854
4 changed files with 6 additions and 5 deletions

@ -48,6 +48,8 @@ def check_latest_version():
#html #html
s=r.read() s=r.read()
if len(s)==0:
return None
l= s[s.find('<ul>')+4:s.find('</ul>')].split('\n') l= s[s.find('<ul>')+4:s.find('</ul>')].split('\n')
l.sort() l.sort()

@ -50,8 +50,7 @@ def optimize_all(expression,rels,specific=True,general=True,debug=None):
general: True if it has to perform general optimizations general: True if it has to perform general optimizations
debug: if a list is provided here, after the end of the function, it debug: if a list is provided here, after the end of the function, it
will contain the query repeated many times to show the performed will contain the query repeated many times to show the performed
steps. Of course don't call optimize_all(... ,debug=[]) because it steps.
would make no sense
Return value: this will return an optimized version of the expression''' Return value: this will return an optimized version of the expression'''
if isinstance(expression,str): if isinstance(expression,str):

@ -85,7 +85,7 @@ class node (object):
'''Expression from right to left, searching for binary operators '''Expression from right to left, searching for binary operators
this means that binary operators have lesser priority than this means that binary operators have lesser priority than
unary operators. unary operators.
It find the operator with lesser priority, uses it as root of this It finds the operator with lesser priority, uses it as root of this
(sub)tree using everything on its left as left parameter (so building (sub)tree using everything on its left as left parameter (so building
a left subtree with the part of the list located on left) and doing a left subtree with the part of the list located on left) and doing
the same on right. the same on right.

@ -129,7 +129,7 @@ class relation (object):
def product (self,other): def product (self,other):
'''Cartesian product, attributes must be different to avoid collisions '''Cartesian product, attributes must be different to avoid collisions
Doing this operation on relations with colliding attributes will Doing this operation on relations with colliding attributes will
cause the return of a None value. cause an exception.
It is possible to use rename on attributes and then use the product''' It is possible to use rename on attributes and then use the product'''
if (self.__class__!=other.__class__)or(self.header.sharedAttributes(other.header)!=0): if (self.__class__!=other.__class__)or(self.header.sharedAttributes(other.header)!=0):