/usr/lib/python2.7/dist-packages/Ice/ImplicitContext_ice.py is in python-zeroc-ice 3.7.0-5.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 | # -*- coding: utf-8 -*-
# **********************************************************************
#
# Copyright (c) 2003-2017 ZeroC, Inc. All rights reserved.
#
# This copy of Ice is licensed to you under the terms described in the
# ICE_LICENSE file included in this distribution.
#
# **********************************************************************
#
# Ice version 3.7.0
#
# <auto-generated>
#
# Generated from file `ImplicitContext.ice'
#
# Warning: do not edit this file.
#
# </auto-generated>
#
from sys import version_info as _version_info_
import Ice, IcePy
import Ice.LocalException_ice
import Ice.Current_ice
# Included module Ice
_M_Ice = Ice.openModule('Ice')
# Start of module Ice
__name__ = 'Ice'
if 'ImplicitContext' not in _M_Ice.__dict__:
_M_Ice.ImplicitContext = Ice.createTempClass()
class ImplicitContext(object):
"""
An interface to associate implict contexts with communicators.
When you make a remote invocation without an explicit context parameter,
Ice uses the per-proxy context (if any) combined with the ImplicitContext
associated with the communicator.
Ice provides several implementations of ImplicitContext. The implementation
used depends on the value of the Ice.ImplicitContext property.
None (default)
No implicit context at all.
PerThread
The implementation maintains a context per thread.
Shared
The implementation maintains a single context shared by all threads.
ImplicitContext also provides a number of operations to create, update or retrieve
an entry in the underlying context without first retrieving a copy of the entire
context. These operations correspond to a subset of the java.util.Map methods,
with java.lang.Object replaced by string and null replaced by the empty-string.
"""
def __init__(self):
if Ice.getType(self) == _M_Ice.ImplicitContext:
raise RuntimeError('Ice.ImplicitContext is an abstract class')
def getContext(self):
"""
Get a copy of the underlying context.
Returns: A copy of the underlying context.
"""
raise NotImplementedError("method 'getContext' not implemented")
def setContext(self, newContext):
"""
Set the underlying context.
Arguments:
newContext -- The new context.
"""
raise NotImplementedError("method 'setContext' not implemented")
def containsKey(self, key):
"""
Check if this key has an associated value in the underlying context.
Arguments:
key -- The key.
Returns: True if the key has an associated value, False otherwise.
"""
raise NotImplementedError("method 'containsKey' not implemented")
def get(self, key):
"""
Get the value associated with the given key in the underlying context.
Returns an empty string if no value is associated with the key.
containsKey allows you to distinguish between an empty-string value and
no value at all.
Arguments:
key -- The key.
Returns: The value associated with the key.
"""
raise NotImplementedError("method 'get' not implemented")
def put(self, key, value):
"""
Create or update a key/value entry in the underlying context.
Arguments:
key -- The key.
value -- The value.
Returns: The previous value associated with the key, if any.
"""
raise NotImplementedError("method 'put' not implemented")
def remove(self, key):
"""
Remove the entry for the given key in the underlying context.
Arguments:
key -- The key.
Returns: The value associated with the key, if any.
"""
raise NotImplementedError("method 'remove' not implemented")
def __str__(self):
return IcePy.stringify(self, _M_Ice._t_ImplicitContext)
__repr__ = __str__
_M_Ice._t_ImplicitContext = IcePy.defineValue('::Ice::ImplicitContext', ImplicitContext, -1, (), False, True, None, ())
ImplicitContext._ice_type = _M_Ice._t_ImplicitContext
_M_Ice.ImplicitContext = ImplicitContext
del ImplicitContext
# End of module Ice
|