"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "lib/vclib/ccvs/rcsparse/__init__.py" between
viewvc-1.1.28.tar.gz and viewvc-1.2.1.tar.gz

About: ViewVC is a browser interface for CVS and Subversion version control repositories.

__init__.py  (viewvc-1.1.28):__init__.py  (viewvc-1.2.1)
skipping to change at line 13 skipping to change at line 13
# Copyright (C) 1999-2020 The ViewCVS Group. All Rights Reserved. # Copyright (C) 1999-2020 The ViewCVS Group. All Rights Reserved.
# #
# By using this file, you agree to the terms and conditions set forth in # By using this file, you agree to the terms and conditions set forth in
# the LICENSE.html file which can be found at the top level of the ViewVC # the LICENSE.html file which can be found at the top level of the ViewVC
# distribution or at http://viewvc.org/license-1.html. # distribution or at http://viewvc.org/license-1.html.
# #
# For more information, visit http://viewvc.org/ # For more information, visit http://viewvc.org/
# #
# ----------------------------------------------------------------------- # -----------------------------------------------------------------------
"""This package provides parsing tools for RCS files.""" """This package provides parsing tools for RCS files.
To use this package, first create a subclass of Sink. This should
declare all the callback methods you care about. Create an instance
of your class, and open() the RCS file you want to read. Then call
parse() to parse the file.
"""
# Make the "Sink" class and the various exception classes visible in this
# scope. That way, applications never need to import any of the
# sub-packages.
from common import * from common import *
try: try:
from tparse import parse from tparse import parse
except ImportError: except ImportError:
try: try:
from texttools import Parser from texttools import Parser
except ImportError: except ImportError:
from default import Parser from default import Parser
def parse(file, sink): def parse(file, sink):
"""Parse an RCS file.
Parameters: FILE is the file object to parse. (I.e. an object of the
built-in Python type "file", usually created using Python's built-in
"open()" function). It should be opened in binary mode.
SINK is an instance of (some subclass of) Sink. It's methods will be
called as the file is parsed; see the definition of Sink for the
details.
"""
return Parser().parse(file, sink) return Parser().parse(file, sink)
 End of changes. 3 change blocks. 
1 lines changed or deleted 19 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)