Skip to main content

A simple to use python app for generating data of different types and configurations.

Project description

Data Factory aka 'dfac'

A simple to use python app for generating data of different types and configurations. Can be run as a module or used as library.

Usage Instruction as app

Usage: dfac.py [OPTION...] [OUTPUT]... Datafactory generates random string of data for testing and other purposes.

Examples:

dfac.py -t a -v n

dfac.py -t s -v u -x [filename]

DESCRIPTION Datafactory generates random string of data for testing and other purposes.

OPTIONS -t, --datatype Option for the data type to be generated. Below are the available datatypes.

Data Types
    s, string 
        print out string as data type
    a, array 
        print out array as data type 

-v, --valuetype Option for the type of value to be generated. Below are the available value type options.

Value Types
    For String data type
        n, alphanumeric 
            print out string containing random values of latin alphabet and numbers
        a, alphabet
            print out random string alphabet in a mix of uppercase and lowercase.
        u, upper
            print out random string of alphabet in uppercase.
        l, lower
            print out random string of alphabet in lowercase.
        y, alphasymbolic
            print out random mix of alphabet and symbols.

    For Array data type
        n, alphanumeric
            print out array containing strings with random alphabets and numbers.
        a, alphabet
            print out array containing strings with random alphabets uppercase and lowercase.
        u, upper
            print out array containing strings with random alphabets uppercase.
        l, lower
            print out array containing strings with random alphabets containing lowercase.
        y, alphasymbolic
            print out array containing strings with random alphabets and symbols.
        i, integer
            print out array containing strings with random integer.
        d, decimal
            print out array containing strings with random decimal numbers.
        o, symbolic
            print out array containing string with random symbols.

-0, --length Option to print out length of string or array.

-L, --low (For Array types) Option to set minimum length of value.

-H, --high (For Array types) Option to set maximum length of value.

-x, --file Print out generated value to file, if no name is provided output.txt is used.

-h, --help Print this help text.

Usage Instruction as library

Examples:

from core.StringGenerator import StringGenerator

object=StringGenerator(7,'AlphaNumeric')

object.generate()

Example Output:

hDCyDM6

Class Available:
    a. StringGenerator(length, type) [from core.StringGenerator]
    b .ArrayGenerator(length,type, low, high) [from core.ArrayGenerator]
        low = lowest length of the data generated
        high = highest length of the data generated  

Types available for ArrayGenerator: 'AlphaNumeric', 'Alphabet', 'Alphabet_Upper', 'Alphabet_Lower', 'AlphaSymbolic', 'Integer', 'Decimal', 'Symbolic'

Types available for StringGenerator: 'AlphaNumeric', 'Alphabet', 'Alphabet_Upper', 'Alphabet_Lower', 'AlphaSymbolic'

Project details


Download files

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

Source Distribution

dfac-1.0.4.tar.gz (7.0 kB view details)

Uploaded Source

Built Distribution

dfac-1.0.4-py3-none-any.whl (11.4 kB view details)

Uploaded Python 3

File details

Details for the file dfac-1.0.4.tar.gz.

File metadata

  • Download URL: dfac-1.0.4.tar.gz
  • Upload date:
  • Size: 7.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.5

File hashes

Hashes for dfac-1.0.4.tar.gz
Algorithm Hash digest
SHA256 32e8bd849d0cf34bcca635f20fcd21d83d25308a560c2c392adf8246c7e0611f
MD5 6c01f09aceec69c198e08db77ab4618e
BLAKE2b-256 d3a677fbf2d30d6545a42145bfaa77a40ec041719e6a0d9766fd4ec4cab8688e

See more details on using hashes here.

File details

Details for the file dfac-1.0.4-py3-none-any.whl.

File metadata

  • Download URL: dfac-1.0.4-py3-none-any.whl
  • Upload date:
  • Size: 11.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.5

File hashes

Hashes for dfac-1.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 05a098125e246a439a5de6f6e167fcfb9a8f80feada8a5a22752b0fcfbca0c49
MD5 34b84478d4b2c69d90235cfa65a23c78
BLAKE2b-256 2267e1099f4a87bbdca12619e23b849d3c052bac6baecee467dcc38d9567a8b7

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page