~ubuntu-branches/debian/sid/botan/sid

« back to all changes in this revision

Viewing changes to misc/python/botan/__init__.py

  • Committer: Package Import Robot
  • Author(s): Laszlo Boszormenyi (GCS)
  • Date: 2018-03-01 22:23:25 UTC
  • mfrom: (1.2.2)
  • Revision ID: package-import@ubuntu.com-20180301222325-7p7vc45gu3hta34d
Tags: 2.4.0-2
* Don't remove .doctrees from the manual if it doesn't exist.
* Don't specify parallel to debhelper.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
from _botan import *
2
 
 
3
 
# Initialize the library when the module is imported
4
 
init = LibraryInitializer()
5
 
 
6
 
class SymmetricKey(OctetString):
7
 
    pass
8
 
 
9
 
class InitializationVector(OctetString):
10
 
    pass
11
 
 
12
 
def Filter(name, key = None, iv = None, dir = None):
13
 
    if key != None and iv != None and dir != None:
14
 
        return make_filter(name, key, iv, dir)
15
 
    elif key != None and dir != None:
16
 
        return make_filter(name, key, dir)
17
 
    elif key != None:
18
 
        return make_filter(name, key)
19
 
    else:
20
 
        return make_filter(name)
21
 
 
22
 
def Pipe(*filters):
23
 
    pipe = PipeObj()
24
 
    for filter in filters:
25
 
        if filter:
26
 
            pipe.append(filter)
27
 
    return pipe