Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
Zope
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
Zope
Commits
0c2a6267
Commit
0c2a6267
authored
Feb 12, 1997
by
cici
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
*** empty log message ***
parent
da840167
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
6 deletions
+15
-6
lib/python/SearchIndex/InvertedIndex.py
lib/python/SearchIndex/InvertedIndex.py
+15
-6
No files found.
lib/python/SearchIndex/InvertedIndex.py
View file @
0c2a6267
...
...
@@ -32,7 +32,7 @@ Example usage:
InvertedIndex provides three types of indexes: one non-persistent
index, Index, and two persistent indexes, Persistent and Transactional.
$Id: InvertedIndex.py,v 1.1
0 1997/01/29 16:48:40 chris
Exp $'''
$Id: InvertedIndex.py,v 1.1
1 1997/02/12 18:11:54 cici
Exp $'''
# Copyright
#
# Copyright 1996 Digital Creations, L.C., 910 Princess Anne
...
...
@@ -66,7 +66,7 @@ $Id: InvertedIndex.py,v 1.10 1997/01/29 16:48:40 chris Exp $'''
#
# Limitation Of Liability
#
3
# In no event will DCLC be liable for direct, indirect, special,
# In no event will DCLC be liable for direct, indirect, special,
# incidental, economic, cover, or consequential damages arising
# out of the use of or inability to use this software even if
# advised of the possibility of such damages. Some states do not
...
...
@@ -84,6 +84,9 @@ $Id: InvertedIndex.py,v 1.10 1997/01/29 16:48:40 chris Exp $'''
# (540) 371-6909
#
# $Log: InvertedIndex.py,v $
# Revision 1.11 1997/02/12 18:11:54 cici
# *** empty log message ***
#
# Revision 1.10 1997/01/29 16:48:40 chris
# added list_class argument to Index __init__
#
...
...
@@ -119,7 +122,7 @@ $Id: InvertedIndex.py,v 1.10 1997/01/29 16:48:40 chris Exp $'''
#
#
#
__version__
=
'$Revision: 1.1
0
$'
[
11
:
-
2
]
__version__
=
'$Revision: 1.1
1
$'
[
11
:
-
2
]
import
regex
,
regsub
,
string
,
marshal
...
...
@@ -567,14 +570,14 @@ class PersistentResultList(ResultList, PickleDictionary.Persistent):
class
STPResultList
(
ResultList
,
SingleThreadedTransaction
.
Persistent
):
def
addentry
(
self
,
freq
,
key
):
def
addentry
(
self
,
key
,
*
info
):
'''Add a frequency/key pair to this object'''
ResultList
.
addentry
(
self
,
key
,
info
)
self
.
__changed__
(
1
)
class
Persistent
(
Index
):
class
Persistent
(
Index
,
PickleDictionary
.
Persistent
):
'''
\
An inverted index.
...
...
@@ -708,8 +711,12 @@ class Persistent(Index):
Recover wasted space in the index file.'''
self
.
_index_object
.
pack
()
def
__getinitargs__
(
self
):
return
(
self
.
picklefile
,)
class
Transactional
(
Index
):
class
Transactional
(
Index
,
SingleThreadedTransaction
.
Persistent
):
'''
\
An inverted index.
...
...
@@ -816,6 +823,8 @@ class Transactional(Index):
self
.
_index_object
.
pack
()
def
__getinitargs__
(
self
):
return
(
self
.
picklefile
,)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment