!C99Shell v. 2.0 [PHP 7 Update] [25.02.2019]!

Software: Apache/2.2.16 (Debian). PHP/5.3.3-7+squeeze19 

uname -a: Linux mail.tri-specialutilitydistrict.com 2.6.32-5-amd64 #1 SMP Tue May 13 16:34:35 UTC
2014 x86_64
 

uid=33(www-data) gid=33(www-data) groups=33(www-data) 

Safe-mode: OFF (not secure)

/usr/share/pyshared/epsilon/   drwxr-xr-x
Free 130.06 GB of 142.11 GB (91.52%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     view.py (1.5 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
# -*- test-case-name: epsilon.test.test_view -*-

"""
Utility functionality for creating wrapping sequences so as to transform
their indices in some manner.
"""

class SlicedView(object):
    """
    Wrapper around a sequence which allows indexing and non-extended
    slicing, adjusting all indices using a transformation defined by a
    L{slice} object.

    For example::

        s = ['a', 'b']
        t = SlicedView(s, slice(1, None))
        t[0] == 'b'

    @ivar sequence: The underlying sequence from which to retrieve elements.
    @ivar bounds: A C{slice} instance defining the boundaries of this view.
    """

    def __init__(self, sequence, bounds):
        self.sequence = sequence
        self.bounds = bounds


    def _getIndices(self):
        start, stop, step = self.bounds.indices(len(self.sequence))
        indices = xrange(start, stop, step)
        return indices


    def __getitem__(self, index):
        """
        Compute the index in the underlying sequence of the given view index
        and return the corresponding element.

        @raise IndexError: If C{index} is out of bounds for the view.
        @raise ValueError: If C{self.bounds} is out of bounds for
        C{self.sequence}.
        """
        if isinstance(index, slice):
            return SlicedView(self, index)
        return self.sequence[self._getIndices()[index]]


    def __len__(self):
        """
        Compute the length of this view onto the sequence and return it.
        """
        return len(self._getIndices())

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 2.0 [PHP 7 Update] [25.02.2019] maintained by KaizenLouie | C99Shell Github | Generation time: 0.0083 ]--