dosomething / mb-toolbox
A library of functionality shared between the components that make up the Quicksilver system: https://github.com/DoSomething/message-broker. Some of the functionality is DoSomething.org specific.
Installs: 908
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 12
Forks: 0
Open Issues: 4
pkg:composer/dosomething/mb-toolbox
Requires
- php: >= 5.3.0
 - dosomething/mobilecommons-php: 1.0.*
 - dosomething/stathat: 2.*
 - drewm/mailchimp-api: 1.*
 - richardfullmer/rabbitmq-management-api: 1.0.*
 
Requires (Dev)
- phpunit/phpunit: 4.4.*
 - squizlabs/php_codesniffer: 2.*
 
- dev-master
 - 0.13.2
 - 0.13.1
 - 0.13.0
 - 0.12.6
 - 0.12.5
 - 0.12.4
 - 0.12.3
 - 0.12.0
 - 0.11.3
 - 0.11.2
 - 0.11.0
 - 0.10.6
 - 0.10.5
 - 0.10.4
 - 0.10.3
 - 0.10.2
 - 0.10.1
 - 0.10.0
 - 0.9.13
 - 0.9.12
 - 0.9.11
 - 0.9.9
 - 0.9.8
 - 0.9.7
 - 0.9.6
 - 0.9.5
 - 0.9.4
 - 0.9.3
 - 0.9.2
 - 0.9.1
 - 0.8.21
 - 0.8.20
 - 0.8.19
 - 0.8.17
 - 0.8.16
 - 0.8.15
 - 0.8.14
 - 0.8.12
 - 0.8.11
 - 0.8.10
 - 0.8.9
 - 0.8.8
 - 0.8.7
 - 0.8.5
 - 0.8.4
 - 0.8.3
 - 0.8.2
 - 0.8.1
 - 0.8.0
 - 0.7.14
 - 0.7.13
 - 0.7.12
 - 0.7.11
 - 0.7.10
 - 0.7.8
 - 0.7.7
 - 0.7.6
 - 0.7.5
 - 0.7.4
 - 0.7.3
 - 0.7.2
 - 0.7.1
 - 0.7.0
 - 0.6.2
 - 0.6.1
 - 0.6.0
 - 0.5.1
 - 0.5.0
 - 0.4.9
 - 0.4.8
 - 0.4.7
 - 0.4.6
 - 0.4.5
 - 0.4.4
 - 0.4.3
 - 0.4.2
 - 0.4.1
 - 0.4.0
 - 0.3.25
 - 0.3.24
 - 0.3.23
 - 0.3.22
 - 0.3.21
 - 0.3.20
 - 0.3.19
 - 0.3.18
 - 0.3.17
 - 0.3.16
 - 0.3.15
 - 0.3.14
 - 0.3.13
 - 0.3.12
 - 0.3.11
 - 0.3.10
 - 0.3.9
 - 0.3.8
 - 0.3.7
 - 0.3.6
 - 0.3.3
 - 0.3.2
 - 0.3.1
 - 0.3.0
 - 0.2.3
 - 0.2.2
 - 0.2.1
 - 0.2.0
 - 0.1.4
 - 0.1.3
 - 0.1.2
 - 0.1.1
 - 0.1.0
 - dev-mailchimp-v3
 - dev-Issue21-Test_coverage
 - dev-q
 - dev-Issue49-GET_image
 - dev-Issue43-Abstract_authenticate
 
This package is not auto-updated.
Last update: 2020-01-24 15:20:22 UTC
README
A collection of classes and related methods that provide common functionality for many of the producers and consumers applications within the Message Broker system.
####class MB_Toolbox Methods
- isDSAffiliate($targetCountyCode)
 - createDrupalUser($user)
 - getPasswordResetURL($uid)
 - getDSMemberCount()
 - subscriptionsLinkGenerator($targetEmail)
 - curlPOST($curlUrl, $post)
 - curlPOSTauth($curlUrl, $post)
 - curlDELETE($curlUrl)
 - curlDELETEauth($curlUrl)
 - authenticate()
 
####class MB_Toolbox_cURL Methods
- curlGET($curlUrl, $isAuth = FALSE)
 - curlGETauth($curlUrl)
 - curlGETImage($imageUrl)
 - authenticate()
 
####class MB_Toolbox_BaseConsumer
@param string $targetMBconfig
The Message Broker object used to interface the RabbitMQ server exchanges and related queues.
$targetMBconfig = 'messageBroker'
Methods
- consumeQueue($payload)
 - throttle($maxMessageRate) abstract protected
 - setter($message)
 - canProcess()
 - process()
 
####class MB_MailChimp($settings)
@param array $settings
Settings from external services - Mailchimp
Methods
- submitBatchToMailChimp($composedBatch)
 - submitToMailChimp($composedItem)
 
####class MB_Configuration
@param array $source
  The source of configuration settings. This can be from a file or an endpoint.
@param array $applicationSettings
  General application settings for use by all classes in application.
Methods
- exchangeSettings($targetExchange)
 
####class MB_Configuration
@param array $settings
  Configuration settings defined by the application script accessing the library.
Methods
- private __construct()
 - static getInstance()
 - setProperty($key, $value)
 - getProperty($key)
 - constructRabbitConfig($targetExchange, $targetQueues = NULL)
 - exchangeSettings($targetExchange)
 - gatherSettings($targetSetting)
 
####Gulp Support
Use path directly to gulp ./node_modules/.bin/gulp or add alias to system config (.bash_profile) in alias gulp='./node_modules/.bin/gulp'
###Linting
gulp lint
###Linting
gulp test
See gulpfile.js for configuration.
PHP CodeSniffer
- 
php ./vendor/bin/phpcs --standard=./ruleset.xml --colors -s src testsListing of all coding volations by file. - 
php ./vendor/bin/phpcbf --standard=./ruleset.xml --colors src testsAutomated processing of files to adjust to meeting coding standards.