Softpedia
 


SCRIPTS CATEGORIES:



NEWS ARCHIVE >>
SOFTPEDIA REVIEWS >>
MEET THE EDITORS >>
WEEK'S BEST
  • Koken 0.8.2
  • ContentBox 1.5.2
  • jQPlayer 0.5.2
  • SPOILER ALERT! 0.0.2
  • jQuery Mask Plugin 0.9.0
  • Easing Slider 2.1.2
  • Btapp.js 0.2.0
  • WiiFlash 0.4.5
  • Breeze.js 1.3.3
  • TinyMCE Templates 3.0.2
  • Home > Scripts > Programming Methods and Algorithms

    Quickslice decorator 1.3

    Download button


    Downloads: 1,329  Tell us about an update
    User Rating:
    Rated by:
    Fair (2.8/5)
    21 user(s)
    Developer:

    Website:

    License / Price:

    Platforms:

    Databases:

    Language:

    Last Updated:

    Category:
    Brian Beck | More scripts
    aspn.activestate.com
    Other Free / Open Source License - Python License 

    Windows / Linux / Mac OS / BSD / Solaris
    N/A
    Python
    June 7th, 2007, 12:11 GMT
    C: \ Programming Methods and Algorithms

     Read user reviews (0)  Refer to a friend  Subscribe

    Quickslice decorator description

    Quickslice decorator script defines a decorator that allows for an abbreviated slice syntax in function arguments: {start:end}.

    This script defines a decorator that allows for an abbreviated slice syntax in function arguments: {start:end}. Step is notsupported. Valid quickslices are dictionaries with a single integer key which has an integer value.

    Arguments can be strings or integers, and indicate the positional or keyword arguments that should be checked for possible quickslices.

    By default, no exception is raised if the indicated arguments turn out not to be quickslices (consider __getitem__, which can accept slices or integers). To change this behavior, set the keyword argument 'argAssert' to True.

    The optional 'argSearch' keyword argument can be True or False, and specifies whether or not to check if every argument of the decorated function is a 'quickslice' rather than just the indicated arguments. The default is False.



    TAGS:

    function decorator | function arguments | function syntax change | function | decorator | syntax

    Go to top

    WindowsGamesDriversMacLinuxScriptsMobileHandheldNews

    SUBMIT PROGRAM   |   ADVERTISE   |   GET HELP   |   SEND US FEEDBACK   |   RSS FEEDS   |   UPDATE YOUR SOFTWARE   |   ROMANIAN FORUM