Skip to main content

guava_preconditions

This library provides some simple functions from guava

Module guava_preconditions

Functions

checkArgument(expression: bool, errorMessageTemplate: Optional[str] = None, *errorMessageArgs: Any) ‑> None : Ensures the truth of an expression involving one or more parameters to the calling method.

checkElementIndex(index: int, size: int, desc: str = None) ‑> int : Ensures that index specifies a valid element in an array, list or string of size size.

checkNotNull(reference: Optional[~T], errorMessageTemplate: str, *errorMessageArgs: Any) ‑> ~T : Ensures that an object reference passed as a parameter to the calling method is not null.

checkPositionIndex(index: int, size: int, desc: str = None) ‑> int : Ensures that index specifies a valid position in an array, list or string of size size.

checkPositionIndexes(start: int, end: int, size: int) ‑> None : Ensures that start and end specify a valid positions in an array, list or string of size size, and are in order.

checkState(expression: bool, errorMessageTemplate: str = None, *errorMessageArgs: Any) ‑> None : Ensures the truth of an expression involving the state of the calling instance, but not involving any parameters to the calling method.

Classes

IllegalArgumentException(*args, **kwargs) : Common base class for all non-exit exceptions.

### Ancestors (in MRO)

* builtins.Exception
* builtins.BaseException

IllegalStateException(*args, **kwargs) : Common base class for all non-exit exceptions.

### Ancestors (in MRO)

* builtins.Exception
* builtins.BaseException

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

guava_preconditions-0.1.4.tar.gz (3.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

guava_preconditions-0.1.4-py3-none-any.whl (3.4 kB view details)

Uploaded Python 3

File details

Details for the file guava_preconditions-0.1.4.tar.gz.

File metadata

  • Download URL: guava_preconditions-0.1.4.tar.gz
  • Upload date:
  • Size: 3.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.6 CPython/3.9.6 Windows/10

File hashes

Hashes for guava_preconditions-0.1.4.tar.gz
Algorithm Hash digest
SHA256 99088bc06a69e67d0d76e0221fc8850dfd258e083b0fc4a26ebce92eed21130d
MD5 130f61824978acd9233246fa76c33d9c
BLAKE2b-256 53bce84ad7db3fe6215d33abcf6008897db2ffad8566b5ed99276a481bc015f4

See more details on using hashes here.

File details

Details for the file guava_preconditions-0.1.4-py3-none-any.whl.

File metadata

File hashes

Hashes for guava_preconditions-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 c3e4705319ae46e4e694f87b481c745e2cb95c747f596754d830837a50ed81be
MD5 67fbcf42e3d4aab91e4b3cf5fb94422e
BLAKE2b-256 320227fdaa2865b4520030fb13773cf9dd5b67f3d3c43b277f131f789534f675

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.1.4 This release

2 files

0.1.3

2 files

0.1.2

2 files

0.1.1

2 files

0.1.0

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page