semvec/pypi-packages huggingface dataset:
protecc 0.0.2
Access modifiers for python

# protecc
Access modifiers for python.


## Setup

#### PIP install

```bash
pip install protecc
```

#### From the source

```bash
git clone https://github.com/avinashshenoy97/protecc
cd protecc
python setup.py install
```

## Usage

### Old-Style Classes
Inherit from/extend the `protecc` class.

```python
from protecc import protecc

class regulatedClass(protecc):
    def __init__(self):
        self.publicVariable = 'public value'
        self._privateVariable = 'private value'

    def publicMethod(self):
        return True

    def __privateMethod(self):
        return True

    def getPrivateVariable(self):
        return self._privateVariable

    def privateMethodProxy(self):
        return self.__privateMethod()
```

### New-Style Classes (type)

If you prefer metaclass (for better readability/what not), use `metaProtecc`.

```python
class metaRegulatedClass(metaclass=metaProtecc):
    def __init__(self):
        self.publicVariable = 'public value'
        self._privateVariable = 'private value'

    def publicMethod(self):
        return True

    def __privateMethod(self):
        return True

    def getPrivateVariable(self):
        return self._privateVariable

    def privateMethodProxy(self):
        return self.__privateMethod()
```

When accessing "private" methods (i.e, methods that begin with either a single or two underscores), this exception is raised

```python
>>> r = regulatedClass()
>>> r.__privateMethod()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Users/avinashshenoy/STUFF/projects/protecc/protecc.py", line 23, in __protecced_getattribute__
    raise AccessException('Cannot access ' + varType + ' member ' + name) from None
protecc.AccessException: Cannot access private member __privateMethod
```

Private methods can still be accessed from within other class methods, as is expected:

```python
>>> r = regulatedClass()
>>> r.privateMethodProxy()
True
```

### Note

- This is, by no means, fool-proof access protection.
- "Private members" are those members whose names are mangled by Python, as per PEP 8 conventions, i.e, starting with 2 underscores and having not more than one trailing underscore.
- Additionally, "protected members" are those members whose names are preceded by a single underscores. These members cannot be accessed from outside the class as well, as is expected.

## Primary Contributors

| | |
|:-:|:-:|
|<img src="https://github.com/avinashshenoy97.png" width="48">  | [Avinash Shenoy](https://github.com/avinashshenoy97) |

#### License

This project is released under the [MIT License](https://github.com/avinashshenoy97/protecc/blob/master/LICENSE).
aws-cdk.runtime-values 0.35.0
Runtime values support for the AWS CDK
Requires Python: >=3.6

## Runtime Values
<!--BEGIN STABILITY BANNER-->

---

![Stability: Deprecated](https://img.shields.io/badge/stability-Deprecated-critical.svg?style=for-the-badge)

> This API may emit warnings. Backward compatibility is not guaranteed.

---
<!--END STABILITY BANNER-->

This module has been deprecated. Use environment variables or SSM parameters to publish values to runtime code.
aws-cdk.aws-quickstarts 0.35.0
AWS Quickstarts for the CDK
Requires Python: >=3.6

## AWS Quickstarts for the CDK
<!--BEGIN STABILITY BANNER-->

---

![Stability: Deprecated](https://img.shields.io/badge/stability-Deprecated-critical.svg?style=for-the-badge)

> This API may emit warnings. Backward compatibility is not guaranteed.

---
<!--END STABILITY BANNER-->

This module has been deprecated. Use `@aws-cdk/aws-cloudformation.CfnStack` instead.

This module is part of the [AWS Cloud Development Kit](https://github.com/awslabs/aws-cdk) project.
aws-cdk.assets-docker 0.35.0
deprecated: moved to @aws-cdk/aws-ecr-assets
Requires Python: >=3.6

# AWS CDK Docker Image Assets
<!--BEGIN STABILITY BANNER-->

---

![Stability: Deprecated](https://img.shields.io/badge/stability-Deprecated-critical.svg?style=for-the-badge)

> This API may emit warnings. Backward compatibility is not guaranteed.

---
<!--END STABILITY BANNER-->

Deprecated: @aws-cdk/aws-ecr-assets
django-random-image-from-folder 0.0.3
Django Random Image From Folder is a simple app to load a random image from a specified directory.

Django Random Image From Folder
=================

Django Random Image From Folder is a simple app to load a random image from a specified directory.

It's trivially simple but I've needed it a few times so I thought maybe others have too.

Installation
************

Add 'random_image' to INSTALLED_APPS.

Settings
************

All settings are optional

**RANDOM_IMAGE_DIR**

Default: Not defined

A path to the directory from which to load the random images. Relative to MEDIA_ROOT.

Note: Passing a path to the template tag will always override the RANDOM_IMAGE_DIR setting.

**RANDOM_IMAGE_EXTENSIONS**

Default: ['.jpg','.jpeg','.png','.gif']

A list containing extensions to be considered when choosing a random image.


Usage
************

Pass in a path to the image directory::

    {% load random_image %}
    <img src="{{ MEDIA_URL}}{% random_image "path/to/image/dir" %}">

The path to the image directory should be relative to MEDIA_ROOT.

or if you have added RANDOM_IMAGE_DIR to your settings file::

   {% load random_image  %}
   <img src="{{ MEDIA_URL }}{% random_image %}">


That's it! Simple as it gets.