diff --git a/.env.travis b/.env.travis new file mode 100644 index 0000000..1258c68 --- /dev/null +++ b/.env.travis @@ -0,0 +1,10 @@ +APP_ENV=testing +APP_KEY=SomeRandomStringSomeRandomString + +DB_CONNECTION=testing +DB_TEST_USERNAME=root +DB_TEST_PASSWORD= + +CACHE_DRIVER=array +SESSION_DRIVER=array +QUEUE_DRIVER=sync diff --git a/.php_cs b/.php_cs new file mode 100644 index 0000000..f04b9bc --- /dev/null +++ b/.php_cs @@ -0,0 +1,25 @@ +exclude($excluded_folders) + ->notName('AcceptanceTester.php') + ->notName('FunctionalTester.php') + ->notName('UnitTester.php') + ->in(__DIR__); +; +return PhpCsFixer\Config::create() + ->setRules(array( + '@Symfony' => true, + 'binary_operator_spaces' => ['align_double_arrow' => true], + 'array_syntax' => ['syntax' => 'short'], + 'linebreak_after_opening_tag' => true, + 'not_operator_with_successor_space' => true, + 'ordered_imports' => true, + 'phpdoc_order' => true, + )) + ->setFinder($finder) +; diff --git a/.styleci.yml b/.styleci.yml new file mode 100644 index 0000000..2b807d3 --- /dev/null +++ b/.styleci.yml @@ -0,0 +1,18 @@ +preset: laravel + +enabled: + - alpha_ordered_imports + +disabled: + - length_ordered_imports + +finder: + exclude: + - "tests" + - "node_modules" + - "storage" + - "vendor" + not-name: + - "AcceptanceTester.php" + - "FunctionalTester.php" + - "UnitTester.php" diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..184224a --- /dev/null +++ b/.travis.yml @@ -0,0 +1,28 @@ +language: php + +php: + - 7.2 + +before_script: + - cp .env.travis .env + - composer self-update + - composer install --prefer-source --no-interaction --dev + - php artisan key:generate + - php artisan migrate + +before_install: + - mysql -e 'CREATE DATABASE homestead;' + +services: + - mysql + +addons: + apt: + sources: + - mysql-5.7-trusty + packages: + - mysql-server + +dist: trusty + +sudo: required \ No newline at end of file diff --git a/_ide_helper.php b/_ide_helper.php index 280dfd2..81b5480 100644 --- a/_ide_helper.php +++ b/_ide_helper.php @@ -8,2400 +8,2598 @@ */ namespace { - exit("This file should not be included, only analyzed by your IDE"); + exit('This file should not be included, only analyzed by your IDE'); - class App extends \Illuminate\Support\Facades\App{ - + class App extends \Illuminate\Support\Facades\App + { /** * Get the version number of the application. * - * @return string - * @static + * @return string + * @static */ - public static function version(){ + public static function version() + { return \Illuminate\Foundation\Application::version(); } - + /** * Run the given array of bootstrap classes. * * @param array $bootstrappers - * @return void - * @static + * @return void + * @static */ - public static function bootstrapWith($bootstrappers){ + public static function bootstrapWith($bootstrappers) + { \Illuminate\Foundation\Application::bootstrapWith($bootstrappers); } - + /** * Register a callback to run after loading the environment. * * @param \Closure $callback - * @return void - * @static + * @return void + * @static */ - public static function afterLoadingEnvironment($callback){ + public static function afterLoadingEnvironment($callback) + { \Illuminate\Foundation\Application::afterLoadingEnvironment($callback); } - + /** * Register a callback to run before a bootstrapper. * * @param string $bootstrapper * @param \Closure $callback - * @return void - * @static + * @return void + * @static */ - public static function beforeBootstrapping($bootstrapper, $callback){ + public static function beforeBootstrapping($bootstrapper, $callback) + { \Illuminate\Foundation\Application::beforeBootstrapping($bootstrapper, $callback); } - + /** * Register a callback to run after a bootstrapper. * * @param string $bootstrapper * @param \Closure $callback - * @return void - * @static + * @return void + * @static */ - public static function afterBootstrapping($bootstrapper, $callback){ + public static function afterBootstrapping($bootstrapper, $callback) + { \Illuminate\Foundation\Application::afterBootstrapping($bootstrapper, $callback); } - + /** * Determine if the application has been bootstrapped before. * - * @return bool - * @static + * @return bool + * @static */ - public static function hasBeenBootstrapped(){ + public static function hasBeenBootstrapped() + { return \Illuminate\Foundation\Application::hasBeenBootstrapped(); } - + /** * Set the base path for the application. * * @param string $basePath - * @return $this - * @static + * @return $this + * @static */ - public static function setBasePath($basePath){ + public static function setBasePath($basePath) + { return \Illuminate\Foundation\Application::setBasePath($basePath); } - + /** * Get the path to the application "app" directory. * - * @return string - * @static + * @return string + * @static */ - public static function path(){ + public static function path() + { return \Illuminate\Foundation\Application::path(); } - + /** * Get the base path of the Laravel installation. * - * @return string - * @static + * @return string + * @static */ - public static function basePath(){ + public static function basePath() + { return \Illuminate\Foundation\Application::basePath(); } - + /** * Get the path to the bootstrap directory. * - * @return string - * @static + * @return string + * @static */ - public static function bootstrapPath(){ + public static function bootstrapPath() + { return \Illuminate\Foundation\Application::bootstrapPath(); } - + /** * Get the path to the application configuration files. * - * @return string - * @static + * @return string + * @static */ - public static function configPath(){ + public static function configPath() + { return \Illuminate\Foundation\Application::configPath(); } - + /** * Get the path to the database directory. * - * @return string - * @static + * @return string + * @static */ - public static function databasePath(){ + public static function databasePath() + { return \Illuminate\Foundation\Application::databasePath(); } - + /** * Set the database directory. * * @param string $path - * @return $this - * @static + * @return $this + * @static */ - public static function useDatabasePath($path){ + public static function useDatabasePath($path) + { return \Illuminate\Foundation\Application::useDatabasePath($path); } - + /** * Get the path to the language files. * - * @return string - * @static + * @return string + * @static */ - public static function langPath(){ + public static function langPath() + { return \Illuminate\Foundation\Application::langPath(); } - + /** * Get the path to the public / web directory. * - * @return string - * @static + * @return string + * @static */ - public static function publicPath(){ + public static function publicPath() + { return \Illuminate\Foundation\Application::publicPath(); } - + /** * Get the path to the storage directory. * - * @return string - * @static + * @return string + * @static */ - public static function storagePath(){ + public static function storagePath() + { return \Illuminate\Foundation\Application::storagePath(); } - + /** * Set the storage directory. * * @param string $path - * @return $this - * @static + * @return $this + * @static */ - public static function useStoragePath($path){ + public static function useStoragePath($path) + { return \Illuminate\Foundation\Application::useStoragePath($path); } - + /** * Get the path to the environment file directory. * - * @return string - * @static + * @return string + * @static */ - public static function environmentPath(){ + public static function environmentPath() + { return \Illuminate\Foundation\Application::environmentPath(); } - + /** * Set the directory for the environment file. * * @param string $path - * @return $this - * @static + * @return $this + * @static */ - public static function useEnvironmentPath($path){ + public static function useEnvironmentPath($path) + { return \Illuminate\Foundation\Application::useEnvironmentPath($path); } - + /** * Set the environment file to be loaded during bootstrapping. * * @param string $file - * @return $this - * @static + * @return $this + * @static */ - public static function loadEnvironmentFrom($file){ + public static function loadEnvironmentFrom($file) + { return \Illuminate\Foundation\Application::loadEnvironmentFrom($file); } - + /** * Get the environment file the application is using. * - * @return string - * @static + * @return string + * @static */ - public static function environmentFile(){ + public static function environmentFile() + { return \Illuminate\Foundation\Application::environmentFile(); } - + /** * Get the fully qualified path to the environment file. * - * @return string - * @static + * @return string + * @static */ - public static function environmentFilePath(){ + public static function environmentFilePath() + { return \Illuminate\Foundation\Application::environmentFilePath(); } - + /** * Get or check the current application environment. * * @param mixed - * @return string|bool - * @static + * @return string|bool + * @static */ - public static function environment(){ + public static function environment() + { return \Illuminate\Foundation\Application::environment(); } - + /** * Determine if application is in local environment. * - * @return bool - * @static + * @return bool + * @static */ - public static function isLocal(){ + public static function isLocal() + { return \Illuminate\Foundation\Application::isLocal(); } - + /** * Detect the application's current environment. * * @param \Closure $callback - * @return string - * @static + * @return string + * @static */ - public static function detectEnvironment($callback){ + public static function detectEnvironment($callback) + { return \Illuminate\Foundation\Application::detectEnvironment($callback); } - + /** * Determine if we are running in the console. * - * @return bool - * @static + * @return bool + * @static */ - public static function runningInConsole(){ + public static function runningInConsole() + { return \Illuminate\Foundation\Application::runningInConsole(); } - + /** * Determine if we are running unit tests. * - * @return bool - * @static + * @return bool + * @static */ - public static function runningUnitTests(){ + public static function runningUnitTests() + { return \Illuminate\Foundation\Application::runningUnitTests(); } - + /** * Register all of the configured providers. * - * @return void - * @static + * @return void + * @static */ - public static function registerConfiguredProviders(){ + public static function registerConfiguredProviders() + { \Illuminate\Foundation\Application::registerConfiguredProviders(); } - + /** * Register a service provider with the application. * * @param \Illuminate\Support\ServiceProvider|string $provider * @param array $options * @param bool $force - * @return \Illuminate\Support\ServiceProvider - * @static + * @return \Illuminate\Support\ServiceProvider + * @static */ - public static function register($provider, $options = array(), $force = false){ + public static function register($provider, $options = [], $force = false) + { return \Illuminate\Foundation\Application::register($provider, $options, $force); } - + /** * Get the registered service provider instance if it exists. * * @param \Illuminate\Support\ServiceProvider|string $provider - * @return \Illuminate\Support\ServiceProvider|null - * @static + * @return \Illuminate\Support\ServiceProvider|null + * @static */ - public static function getProvider($provider){ + public static function getProvider($provider) + { return \Illuminate\Foundation\Application::getProvider($provider); } - + /** * Resolve a service provider instance from the class name. * * @param string $provider - * @return \Illuminate\Support\ServiceProvider - * @static + * @return \Illuminate\Support\ServiceProvider + * @static */ - public static function resolveProviderClass($provider){ + public static function resolveProviderClass($provider) + { return \Illuminate\Foundation\Application::resolveProviderClass($provider); } - + /** * Load and boot all of the remaining deferred providers. * - * @return void - * @static + * @return void + * @static */ - public static function loadDeferredProviders(){ + public static function loadDeferredProviders() + { \Illuminate\Foundation\Application::loadDeferredProviders(); } - + /** * Load the provider for a deferred service. * * @param string $service - * @return void - * @static + * @return void + * @static */ - public static function loadDeferredProvider($service){ + public static function loadDeferredProvider($service) + { \Illuminate\Foundation\Application::loadDeferredProvider($service); } - + /** * Register a deferred provider and service. * * @param string $provider * @param string $service - * @return void - * @static + * @return void + * @static */ - public static function registerDeferredProvider($provider, $service = null){ + public static function registerDeferredProvider($provider, $service = null) + { \Illuminate\Foundation\Application::registerDeferredProvider($provider, $service); } - + /** * Resolve the given type from the container. - * + * * (Overriding Container::make) * * @param string $abstract * @param array $parameters - * @return mixed - * @static + * @return mixed + * @static */ - public static function make($abstract, $parameters = array()){ + public static function make($abstract, $parameters = []) + { return \Illuminate\Foundation\Application::make($abstract, $parameters); } - + /** * Determine if the given abstract type has been bound. - * + * * (Overriding Container::bound) * * @param string $abstract - * @return bool - * @static + * @return bool + * @static */ - public static function bound($abstract){ + public static function bound($abstract) + { return \Illuminate\Foundation\Application::bound($abstract); } - + /** * Determine if the application has booted. * - * @return bool - * @static + * @return bool + * @static */ - public static function isBooted(){ + public static function isBooted() + { return \Illuminate\Foundation\Application::isBooted(); } - + /** * Boot the application's service providers. * - * @return void - * @static + * @return void + * @static */ - public static function boot(){ + public static function boot() + { \Illuminate\Foundation\Application::boot(); } - + /** * Register a new boot listener. * * @param mixed $callback - * @return void - * @static + * @return void + * @static */ - public static function booting($callback){ + public static function booting($callback) + { \Illuminate\Foundation\Application::booting($callback); } - + /** * Register a new "booted" listener. * * @param mixed $callback - * @return void - * @static + * @return void + * @static */ - public static function booted($callback){ + public static function booted($callback) + { \Illuminate\Foundation\Application::booted($callback); } - + /** * {@inheritdoc} * - * @static + * @static */ - public static function handle($request, $type = 1, $catch = true){ + public static function handle($request, $type = 1, $catch = true) + { return \Illuminate\Foundation\Application::handle($request, $type, $catch); } - + /** * Determine if middleware has been disabled for the application. * - * @return bool - * @static + * @return bool + * @static */ - public static function shouldSkipMiddleware(){ + public static function shouldSkipMiddleware() + { return \Illuminate\Foundation\Application::shouldSkipMiddleware(); } - + /** * Determine if the application configuration is cached. * - * @return bool - * @static + * @return bool + * @static */ - public static function configurationIsCached(){ + public static function configurationIsCached() + { return \Illuminate\Foundation\Application::configurationIsCached(); } - + /** * Get the path to the configuration cache file. * - * @return string - * @static + * @return string + * @static */ - public static function getCachedConfigPath(){ + public static function getCachedConfigPath() + { return \Illuminate\Foundation\Application::getCachedConfigPath(); } - + /** * Determine if the application routes are cached. * - * @return bool - * @static + * @return bool + * @static */ - public static function routesAreCached(){ + public static function routesAreCached() + { return \Illuminate\Foundation\Application::routesAreCached(); } - + /** * Get the path to the routes cache file. * - * @return string - * @static + * @return string + * @static */ - public static function getCachedRoutesPath(){ + public static function getCachedRoutesPath() + { return \Illuminate\Foundation\Application::getCachedRoutesPath(); } - + /** * Get the path to the cached "compiled.php" file. * - * @return string - * @static + * @return string + * @static */ - public static function getCachedCompilePath(){ + public static function getCachedCompilePath() + { return \Illuminate\Foundation\Application::getCachedCompilePath(); } - + /** * Get the path to the cached services.php file. * - * @return string - * @static + * @return string + * @static */ - public static function getCachedServicesPath(){ + public static function getCachedServicesPath() + { return \Illuminate\Foundation\Application::getCachedServicesPath(); } - + /** * Determine if the application is currently down for maintenance. * - * @return bool - * @static + * @return bool + * @static */ - public static function isDownForMaintenance(){ + public static function isDownForMaintenance() + { return \Illuminate\Foundation\Application::isDownForMaintenance(); } - + /** * Throw an HttpException with the given data. * * @param int $code * @param string $message * @param array $headers - * @return void + * @return void * @throws \Symfony\Component\HttpKernel\Exception\HttpException - * @static + * @static */ - public static function abort($code, $message = '', $headers = array()){ + public static function abort($code, $message = '', $headers = []) + { \Illuminate\Foundation\Application::abort($code, $message, $headers); } - + /** * Register a terminating callback with the application. * * @param \Closure $callback - * @return $this - * @static + * @return $this + * @static */ - public static function terminating($callback){ + public static function terminating($callback) + { return \Illuminate\Foundation\Application::terminating($callback); } - + /** * Terminate the application. * - * @return void - * @static + * @return void + * @static */ - public static function terminate(){ + public static function terminate() + { \Illuminate\Foundation\Application::terminate(); } - + /** * Get the service providers that have been loaded. * - * @return array - * @static + * @return array + * @static */ - public static function getLoadedProviders(){ + public static function getLoadedProviders() + { return \Illuminate\Foundation\Application::getLoadedProviders(); } - + /** * Get the application's deferred services. * - * @return array - * @static + * @return array + * @static */ - public static function getDeferredServices(){ + public static function getDeferredServices() + { return \Illuminate\Foundation\Application::getDeferredServices(); } - + /** * Set the application's deferred services. * * @param array $services - * @return void - * @static + * @return void + * @static */ - public static function setDeferredServices($services){ + public static function setDeferredServices($services) + { \Illuminate\Foundation\Application::setDeferredServices($services); } - + /** * Add an array of services to the application's deferred services. * * @param array $services - * @return void - * @static + * @return void + * @static */ - public static function addDeferredServices($services){ + public static function addDeferredServices($services) + { \Illuminate\Foundation\Application::addDeferredServices($services); } - + /** * Determine if the given service is a deferred service. * * @param string $service - * @return bool - * @static + * @return bool + * @static */ - public static function isDeferredService($service){ + public static function isDeferredService($service) + { return \Illuminate\Foundation\Application::isDeferredService($service); } - + /** * Define a callback to be used to configure Monolog. * * @param callable $callback - * @return $this - * @static + * @return $this + * @static */ - public static function configureMonologUsing($callback){ + public static function configureMonologUsing($callback) + { return \Illuminate\Foundation\Application::configureMonologUsing($callback); } - + /** * Determine if the application has a custom Monolog configurator. * - * @return bool - * @static + * @return bool + * @static */ - public static function hasMonologConfigurator(){ + public static function hasMonologConfigurator() + { return \Illuminate\Foundation\Application::hasMonologConfigurator(); } - + /** * Get the custom Monolog configurator for the application. * - * @return callable - * @static + * @return callable + * @static */ - public static function getMonologConfigurator(){ + public static function getMonologConfigurator() + { return \Illuminate\Foundation\Application::getMonologConfigurator(); } - + /** * Get the current application locale. * - * @return string - * @static + * @return string + * @static */ - public static function getLocale(){ + public static function getLocale() + { return \Illuminate\Foundation\Application::getLocale(); } - + /** * Set the current application locale. * * @param string $locale - * @return void - * @static + * @return void + * @static */ - public static function setLocale($locale){ + public static function setLocale($locale) + { \Illuminate\Foundation\Application::setLocale($locale); } - + /** * Determine if application locale is the given locale. * * @param string $locale - * @return bool - * @static + * @return bool + * @static */ - public static function isLocale($locale){ + public static function isLocale($locale) + { return \Illuminate\Foundation\Application::isLocale($locale); } - + /** * Register the core class aliases in the container. * - * @return void - * @static + * @return void + * @static */ - public static function registerCoreContainerAliases(){ + public static function registerCoreContainerAliases() + { \Illuminate\Foundation\Application::registerCoreContainerAliases(); } - + /** * Flush the container of all bindings and resolved instances. * - * @return void - * @static + * @return void + * @static */ - public static function flush(){ + public static function flush() + { \Illuminate\Foundation\Application::flush(); } - + /** * Get the application namespace. * - * @return string + * @return string * @throws \RuntimeException - * @static + * @static */ - public static function getNamespace(){ + public static function getNamespace() + { return \Illuminate\Foundation\Application::getNamespace(); } - + /** * Define a contextual binding. * * @param string $concrete - * @return \Illuminate\Contracts\Container\ContextualBindingBuilder - * @static + * @return \Illuminate\Contracts\Container\ContextualBindingBuilder + * @static */ - public static function when($concrete){ - //Method inherited from \Illuminate\Container\Container + public static function when($concrete) + { + //Method inherited from \Illuminate\Container\Container return \Illuminate\Foundation\Application::when($concrete); } - + /** * Determine if the given abstract type has been resolved. * * @param string $abstract - * @return bool - * @static + * @return bool + * @static */ - public static function resolved($abstract){ - //Method inherited from \Illuminate\Container\Container + public static function resolved($abstract) + { + //Method inherited from \Illuminate\Container\Container return \Illuminate\Foundation\Application::resolved($abstract); } - + /** * Determine if a given string is an alias. * * @param string $name - * @return bool - * @static + * @return bool + * @static */ - public static function isAlias($name){ - //Method inherited from \Illuminate\Container\Container + public static function isAlias($name) + { + //Method inherited from \Illuminate\Container\Container return \Illuminate\Foundation\Application::isAlias($name); } - + /** * Register a binding with the container. * * @param string|array $abstract * @param \Closure|string|null $concrete * @param bool $shared - * @return void - * @static + * @return void + * @static */ - public static function bind($abstract, $concrete = null, $shared = false){ - //Method inherited from \Illuminate\Container\Container + public static function bind($abstract, $concrete = null, $shared = false) + { + //Method inherited from \Illuminate\Container\Container \Illuminate\Foundation\Application::bind($abstract, $concrete, $shared); } - + /** * Add a contextual binding to the container. * * @param string $concrete * @param string $abstract * @param \Closure|string $implementation - * @return void - * @static + * @return void + * @static */ - public static function addContextualBinding($concrete, $abstract, $implementation){ - //Method inherited from \Illuminate\Container\Container + public static function addContextualBinding($concrete, $abstract, $implementation) + { + //Method inherited from \Illuminate\Container\Container \Illuminate\Foundation\Application::addContextualBinding($concrete, $abstract, $implementation); } - + /** * Register a binding if it hasn't already been registered. * * @param string $abstract * @param \Closure|string|null $concrete * @param bool $shared - * @return void - * @static + * @return void + * @static */ - public static function bindIf($abstract, $concrete = null, $shared = false){ - //Method inherited from \Illuminate\Container\Container + public static function bindIf($abstract, $concrete = null, $shared = false) + { + //Method inherited from \Illuminate\Container\Container \Illuminate\Foundation\Application::bindIf($abstract, $concrete, $shared); } - + /** * Register a shared binding in the container. * * @param string|array $abstract * @param \Closure|string|null $concrete - * @return void - * @static + * @return void + * @static */ - public static function singleton($abstract, $concrete = null){ - //Method inherited from \Illuminate\Container\Container + public static function singleton($abstract, $concrete = null) + { + //Method inherited from \Illuminate\Container\Container \Illuminate\Foundation\Application::singleton($abstract, $concrete); } - + /** * Wrap a Closure such that it is shared. * * @param \Closure $closure - * @return \Closure - * @static + * @return \Closure + * @static */ - public static function share($closure){ - //Method inherited from \Illuminate\Container\Container + public static function share($closure) + { + //Method inherited from \Illuminate\Container\Container return \Illuminate\Foundation\Application::share($closure); } - + /** * "Extend" an abstract type in the container. * * @param string $abstract * @param \Closure $closure - * @return void + * @return void * @throws \InvalidArgumentException - * @static + * @static */ - public static function extend($abstract, $closure){ - //Method inherited from \Illuminate\Container\Container + public static function extend($abstract, $closure) + { + //Method inherited from \Illuminate\Container\Container \Illuminate\Foundation\Application::extend($abstract, $closure); } - + /** * Register an existing instance as shared in the container. * * @param string $abstract * @param mixed $instance - * @return void - * @static + * @return void + * @static */ - public static function instance($abstract, $instance){ - //Method inherited from \Illuminate\Container\Container + public static function instance($abstract, $instance) + { + //Method inherited from \Illuminate\Container\Container \Illuminate\Foundation\Application::instance($abstract, $instance); } - + /** * Assign a set of tags to a given binding. * * @param array|string $abstracts * @param array|mixed $tags - * @return void - * @static + * @return void + * @static */ - public static function tag($abstracts, $tags){ - //Method inherited from \Illuminate\Container\Container + public static function tag($abstracts, $tags) + { + //Method inherited from \Illuminate\Container\Container \Illuminate\Foundation\Application::tag($abstracts, $tags); } - + /** * Resolve all of the bindings for a given tag. * * @param string $tag - * @return array - * @static + * @return array + * @static */ - public static function tagged($tag){ - //Method inherited from \Illuminate\Container\Container + public static function tagged($tag) + { + //Method inherited from \Illuminate\Container\Container return \Illuminate\Foundation\Application::tagged($tag); } - + /** * Alias a type to a different name. * * @param string $abstract * @param string $alias - * @return void - * @static + * @return void + * @static */ - public static function alias($abstract, $alias){ - //Method inherited from \Illuminate\Container\Container + public static function alias($abstract, $alias) + { + //Method inherited from \Illuminate\Container\Container \Illuminate\Foundation\Application::alias($abstract, $alias); } - + /** * Bind a new callback to an abstract's rebind event. * * @param string $abstract * @param \Closure $callback - * @return mixed - * @static + * @return mixed + * @static */ - public static function rebinding($abstract, $callback){ - //Method inherited from \Illuminate\Container\Container + public static function rebinding($abstract, $callback) + { + //Method inherited from \Illuminate\Container\Container return \Illuminate\Foundation\Application::rebinding($abstract, $callback); } - + /** * Refresh an instance on the given target and method. * * @param string $abstract * @param mixed $target * @param string $method - * @return mixed - * @static + * @return mixed + * @static */ - public static function refresh($abstract, $target, $method){ - //Method inherited from \Illuminate\Container\Container + public static function refresh($abstract, $target, $method) + { + //Method inherited from \Illuminate\Container\Container return \Illuminate\Foundation\Application::refresh($abstract, $target, $method); } - + /** * Wrap the given closure such that its dependencies will be injected when executed. * * @param \Closure $callback * @param array $parameters - * @return \Closure - * @static + * @return \Closure + * @static */ - public static function wrap($callback, $parameters = array()){ - //Method inherited from \Illuminate\Container\Container + public static function wrap($callback, $parameters = []) + { + //Method inherited from \Illuminate\Container\Container return \Illuminate\Foundation\Application::wrap($callback, $parameters); } - + /** * Call the given Closure / class@method and inject its dependencies. * * @param callable|string $callback * @param array $parameters * @param string|null $defaultMethod - * @return mixed - * @static + * @return mixed + * @static */ - public static function call($callback, $parameters = array(), $defaultMethod = null){ - //Method inherited from \Illuminate\Container\Container + public static function call($callback, $parameters = [], $defaultMethod = null) + { + //Method inherited from \Illuminate\Container\Container return \Illuminate\Foundation\Application::call($callback, $parameters, $defaultMethod); } - + /** * Instantiate a concrete instance of the given type. * * @param string $concrete * @param array $parameters - * @return mixed + * @return mixed * @throws \Illuminate\Contracts\Container\BindingResolutionException - * @static + * @static */ - public static function build($concrete, $parameters = array()){ - //Method inherited from \Illuminate\Container\Container + public static function build($concrete, $parameters = []) + { + //Method inherited from \Illuminate\Container\Container return \Illuminate\Foundation\Application::build($concrete, $parameters); } - + /** * Register a new resolving callback. * * @param string $abstract * @param \Closure|null $callback - * @return void - * @static + * @return void + * @static */ - public static function resolving($abstract, $callback = null){ - //Method inherited from \Illuminate\Container\Container + public static function resolving($abstract, $callback = null) + { + //Method inherited from \Illuminate\Container\Container \Illuminate\Foundation\Application::resolving($abstract, $callback); } - + /** * Register a new after resolving callback for all types. * * @param string $abstract * @param \Closure|null $callback - * @return void - * @static + * @return void + * @static */ - public static function afterResolving($abstract, $callback = null){ - //Method inherited from \Illuminate\Container\Container + public static function afterResolving($abstract, $callback = null) + { + //Method inherited from \Illuminate\Container\Container \Illuminate\Foundation\Application::afterResolving($abstract, $callback); } - + /** * Determine if a given type is shared. * * @param string $abstract - * @return bool - * @static + * @return bool + * @static */ - public static function isShared($abstract){ - //Method inherited from \Illuminate\Container\Container + public static function isShared($abstract) + { + //Method inherited from \Illuminate\Container\Container return \Illuminate\Foundation\Application::isShared($abstract); } - + /** * Get the container's bindings. * - * @return array - * @static + * @return array + * @static */ - public static function getBindings(){ - //Method inherited from \Illuminate\Container\Container + public static function getBindings() + { + //Method inherited from \Illuminate\Container\Container return \Illuminate\Foundation\Application::getBindings(); } - + /** * Remove a resolved instance from the instance cache. * * @param string $abstract - * @return void - * @static + * @return void + * @static */ - public static function forgetInstance($abstract){ - //Method inherited from \Illuminate\Container\Container + public static function forgetInstance($abstract) + { + //Method inherited from \Illuminate\Container\Container \Illuminate\Foundation\Application::forgetInstance($abstract); } - + /** * Clear all of the instances from the container. * - * @return void - * @static + * @return void + * @static */ - public static function forgetInstances(){ - //Method inherited from \Illuminate\Container\Container + public static function forgetInstances() + { + //Method inherited from \Illuminate\Container\Container \Illuminate\Foundation\Application::forgetInstances(); } - + /** * Set the globally available instance of the container. * - * @return static - * @static + * @return static + * @static */ - public static function getInstance(){ - //Method inherited from \Illuminate\Container\Container + public static function getInstance() + { + //Method inherited from \Illuminate\Container\Container return \Illuminate\Foundation\Application::getInstance(); } - + /** * Set the shared instance of the container. * * @param \Illuminate\Contracts\Container\Container $container - * @return void - * @static + * @return void + * @static */ - public static function setInstance($container){ - //Method inherited from \Illuminate\Container\Container + public static function setInstance($container) + { + //Method inherited from \Illuminate\Container\Container \Illuminate\Foundation\Application::setInstance($container); } - + /** * Determine if a given offset exists. * * @param string $key - * @return bool - * @static + * @return bool + * @static */ - public static function offsetExists($key){ - //Method inherited from \Illuminate\Container\Container + public static function offsetExists($key) + { + //Method inherited from \Illuminate\Container\Container return \Illuminate\Foundation\Application::offsetExists($key); } - + /** * Get the value at a given offset. * * @param string $key - * @return mixed - * @static + * @return mixed + * @static */ - public static function offsetGet($key){ - //Method inherited from \Illuminate\Container\Container + public static function offsetGet($key) + { + //Method inherited from \Illuminate\Container\Container return \Illuminate\Foundation\Application::offsetGet($key); } - + /** * Set the value at a given offset. * * @param string $key * @param mixed $value - * @return void - * @static + * @return void + * @static */ - public static function offsetSet($key, $value){ - //Method inherited from \Illuminate\Container\Container + public static function offsetSet($key, $value) + { + //Method inherited from \Illuminate\Container\Container \Illuminate\Foundation\Application::offsetSet($key, $value); } - + /** * Unset the value at a given offset. * * @param string $key - * @return void - * @static + * @return void + * @static */ - public static function offsetUnset($key){ - //Method inherited from \Illuminate\Container\Container + public static function offsetUnset($key) + { + //Method inherited from \Illuminate\Container\Container \Illuminate\Foundation\Application::offsetUnset($key); } - } - - class Artisan extends \Illuminate\Support\Facades\Artisan{ - + class Artisan extends \Illuminate\Support\Facades\Artisan + { /** * Run the console application. * * @param \Symfony\Component\Console\Input\InputInterface $input * @param \Symfony\Component\Console\Output\OutputInterface $output - * @return int - * @static + * @return int + * @static */ - public static function handle($input, $output = null){ - //Method inherited from \Illuminate\Foundation\Console\Kernel + public static function handle($input, $output = null) + { + //Method inherited from \Illuminate\Foundation\Console\Kernel return \App\Console\Kernel::handle($input, $output); } - + /** * Terminate the application. * * @param \Symfony\Component\Console\Input\InputInterface $input * @param int $status - * @return void - * @static + * @return void + * @static */ - public static function terminate($input, $status){ - //Method inherited from \Illuminate\Foundation\Console\Kernel + public static function terminate($input, $status) + { + //Method inherited from \Illuminate\Foundation\Console\Kernel \App\Console\Kernel::terminate($input, $status); } - + /** * Register the given command with the console application. * * @param \Symfony\Component\Console\Command\Command $command - * @return void - * @static + * @return void + * @static */ - public static function registerCommand($command){ - //Method inherited from \Illuminate\Foundation\Console\Kernel + public static function registerCommand($command) + { + //Method inherited from \Illuminate\Foundation\Console\Kernel \App\Console\Kernel::registerCommand($command); } - + /** * Run an Artisan console command by name. * * @param string $command * @param array $parameters - * @return int - * @static + * @return int + * @static */ - public static function call($command, $parameters = array()){ - //Method inherited from \Illuminate\Foundation\Console\Kernel + public static function call($command, $parameters = []) + { + //Method inherited from \Illuminate\Foundation\Console\Kernel return \App\Console\Kernel::call($command, $parameters); } - + /** * Queue the given console command. * * @param string $command * @param array $parameters - * @return void - * @static + * @return void + * @static */ - public static function queue($command, $parameters = array()){ - //Method inherited from \Illuminate\Foundation\Console\Kernel + public static function queue($command, $parameters = []) + { + //Method inherited from \Illuminate\Foundation\Console\Kernel \App\Console\Kernel::queue($command, $parameters); } - + /** * Get all of the commands registered with the console. * - * @return array - * @static + * @return array + * @static */ - public static function all(){ - //Method inherited from \Illuminate\Foundation\Console\Kernel + public static function all() + { + //Method inherited from \Illuminate\Foundation\Console\Kernel return \App\Console\Kernel::all(); } - + /** * Get the output for the last run command. * - * @return string - * @static + * @return string + * @static */ - public static function output(){ - //Method inherited from \Illuminate\Foundation\Console\Kernel + public static function output() + { + //Method inherited from \Illuminate\Foundation\Console\Kernel return \App\Console\Kernel::output(); } - + /** * Bootstrap the application for artisan commands. * - * @return void - * @static + * @return void + * @static */ - public static function bootstrap(){ - //Method inherited from \Illuminate\Foundation\Console\Kernel + public static function bootstrap() + { + //Method inherited from \Illuminate\Foundation\Console\Kernel \App\Console\Kernel::bootstrap(); } - } - - class Auth extends \Illuminate\Support\Facades\Auth{ - + class Auth extends \Illuminate\Support\Facades\Auth + { /** * Attempt to get the guard from the local cache. * * @param string $name - * @return \Illuminate\Contracts\Auth\Guard|\Illuminate\Contracts\Auth\StatefulGuard - * @static + * @return \Illuminate\Contracts\Auth\Guard|\Illuminate\Contracts\Auth\StatefulGuard + * @static */ - public static function guard($name = null){ + public static function guard($name = null) + { return \Illuminate\Auth\AuthManager::guard($name); } - + /** * Create a session based authentication guard. * * @param string $name * @param array $config - * @return \Illuminate\Auth\SessionGuard - * @static + * @return \Illuminate\Auth\SessionGuard + * @static */ - public static function createSessionDriver($name, $config){ + public static function createSessionDriver($name, $config) + { return \Illuminate\Auth\AuthManager::createSessionDriver($name, $config); } - + /** * Create a token based authentication guard. * * @param string $name * @param array $config - * @return \Illuminate\Auth\TokenGuard - * @static + * @return \Illuminate\Auth\TokenGuard + * @static */ - public static function createTokenDriver($name, $config){ + public static function createTokenDriver($name, $config) + { return \Illuminate\Auth\AuthManager::createTokenDriver($name, $config); } - + /** * Get the default authentication driver name. * - * @return string - * @static + * @return string + * @static */ - public static function getDefaultDriver(){ + public static function getDefaultDriver() + { return \Illuminate\Auth\AuthManager::getDefaultDriver(); } - + /** * Set the default guard driver the factory should serve. * * @param string $name - * @return void - * @static + * @return void + * @static */ - public static function shouldUse($name){ + public static function shouldUse($name) + { \Illuminate\Auth\AuthManager::shouldUse($name); } - + /** * Set the default authentication driver name. * * @param string $name - * @return void - * @static + * @return void + * @static */ - public static function setDefaultDriver($name){ + public static function setDefaultDriver($name) + { \Illuminate\Auth\AuthManager::setDefaultDriver($name); } - + /** * Register a new callback based request guard. * * @param string $driver * @param callable $callback - * @return $this - * @static + * @return $this + * @static */ - public static function viaRequest($driver, $callback){ + public static function viaRequest($driver, $callback) + { return \Illuminate\Auth\AuthManager::viaRequest($driver, $callback); } - + /** * Get the user resolver callback. * - * @return \Closure - * @static + * @return \Closure + * @static */ - public static function userResolver(){ + public static function userResolver() + { return \Illuminate\Auth\AuthManager::userResolver(); } - + /** * Set the callback to be used to resolve users. * * @param \Closure $userResolver - * @return $this - * @static + * @return $this + * @static */ - public static function resolveUsersUsing($userResolver){ + public static function resolveUsersUsing($userResolver) + { return \Illuminate\Auth\AuthManager::resolveUsersUsing($userResolver); } - + /** * Register a custom driver creator Closure. * * @param string $driver * @param \Closure $callback - * @return $this - * @static + * @return $this + * @static */ - public static function extend($driver, $callback){ + public static function extend($driver, $callback) + { return \Illuminate\Auth\AuthManager::extend($driver, $callback); } - + /** * Register a custom provider creator Closure. * * @param string $name * @param \Closure $callback - * @return $this - * @static + * @return $this + * @static */ - public static function provider($name, $callback){ + public static function provider($name, $callback) + { return \Illuminate\Auth\AuthManager::provider($name, $callback); } - + /** * Create the user provider implementation for the driver. * * @param string $provider - * @return \Illuminate\Contracts\Auth\UserProvider + * @return \Illuminate\Contracts\Auth\UserProvider * @throws \InvalidArgumentException - * @static + * @static */ - public static function createUserProvider($provider){ + public static function createUserProvider($provider) + { return \Illuminate\Auth\AuthManager::createUserProvider($provider); } - + /** * Get the currently authenticated user. * - * @return \App\User|null - * @static + * @return \App\User|null + * @static */ - public static function user(){ + public static function user() + { return \Illuminate\Auth\SessionGuard::user(); } - + /** * Get the ID for the currently authenticated user. * - * @return int|null - * @static + * @return int|null + * @static */ - public static function id(){ + public static function id() + { return \Illuminate\Auth\SessionGuard::id(); } - + /** * Log a user into the application without sessions or cookies. * * @param array $credentials - * @return bool - * @static + * @return bool + * @static */ - public static function once($credentials = array()){ + public static function once($credentials = []) + { return \Illuminate\Auth\SessionGuard::once($credentials); } - + /** * Validate a user's credentials. * * @param array $credentials - * @return bool - * @static + * @return bool + * @static */ - public static function validate($credentials = array()){ + public static function validate($credentials = []) + { return \Illuminate\Auth\SessionGuard::validate($credentials); } - + /** * Attempt to authenticate using HTTP Basic Auth. * * @param string $field * @param array $extraConditions - * @return \Symfony\Component\HttpFoundation\Response|null - * @static + * @return \Symfony\Component\HttpFoundation\Response|null + * @static */ - public static function basic($field = 'email', $extraConditions = array()){ + public static function basic($field = 'email', $extraConditions = []) + { return \Illuminate\Auth\SessionGuard::basic($field, $extraConditions); } - + /** * Perform a stateless HTTP Basic login attempt. * * @param string $field * @param array $extraConditions - * @return \Symfony\Component\HttpFoundation\Response|null - * @static + * @return \Symfony\Component\HttpFoundation\Response|null + * @static */ - public static function onceBasic($field = 'email', $extraConditions = array()){ + public static function onceBasic($field = 'email', $extraConditions = []) + { return \Illuminate\Auth\SessionGuard::onceBasic($field, $extraConditions); } - + /** * Attempt to authenticate a user using the given credentials. * * @param array $credentials * @param bool $remember * @param bool $login - * @return bool - * @static + * @return bool + * @static */ - public static function attempt($credentials = array(), $remember = false, $login = true){ + public static function attempt($credentials = [], $remember = false, $login = true) + { return \Illuminate\Auth\SessionGuard::attempt($credentials, $remember, $login); } - + /** * Register an authentication attempt event listener. * * @param mixed $callback - * @return void - * @static + * @return void + * @static */ - public static function attempting($callback){ + public static function attempting($callback) + { \Illuminate\Auth\SessionGuard::attempting($callback); } - + /** * Log a user into the application. * * @param \Illuminate\Contracts\Auth\Authenticatable $user * @param bool $remember - * @return void - * @static + * @return void + * @static */ - public static function login($user, $remember = false){ + public static function login($user, $remember = false) + { \Illuminate\Auth\SessionGuard::login($user, $remember); } - + /** * Log the given user ID into the application. * * @param mixed $id * @param bool $remember - * @return \App\User - * @static + * @return \App\User + * @static */ - public static function loginUsingId($id, $remember = false){ + public static function loginUsingId($id, $remember = false) + { return \Illuminate\Auth\SessionGuard::loginUsingId($id, $remember); } - + /** * Log the given user ID into the application without sessions or cookies. * * @param mixed $id - * @return bool - * @static + * @return bool + * @static */ - public static function onceUsingId($id){ + public static function onceUsingId($id) + { return \Illuminate\Auth\SessionGuard::onceUsingId($id); } - + /** * Log the user out of the application. * - * @return void - * @static + * @return void + * @static */ - public static function logout(){ + public static function logout() + { \Illuminate\Auth\SessionGuard::logout(); } - + /** * Get the cookie creator instance used by the guard. * - * @return \Illuminate\Contracts\Cookie\QueueingFactory + * @return \Illuminate\Contracts\Cookie\QueueingFactory * @throws \RuntimeException - * @static + * @static */ - public static function getCookieJar(){ + public static function getCookieJar() + { return \Illuminate\Auth\SessionGuard::getCookieJar(); } - + /** * Set the cookie creator instance used by the guard. * * @param \Illuminate\Contracts\Cookie\QueueingFactory $cookie - * @return void - * @static + * @return void + * @static */ - public static function setCookieJar($cookie){ + public static function setCookieJar($cookie) + { \Illuminate\Auth\SessionGuard::setCookieJar($cookie); } - + /** * Get the event dispatcher instance. * - * @return \Illuminate\Contracts\Events\Dispatcher - * @static + * @return \Illuminate\Contracts\Events\Dispatcher + * @static */ - public static function getDispatcher(){ + public static function getDispatcher() + { return \Illuminate\Auth\SessionGuard::getDispatcher(); } - + /** * Set the event dispatcher instance. * * @param \Illuminate\Contracts\Events\Dispatcher $events - * @return void - * @static + * @return void + * @static */ - public static function setDispatcher($events){ + public static function setDispatcher($events) + { \Illuminate\Auth\SessionGuard::setDispatcher($events); } - + /** * Get the session store used by the guard. * - * @return \Illuminate\Session\Store - * @static + * @return \Illuminate\Session\Store + * @static */ - public static function getSession(){ + public static function getSession() + { return \Illuminate\Auth\SessionGuard::getSession(); } - + /** * Get the user provider used by the guard. * - * @return \Illuminate\Contracts\Auth\UserProvider - * @static + * @return \Illuminate\Contracts\Auth\UserProvider + * @static */ - public static function getProvider(){ + public static function getProvider() + { return \Illuminate\Auth\SessionGuard::getProvider(); } - + /** * Set the user provider used by the guard. * * @param \Illuminate\Contracts\Auth\UserProvider $provider - * @return void - * @static + * @return void + * @static */ - public static function setProvider($provider){ + public static function setProvider($provider) + { \Illuminate\Auth\SessionGuard::setProvider($provider); } - + /** * Return the currently cached user. * - * @return \App\User|null - * @static + * @return \App\User|null + * @static */ - public static function getUser(){ + public static function getUser() + { return \Illuminate\Auth\SessionGuard::getUser(); } - + /** * Set the current user. * * @param \Illuminate\Contracts\Auth\Authenticatable $user - * @return $this - * @static + * @return $this + * @static */ - public static function setUser($user){ + public static function setUser($user) + { return \Illuminate\Auth\SessionGuard::setUser($user); } - + /** * Get the current request instance. * - * @return \Symfony\Component\HttpFoundation\Request - * @static + * @return \Symfony\Component\HttpFoundation\Request + * @static */ - public static function getRequest(){ + public static function getRequest() + { return \Illuminate\Auth\SessionGuard::getRequest(); } - + /** * Set the current request instance. * * @param \Symfony\Component\HttpFoundation\Request $request - * @return $this - * @static + * @return $this + * @static */ - public static function setRequest($request){ + public static function setRequest($request) + { return \Illuminate\Auth\SessionGuard::setRequest($request); } - + /** * Get the last user we attempted to authenticate. * - * @return \App\User - * @static + * @return \App\User + * @static */ - public static function getLastAttempted(){ + public static function getLastAttempted() + { return \Illuminate\Auth\SessionGuard::getLastAttempted(); } - + /** * Get a unique identifier for the auth session value. * - * @return string - * @static + * @return string + * @static */ - public static function getName(){ + public static function getName() + { return \Illuminate\Auth\SessionGuard::getName(); } - + /** * Get the name of the cookie used to store the "recaller". * - * @return string - * @static + * @return string + * @static */ - public static function getRecallerName(){ + public static function getRecallerName() + { return \Illuminate\Auth\SessionGuard::getRecallerName(); } - + /** * Determine if the user was authenticated via "remember me" cookie. * - * @return bool - * @static + * @return bool + * @static */ - public static function viaRemember(){ + public static function viaRemember() + { return \Illuminate\Auth\SessionGuard::viaRemember(); } - + /** * Determine if the current user is authenticated. * - * @return \App\User + * @return \App\User * @throws \Illuminate\Auth\AuthenticationException - * @static + * @static */ - public static function authenticate(){ + public static function authenticate() + { return \Illuminate\Auth\SessionGuard::authenticate(); } - + /** * Determine if the current user is authenticated. * - * @return bool - * @static + * @return bool + * @static */ - public static function check(){ + public static function check() + { return \Illuminate\Auth\SessionGuard::check(); } - + /** * Determine if the current user is a guest. * - * @return bool - * @static + * @return bool + * @static */ - public static function guest(){ + public static function guest() + { return \Illuminate\Auth\SessionGuard::guest(); } - } - - class Blade extends \Illuminate\Support\Facades\Blade{ - + class Blade extends \Illuminate\Support\Facades\Blade + { /** * Compile the view at the given path. * * @param string $path - * @return void - * @static + * @return void + * @static */ - public static function compile($path = null){ + public static function compile($path = null) + { \Illuminate\View\Compilers\BladeCompiler::compile($path); } - + /** * Get the path currently being compiled. * - * @return string - * @static + * @return string + * @static */ - public static function getPath(){ + public static function getPath() + { return \Illuminate\View\Compilers\BladeCompiler::getPath(); } - + /** * Set the path currently being compiled. * * @param string $path - * @return void - * @static + * @return void + * @static */ - public static function setPath($path){ + public static function setPath($path) + { \Illuminate\View\Compilers\BladeCompiler::setPath($path); } - + /** * Compile the given Blade template contents. * * @param string $value - * @return string - * @static + * @return string + * @static */ - public static function compileString($value){ + public static function compileString($value) + { return \Illuminate\View\Compilers\BladeCompiler::compileString($value); } - + /** * Compile the default values for the echo statement. * * @param string $value - * @return string - * @static + * @return string + * @static */ - public static function compileEchoDefaults($value){ + public static function compileEchoDefaults($value) + { return \Illuminate\View\Compilers\BladeCompiler::compileEchoDefaults($value); } - + /** * Get the extensions used by the compiler. * - * @return array - * @static + * @return array + * @static */ - public static function getExtensions(){ + public static function getExtensions() + { return \Illuminate\View\Compilers\BladeCompiler::getExtensions(); } - + /** * Register a custom Blade compiler. * * @param callable $compiler - * @return void - * @static + * @return void + * @static */ - public static function extend($compiler){ + public static function extend($compiler) + { \Illuminate\View\Compilers\BladeCompiler::extend($compiler); } - + /** * Register a handler for custom directives. * * @param string $name * @param callable $handler - * @return void - * @static + * @return void + * @static */ - public static function directive($name, $handler){ + public static function directive($name, $handler) + { \Illuminate\View\Compilers\BladeCompiler::directive($name, $handler); } - + /** * Get the list of custom directives. * - * @return array - * @static + * @return array + * @static */ - public static function getCustomDirectives(){ + public static function getCustomDirectives() + { return \Illuminate\View\Compilers\BladeCompiler::getCustomDirectives(); } - + /** * Gets the raw tags used by the compiler. * - * @return array - * @static + * @return array + * @static */ - public static function getRawTags(){ + public static function getRawTags() + { return \Illuminate\View\Compilers\BladeCompiler::getRawTags(); } - + /** * Sets the raw tags used for the compiler. * * @param string $openTag * @param string $closeTag - * @return void - * @static + * @return void + * @static */ - public static function setRawTags($openTag, $closeTag){ + public static function setRawTags($openTag, $closeTag) + { \Illuminate\View\Compilers\BladeCompiler::setRawTags($openTag, $closeTag); } - + /** * Sets the content tags used for the compiler. * * @param string $openTag * @param string $closeTag * @param bool $escaped - * @return void - * @static + * @return void + * @static */ - public static function setContentTags($openTag, $closeTag, $escaped = false){ + public static function setContentTags($openTag, $closeTag, $escaped = false) + { \Illuminate\View\Compilers\BladeCompiler::setContentTags($openTag, $closeTag, $escaped); } - + /** * Sets the escaped content tags used for the compiler. * * @param string $openTag * @param string $closeTag - * @return void - * @static + * @return void + * @static */ - public static function setEscapedContentTags($openTag, $closeTag){ + public static function setEscapedContentTags($openTag, $closeTag) + { \Illuminate\View\Compilers\BladeCompiler::setEscapedContentTags($openTag, $closeTag); } - + /** * Gets the content tags used for the compiler. * - * @return string - * @static + * @return string + * @static */ - public static function getContentTags(){ + public static function getContentTags() + { return \Illuminate\View\Compilers\BladeCompiler::getContentTags(); } - + /** * Gets the escaped content tags used for the compiler. * - * @return string - * @static + * @return string + * @static */ - public static function getEscapedContentTags(){ + public static function getEscapedContentTags() + { return \Illuminate\View\Compilers\BladeCompiler::getEscapedContentTags(); } - + /** * Set the echo format to be used by the compiler. * * @param string $format - * @return void - * @static + * @return void + * @static */ - public static function setEchoFormat($format){ + public static function setEchoFormat($format) + { \Illuminate\View\Compilers\BladeCompiler::setEchoFormat($format); } - + /** * Get the path to the compiled version of a view. * * @param string $path - * @return string - * @static + * @return string + * @static */ - public static function getCompiledPath($path){ - //Method inherited from \Illuminate\View\Compilers\Compiler + public static function getCompiledPath($path) + { + //Method inherited from \Illuminate\View\Compilers\Compiler return \Illuminate\View\Compilers\BladeCompiler::getCompiledPath($path); } - + /** * Determine if the view at the given path is expired. * * @param string $path - * @return bool - * @static + * @return bool + * @static */ - public static function isExpired($path){ - //Method inherited from \Illuminate\View\Compilers\Compiler + public static function isExpired($path) + { + //Method inherited from \Illuminate\View\Compilers\Compiler return \Illuminate\View\Compilers\BladeCompiler::isExpired($path); } - } - - class Cache extends \Illuminate\Support\Facades\Cache{ - + class Cache extends \Illuminate\Support\Facades\Cache + { /** * Get a cache store instance by name. * * @param string|null $name - * @return mixed - * @static + * @return mixed + * @static */ - public static function store($name = null){ + public static function store($name = null) + { return \Illuminate\Cache\CacheManager::store($name); } - + /** * Get a cache driver instance. * * @param string $driver - * @return mixed - * @static + * @return mixed + * @static */ - public static function driver($driver = null){ + public static function driver($driver = null) + { return \Illuminate\Cache\CacheManager::driver($driver); } - + /** * Create a new cache repository with the given implementation. * * @param \Illuminate\Contracts\Cache\Store $store - * @return \Illuminate\Cache\Repository - * @static + * @return \Illuminate\Cache\Repository + * @static */ - public static function repository($store){ + public static function repository($store) + { return \Illuminate\Cache\CacheManager::repository($store); } - + /** * Get the default cache driver name. * - * @return string - * @static + * @return string + * @static */ - public static function getDefaultDriver(){ + public static function getDefaultDriver() + { return \Illuminate\Cache\CacheManager::getDefaultDriver(); } - + /** * Set the default cache driver name. * * @param string $name - * @return void - * @static + * @return void + * @static */ - public static function setDefaultDriver($name){ + public static function setDefaultDriver($name) + { \Illuminate\Cache\CacheManager::setDefaultDriver($name); } - + /** * Register a custom driver creator Closure. * * @param string $driver * @param \Closure $callback - * @return $this - * @static + * @return $this + * @static */ - public static function extend($driver, $callback){ + public static function extend($driver, $callback) + { return \Illuminate\Cache\CacheManager::extend($driver, $callback); } - + /** * Set the event dispatcher instance. * * @param \Illuminate\Contracts\Events\Dispatcher $events - * @return void - * @static + * @return void + * @static */ - public static function setEventDispatcher($events){ + public static function setEventDispatcher($events) + { \Illuminate\Cache\Repository::setEventDispatcher($events); } - + /** * Determine if an item exists in the cache. * * @param string $key - * @return bool - * @static + * @return bool + * @static */ - public static function has($key){ + public static function has($key) + { return \Illuminate\Cache\Repository::has($key); } - + /** * Retrieve an item from the cache by key. * * @param string $key * @param mixed $default - * @return mixed - * @static + * @return mixed + * @static */ - public static function get($key, $default = null){ + public static function get($key, $default = null) + { return \Illuminate\Cache\Repository::get($key, $default); } - + /** * Retrieve multiple items from the cache by key. - * + * * Items not found in the cache will have a null value. * * @param array $keys - * @return array - * @static + * @return array + * @static */ - public static function many($keys){ + public static function many($keys) + { return \Illuminate\Cache\Repository::many($keys); } - + /** * Retrieve an item from the cache and delete it. * * @param string $key * @param mixed $default - * @return mixed - * @static + * @return mixed + * @static */ - public static function pull($key, $default = null){ + public static function pull($key, $default = null) + { return \Illuminate\Cache\Repository::pull($key, $default); } - + /** * Store an item in the cache. * * @param string $key * @param mixed $value * @param \DateTime|int $minutes - * @return void - * @static + * @return void + * @static */ - public static function put($key, $value, $minutes = null){ + public static function put($key, $value, $minutes = null) + { \Illuminate\Cache\Repository::put($key, $value, $minutes); } - + /** * Store multiple items in the cache for a given number of minutes. * * @param array $values * @param int $minutes - * @return void - * @static + * @return void + * @static */ - public static function putMany($values, $minutes){ + public static function putMany($values, $minutes) + { \Illuminate\Cache\Repository::putMany($values, $minutes); } - + /** * Store an item in the cache if the key does not exist. * * @param string $key * @param mixed $value * @param \DateTime|int $minutes - * @return bool - * @static + * @return bool + * @static */ - public static function add($key, $value, $minutes){ + public static function add($key, $value, $minutes) + { return \Illuminate\Cache\Repository::add($key, $value, $minutes); } - + /** * Store an item in the cache indefinitely. * * @param string $key * @param mixed $value - * @return void - * @static + * @return void + * @static */ - public static function forever($key, $value){ + public static function forever($key, $value) + { \Illuminate\Cache\Repository::forever($key, $value); } - + /** * Get an item from the cache, or store the default value. * * @param string $key * @param \DateTime|int $minutes * @param \Closure $callback - * @return mixed - * @static + * @return mixed + * @static */ - public static function remember($key, $minutes, $callback){ + public static function remember($key, $minutes, $callback) + { return \Illuminate\Cache\Repository::remember($key, $minutes, $callback); } - + /** * Get an item from the cache, or store the default value forever. * * @param string $key * @param \Closure $callback - * @return mixed - * @static + * @return mixed + * @static */ - public static function sear($key, $callback){ + public static function sear($key, $callback) + { return \Illuminate\Cache\Repository::sear($key, $callback); } - + /** * Get an item from the cache, or store the default value forever. * * @param string $key * @param \Closure $callback - * @return mixed - * @static + * @return mixed + * @static */ - public static function rememberForever($key, $callback){ + public static function rememberForever($key, $callback) + { return \Illuminate\Cache\Repository::rememberForever($key, $callback); } - + /** * Remove an item from the cache. * * @param string $key - * @return bool - * @static + * @return bool + * @static */ - public static function forget($key){ + public static function forget($key) + { return \Illuminate\Cache\Repository::forget($key); } - + /** * Begin executing a new tags operation if the store supports it. * * @param array|mixed $names - * @return \Illuminate\Cache\TaggedCache + * @return \Illuminate\Cache\TaggedCache * @throws \BadMethodCallException - * @static + * @static */ - public static function tags($names){ + public static function tags($names) + { return \Illuminate\Cache\Repository::tags($names); } - + /** * Get the default cache time. * - * @return int - * @static + * @return int + * @static */ - public static function getDefaultCacheTime(){ + public static function getDefaultCacheTime() + { return \Illuminate\Cache\Repository::getDefaultCacheTime(); } - + /** * Set the default cache time in minutes. * * @param int $minutes - * @return void - * @static + * @return void + * @static */ - public static function setDefaultCacheTime($minutes){ + public static function setDefaultCacheTime($minutes) + { \Illuminate\Cache\Repository::setDefaultCacheTime($minutes); } - + /** * Get the cache store implementation. * - * @return \Illuminate\Contracts\Cache\Store - * @static + * @return \Illuminate\Contracts\Cache\Store + * @static */ - public static function getStore(){ + public static function getStore() + { return \Illuminate\Cache\Repository::getStore(); } - + /** * Determine if a cached value exists. * * @param string $key - * @return bool - * @static + * @return bool + * @static */ - public static function offsetExists($key){ + public static function offsetExists($key) + { return \Illuminate\Cache\Repository::offsetExists($key); } - + /** * Retrieve an item from the cache by key. * * @param string $key - * @return mixed - * @static + * @return mixed + * @static */ - public static function offsetGet($key){ + public static function offsetGet($key) + { return \Illuminate\Cache\Repository::offsetGet($key); } - + /** * Store an item in the cache for the default time. * * @param string $key * @param mixed $value - * @return void - * @static + * @return void + * @static */ - public static function offsetSet($key, $value){ + public static function offsetSet($key, $value) + { \Illuminate\Cache\Repository::offsetSet($key, $value); } - + /** * Remove an item from the cache. * * @param string $key - * @return void - * @static + * @return void + * @static */ - public static function offsetUnset($key){ + public static function offsetUnset($key) + { \Illuminate\Cache\Repository::offsetUnset($key); } - + /** * Register a custom macro. * * @param string $name * @param callable $macro - * @return void - * @static + * @return void + * @static */ - public static function macro($name, $macro){ + public static function macro($name, $macro) + { \Illuminate\Cache\Repository::macro($name, $macro); } - + /** * Checks if macro is registered. * * @param string $name - * @return bool - * @static + * @return bool + * @static */ - public static function hasMacro($name){ + public static function hasMacro($name) + { return \Illuminate\Cache\Repository::hasMacro($name); } - + /** * Dynamically handle calls to the class. * * @param string $method * @param array $parameters - * @return mixed + * @return mixed * @throws \BadMethodCallException - * @static + * @static */ - public static function macroCall($method, $parameters){ + public static function macroCall($method, $parameters) + { return \Illuminate\Cache\Repository::macroCall($method, $parameters); } - + /** * Increment the value of an item in the cache. * * @param string $key * @param mixed $value - * @return int - * @static + * @return int + * @static */ - public static function increment($key, $value = 1){ + public static function increment($key, $value = 1) + { return \Illuminate\Cache\FileStore::increment($key, $value); } - + /** * Decrement the value of an item in the cache. * * @param string $key * @param mixed $value - * @return int - * @static + * @return int + * @static */ - public static function decrement($key, $value = 1){ + public static function decrement($key, $value = 1) + { return \Illuminate\Cache\FileStore::decrement($key, $value); } - + /** * Remove all items from the cache. * - * @return void - * @static + * @return void + * @static */ - public static function flush(){ + public static function flush() + { \Illuminate\Cache\FileStore::flush(); } - + /** * Get the Filesystem instance. * - * @return \Illuminate\Filesystem\Filesystem - * @static + * @return \Illuminate\Filesystem\Filesystem + * @static */ - public static function getFilesystem(){ + public static function getFilesystem() + { return \Illuminate\Cache\FileStore::getFilesystem(); } - + /** * Get the working directory of the cache. * - * @return string - * @static + * @return string + * @static */ - public static function getDirectory(){ + public static function getDirectory() + { return \Illuminate\Cache\FileStore::getDirectory(); } - + /** * Get the cache key prefix. * - * @return string - * @static + * @return string + * @static */ - public static function getPrefix(){ + public static function getPrefix() + { return \Illuminate\Cache\FileStore::getPrefix(); } - } - - class Config extends \Illuminate\Support\Facades\Config{ - + class Config extends \Illuminate\Support\Facades\Config + { /** * Determine if the given configuration value exists. * * @param string $key - * @return bool - * @static + * @return bool + * @static */ - public static function has($key){ + public static function has($key) + { return \Illuminate\Config\Repository::has($key); } - + /** * Get the specified configuration value. * * @param string $key * @param mixed $default - * @return mixed - * @static + * @return mixed + * @static */ - public static function get($key, $default = null){ + public static function get($key, $default = null) + { return \Illuminate\Config\Repository::get($key, $default); } - + /** * Set a given configuration value. * * @param array|string $key * @param mixed $value - * @return void - * @static + * @return void + * @static */ - public static function set($key, $value = null){ + public static function set($key, $value = null) + { \Illuminate\Config\Repository::set($key, $value); } - + /** * Prepend a value onto an array configuration value. * * @param string $key * @param mixed $value - * @return void - * @static + * @return void + * @static */ - public static function prepend($key, $value){ + public static function prepend($key, $value) + { \Illuminate\Config\Repository::prepend($key, $value); } - + /** * Push a value onto an array configuration value. * * @param string $key * @param mixed $value - * @return void - * @static + * @return void + * @static */ - public static function push($key, $value){ + public static function push($key, $value) + { \Illuminate\Config\Repository::push($key, $value); } - + /** * Get all of the configuration items for the application. * - * @return array - * @static + * @return array + * @static */ - public static function all(){ + public static function all() + { return \Illuminate\Config\Repository::all(); } - + /** * Determine if the given configuration option exists. * * @param string $key - * @return bool - * @static + * @return bool + * @static */ - public static function offsetExists($key){ + public static function offsetExists($key) + { return \Illuminate\Config\Repository::offsetExists($key); } - + /** * Get a configuration option. * * @param string $key - * @return mixed - * @static + * @return mixed + * @static */ - public static function offsetGet($key){ + public static function offsetGet($key) + { return \Illuminate\Config\Repository::offsetGet($key); } - + /** * Set a configuration option. * * @param string $key * @param mixed $value - * @return void - * @static + * @return void + * @static */ - public static function offsetSet($key, $value){ + public static function offsetSet($key, $value) + { \Illuminate\Config\Repository::offsetSet($key, $value); } - + /** * Unset a configuration option. * * @param string $key - * @return void - * @static + * @return void + * @static */ - public static function offsetUnset($key){ + public static function offsetUnset($key) + { \Illuminate\Config\Repository::offsetUnset($key); } - } - - class Cookie extends \Illuminate\Support\Facades\Cookie{ - + class Cookie extends \Illuminate\Support\Facades\Cookie + { /** * Create a new cookie instance. * @@ -2412,13 +2610,14 @@ class Cookie extends \Illuminate\Support\Facades\Cookie{ * @param string $domain * @param bool $secure * @param bool $httpOnly - * @return \Symfony\Component\HttpFoundation\Cookie - * @static + * @return \Symfony\Component\HttpFoundation\Cookie + * @static */ - public static function make($name, $value, $minutes = 0, $path = null, $domain = null, $secure = false, $httpOnly = true){ + public static function make($name, $value, $minutes = 0, $path = null, $domain = null, $secure = false, $httpOnly = true) + { return \Illuminate\Cookie\CookieJar::make($name, $value, $minutes, $path, $domain, $secure, $httpOnly); } - + /** * Create a cookie that lasts "forever" (five years). * @@ -2428,1215 +2627,1312 @@ public static function make($name, $value, $minutes = 0, $path = null, $domain = * @param string $domain * @param bool $secure * @param bool $httpOnly - * @return \Symfony\Component\HttpFoundation\Cookie - * @static + * @return \Symfony\Component\HttpFoundation\Cookie + * @static */ - public static function forever($name, $value, $path = null, $domain = null, $secure = false, $httpOnly = true){ + public static function forever($name, $value, $path = null, $domain = null, $secure = false, $httpOnly = true) + { return \Illuminate\Cookie\CookieJar::forever($name, $value, $path, $domain, $secure, $httpOnly); } - + /** * Expire the given cookie. * * @param string $name * @param string $path * @param string $domain - * @return \Symfony\Component\HttpFoundation\Cookie - * @static + * @return \Symfony\Component\HttpFoundation\Cookie + * @static */ - public static function forget($name, $path = null, $domain = null){ + public static function forget($name, $path = null, $domain = null) + { return \Illuminate\Cookie\CookieJar::forget($name, $path, $domain); } - + /** * Determine if a cookie has been queued. * * @param string $key - * @return bool - * @static + * @return bool + * @static */ - public static function hasQueued($key){ + public static function hasQueued($key) + { return \Illuminate\Cookie\CookieJar::hasQueued($key); } - + /** * Get a queued cookie instance. * * @param string $key * @param mixed $default - * @return \Symfony\Component\HttpFoundation\Cookie - * @static + * @return \Symfony\Component\HttpFoundation\Cookie + * @static */ - public static function queued($key, $default = null){ + public static function queued($key, $default = null) + { return \Illuminate\Cookie\CookieJar::queued($key, $default); } - + /** * Queue a cookie to send with the next response. * * @param mixed - * @return void - * @static + * @return void + * @static */ - public static function queue(){ + public static function queue() + { \Illuminate\Cookie\CookieJar::queue(); } - + /** * Remove a cookie from the queue. * * @param string $name - * @return void - * @static + * @return void + * @static */ - public static function unqueue($name){ + public static function unqueue($name) + { \Illuminate\Cookie\CookieJar::unqueue($name); } - + /** * Set the default path and domain for the jar. * * @param string $path * @param string $domain * @param bool $secure - * @return $this - * @static + * @return $this + * @static */ - public static function setDefaultPathAndDomain($path, $domain, $secure = false){ + public static function setDefaultPathAndDomain($path, $domain, $secure = false) + { return \Illuminate\Cookie\CookieJar::setDefaultPathAndDomain($path, $domain, $secure); } - + /** * Get the cookies which have been queued for the next request. * - * @return array - * @static + * @return array + * @static */ - public static function getQueuedCookies(){ + public static function getQueuedCookies() + { return \Illuminate\Cookie\CookieJar::getQueuedCookies(); } - } - - class Crypt extends \Illuminate\Support\Facades\Crypt{ - + class Crypt extends \Illuminate\Support\Facades\Crypt + { /** * Determine if the given key and cipher combination is valid. * * @param string $key * @param string $cipher - * @return bool - * @static + * @return bool + * @static */ - public static function supported($key, $cipher){ + public static function supported($key, $cipher) + { return \Illuminate\Encryption\Encrypter::supported($key, $cipher); } - + /** * Encrypt the given value. * * @param string $value - * @return string + * @return string * @throws \Illuminate\Contracts\Encryption\EncryptException - * @static + * @static */ - public static function encrypt($value){ + public static function encrypt($value) + { return \Illuminate\Encryption\Encrypter::encrypt($value); } - + /** * Decrypt the given value. * * @param string $payload - * @return string + * @return string * @throws \Illuminate\Contracts\Encryption\DecryptException - * @static + * @static */ - public static function decrypt($payload){ + public static function decrypt($payload) + { return \Illuminate\Encryption\Encrypter::decrypt($payload); } - } - - class DB extends \Illuminate\Support\Facades\DB{ - + class DB extends \Illuminate\Support\Facades\DB + { /** * Get a database connection instance. * * @param string $name - * @return \Illuminate\Database\Connection - * @static + * @return \Illuminate\Database\Connection + * @static */ - public static function connection($name = null){ + public static function connection($name = null) + { return \Illuminate\Database\DatabaseManager::connection($name); } - + /** * Disconnect from the given database and remove from local cache. * * @param string $name - * @return void - * @static + * @return void + * @static */ - public static function purge($name = null){ + public static function purge($name = null) + { \Illuminate\Database\DatabaseManager::purge($name); } - + /** * Disconnect from the given database. * * @param string $name - * @return void - * @static + * @return void + * @static */ - public static function disconnect($name = null){ + public static function disconnect($name = null) + { \Illuminate\Database\DatabaseManager::disconnect($name); } - + /** * Reconnect to the given database. * * @param string $name - * @return \Illuminate\Database\Connection - * @static + * @return \Illuminate\Database\Connection + * @static */ - public static function reconnect($name = null){ + public static function reconnect($name = null) + { return \Illuminate\Database\DatabaseManager::reconnect($name); } - + /** * Get the default connection name. * - * @return string - * @static + * @return string + * @static */ - public static function getDefaultConnection(){ + public static function getDefaultConnection() + { return \Illuminate\Database\DatabaseManager::getDefaultConnection(); } - + /** * Set the default connection name. * * @param string $name - * @return void - * @static + * @return void + * @static */ - public static function setDefaultConnection($name){ + public static function setDefaultConnection($name) + { \Illuminate\Database\DatabaseManager::setDefaultConnection($name); } - + /** * Get all of the support drivers. * - * @return array - * @static + * @return array + * @static */ - public static function supportedDrivers(){ + public static function supportedDrivers() + { return \Illuminate\Database\DatabaseManager::supportedDrivers(); } - + /** * Get all of the drivers that are actually available. * - * @return array - * @static + * @return array + * @static */ - public static function availableDrivers(){ + public static function availableDrivers() + { return \Illuminate\Database\DatabaseManager::availableDrivers(); } - + /** * Register an extension connection resolver. * * @param string $name * @param callable $resolver - * @return void - * @static + * @return void + * @static */ - public static function extend($name, $resolver){ + public static function extend($name, $resolver) + { \Illuminate\Database\DatabaseManager::extend($name, $resolver); } - + /** * Return all of the created connections. * - * @return array - * @static + * @return array + * @static */ - public static function getConnections(){ + public static function getConnections() + { return \Illuminate\Database\DatabaseManager::getConnections(); } - + /** * Get a schema builder instance for the connection. * - * @return \Illuminate\Database\Schema\MySqlBuilder - * @static + * @return \Illuminate\Database\Schema\MySqlBuilder + * @static */ - public static function getSchemaBuilder(){ + public static function getSchemaBuilder() + { return \Illuminate\Database\MySqlConnection::getSchemaBuilder(); } - + /** * Set the query grammar to the default implementation. * - * @return void - * @static + * @return void + * @static */ - public static function useDefaultQueryGrammar(){ - //Method inherited from \Illuminate\Database\Connection + public static function useDefaultQueryGrammar() + { + //Method inherited from \Illuminate\Database\Connection \Illuminate\Database\MySqlConnection::useDefaultQueryGrammar(); } - + /** * Set the schema grammar to the default implementation. * - * @return void - * @static + * @return void + * @static */ - public static function useDefaultSchemaGrammar(){ - //Method inherited from \Illuminate\Database\Connection + public static function useDefaultSchemaGrammar() + { + //Method inherited from \Illuminate\Database\Connection \Illuminate\Database\MySqlConnection::useDefaultSchemaGrammar(); } - + /** * Set the query post processor to the default implementation. * - * @return void - * @static + * @return void + * @static */ - public static function useDefaultPostProcessor(){ - //Method inherited from \Illuminate\Database\Connection + public static function useDefaultPostProcessor() + { + //Method inherited from \Illuminate\Database\Connection \Illuminate\Database\MySqlConnection::useDefaultPostProcessor(); } - + /** * Begin a fluent query against a database table. * * @param string $table - * @return \Illuminate\Database\Query\Builder - * @static + * @return \Illuminate\Database\Query\Builder + * @static */ - public static function table($table){ - //Method inherited from \Illuminate\Database\Connection + public static function table($table) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::table($table); } - + /** * Get a new query builder instance. * - * @return \Illuminate\Database\Query\Builder - * @static + * @return \Illuminate\Database\Query\Builder + * @static */ - public static function query(){ - //Method inherited from \Illuminate\Database\Connection + public static function query() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::query(); } - + /** * Get a new raw query expression. * * @param mixed $value - * @return \Illuminate\Database\Query\Expression - * @static + * @return \Illuminate\Database\Query\Expression + * @static */ - public static function raw($value){ - //Method inherited from \Illuminate\Database\Connection + public static function raw($value) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::raw($value); } - + /** * Run a select statement and return a single result. * * @param string $query * @param array $bindings - * @return mixed - * @static + * @return mixed + * @static */ - public static function selectOne($query, $bindings = array()){ - //Method inherited from \Illuminate\Database\Connection + public static function selectOne($query, $bindings = []) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::selectOne($query, $bindings); } - + /** * Run a select statement against the database. * * @param string $query * @param array $bindings - * @return array - * @static + * @return array + * @static */ - public static function selectFromWriteConnection($query, $bindings = array()){ - //Method inherited from \Illuminate\Database\Connection + public static function selectFromWriteConnection($query, $bindings = []) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::selectFromWriteConnection($query, $bindings); } - + /** * Run a select statement against the database. * * @param string $query * @param array $bindings * @param bool $useReadPdo - * @return array - * @static + * @return array + * @static */ - public static function select($query, $bindings = array(), $useReadPdo = true){ - //Method inherited from \Illuminate\Database\Connection + public static function select($query, $bindings = [], $useReadPdo = true) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::select($query, $bindings, $useReadPdo); } - + /** * Run a select statement against the database and returns a generator. * * @param string $query * @param array $bindings * @param bool $useReadPdo - * @return \Generator - * @static + * @return \Generator + * @static */ - public static function cursor($query, $bindings = array(), $useReadPdo = true){ - //Method inherited from \Illuminate\Database\Connection + public static function cursor($query, $bindings = [], $useReadPdo = true) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::cursor($query, $bindings, $useReadPdo); } - + /** * Run an insert statement against the database. * * @param string $query * @param array $bindings - * @return bool - * @static + * @return bool + * @static */ - public static function insert($query, $bindings = array()){ - //Method inherited from \Illuminate\Database\Connection + public static function insert($query, $bindings = []) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::insert($query, $bindings); } - + /** * Run an update statement against the database. * * @param string $query * @param array $bindings - * @return int - * @static + * @return int + * @static */ - public static function update($query, $bindings = array()){ - //Method inherited from \Illuminate\Database\Connection + public static function update($query, $bindings = []) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::update($query, $bindings); } - + /** * Run a delete statement against the database. * * @param string $query * @param array $bindings - * @return int - * @static + * @return int + * @static */ - public static function delete($query, $bindings = array()){ - //Method inherited from \Illuminate\Database\Connection + public static function delete($query, $bindings = []) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::delete($query, $bindings); } - + /** * Execute an SQL statement and return the boolean result. * * @param string $query * @param array $bindings - * @return bool - * @static + * @return bool + * @static */ - public static function statement($query, $bindings = array()){ - //Method inherited from \Illuminate\Database\Connection + public static function statement($query, $bindings = []) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::statement($query, $bindings); } - + /** * Run an SQL statement and get the number of rows affected. * * @param string $query * @param array $bindings - * @return int - * @static + * @return int + * @static */ - public static function affectingStatement($query, $bindings = array()){ - //Method inherited from \Illuminate\Database\Connection + public static function affectingStatement($query, $bindings = []) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::affectingStatement($query, $bindings); } - + /** * Run a raw, unprepared query against the PDO connection. * * @param string $query - * @return bool - * @static + * @return bool + * @static */ - public static function unprepared($query){ - //Method inherited from \Illuminate\Database\Connection + public static function unprepared($query) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::unprepared($query); } - + /** * Prepare the query bindings for execution. * * @param array $bindings - * @return array - * @static + * @return array + * @static */ - public static function prepareBindings($bindings){ - //Method inherited from \Illuminate\Database\Connection + public static function prepareBindings($bindings) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::prepareBindings($bindings); } - + /** * Execute a Closure within a transaction. * * @param \Closure $callback - * @return mixed + * @return mixed * @throws \Exception|\Throwable - * @static + * @static */ - public static function transaction($callback){ - //Method inherited from \Illuminate\Database\Connection + public static function transaction($callback) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::transaction($callback); } - + /** * Start a new database transaction. * - * @return void + * @return void * @throws Exception - * @static + * @static */ - public static function beginTransaction(){ - //Method inherited from \Illuminate\Database\Connection + public static function beginTransaction() + { + //Method inherited from \Illuminate\Database\Connection \Illuminate\Database\MySqlConnection::beginTransaction(); } - + /** * Commit the active database transaction. * - * @return void - * @static + * @return void + * @static */ - public static function commit(){ - //Method inherited from \Illuminate\Database\Connection + public static function commit() + { + //Method inherited from \Illuminate\Database\Connection \Illuminate\Database\MySqlConnection::commit(); } - + /** * Rollback the active database transaction. * - * @return void - * @static + * @return void + * @static */ - public static function rollBack(){ - //Method inherited from \Illuminate\Database\Connection + public static function rollBack() + { + //Method inherited from \Illuminate\Database\Connection \Illuminate\Database\MySqlConnection::rollBack(); } - + /** * Get the number of active transactions. * - * @return int - * @static + * @return int + * @static */ - public static function transactionLevel(){ - //Method inherited from \Illuminate\Database\Connection + public static function transactionLevel() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::transactionLevel(); } - + /** * Execute the given callback in "dry run" mode. * * @param \Closure $callback - * @return array - * @static + * @return array + * @static */ - public static function pretend($callback){ - //Method inherited from \Illuminate\Database\Connection + public static function pretend($callback) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::pretend($callback); } - + /** * Log a query in the connection's query log. * * @param string $query * @param array $bindings * @param float|null $time - * @return void - * @static + * @return void + * @static */ - public static function logQuery($query, $bindings, $time = null){ - //Method inherited from \Illuminate\Database\Connection + public static function logQuery($query, $bindings, $time = null) + { + //Method inherited from \Illuminate\Database\Connection \Illuminate\Database\MySqlConnection::logQuery($query, $bindings, $time); } - + /** * Register a database query listener with the connection. * * @param \Closure $callback - * @return void - * @static + * @return void + * @static */ - public static function listen($callback){ - //Method inherited from \Illuminate\Database\Connection + public static function listen($callback) + { + //Method inherited from \Illuminate\Database\Connection \Illuminate\Database\MySqlConnection::listen($callback); } - + /** * Is Doctrine available? * - * @return bool - * @static + * @return bool + * @static */ - public static function isDoctrineAvailable(){ - //Method inherited from \Illuminate\Database\Connection + public static function isDoctrineAvailable() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::isDoctrineAvailable(); } - + /** * Get a Doctrine Schema Column instance. * * @param string $table * @param string $column - * @return \Doctrine\DBAL\Schema\Column - * @static + * @return \Doctrine\DBAL\Schema\Column + * @static */ - public static function getDoctrineColumn($table, $column){ - //Method inherited from \Illuminate\Database\Connection + public static function getDoctrineColumn($table, $column) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::getDoctrineColumn($table, $column); } - + /** * Get the Doctrine DBAL schema manager for the connection. * - * @return \Doctrine\DBAL\Schema\AbstractSchemaManager - * @static + * @return \Doctrine\DBAL\Schema\AbstractSchemaManager + * @static */ - public static function getDoctrineSchemaManager(){ - //Method inherited from \Illuminate\Database\Connection + public static function getDoctrineSchemaManager() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::getDoctrineSchemaManager(); } - + /** * Get the Doctrine DBAL database connection instance. * - * @return \Doctrine\DBAL\Connection - * @static + * @return \Doctrine\DBAL\Connection + * @static */ - public static function getDoctrineConnection(){ - //Method inherited from \Illuminate\Database\Connection + public static function getDoctrineConnection() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::getDoctrineConnection(); } - + /** * Get the current PDO connection. * - * @return \PDO - * @static + * @return \PDO + * @static */ - public static function getPdo(){ - //Method inherited from \Illuminate\Database\Connection + public static function getPdo() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::getPdo(); } - + /** * Get the current PDO connection used for reading. * - * @return \PDO - * @static + * @return \PDO + * @static */ - public static function getReadPdo(){ - //Method inherited from \Illuminate\Database\Connection + public static function getReadPdo() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::getReadPdo(); } - + /** * Set the PDO connection. * * @param \PDO|null $pdo - * @return $this + * @return $this * @throws \RuntimeException - * @static + * @static */ - public static function setPdo($pdo){ - //Method inherited from \Illuminate\Database\Connection + public static function setPdo($pdo) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::setPdo($pdo); } - + /** * Set the PDO connection used for reading. * * @param \PDO|null $pdo - * @return $this - * @static + * @return $this + * @static */ - public static function setReadPdo($pdo){ - //Method inherited from \Illuminate\Database\Connection + public static function setReadPdo($pdo) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::setReadPdo($pdo); } - + /** * Set the reconnect instance on the connection. * * @param callable $reconnector - * @return $this - * @static + * @return $this + * @static */ - public static function setReconnector($reconnector){ - //Method inherited from \Illuminate\Database\Connection + public static function setReconnector($reconnector) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::setReconnector($reconnector); } - + /** * Get the database connection name. * - * @return string|null - * @static + * @return string|null + * @static */ - public static function getName(){ - //Method inherited from \Illuminate\Database\Connection + public static function getName() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::getName(); } - + /** * Get an option from the configuration options. * * @param string $option - * @return mixed - * @static + * @return mixed + * @static */ - public static function getConfig($option){ - //Method inherited from \Illuminate\Database\Connection + public static function getConfig($option) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::getConfig($option); } - + /** * Get the PDO driver name. * - * @return string - * @static + * @return string + * @static */ - public static function getDriverName(){ - //Method inherited from \Illuminate\Database\Connection + public static function getDriverName() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::getDriverName(); } - + /** * Get the query grammar used by the connection. * - * @return \Illuminate\Database\Query\Grammars\Grammar - * @static + * @return \Illuminate\Database\Query\Grammars\Grammar + * @static */ - public static function getQueryGrammar(){ - //Method inherited from \Illuminate\Database\Connection + public static function getQueryGrammar() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::getQueryGrammar(); } - + /** * Set the query grammar used by the connection. * * @param \Illuminate\Database\Query\Grammars\Grammar $grammar - * @return void - * @static + * @return void + * @static */ - public static function setQueryGrammar($grammar){ - //Method inherited from \Illuminate\Database\Connection + public static function setQueryGrammar($grammar) + { + //Method inherited from \Illuminate\Database\Connection \Illuminate\Database\MySqlConnection::setQueryGrammar($grammar); } - + /** * Get the schema grammar used by the connection. * - * @return \Illuminate\Database\Schema\Grammars\Grammar - * @static + * @return \Illuminate\Database\Schema\Grammars\Grammar + * @static */ - public static function getSchemaGrammar(){ - //Method inherited from \Illuminate\Database\Connection + public static function getSchemaGrammar() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::getSchemaGrammar(); } - + /** * Set the schema grammar used by the connection. * * @param \Illuminate\Database\Schema\Grammars\Grammar $grammar - * @return void - * @static + * @return void + * @static */ - public static function setSchemaGrammar($grammar){ - //Method inherited from \Illuminate\Database\Connection + public static function setSchemaGrammar($grammar) + { + //Method inherited from \Illuminate\Database\Connection \Illuminate\Database\MySqlConnection::setSchemaGrammar($grammar); } - + /** * Get the query post processor used by the connection. * - * @return \Illuminate\Database\Query\Processors\Processor - * @static + * @return \Illuminate\Database\Query\Processors\Processor + * @static */ - public static function getPostProcessor(){ - //Method inherited from \Illuminate\Database\Connection + public static function getPostProcessor() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::getPostProcessor(); } - + /** * Set the query post processor used by the connection. * * @param \Illuminate\Database\Query\Processors\Processor $processor - * @return void - * @static + * @return void + * @static */ - public static function setPostProcessor($processor){ - //Method inherited from \Illuminate\Database\Connection + public static function setPostProcessor($processor) + { + //Method inherited from \Illuminate\Database\Connection \Illuminate\Database\MySqlConnection::setPostProcessor($processor); } - + /** * Get the event dispatcher used by the connection. * - * @return \Illuminate\Contracts\Events\Dispatcher - * @static + * @return \Illuminate\Contracts\Events\Dispatcher + * @static */ - public static function getEventDispatcher(){ - //Method inherited from \Illuminate\Database\Connection + public static function getEventDispatcher() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::getEventDispatcher(); } - + /** * Set the event dispatcher instance on the connection. * * @param \Illuminate\Contracts\Events\Dispatcher $events - * @return void - * @static + * @return void + * @static */ - public static function setEventDispatcher($events){ - //Method inherited from \Illuminate\Database\Connection + public static function setEventDispatcher($events) + { + //Method inherited from \Illuminate\Database\Connection \Illuminate\Database\MySqlConnection::setEventDispatcher($events); } - + /** * Determine if the connection in a "dry run". * - * @return bool - * @static + * @return bool + * @static */ - public static function pretending(){ - //Method inherited from \Illuminate\Database\Connection + public static function pretending() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::pretending(); } - + /** * Get the default fetch mode for the connection. * - * @return int - * @static + * @return int + * @static */ - public static function getFetchMode(){ - //Method inherited from \Illuminate\Database\Connection + public static function getFetchMode() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::getFetchMode(); } - + /** * Get the fetch argument to be applied when selecting. * - * @return mixed - * @static + * @return mixed + * @static */ - public static function getFetchArgument(){ - //Method inherited from \Illuminate\Database\Connection + public static function getFetchArgument() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::getFetchArgument(); } - + /** * Get custom constructor arguments for the PDO::FETCH_CLASS fetch mode. * - * @return array - * @static + * @return array + * @static */ - public static function getFetchConstructorArgument(){ - //Method inherited from \Illuminate\Database\Connection + public static function getFetchConstructorArgument() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::getFetchConstructorArgument(); } - + /** * Set the default fetch mode for the connection, and optional arguments for the given fetch mode. * * @param int $fetchMode * @param mixed $fetchArgument * @param array $fetchConstructorArgument - * @return int - * @static + * @return int + * @static */ - public static function setFetchMode($fetchMode, $fetchArgument = null, $fetchConstructorArgument = array()){ - //Method inherited from \Illuminate\Database\Connection + public static function setFetchMode($fetchMode, $fetchArgument = null, $fetchConstructorArgument = []) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::setFetchMode($fetchMode, $fetchArgument, $fetchConstructorArgument); } - + /** * Get the connection query log. * - * @return array - * @static + * @return array + * @static */ - public static function getQueryLog(){ - //Method inherited from \Illuminate\Database\Connection + public static function getQueryLog() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::getQueryLog(); } - + /** * Clear the query log. * - * @return void - * @static + * @return void + * @static */ - public static function flushQueryLog(){ - //Method inherited from \Illuminate\Database\Connection + public static function flushQueryLog() + { + //Method inherited from \Illuminate\Database\Connection \Illuminate\Database\MySqlConnection::flushQueryLog(); } - + /** * Enable the query log on the connection. * - * @return void - * @static + * @return void + * @static */ - public static function enableQueryLog(){ - //Method inherited from \Illuminate\Database\Connection + public static function enableQueryLog() + { + //Method inherited from \Illuminate\Database\Connection \Illuminate\Database\MySqlConnection::enableQueryLog(); } - + /** * Disable the query log on the connection. * - * @return void - * @static + * @return void + * @static */ - public static function disableQueryLog(){ - //Method inherited from \Illuminate\Database\Connection + public static function disableQueryLog() + { + //Method inherited from \Illuminate\Database\Connection \Illuminate\Database\MySqlConnection::disableQueryLog(); } - + /** * Determine whether we're logging queries. * - * @return bool - * @static + * @return bool + * @static */ - public static function logging(){ - //Method inherited from \Illuminate\Database\Connection + public static function logging() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::logging(); } - + /** * Get the name of the connected database. * - * @return string - * @static + * @return string + * @static */ - public static function getDatabaseName(){ - //Method inherited from \Illuminate\Database\Connection + public static function getDatabaseName() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::getDatabaseName(); } - + /** * Set the name of the connected database. * * @param string $database - * @return string - * @static + * @return string + * @static */ - public static function setDatabaseName($database){ - //Method inherited from \Illuminate\Database\Connection + public static function setDatabaseName($database) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::setDatabaseName($database); } - + /** * Get the table prefix for the connection. * - * @return string - * @static + * @return string + * @static */ - public static function getTablePrefix(){ - //Method inherited from \Illuminate\Database\Connection + public static function getTablePrefix() + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::getTablePrefix(); } - + /** * Set the table prefix in use by the connection. * * @param string $prefix - * @return void - * @static + * @return void + * @static */ - public static function setTablePrefix($prefix){ - //Method inherited from \Illuminate\Database\Connection + public static function setTablePrefix($prefix) + { + //Method inherited from \Illuminate\Database\Connection \Illuminate\Database\MySqlConnection::setTablePrefix($prefix); } - + /** * Set the table prefix and return the grammar. * * @param \Illuminate\Database\Grammar $grammar - * @return \Illuminate\Database\Grammar - * @static + * @return \Illuminate\Database\Grammar + * @static */ - public static function withTablePrefix($grammar){ - //Method inherited from \Illuminate\Database\Connection + public static function withTablePrefix($grammar) + { + //Method inherited from \Illuminate\Database\Connection return \Illuminate\Database\MySqlConnection::withTablePrefix($grammar); } - } - - class Eloquent extends \Illuminate\Database\Eloquent\Model{ - + class Eloquent extends \Illuminate\Database\Eloquent\Model + { /** * Register a new global scope. * * @param string $identifier * @param \Illuminate\Database\Eloquent\Scope|\Closure $scope - * @return $this - * @static + * @return $this + * @static */ - public static function withGlobalScope($identifier, $scope){ + public static function withGlobalScope($identifier, $scope) + { return \Illuminate\Database\Eloquent\Builder::withGlobalScope($identifier, $scope); } - + /** * Remove a registered global scope. * * @param \Illuminate\Database\Eloquent\Scope|string $scope - * @return $this - * @static + * @return $this + * @static */ - public static function withoutGlobalScope($scope){ + public static function withoutGlobalScope($scope) + { return \Illuminate\Database\Eloquent\Builder::withoutGlobalScope($scope); } - + /** * Remove all or passed registered global scopes. * * @param array|null $scopes - * @return $this - * @static + * @return $this + * @static */ - public static function withoutGlobalScopes($scopes = null){ + public static function withoutGlobalScopes($scopes = null) + { return \Illuminate\Database\Eloquent\Builder::withoutGlobalScopes($scopes); } - + /** * Get an array of global scopes that were removed from the query. * - * @return array - * @static + * @return array + * @static */ - public static function removedScopes(){ + public static function removedScopes() + { return \Illuminate\Database\Eloquent\Builder::removedScopes(); } - + /** * Find a model by its primary key. * * @param mixed $id * @param array $columns - * @return \Illuminate\Database\Eloquent\Model|\Illuminate\Database\Eloquent\Collection|static[]|static|null - * @static + * @return \Illuminate\Database\Eloquent\Model|\Illuminate\Database\Eloquent\Collection|static[]|static|null + * @static */ - public static function find($id, $columns = array()){ + public static function find($id, $columns = []) + { return \Illuminate\Database\Eloquent\Builder::find($id, $columns); } - + /** * Find multiple models by their primary keys. * * @param array $ids * @param array $columns - * @return \Illuminate\Database\Eloquent\Collection - * @static + * @return \Illuminate\Database\Eloquent\Collection + * @static */ - public static function findMany($ids, $columns = array()){ + public static function findMany($ids, $columns = []) + { return \Illuminate\Database\Eloquent\Builder::findMany($ids, $columns); } - + /** * Find a model by its primary key or throw an exception. * * @param mixed $id * @param array $columns - * @return \Illuminate\Database\Eloquent\Model|\Illuminate\Database\Eloquent\Collection + * @return \Illuminate\Database\Eloquent\Model|\Illuminate\Database\Eloquent\Collection * @throws \Illuminate\Database\Eloquent\ModelNotFoundException - * @static + * @static */ - public static function findOrFail($id, $columns = array()){ + public static function findOrFail($id, $columns = []) + { return \Illuminate\Database\Eloquent\Builder::findOrFail($id, $columns); } - + /** * Find a model by its primary key or return fresh model instance. * * @param mixed $id * @param array $columns - * @return \Illuminate\Database\Eloquent\Model - * @static + * @return \Illuminate\Database\Eloquent\Model + * @static */ - public static function findOrNew($id, $columns = array()){ + public static function findOrNew($id, $columns = []) + { return \Illuminate\Database\Eloquent\Builder::findOrNew($id, $columns); } - + /** * Get the first record matching the attributes or instantiate it. * * @param array $attributes - * @return \Illuminate\Database\Eloquent\Model - * @static + * @return \Illuminate\Database\Eloquent\Model + * @static */ - public static function firstOrNew($attributes){ + public static function firstOrNew($attributes) + { return \Illuminate\Database\Eloquent\Builder::firstOrNew($attributes); } - + /** * Get the first record matching the attributes or create it. * * @param array $attributes - * @return \Illuminate\Database\Eloquent\Model - * @static + * @return \Illuminate\Database\Eloquent\Model + * @static */ - public static function firstOrCreate($attributes){ + public static function firstOrCreate($attributes) + { return \Illuminate\Database\Eloquent\Builder::firstOrCreate($attributes); } - + /** * Create or update a record matching the attributes, and fill it with values. * * @param array $attributes * @param array $values - * @return \Illuminate\Database\Eloquent\Model - * @static + * @return \Illuminate\Database\Eloquent\Model + * @static */ - public static function updateOrCreate($attributes, $values = array()){ + public static function updateOrCreate($attributes, $values = []) + { return \Illuminate\Database\Eloquent\Builder::updateOrCreate($attributes, $values); } - + /** * Execute the query and get the first result. * * @param array $columns - * @return \Illuminate\Database\Eloquent\Model|static|null - * @static + * @return \Illuminate\Database\Eloquent\Model|static|null + * @static */ - public static function first($columns = array()){ + public static function first($columns = []) + { return \Illuminate\Database\Eloquent\Builder::first($columns); } - + /** * Execute the query and get the first result or throw an exception. * * @param array $columns - * @return \Illuminate\Database\Eloquent\Model|static + * @return \Illuminate\Database\Eloquent\Model|static * @throws \Illuminate\Database\Eloquent\ModelNotFoundException - * @static + * @static */ - public static function firstOrFail($columns = array()){ + public static function firstOrFail($columns = []) + { return \Illuminate\Database\Eloquent\Builder::firstOrFail($columns); } - + /** * Execute the query as a "select" statement. * * @param array $columns - * @return \Illuminate\Database\Eloquent\Collection|static[] - * @static + * @return \Illuminate\Database\Eloquent\Collection|static[] + * @static */ - public static function get($columns = array()){ + public static function get($columns = []) + { return \Illuminate\Database\Eloquent\Builder::get($columns); } - + /** * Get a single column's value from the first result of a query. * * @param string $column - * @return mixed - * @static + * @return mixed + * @static */ - public static function value($column){ + public static function value($column) + { return \Illuminate\Database\Eloquent\Builder::value($column); } - + /** * Get a generator for the given query. * - * @return \Generator - * @static + * @return \Generator + * @static */ - public static function cursor(){ + public static function cursor() + { return \Illuminate\Database\Eloquent\Builder::cursor(); } - + /** * Chunk the results of the query. * * @param int $count * @param callable $callback - * @return bool - * @static + * @return bool + * @static */ - public static function chunk($count, $callback){ + public static function chunk($count, $callback) + { return \Illuminate\Database\Eloquent\Builder::chunk($count, $callback); } - + /** * Chunk the results of a query by comparing numeric IDs. * * @param int $count * @param callable $callback * @param string $column - * @return bool - * @static + * @return bool + * @static */ - public static function chunkById($count, $callback, $column = 'id'){ + public static function chunkById($count, $callback, $column = 'id') + { return \Illuminate\Database\Eloquent\Builder::chunkById($count, $callback, $column); } - + /** * Execute a callback over each item while chunking. * * @param callable $callback * @param int $count - * @return bool - * @static + * @return bool + * @static */ - public static function each($callback, $count = 1000){ + public static function each($callback, $count = 1000) + { return \Illuminate\Database\Eloquent\Builder::each($callback, $count); } - + /** * Get an array with the values of a given column. * * @param string $column * @param string|null $key - * @return \Illuminate\Support\Collection - * @static + * @return \Illuminate\Support\Collection + * @static */ - public static function pluck($column, $key = null){ + public static function pluck($column, $key = null) + { return \Illuminate\Database\Eloquent\Builder::pluck($column, $key); } - + /** * Alias for the "pluck" method. * * @param string $column * @param string $key - * @return \Illuminate\Support\Collection + * @return \Illuminate\Support\Collection * @deprecated since version 5.2. Use the "pluck" method directly. - * @static + * @static */ - public static function lists($column, $key = null){ + public static function lists($column, $key = null) + { return \Illuminate\Database\Eloquent\Builder::lists($column, $key); } - + /** * Paginate the given query. * @@ -3644,14 +3940,15 @@ public static function lists($column, $key = null){ * @param array $columns * @param string $pageName * @param int|null $page - * @return \Illuminate\Contracts\Pagination\LengthAwarePaginator + * @return \Illuminate\Contracts\Pagination\LengthAwarePaginator * @throws \InvalidArgumentException - * @static + * @static */ - public static function paginate($perPage = null, $columns = array(), $pageName = 'page', $page = null){ + public static function paginate($perPage = null, $columns = [], $pageName = 'page', $page = null) + { return \Illuminate\Database\Eloquent\Builder::paginate($perPage, $columns, $pageName, $page); } - + /** * Paginate the given query into a simple paginator. * @@ -3659,58 +3956,63 @@ public static function paginate($perPage = null, $columns = array(), $pageName = * @param array $columns * @param string $pageName * @param int|null $page - * @return \Illuminate\Contracts\Pagination\Paginator - * @static + * @return \Illuminate\Contracts\Pagination\Paginator + * @static */ - public static function simplePaginate($perPage = null, $columns = array(), $pageName = 'page', $page = null){ + public static function simplePaginate($perPage = null, $columns = [], $pageName = 'page', $page = null) + { return \Illuminate\Database\Eloquent\Builder::simplePaginate($perPage, $columns, $pageName, $page); } - + /** * Register a replacement for the default delete function. * * @param \Closure $callback - * @return void - * @static + * @return void + * @static */ - public static function onDelete($callback){ + public static function onDelete($callback) + { \Illuminate\Database\Eloquent\Builder::onDelete($callback); } - + /** * Get the hydrated models without eager loading. * * @param array $columns - * @return \Illuminate\Database\Eloquent\Model[] - * @static + * @return \Illuminate\Database\Eloquent\Model[] + * @static */ - public static function getModels($columns = array()){ + public static function getModels($columns = []) + { return \Illuminate\Database\Eloquent\Builder::getModels($columns); } - + /** * Eager load the relationships for the models. * * @param array $models - * @return array - * @static + * @return array + * @static */ - public static function eagerLoadRelations($models){ + public static function eagerLoadRelations($models) + { return \Illuminate\Database\Eloquent\Builder::eagerLoadRelations($models); } - + /** * Apply the callback's query changes if the given "value" is true. * * @param bool $value * @param \Closure $callback - * @return $this - * @static + * @return $this + * @static */ - public static function when($value, $callback){ + public static function when($value, $callback) + { return \Illuminate\Database\Eloquent\Builder::when($value, $callback); } - + /** * Add a basic where clause to the query. * @@ -3718,26 +4020,28 @@ public static function when($value, $callback){ * @param string $operator * @param mixed $value * @param string $boolean - * @return $this - * @static + * @return $this + * @static */ - public static function where($column, $operator = null, $value = null, $boolean = 'and'){ + public static function where($column, $operator = null, $value = null, $boolean = 'and') + { return \Illuminate\Database\Eloquent\Builder::where($column, $operator, $value, $boolean); } - + /** * Add an "or where" clause to the query. * * @param string $column * @param string $operator * @param mixed $value - * @return \Illuminate\Database\Eloquent\Builder|static - * @static + * @return \Illuminate\Database\Eloquent\Builder|static + * @static */ - public static function orWhere($column, $operator = null, $value = null){ + public static function orWhere($column, $operator = null, $value = null) + { return \Illuminate\Database\Eloquent\Builder::orWhere($column, $operator, $value); } - + /** * Add a relationship count / exists condition to the query. * @@ -3746,26 +4050,28 @@ public static function orWhere($column, $operator = null, $value = null){ * @param int $count * @param string $boolean * @param \Closure|null $callback - * @return \Illuminate\Database\Eloquent\Builder|static - * @static + * @return \Illuminate\Database\Eloquent\Builder|static + * @static */ - public static function has($relation, $operator = '>=', $count = 1, $boolean = 'and', $callback = null){ + public static function has($relation, $operator = '>=', $count = 1, $boolean = 'and', $callback = null) + { return \Illuminate\Database\Eloquent\Builder::has($relation, $operator, $count, $boolean, $callback); } - + /** * Add a relationship count / exists condition to the query. * * @param string $relation * @param string $boolean * @param \Closure|null $callback - * @return \Illuminate\Database\Eloquent\Builder|static - * @static + * @return \Illuminate\Database\Eloquent\Builder|static + * @static */ - public static function doesntHave($relation, $boolean = 'and', $callback = null){ + public static function doesntHave($relation, $boolean = 'and', $callback = null) + { return \Illuminate\Database\Eloquent\Builder::doesntHave($relation, $boolean, $callback); } - + /** * Add a relationship count / exists condition to the query with where clauses. * @@ -3773,38 +4079,41 @@ public static function doesntHave($relation, $boolean = 'and', $callback = null) * @param \Closure $callback * @param string $operator * @param int $count - * @return \Illuminate\Database\Eloquent\Builder|static - * @static + * @return \Illuminate\Database\Eloquent\Builder|static + * @static */ - public static function whereHas($relation, $callback, $operator = '>=', $count = 1){ + public static function whereHas($relation, $callback, $operator = '>=', $count = 1) + { return \Illuminate\Database\Eloquent\Builder::whereHas($relation, $callback, $operator, $count); } - + /** * Add a relationship count / exists condition to the query with where clauses. * * @param string $relation * @param \Closure|null $callback - * @return \Illuminate\Database\Eloquent\Builder|static - * @static + * @return \Illuminate\Database\Eloquent\Builder|static + * @static */ - public static function whereDoesntHave($relation, $callback = null){ + public static function whereDoesntHave($relation, $callback = null) + { return \Illuminate\Database\Eloquent\Builder::whereDoesntHave($relation, $callback); } - + /** * Add a relationship count / exists condition to the query with an "or". * * @param string $relation * @param string $operator * @param int $count - * @return \Illuminate\Database\Eloquent\Builder|static - * @static + * @return \Illuminate\Database\Eloquent\Builder|static + * @static */ - public static function orHas($relation, $operator = '>=', $count = 1){ + public static function orHas($relation, $operator = '>=', $count = 1) + { return \Illuminate\Database\Eloquent\Builder::orHas($relation, $operator, $count); } - + /** * Add a relationship count / exists condition to the query with where clauses and an "or". * @@ -3812,231 +4121,252 @@ public static function orHas($relation, $operator = '>=', $count = 1){ * @param \Closure $callback * @param string $operator * @param int $count - * @return \Illuminate\Database\Eloquent\Builder|static - * @static + * @return \Illuminate\Database\Eloquent\Builder|static + * @static */ - public static function orWhereHas($relation, $callback, $operator = '>=', $count = 1){ + public static function orWhereHas($relation, $callback, $operator = '>=', $count = 1) + { return \Illuminate\Database\Eloquent\Builder::orWhereHas($relation, $callback, $operator, $count); } - + /** * Merge the constraints from a relation query to the current query. * * @param \Illuminate\Database\Eloquent\Builder $relation - * @return \Illuminate\Database\Eloquent\Builder|static - * @static + * @return \Illuminate\Database\Eloquent\Builder|static + * @static */ - public static function mergeModelDefinedRelationConstraints($relation){ + public static function mergeModelDefinedRelationConstraints($relation) + { return \Illuminate\Database\Eloquent\Builder::mergeModelDefinedRelationConstraints($relation); } - + /** * Prevent the specified relations from being eager loaded. * * @param mixed $relations - * @return $this - * @static + * @return $this + * @static */ - public static function without($relations){ + public static function without($relations) + { return \Illuminate\Database\Eloquent\Builder::without($relations); } - + /** * Add subselect queries to count the relations. * * @param mixed $relations - * @return $this - * @static + * @return $this + * @static */ - public static function withCount($relations){ + public static function withCount($relations) + { return \Illuminate\Database\Eloquent\Builder::withCount($relations); } - + /** * Add the given scopes to the current builder instance. * * @param array $scopes - * @return mixed - * @static + * @return mixed + * @static */ - public static function scopes($scopes){ + public static function scopes($scopes) + { return \Illuminate\Database\Eloquent\Builder::scopes($scopes); } - + /** * Apply the scopes to the Eloquent builder instance and return it. * - * @return \Illuminate\Database\Eloquent\Builder|static - * @static + * @return \Illuminate\Database\Eloquent\Builder|static + * @static */ - public static function applyScopes(){ + public static function applyScopes() + { return \Illuminate\Database\Eloquent\Builder::applyScopes(); } - + /** * Get the underlying query builder instance. * - * @return \Illuminate\Database\Query\Builder - * @static + * @return \Illuminate\Database\Query\Builder + * @static */ - public static function getQuery(){ + public static function getQuery() + { return \Illuminate\Database\Eloquent\Builder::getQuery(); } - + /** * Get a base query builder instance. * - * @return \Illuminate\Database\Query\Builder - * @static + * @return \Illuminate\Database\Query\Builder + * @static */ - public static function toBase(){ + public static function toBase() + { return \Illuminate\Database\Eloquent\Builder::toBase(); } - + /** * Set the underlying query builder instance. * * @param \Illuminate\Database\Query\Builder $query - * @return $this - * @static + * @return $this + * @static */ - public static function setQuery($query){ + public static function setQuery($query) + { return \Illuminate\Database\Eloquent\Builder::setQuery($query); } - + /** * Get the relationships being eagerly loaded. * - * @return array - * @static + * @return array + * @static */ - public static function getEagerLoads(){ + public static function getEagerLoads() + { return \Illuminate\Database\Eloquent\Builder::getEagerLoads(); } - + /** * Set the relationships being eagerly loaded. * * @param array $eagerLoad - * @return $this - * @static + * @return $this + * @static */ - public static function setEagerLoads($eagerLoad){ + public static function setEagerLoads($eagerLoad) + { return \Illuminate\Database\Eloquent\Builder::setEagerLoads($eagerLoad); } - + /** * Get the model instance being queried. * - * @return \Illuminate\Database\Eloquent\Model - * @static + * @return \Illuminate\Database\Eloquent\Model + * @static */ - public static function getModel(){ + public static function getModel() + { return \Illuminate\Database\Eloquent\Builder::getModel(); } - + /** * Set a model instance for the model being queried. * * @param \Illuminate\Database\Eloquent\Model $model - * @return $this - * @static + * @return $this + * @static */ - public static function setModel($model){ + public static function setModel($model) + { return \Illuminate\Database\Eloquent\Builder::setModel($model); } - + /** * Extend the builder with a given callback. * * @param string $name * @param \Closure $callback - * @return void - * @static + * @return void + * @static */ - public static function macro($name, $callback){ + public static function macro($name, $callback) + { \Illuminate\Database\Eloquent\Builder::macro($name, $callback); } - + /** * Get the given macro by name. * * @param string $name - * @return \Closure - * @static + * @return \Closure + * @static */ - public static function getMacro($name){ + public static function getMacro($name) + { return \Illuminate\Database\Eloquent\Builder::getMacro($name); } - + /** * Set the columns to be selected. * * @param array|mixed $columns - * @return $this - * @static + * @return $this + * @static */ - public static function select($columns = array()){ + public static function select($columns = []) + { return \Illuminate\Database\Query\Builder::select($columns); } - + /** * Add a new "raw" select expression to the query. * * @param string $expression * @param array $bindings - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function selectRaw($expression, $bindings = array()){ + public static function selectRaw($expression, $bindings = []) + { return \Illuminate\Database\Query\Builder::selectRaw($expression, $bindings); } - + /** * Add a subselect expression to the query. * * @param \Closure|\Illuminate\Database\Query\Builder|string $query * @param string $as - * @return \Illuminate\Database\Query\Builder|static + * @return \Illuminate\Database\Query\Builder|static * @throws \InvalidArgumentException - * @static + * @static */ - public static function selectSub($query, $as){ + public static function selectSub($query, $as) + { return \Illuminate\Database\Query\Builder::selectSub($query, $as); } - + /** * Add a new select column to the query. * * @param array|mixed $column - * @return $this - * @static + * @return $this + * @static */ - public static function addSelect($column){ + public static function addSelect($column) + { return \Illuminate\Database\Query\Builder::addSelect($column); } - + /** * Force the query to only return distinct results. * - * @return $this - * @static + * @return $this + * @static */ - public static function distinct(){ + public static function distinct() + { return \Illuminate\Database\Query\Builder::distinct(); } - + /** * Set the table which the query is targeting. * * @param string $table - * @return $this - * @static + * @return $this + * @static */ - public static function from($table){ + public static function from($table) + { return \Illuminate\Database\Query\Builder::from($table); } - + /** * Add a join clause to the query. * @@ -4046,13 +4376,14 @@ public static function from($table){ * @param string $two * @param string $type * @param bool $where - * @return $this - * @static + * @return $this + * @static */ - public static function join($table, $one, $operator = null, $two = null, $type = 'inner', $where = false){ + public static function join($table, $one, $operator = null, $two = null, $type = 'inner', $where = false) + { return \Illuminate\Database\Query\Builder::join($table, $one, $operator, $two, $type, $where); } - + /** * Add a "join where" clause to the query. * @@ -4061,13 +4392,14 @@ public static function join($table, $one, $operator = null, $two = null, $type = * @param string $operator * @param string $two * @param string $type - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function joinWhere($table, $one, $operator, $two, $type = 'inner'){ + public static function joinWhere($table, $one, $operator, $two, $type = 'inner') + { return \Illuminate\Database\Query\Builder::joinWhere($table, $one, $operator, $two, $type); } - + /** * Add a left join to the query. * @@ -4075,13 +4407,14 @@ public static function joinWhere($table, $one, $operator, $two, $type = 'inner') * @param string $first * @param string $operator * @param string $second - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function leftJoin($table, $first, $operator = null, $second = null){ + public static function leftJoin($table, $first, $operator = null, $second = null) + { return \Illuminate\Database\Query\Builder::leftJoin($table, $first, $operator, $second); } - + /** * Add a "join where" clause to the query. * @@ -4089,13 +4422,14 @@ public static function leftJoin($table, $first, $operator = null, $second = null * @param string $one * @param string $operator * @param string $two - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function leftJoinWhere($table, $one, $operator, $two){ + public static function leftJoinWhere($table, $one, $operator, $two) + { return \Illuminate\Database\Query\Builder::leftJoinWhere($table, $one, $operator, $two); } - + /** * Add a right join to the query. * @@ -4103,13 +4437,14 @@ public static function leftJoinWhere($table, $one, $operator, $two){ * @param string $first * @param string $operator * @param string $second - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function rightJoin($table, $first, $operator = null, $second = null){ + public static function rightJoin($table, $first, $operator = null, $second = null) + { return \Illuminate\Database\Query\Builder::rightJoin($table, $first, $operator, $second); } - + /** * Add a "right join where" clause to the query. * @@ -4117,13 +4452,14 @@ public static function rightJoin($table, $first, $operator = null, $second = nul * @param string $one * @param string $operator * @param string $two - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function rightJoinWhere($table, $one, $operator, $two){ + public static function rightJoinWhere($table, $one, $operator, $two) + { return \Illuminate\Database\Query\Builder::rightJoinWhere($table, $one, $operator, $two); } - + /** * Add a "cross join" clause to the query. * @@ -4131,13 +4467,14 @@ public static function rightJoinWhere($table, $one, $operator, $two){ * @param string $first * @param string $operator * @param string $second - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function crossJoin($table, $first = null, $operator = null, $second = null){ + public static function crossJoin($table, $first = null, $operator = null, $second = null) + { return \Illuminate\Database\Query\Builder::crossJoin($table, $first, $operator, $second); } - + /** * Add a "where" clause comparing two columns to the query. * @@ -4145,51 +4482,55 @@ public static function crossJoin($table, $first = null, $operator = null, $secon * @param string|null $operator * @param string|null $second * @param string|null $boolean - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function whereColumn($first, $operator = null, $second = null, $boolean = 'and'){ + public static function whereColumn($first, $operator = null, $second = null, $boolean = 'and') + { return \Illuminate\Database\Query\Builder::whereColumn($first, $operator, $second, $boolean); } - + /** * Add an "or where" clause comparing two columns to the query. * * @param string|array $first * @param string|null $operator * @param string|null $second - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function orWhereColumn($first, $operator = null, $second = null){ + public static function orWhereColumn($first, $operator = null, $second = null) + { return \Illuminate\Database\Query\Builder::orWhereColumn($first, $operator, $second); } - + /** * Add a raw where clause to the query. * * @param string $sql * @param array $bindings * @param string $boolean - * @return $this - * @static + * @return $this + * @static */ - public static function whereRaw($sql, $bindings = array(), $boolean = 'and'){ + public static function whereRaw($sql, $bindings = [], $boolean = 'and') + { return \Illuminate\Database\Query\Builder::whereRaw($sql, $bindings, $boolean); } - + /** * Add a raw or where clause to the query. * * @param string $sql * @param array $bindings - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function orWhereRaw($sql, $bindings = array()){ + public static function orWhereRaw($sql, $bindings = []) + { return \Illuminate\Database\Query\Builder::orWhereRaw($sql, $bindings); } - + /** * Add a where between statement to the query. * @@ -4197,145 +4538,157 @@ public static function orWhereRaw($sql, $bindings = array()){ * @param array $values * @param string $boolean * @param bool $not - * @return $this - * @static + * @return $this + * @static */ - public static function whereBetween($column, $values, $boolean = 'and', $not = false){ + public static function whereBetween($column, $values, $boolean = 'and', $not = false) + { return \Illuminate\Database\Query\Builder::whereBetween($column, $values, $boolean, $not); } - + /** * Add an or where between statement to the query. * * @param string $column * @param array $values - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function orWhereBetween($column, $values){ + public static function orWhereBetween($column, $values) + { return \Illuminate\Database\Query\Builder::orWhereBetween($column, $values); } - + /** * Add a where not between statement to the query. * * @param string $column * @param array $values * @param string $boolean - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function whereNotBetween($column, $values, $boolean = 'and'){ + public static function whereNotBetween($column, $values, $boolean = 'and') + { return \Illuminate\Database\Query\Builder::whereNotBetween($column, $values, $boolean); } - + /** * Add an or where not between statement to the query. * * @param string $column * @param array $values - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function orWhereNotBetween($column, $values){ + public static function orWhereNotBetween($column, $values) + { return \Illuminate\Database\Query\Builder::orWhereNotBetween($column, $values); } - + /** * Add a nested where statement to the query. * * @param \Closure $callback * @param string $boolean - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function whereNested($callback, $boolean = 'and'){ + public static function whereNested($callback, $boolean = 'and') + { return \Illuminate\Database\Query\Builder::whereNested($callback, $boolean); } - + /** * Create a new query instance for nested where condition. * - * @return \Illuminate\Database\Query\Builder - * @static + * @return \Illuminate\Database\Query\Builder + * @static */ - public static function forNestedWhere(){ + public static function forNestedWhere() + { return \Illuminate\Database\Query\Builder::forNestedWhere(); } - + /** * Add another query builder as a nested where to the query builder. * * @param \Illuminate\Database\Query\Builder|static $query * @param string $boolean - * @return $this - * @static + * @return $this + * @static */ - public static function addNestedWhereQuery($query, $boolean = 'and'){ + public static function addNestedWhereQuery($query, $boolean = 'and') + { return \Illuminate\Database\Query\Builder::addNestedWhereQuery($query, $boolean); } - + /** * Add an exists clause to the query. * * @param \Closure $callback * @param string $boolean * @param bool $not - * @return $this - * @static + * @return $this + * @static */ - public static function whereExists($callback, $boolean = 'and', $not = false){ + public static function whereExists($callback, $boolean = 'and', $not = false) + { return \Illuminate\Database\Query\Builder::whereExists($callback, $boolean, $not); } - + /** * Add an or exists clause to the query. * * @param \Closure $callback * @param bool $not - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function orWhereExists($callback, $not = false){ + public static function orWhereExists($callback, $not = false) + { return \Illuminate\Database\Query\Builder::orWhereExists($callback, $not); } - + /** * Add a where not exists clause to the query. * * @param \Closure $callback * @param string $boolean - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function whereNotExists($callback, $boolean = 'and'){ + public static function whereNotExists($callback, $boolean = 'and') + { return \Illuminate\Database\Query\Builder::whereNotExists($callback, $boolean); } - + /** * Add a where not exists clause to the query. * * @param \Closure $callback - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function orWhereNotExists($callback){ + public static function orWhereNotExists($callback) + { return \Illuminate\Database\Query\Builder::orWhereNotExists($callback); } - + /** * Add an exists clause to the query. * * @param \Illuminate\Database\Query\Builder $query * @param string $boolean * @param bool $not - * @return $this - * @static + * @return $this + * @static */ - public static function addWhereExistsQuery($query, $boolean = 'and', $not = false){ + public static function addWhereExistsQuery($query, $boolean = 'and', $not = false) + { return \Illuminate\Database\Query\Builder::addWhereExistsQuery($query, $boolean, $not); } - + /** * Add a "where in" clause to the query. * @@ -4343,97 +4696,105 @@ public static function addWhereExistsQuery($query, $boolean = 'and', $not = fals * @param mixed $values * @param string $boolean * @param bool $not - * @return $this - * @static + * @return $this + * @static */ - public static function whereIn($column, $values, $boolean = 'and', $not = false){ + public static function whereIn($column, $values, $boolean = 'and', $not = false) + { return \Illuminate\Database\Query\Builder::whereIn($column, $values, $boolean, $not); } - + /** * Add an "or where in" clause to the query. * * @param string $column * @param mixed $values - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function orWhereIn($column, $values){ + public static function orWhereIn($column, $values) + { return \Illuminate\Database\Query\Builder::orWhereIn($column, $values); } - + /** * Add a "where not in" clause to the query. * * @param string $column * @param mixed $values * @param string $boolean - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function whereNotIn($column, $values, $boolean = 'and'){ + public static function whereNotIn($column, $values, $boolean = 'and') + { return \Illuminate\Database\Query\Builder::whereNotIn($column, $values, $boolean); } - + /** * Add an "or where not in" clause to the query. * * @param string $column * @param mixed $values - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function orWhereNotIn($column, $values){ + public static function orWhereNotIn($column, $values) + { return \Illuminate\Database\Query\Builder::orWhereNotIn($column, $values); } - + /** * Add a "where null" clause to the query. * * @param string $column * @param string $boolean * @param bool $not - * @return $this - * @static + * @return $this + * @static */ - public static function whereNull($column, $boolean = 'and', $not = false){ + public static function whereNull($column, $boolean = 'and', $not = false) + { return \Illuminate\Database\Query\Builder::whereNull($column, $boolean, $not); } - + /** * Add an "or where null" clause to the query. * * @param string $column - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function orWhereNull($column){ + public static function orWhereNull($column) + { return \Illuminate\Database\Query\Builder::orWhereNull($column); } - + /** * Add a "where not null" clause to the query. * * @param string $column * @param string $boolean - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function whereNotNull($column, $boolean = 'and'){ + public static function whereNotNull($column, $boolean = 'and') + { return \Illuminate\Database\Query\Builder::whereNotNull($column, $boolean); } - + /** * Add an "or where not null" clause to the query. * * @param string $column - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function orWhereNotNull($column){ + public static function orWhereNotNull($column) + { return \Illuminate\Database\Query\Builder::orWhereNotNull($column); } - + /** * Add a "where date" statement to the query. * @@ -4441,26 +4802,28 @@ public static function orWhereNotNull($column){ * @param string $operator * @param int $value * @param string $boolean - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function whereDate($column, $operator, $value, $boolean = 'and'){ + public static function whereDate($column, $operator, $value, $boolean = 'and') + { return \Illuminate\Database\Query\Builder::whereDate($column, $operator, $value, $boolean); } - + /** * Add an "or where date" statement to the query. * * @param string $column * @param string $operator * @param int $value - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function orWhereDate($column, $operator, $value){ + public static function orWhereDate($column, $operator, $value) + { return \Illuminate\Database\Query\Builder::orWhereDate($column, $operator, $value); } - + /** * Add a "where time" statement to the query. * @@ -4468,26 +4831,28 @@ public static function orWhereDate($column, $operator, $value){ * @param string $operator * @param int $value * @param string $boolean - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function whereTime($column, $operator, $value, $boolean = 'and'){ + public static function whereTime($column, $operator, $value, $boolean = 'and') + { return \Illuminate\Database\Query\Builder::whereTime($column, $operator, $value, $boolean); } - + /** * Add an "or where time" statement to the query. * * @param string $column * @param string $operator * @param int $value - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function orWhereTime($column, $operator, $value){ + public static function orWhereTime($column, $operator, $value) + { return \Illuminate\Database\Query\Builder::orWhereTime($column, $operator, $value); } - + /** * Add a "where day" statement to the query. * @@ -4495,13 +4860,14 @@ public static function orWhereTime($column, $operator, $value){ * @param string $operator * @param int $value * @param string $boolean - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function whereDay($column, $operator, $value, $boolean = 'and'){ + public static function whereDay($column, $operator, $value, $boolean = 'and') + { return \Illuminate\Database\Query\Builder::whereDay($column, $operator, $value, $boolean); } - + /** * Add a "where month" statement to the query. * @@ -4509,13 +4875,14 @@ public static function whereDay($column, $operator, $value, $boolean = 'and'){ * @param string $operator * @param int $value * @param string $boolean - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function whereMonth($column, $operator, $value, $boolean = 'and'){ + public static function whereMonth($column, $operator, $value, $boolean = 'and') + { return \Illuminate\Database\Query\Builder::whereMonth($column, $operator, $value, $boolean); } - + /** * Add a "where year" statement to the query. * @@ -4523,36 +4890,39 @@ public static function whereMonth($column, $operator, $value, $boolean = 'and'){ * @param string $operator * @param int $value * @param string $boolean - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function whereYear($column, $operator, $value, $boolean = 'and'){ + public static function whereYear($column, $operator, $value, $boolean = 'and') + { return \Illuminate\Database\Query\Builder::whereYear($column, $operator, $value, $boolean); } - + /** * Handles dynamic "where" clauses to the query. * * @param string $method * @param string $parameters - * @return $this - * @static + * @return $this + * @static */ - public static function dynamicWhere($method, $parameters){ + public static function dynamicWhere($method, $parameters) + { return \Illuminate\Database\Query\Builder::dynamicWhere($method, $parameters); } - + /** * Add a "group by" clause to the query. * * @param array|string $column,... - * @return $this - * @static + * @return $this + * @static */ - public static function groupBy(){ + public static function groupBy() + { return \Illuminate\Database\Query\Builder::groupBy(); } - + /** * Add a "having" clause to the query. * @@ -4560,1008 +4930,1092 @@ public static function groupBy(){ * @param string $operator * @param string $value * @param string $boolean - * @return $this - * @static + * @return $this + * @static */ - public static function having($column, $operator = null, $value = null, $boolean = 'and'){ + public static function having($column, $operator = null, $value = null, $boolean = 'and') + { return \Illuminate\Database\Query\Builder::having($column, $operator, $value, $boolean); } - + /** * Add a "or having" clause to the query. * * @param string $column * @param string $operator * @param string $value - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function orHaving($column, $operator = null, $value = null){ + public static function orHaving($column, $operator = null, $value = null) + { return \Illuminate\Database\Query\Builder::orHaving($column, $operator, $value); } - + /** * Add a raw having clause to the query. * * @param string $sql * @param array $bindings * @param string $boolean - * @return $this - * @static + * @return $this + * @static */ - public static function havingRaw($sql, $bindings = array(), $boolean = 'and'){ + public static function havingRaw($sql, $bindings = [], $boolean = 'and') + { return \Illuminate\Database\Query\Builder::havingRaw($sql, $bindings, $boolean); } - + /** * Add a raw or having clause to the query. * * @param string $sql * @param array $bindings - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function orHavingRaw($sql, $bindings = array()){ + public static function orHavingRaw($sql, $bindings = []) + { return \Illuminate\Database\Query\Builder::orHavingRaw($sql, $bindings); } - + /** * Add an "order by" clause to the query. * * @param string $column * @param string $direction - * @return $this - * @static + * @return $this + * @static */ - public static function orderBy($column, $direction = 'asc'){ + public static function orderBy($column, $direction = 'asc') + { return \Illuminate\Database\Query\Builder::orderBy($column, $direction); } - + /** * Add an "order by" clause for a timestamp to the query. * * @param string $column - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function latest($column = 'created_at'){ + public static function latest($column = 'created_at') + { return \Illuminate\Database\Query\Builder::latest($column); } - + /** * Add an "order by" clause for a timestamp to the query. * * @param string $column - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function oldest($column = 'created_at'){ + public static function oldest($column = 'created_at') + { return \Illuminate\Database\Query\Builder::oldest($column); } - + /** * Put the query's results in random order. * * @param string $seed - * @return $this - * @static + * @return $this + * @static */ - public static function inRandomOrder($seed = ''){ + public static function inRandomOrder($seed = '') + { return \Illuminate\Database\Query\Builder::inRandomOrder($seed); } - + /** * Add a raw "order by" clause to the query. * * @param string $sql * @param array $bindings - * @return $this - * @static + * @return $this + * @static */ - public static function orderByRaw($sql, $bindings = array()){ + public static function orderByRaw($sql, $bindings = []) + { return \Illuminate\Database\Query\Builder::orderByRaw($sql, $bindings); } - + /** * Set the "offset" value of the query. * * @param int $value - * @return $this - * @static + * @return $this + * @static */ - public static function offset($value){ + public static function offset($value) + { return \Illuminate\Database\Query\Builder::offset($value); } - + /** * Alias to set the "offset" value of the query. * * @param int $value - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function skip($value){ + public static function skip($value) + { return \Illuminate\Database\Query\Builder::skip($value); } - + /** * Set the "limit" value of the query. * * @param int $value - * @return $this - * @static + * @return $this + * @static */ - public static function limit($value){ + public static function limit($value) + { return \Illuminate\Database\Query\Builder::limit($value); } - + /** * Alias to set the "limit" value of the query. * * @param int $value - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function take($value){ + public static function take($value) + { return \Illuminate\Database\Query\Builder::take($value); } - + /** * Set the limit and offset for a given page. * * @param int $page * @param int $perPage - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function forPage($page, $perPage = 15){ + public static function forPage($page, $perPage = 15) + { return \Illuminate\Database\Query\Builder::forPage($page, $perPage); } - + /** * Constrain the query to the next "page" of results after a given ID. * * @param int $perPage * @param int $lastId * @param string $column - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function forPageAfterId($perPage = 15, $lastId = 0, $column = 'id'){ + public static function forPageAfterId($perPage = 15, $lastId = 0, $column = 'id') + { return \Illuminate\Database\Query\Builder::forPageAfterId($perPage, $lastId, $column); } - + /** * Add a union statement to the query. * * @param \Illuminate\Database\Query\Builder|\Closure $query * @param bool $all - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function union($query, $all = false){ + public static function union($query, $all = false) + { return \Illuminate\Database\Query\Builder::union($query, $all); } - + /** * Add a union all statement to the query. * * @param \Illuminate\Database\Query\Builder|\Closure $query - * @return \Illuminate\Database\Query\Builder|static - * @static + * @return \Illuminate\Database\Query\Builder|static + * @static */ - public static function unionAll($query){ + public static function unionAll($query) + { return \Illuminate\Database\Query\Builder::unionAll($query); } - + /** * Lock the selected rows in the table. * * @param bool $value - * @return $this - * @static + * @return $this + * @static */ - public static function lock($value = true){ + public static function lock($value = true) + { return \Illuminate\Database\Query\Builder::lock($value); } - + /** * Lock the selected rows in the table for updating. * - * @return \Illuminate\Database\Query\Builder - * @static + * @return \Illuminate\Database\Query\Builder + * @static */ - public static function lockForUpdate(){ + public static function lockForUpdate() + { return \Illuminate\Database\Query\Builder::lockForUpdate(); } - + /** * Share lock the selected rows in the table. * - * @return \Illuminate\Database\Query\Builder - * @static + * @return \Illuminate\Database\Query\Builder + * @static */ - public static function sharedLock(){ + public static function sharedLock() + { return \Illuminate\Database\Query\Builder::sharedLock(); } - + /** * Get the SQL representation of the query. * - * @return string - * @static + * @return string + * @static */ - public static function toSql(){ + public static function toSql() + { return \Illuminate\Database\Query\Builder::toSql(); } - + /** * Get the count of the total records for the paginator. * * @param array $columns - * @return int - * @static + * @return int + * @static */ - public static function getCountForPagination($columns = array()){ + public static function getCountForPagination($columns = []) + { return \Illuminate\Database\Query\Builder::getCountForPagination($columns); } - + /** * Concatenate values of a given column as a string. * * @param string $column * @param string $glue - * @return string - * @static + * @return string + * @static */ - public static function implode($column, $glue = ''){ + public static function implode($column, $glue = '') + { return \Illuminate\Database\Query\Builder::implode($column, $glue); } - + /** * Determine if any rows exist for the current query. * - * @return bool - * @static + * @return bool + * @static */ - public static function exists(){ + public static function exists() + { return \Illuminate\Database\Query\Builder::exists(); } - + /** * Retrieve the "count" result of the query. * * @param string $columns - * @return int - * @static + * @return int + * @static */ - public static function count($columns = '*'){ + public static function count($columns = '*') + { return \Illuminate\Database\Query\Builder::count($columns); } - + /** * Retrieve the minimum value of a given column. * * @param string $column - * @return mixed - * @static + * @return mixed + * @static */ - public static function min($column){ + public static function min($column) + { return \Illuminate\Database\Query\Builder::min($column); } - + /** * Retrieve the maximum value of a given column. * * @param string $column - * @return mixed - * @static + * @return mixed + * @static */ - public static function max($column){ + public static function max($column) + { return \Illuminate\Database\Query\Builder::max($column); } - + /** * Retrieve the sum of the values of a given column. * * @param string $column - * @return mixed - * @static + * @return mixed + * @static */ - public static function sum($column){ + public static function sum($column) + { return \Illuminate\Database\Query\Builder::sum($column); } - + /** * Retrieve the average of the values of a given column. * * @param string $column - * @return mixed - * @static + * @return mixed + * @static */ - public static function avg($column){ + public static function avg($column) + { return \Illuminate\Database\Query\Builder::avg($column); } - + /** * Alias for the "avg" method. * * @param string $column - * @return mixed - * @static + * @return mixed + * @static */ - public static function average($column){ + public static function average($column) + { return \Illuminate\Database\Query\Builder::average($column); } - + /** * Execute an aggregate function on the database. * * @param string $function * @param array $columns - * @return mixed - * @static + * @return mixed + * @static */ - public static function aggregate($function, $columns = array()){ + public static function aggregate($function, $columns = []) + { return \Illuminate\Database\Query\Builder::aggregate($function, $columns); } - + /** * Execute a numeric aggregate function on the database. * * @param string $function * @param array $columns - * @return float|int - * @static + * @return float|int + * @static */ - public static function numericAggregate($function, $columns = array()){ + public static function numericAggregate($function, $columns = []) + { return \Illuminate\Database\Query\Builder::numericAggregate($function, $columns); } - + /** * Insert a new record into the database. * * @param array $values - * @return bool - * @static + * @return bool + * @static */ - public static function insert($values){ + public static function insert($values) + { return \Illuminate\Database\Query\Builder::insert($values); } - + /** * Insert a new record and get the value of the primary key. * * @param array $values * @param string $sequence - * @return int - * @static + * @return int + * @static */ - public static function insertGetId($values, $sequence = null){ + public static function insertGetId($values, $sequence = null) + { return \Illuminate\Database\Query\Builder::insertGetId($values, $sequence); } - + /** * Insert or update a record matching the attributes, and fill it with values. * * @param array $attributes * @param array $values - * @return bool - * @static + * @return bool + * @static */ - public static function updateOrInsert($attributes, $values = array()){ + public static function updateOrInsert($attributes, $values = []) + { return \Illuminate\Database\Query\Builder::updateOrInsert($attributes, $values); } - + /** * Run a truncate statement on the table. * - * @return void - * @static + * @return void + * @static */ - public static function truncate(){ + public static function truncate() + { \Illuminate\Database\Query\Builder::truncate(); } - + /** * Merge an array of where clauses and bindings. * * @param array $wheres * @param array $bindings - * @return void - * @static + * @return void + * @static */ - public static function mergeWheres($wheres, $bindings){ + public static function mergeWheres($wheres, $bindings) + { \Illuminate\Database\Query\Builder::mergeWheres($wheres, $bindings); } - + /** * Create a raw database expression. * * @param mixed $value - * @return \Illuminate\Database\Query\Expression - * @static + * @return \Illuminate\Database\Query\Expression + * @static */ - public static function raw($value){ + public static function raw($value) + { return \Illuminate\Database\Query\Builder::raw($value); } - + /** * Get the current query value bindings in a flattened array. * - * @return array - * @static + * @return array + * @static */ - public static function getBindings(){ + public static function getBindings() + { return \Illuminate\Database\Query\Builder::getBindings(); } - + /** * Get the raw array of bindings. * - * @return array - * @static + * @return array + * @static */ - public static function getRawBindings(){ + public static function getRawBindings() + { return \Illuminate\Database\Query\Builder::getRawBindings(); } - + /** * Set the bindings on the query builder. * * @param array $bindings * @param string $type - * @return $this + * @return $this * @throws \InvalidArgumentException - * @static + * @static */ - public static function setBindings($bindings, $type = 'where'){ + public static function setBindings($bindings, $type = 'where') + { return \Illuminate\Database\Query\Builder::setBindings($bindings, $type); } - + /** * Add a binding to the query. * * @param mixed $value * @param string $type - * @return $this + * @return $this * @throws \InvalidArgumentException - * @static + * @static */ - public static function addBinding($value, $type = 'where'){ + public static function addBinding($value, $type = 'where') + { return \Illuminate\Database\Query\Builder::addBinding($value, $type); } - + /** * Merge an array of bindings into our bindings. * * @param \Illuminate\Database\Query\Builder $query - * @return $this - * @static + * @return $this + * @static */ - public static function mergeBindings($query){ + public static function mergeBindings($query) + { return \Illuminate\Database\Query\Builder::mergeBindings($query); } - + /** * Get the database query processor instance. * - * @return \Illuminate\Database\Query\Processors\Processor - * @static + * @return \Illuminate\Database\Query\Processors\Processor + * @static */ - public static function getProcessor(){ + public static function getProcessor() + { return \Illuminate\Database\Query\Builder::getProcessor(); } - + /** * Get the query grammar instance. * - * @return \Illuminate\Database\Query\Grammars\Grammar - * @static + * @return \Illuminate\Database\Query\Grammars\Grammar + * @static */ - public static function getGrammar(){ + public static function getGrammar() + { return \Illuminate\Database\Query\Builder::getGrammar(); } - + /** * Use the write pdo for query. * - * @return $this - * @static + * @return $this + * @static */ - public static function useWritePdo(){ + public static function useWritePdo() + { return \Illuminate\Database\Query\Builder::useWritePdo(); } - + /** * Checks if macro is registered. * * @param string $name - * @return bool - * @static + * @return bool + * @static */ - public static function hasMacro($name){ + public static function hasMacro($name) + { return \Illuminate\Database\Query\Builder::hasMacro($name); } - + /** * Dynamically handle calls to the class. * * @param string $method * @param array $parameters - * @return mixed + * @return mixed * @throws \BadMethodCallException - * @static + * @static */ - public static function macroCall($method, $parameters){ + public static function macroCall($method, $parameters) + { return \Illuminate\Database\Query\Builder::macroCall($method, $parameters); } - } - - class Event extends \Illuminate\Support\Facades\Event{ - + class Event extends \Illuminate\Support\Facades\Event + { /** * Register an event listener with the dispatcher. * * @param string|array $events * @param mixed $listener * @param int $priority - * @return void - * @static + * @return void + * @static */ - public static function listen($events, $listener, $priority = 0){ + public static function listen($events, $listener, $priority = 0) + { \Illuminate\Events\Dispatcher::listen($events, $listener, $priority); } - + /** * Determine if a given event has listeners. * * @param string $eventName - * @return bool - * @static + * @return bool + * @static */ - public static function hasListeners($eventName){ + public static function hasListeners($eventName) + { return \Illuminate\Events\Dispatcher::hasListeners($eventName); } - + /** * Register an event and payload to be fired later. * * @param string $event * @param array $payload - * @return void - * @static + * @return void + * @static */ - public static function push($event, $payload = array()){ + public static function push($event, $payload = []) + { \Illuminate\Events\Dispatcher::push($event, $payload); } - + /** * Register an event subscriber with the dispatcher. * * @param object|string $subscriber - * @return void - * @static + * @return void + * @static */ - public static function subscribe($subscriber){ + public static function subscribe($subscriber) + { \Illuminate\Events\Dispatcher::subscribe($subscriber); } - + /** * Fire an event until the first non-null response is returned. * * @param string|object $event * @param array $payload - * @return mixed - * @static + * @return mixed + * @static */ - public static function until($event, $payload = array()){ + public static function until($event, $payload = []) + { return \Illuminate\Events\Dispatcher::until($event, $payload); } - + /** * Flush a set of pushed events. * * @param string $event - * @return void - * @static + * @return void + * @static */ - public static function flush($event){ + public static function flush($event) + { \Illuminate\Events\Dispatcher::flush($event); } - + /** * Get the event that is currently firing. * - * @return string - * @static + * @return string + * @static */ - public static function firing(){ + public static function firing() + { return \Illuminate\Events\Dispatcher::firing(); } - + /** * Fire an event and call the listeners. * * @param string|object $event * @param mixed $payload * @param bool $halt - * @return array|null - * @static + * @return array|null + * @static */ - public static function fire($event, $payload = array(), $halt = false){ + public static function fire($event, $payload = [], $halt = false) + { return \Illuminate\Events\Dispatcher::fire($event, $payload, $halt); } - + /** * Get all of the listeners for a given event name. * * @param string $eventName - * @return array - * @static + * @return array + * @static */ - public static function getListeners($eventName){ + public static function getListeners($eventName) + { return \Illuminate\Events\Dispatcher::getListeners($eventName); } - + /** * Register an event listener with the dispatcher. * * @param mixed $listener - * @return mixed - * @static + * @return mixed + * @static */ - public static function makeListener($listener){ + public static function makeListener($listener) + { return \Illuminate\Events\Dispatcher::makeListener($listener); } - + /** * Create a class based listener using the IoC container. * * @param mixed $listener - * @return \Closure - * @static + * @return \Closure + * @static */ - public static function createClassListener($listener){ + public static function createClassListener($listener) + { return \Illuminate\Events\Dispatcher::createClassListener($listener); } - + /** * Remove a set of listeners from the dispatcher. * * @param string $event - * @return void - * @static + * @return void + * @static */ - public static function forget($event){ + public static function forget($event) + { \Illuminate\Events\Dispatcher::forget($event); } - + /** * Forget all of the pushed listeners. * - * @return void - * @static + * @return void + * @static */ - public static function forgetPushed(){ + public static function forgetPushed() + { \Illuminate\Events\Dispatcher::forgetPushed(); } - + /** * Set the queue resolver implementation. * * @param callable $resolver - * @return $this - * @static + * @return $this + * @static */ - public static function setQueueResolver($resolver){ + public static function setQueueResolver($resolver) + { return \Illuminate\Events\Dispatcher::setQueueResolver($resolver); } - } - - class File extends \Illuminate\Support\Facades\File{ - + class File extends \Illuminate\Support\Facades\File + { /** * Determine if a file or directory exists. * * @param string $path - * @return bool - * @static + * @return bool + * @static */ - public static function exists($path){ + public static function exists($path) + { return \Illuminate\Filesystem\Filesystem::exists($path); } - + /** * Get the contents of a file. * * @param string $path * @param bool $lock - * @return string + * @return string * @throws \Illuminate\Contracts\Filesystem\FileNotFoundException - * @static + * @static */ - public static function get($path, $lock = false){ + public static function get($path, $lock = false) + { return \Illuminate\Filesystem\Filesystem::get($path, $lock); } - + /** * Get contents of a file with shared access. * * @param string $path - * @return string - * @static + * @return string + * @static */ - public static function sharedGet($path){ + public static function sharedGet($path) + { return \Illuminate\Filesystem\Filesystem::sharedGet($path); } - + /** * Get the returned value of a file. * * @param string $path - * @return mixed + * @return mixed * @throws \Illuminate\Contracts\Filesystem\FileNotFoundException - * @static + * @static */ - public static function getRequire($path){ + public static function getRequire($path) + { return \Illuminate\Filesystem\Filesystem::getRequire($path); } - + /** * Require the given file once. * * @param string $file - * @return mixed - * @static + * @return mixed + * @static */ - public static function requireOnce($file){ + public static function requireOnce($file) + { return \Illuminate\Filesystem\Filesystem::requireOnce($file); } - + /** * Write the contents of a file. * * @param string $path * @param string $contents * @param bool $lock - * @return int - * @static + * @return int + * @static */ - public static function put($path, $contents, $lock = false){ + public static function put($path, $contents, $lock = false) + { return \Illuminate\Filesystem\Filesystem::put($path, $contents, $lock); } - + /** * Prepend to a file. * * @param string $path * @param string $data - * @return int - * @static + * @return int + * @static */ - public static function prepend($path, $data){ + public static function prepend($path, $data) + { return \Illuminate\Filesystem\Filesystem::prepend($path, $data); } - + /** * Append to a file. * * @param string $path * @param string $data - * @return int - * @static + * @return int + * @static */ - public static function append($path, $data){ + public static function append($path, $data) + { return \Illuminate\Filesystem\Filesystem::append($path, $data); } - + /** * Delete the file at a given path. * * @param string|array $paths - * @return bool - * @static + * @return bool + * @static */ - public static function delete($paths){ + public static function delete($paths) + { return \Illuminate\Filesystem\Filesystem::delete($paths); } - + /** * Move a file to a new location. * * @param string $path * @param string $target - * @return bool - * @static + * @return bool + * @static */ - public static function move($path, $target){ + public static function move($path, $target) + { return \Illuminate\Filesystem\Filesystem::move($path, $target); } - + /** * Copy a file to a new location. * * @param string $path * @param string $target - * @return bool - * @static + * @return bool + * @static */ - public static function copy($path, $target){ + public static function copy($path, $target) + { return \Illuminate\Filesystem\Filesystem::copy($path, $target); } - + /** * Extract the file name from a file path. * * @param string $path - * @return string - * @static + * @return string + * @static */ - public static function name($path){ + public static function name($path) + { return \Illuminate\Filesystem\Filesystem::name($path); } - + /** * Extract the trailing name component from a file path. * * @param string $path - * @return string - * @static + * @return string + * @static */ - public static function basename($path){ + public static function basename($path) + { return \Illuminate\Filesystem\Filesystem::basename($path); } - + /** * Extract the parent directory from a file path. * * @param string $path - * @return string - * @static + * @return string + * @static */ - public static function dirname($path){ + public static function dirname($path) + { return \Illuminate\Filesystem\Filesystem::dirname($path); } - + /** * Extract the file extension from a file path. * * @param string $path - * @return string - * @static + * @return string + * @static */ - public static function extension($path){ + public static function extension($path) + { return \Illuminate\Filesystem\Filesystem::extension($path); } - + /** * Get the file type of a given file. * * @param string $path - * @return string - * @static + * @return string + * @static */ - public static function type($path){ + public static function type($path) + { return \Illuminate\Filesystem\Filesystem::type($path); } - + /** * Get the mime-type of a given file. * * @param string $path - * @return string|false - * @static + * @return string|false + * @static */ - public static function mimeType($path){ + public static function mimeType($path) + { return \Illuminate\Filesystem\Filesystem::mimeType($path); } - + /** * Get the file size of a given file. * * @param string $path - * @return int - * @static + * @return int + * @static */ - public static function size($path){ + public static function size($path) + { return \Illuminate\Filesystem\Filesystem::size($path); } - + /** * Get the file's last modification time. * * @param string $path - * @return int - * @static + * @return int + * @static */ - public static function lastModified($path){ + public static function lastModified($path) + { return \Illuminate\Filesystem\Filesystem::lastModified($path); } - + /** * Determine if the given path is a directory. * * @param string $directory - * @return bool - * @static + * @return bool + * @static */ - public static function isDirectory($directory){ + public static function isDirectory($directory) + { return \Illuminate\Filesystem\Filesystem::isDirectory($directory); } - + /** * Determine if the given path is writable. * * @param string $path - * @return bool - * @static + * @return bool + * @static */ - public static function isWritable($path){ + public static function isWritable($path) + { return \Illuminate\Filesystem\Filesystem::isWritable($path); } - + /** * Determine if the given path is a file. * * @param string $file - * @return bool - * @static + * @return bool + * @static */ - public static function isFile($file){ + public static function isFile($file) + { return \Illuminate\Filesystem\Filesystem::isFile($file); } - + /** * Find path names matching a given pattern. * * @param string $pattern * @param int $flags - * @return array - * @static + * @return array + * @static */ - public static function glob($pattern, $flags = 0){ + public static function glob($pattern, $flags = 0) + { return \Illuminate\Filesystem\Filesystem::glob($pattern, $flags); } - + /** * Get an array of all files in a directory. * * @param string $directory - * @return array - * @static + * @return array + * @static */ - public static function files($directory){ + public static function files($directory) + { return \Illuminate\Filesystem\Filesystem::files($directory); } - + /** * Get all of the files from the given directory (recursive). * * @param string $directory * @param bool $hidden - * @return array - * @static + * @return array + * @static */ - public static function allFiles($directory, $hidden = false){ + public static function allFiles($directory, $hidden = false) + { return \Illuminate\Filesystem\Filesystem::allFiles($directory, $hidden); } - + /** * Get all of the directories within a given directory. * * @param string $directory - * @return array - * @static + * @return array + * @static */ - public static function directories($directory){ + public static function directories($directory) + { return \Illuminate\Filesystem\Filesystem::directories($directory); } - + /** * Create a directory. * @@ -5569,317 +6023,336 @@ public static function directories($directory){ * @param int $mode * @param bool $recursive * @param bool $force - * @return bool - * @static + * @return bool + * @static */ - public static function makeDirectory($path, $mode = 493, $recursive = false, $force = false){ + public static function makeDirectory($path, $mode = 493, $recursive = false, $force = false) + { return \Illuminate\Filesystem\Filesystem::makeDirectory($path, $mode, $recursive, $force); } - + /** * Move a directory. * * @param string $from * @param string $to * @param bool $overwrite - * @return bool - * @static + * @return bool + * @static */ - public static function moveDirectory($from, $to, $overwrite = false){ + public static function moveDirectory($from, $to, $overwrite = false) + { return \Illuminate\Filesystem\Filesystem::moveDirectory($from, $to, $overwrite); } - + /** * Copy a directory from one location to another. * * @param string $directory * @param string $destination * @param int $options - * @return bool - * @static + * @return bool + * @static */ - public static function copyDirectory($directory, $destination, $options = null){ + public static function copyDirectory($directory, $destination, $options = null) + { return \Illuminate\Filesystem\Filesystem::copyDirectory($directory, $destination, $options); } - + /** * Recursively delete a directory. - * + * * The directory itself may be optionally preserved. * * @param string $directory * @param bool $preserve - * @return bool - * @static + * @return bool + * @static */ - public static function deleteDirectory($directory, $preserve = false){ + public static function deleteDirectory($directory, $preserve = false) + { return \Illuminate\Filesystem\Filesystem::deleteDirectory($directory, $preserve); } - + /** * Empty the specified directory of all files and folders. * * @param string $directory - * @return bool - * @static + * @return bool + * @static */ - public static function cleanDirectory($directory){ + public static function cleanDirectory($directory) + { return \Illuminate\Filesystem\Filesystem::cleanDirectory($directory); } - + /** * Register a custom macro. * * @param string $name * @param callable $macro - * @return void - * @static + * @return void + * @static */ - public static function macro($name, $macro){ + public static function macro($name, $macro) + { \Illuminate\Filesystem\Filesystem::macro($name, $macro); } - + /** * Checks if macro is registered. * * @param string $name - * @return bool - * @static + * @return bool + * @static */ - public static function hasMacro($name){ + public static function hasMacro($name) + { return \Illuminate\Filesystem\Filesystem::hasMacro($name); } - } - - class Gate extends \Illuminate\Support\Facades\Gate{ - + class Gate extends \Illuminate\Support\Facades\Gate + { /** * Determine if a given ability has been defined. * * @param string $ability - * @return bool - * @static + * @return bool + * @static */ - public static function has($ability){ + public static function has($ability) + { return \Illuminate\Auth\Access\Gate::has($ability); } - + /** * Define a new ability. * * @param string $ability * @param callable|string $callback - * @return $this + * @return $this * @throws \InvalidArgumentException - * @static + * @static */ - public static function define($ability, $callback){ + public static function define($ability, $callback) + { return \Illuminate\Auth\Access\Gate::define($ability, $callback); } - + /** * Define a policy class for a given class type. * * @param string $class * @param string $policy - * @return $this - * @static + * @return $this + * @static */ - public static function policy($class, $policy){ + public static function policy($class, $policy) + { return \Illuminate\Auth\Access\Gate::policy($class, $policy); } - + /** * Register a callback to run before all Gate checks. * * @param callable $callback - * @return $this - * @static + * @return $this + * @static */ - public static function before($callback){ + public static function before($callback) + { return \Illuminate\Auth\Access\Gate::before($callback); } - + /** * Register a callback to run after all Gate checks. * * @param callable $callback - * @return $this - * @static + * @return $this + * @static */ - public static function after($callback){ + public static function after($callback) + { return \Illuminate\Auth\Access\Gate::after($callback); } - + /** * Determine if the given ability should be granted for the current user. * * @param string $ability * @param array|mixed $arguments - * @return bool - * @static + * @return bool + * @static */ - public static function allows($ability, $arguments = array()){ + public static function allows($ability, $arguments = []) + { return \Illuminate\Auth\Access\Gate::allows($ability, $arguments); } - + /** * Determine if the given ability should be denied for the current user. * * @param string $ability * @param array|mixed $arguments - * @return bool - * @static + * @return bool + * @static */ - public static function denies($ability, $arguments = array()){ + public static function denies($ability, $arguments = []) + { return \Illuminate\Auth\Access\Gate::denies($ability, $arguments); } - + /** * Determine if the given ability should be granted for the current user. * * @param string $ability * @param array|mixed $arguments - * @return bool - * @static + * @return bool + * @static */ - public static function check($ability, $arguments = array()){ + public static function check($ability, $arguments = []) + { return \Illuminate\Auth\Access\Gate::check($ability, $arguments); } - + /** * Determine if the given ability should be granted for the current user. * * @param string $ability * @param array|mixed $arguments - * @return \Illuminate\Auth\Access\Response + * @return \Illuminate\Auth\Access\Response * @throws \Illuminate\Auth\Access\AuthorizationException - * @static + * @static */ - public static function authorize($ability, $arguments = array()){ + public static function authorize($ability, $arguments = []) + { return \Illuminate\Auth\Access\Gate::authorize($ability, $arguments); } - + /** * Get a policy instance for a given class. * * @param object|string $class - * @return mixed + * @return mixed * @throws \InvalidArgumentException - * @static + * @static */ - public static function getPolicyFor($class){ + public static function getPolicyFor($class) + { return \Illuminate\Auth\Access\Gate::getPolicyFor($class); } - + /** * Build a policy class instance of the given type. * * @param object|string $class - * @return mixed - * @static + * @return mixed + * @static */ - public static function resolvePolicy($class){ + public static function resolvePolicy($class) + { return \Illuminate\Auth\Access\Gate::resolvePolicy($class); } - + /** * Get a gate instance for the given user. * * @param \Illuminate\Contracts\Auth\Authenticatable|mixed $user - * @return static - * @static + * @return static + * @static */ - public static function forUser($user){ + public static function forUser($user) + { return \Illuminate\Auth\Access\Gate::forUser($user); } - } - - class Hash extends \Illuminate\Support\Facades\Hash{ - + class Hash extends \Illuminate\Support\Facades\Hash + { /** * Hash the given value. * * @param string $value * @param array $options - * @return string + * @return string * @throws \RuntimeException - * @static + * @static */ - public static function make($value, $options = array()){ + public static function make($value, $options = []) + { return \Illuminate\Hashing\BcryptHasher::make($value, $options); } - + /** * Check the given plain value against a hash. * * @param string $value * @param string $hashedValue * @param array $options - * @return bool - * @static + * @return bool + * @static */ - public static function check($value, $hashedValue, $options = array()){ + public static function check($value, $hashedValue, $options = []) + { return \Illuminate\Hashing\BcryptHasher::check($value, $hashedValue, $options); } - + /** * Check if the given hash has been hashed using the given options. * * @param string $hashedValue * @param array $options - * @return bool - * @static + * @return bool + * @static */ - public static function needsRehash($hashedValue, $options = array()){ + public static function needsRehash($hashedValue, $options = []) + { return \Illuminate\Hashing\BcryptHasher::needsRehash($hashedValue, $options); } - + /** * Set the default password work factor. * * @param int $rounds - * @return $this - * @static + * @return $this + * @static */ - public static function setRounds($rounds){ + public static function setRounds($rounds) + { return \Illuminate\Hashing\BcryptHasher::setRounds($rounds); } - } - - class Lang extends \Illuminate\Support\Facades\Lang{ - + class Lang extends \Illuminate\Support\Facades\Lang + { /** * Determine if a translation exists for a given locale. * * @param string $key * @param string|null $locale - * @return bool - * @static + * @return bool + * @static */ - public static function hasForLocale($key, $locale = null){ + public static function hasForLocale($key, $locale = null) + { return \Illuminate\Translation\Translator::hasForLocale($key, $locale); } - + /** * Determine if a translation exists. * * @param string $key * @param string|null $locale * @param bool $fallback - * @return bool - * @static + * @return bool + * @static */ - public static function has($key, $locale = null, $fallback = true){ + public static function has($key, $locale = null, $fallback = true) + { return \Illuminate\Translation\Translator::has($key, $locale, $fallback); } - + /** * Get the translation for the given key. * @@ -5887,13 +6360,14 @@ public static function has($key, $locale = null, $fallback = true){ * @param array $replace * @param string|null $locale * @param bool $fallback - * @return string|array|null - * @static + * @return string|array|null + * @static */ - public static function get($key, $replace = array(), $locale = null, $fallback = true){ + public static function get($key, $replace = [], $locale = null, $fallback = true) + { return \Illuminate\Translation\Translator::get($key, $replace, $locale, $fallback); } - + /** * Get a translation according to an integer value. * @@ -5901,13 +6375,14 @@ public static function get($key, $replace = array(), $locale = null, $fallback = * @param int|array|\Countable $number * @param array $replace * @param string $locale - * @return string - * @static + * @return string + * @static */ - public static function choice($key, $number, $replace = array(), $locale = null){ + public static function choice($key, $number, $replace = [], $locale = null) + { return \Illuminate\Translation\Translator::choice($key, $number, $replace, $locale); } - + /** * Get the translation for a given key. * @@ -5915,13 +6390,14 @@ public static function choice($key, $number, $replace = array(), $locale = null) * @param array $parameters * @param string $domain * @param string $locale - * @return string|array|null - * @static + * @return string|array|null + * @static */ - public static function trans($id, $parameters = array(), $domain = 'messages', $locale = null){ + public static function trans($id, $parameters = [], $domain = 'messages', $locale = null) + { return \Illuminate\Translation\Translator::trans($id, $parameters, $domain, $locale); } - + /** * Get a translation according to an integer value. * @@ -5930,431 +6406,463 @@ public static function trans($id, $parameters = array(), $domain = 'messages', $ * @param array $parameters * @param string $domain * @param string $locale - * @return string - * @static + * @return string + * @static */ - public static function transChoice($id, $number, $parameters = array(), $domain = 'messages', $locale = null){ + public static function transChoice($id, $number, $parameters = [], $domain = 'messages', $locale = null) + { return \Illuminate\Translation\Translator::transChoice($id, $number, $parameters, $domain, $locale); } - + /** * Load the specified language group. * * @param string $namespace * @param string $group * @param string $locale - * @return void - * @static + * @return void + * @static */ - public static function load($namespace, $group, $locale){ + public static function load($namespace, $group, $locale) + { \Illuminate\Translation\Translator::load($namespace, $group, $locale); } - + /** * Add a new namespace to the loader. * * @param string $namespace * @param string $hint - * @return void - * @static + * @return void + * @static */ - public static function addNamespace($namespace, $hint){ + public static function addNamespace($namespace, $hint) + { \Illuminate\Translation\Translator::addNamespace($namespace, $hint); } - + /** * Parse a key into namespace, group, and item. * * @param string $key - * @return array - * @static + * @return array + * @static */ - public static function parseKey($key){ + public static function parseKey($key) + { return \Illuminate\Translation\Translator::parseKey($key); } - + /** * Get the message selector instance. * - * @return \Symfony\Component\Translation\MessageSelector - * @static + * @return \Symfony\Component\Translation\MessageSelector + * @static */ - public static function getSelector(){ + public static function getSelector() + { return \Illuminate\Translation\Translator::getSelector(); } - + /** * Set the message selector instance. * * @param \Symfony\Component\Translation\MessageSelector $selector - * @return void - * @static + * @return void + * @static */ - public static function setSelector($selector){ + public static function setSelector($selector) + { \Illuminate\Translation\Translator::setSelector($selector); } - + /** * Get the language line loader implementation. * - * @return \Illuminate\Translation\LoaderInterface - * @static + * @return \Illuminate\Translation\LoaderInterface + * @static */ - public static function getLoader(){ + public static function getLoader() + { return \Illuminate\Translation\Translator::getLoader(); } - + /** * Get the default locale being used. * - * @return string - * @static + * @return string + * @static */ - public static function locale(){ + public static function locale() + { return \Illuminate\Translation\Translator::locale(); } - + /** * Get the default locale being used. * - * @return string - * @static + * @return string + * @static */ - public static function getLocale(){ + public static function getLocale() + { return \Illuminate\Translation\Translator::getLocale(); } - + /** * Set the default locale. * * @param string $locale - * @return void - * @static + * @return void + * @static */ - public static function setLocale($locale){ + public static function setLocale($locale) + { \Illuminate\Translation\Translator::setLocale($locale); } - + /** * Get the fallback locale being used. * - * @return string - * @static + * @return string + * @static */ - public static function getFallback(){ + public static function getFallback() + { return \Illuminate\Translation\Translator::getFallback(); } - + /** * Set the fallback locale being used. * * @param string $fallback - * @return void - * @static + * @return void + * @static */ - public static function setFallback($fallback){ + public static function setFallback($fallback) + { \Illuminate\Translation\Translator::setFallback($fallback); } - + /** * Set the parsed value of a key. * * @param string $key * @param array $parsed - * @return void - * @static + * @return void + * @static */ - public static function setParsedKey($key, $parsed){ - //Method inherited from \Illuminate\Support\NamespacedItemResolver + public static function setParsedKey($key, $parsed) + { + //Method inherited from \Illuminate\Support\NamespacedItemResolver \Illuminate\Translation\Translator::setParsedKey($key, $parsed); } - } - - class Log extends \Illuminate\Support\Facades\Log{ - + class Log extends \Illuminate\Support\Facades\Log + { /** * Adds a log record at the DEBUG level. * * @param string $message The log message * @param array $context The log context - * @return Boolean Whether the record has been processed - * @static + * @return bool Whether the record has been processed + * @static */ - public static function debug($message, $context = array()){ + public static function debug($message, $context = []) + { return \Monolog\Logger::debug($message, $context); } - + /** * Adds a log record at the INFO level. * * @param string $message The log message * @param array $context The log context - * @return Boolean Whether the record has been processed - * @static + * @return bool Whether the record has been processed + * @static */ - public static function info($message, $context = array()){ + public static function info($message, $context = []) + { return \Monolog\Logger::info($message, $context); } - + /** * Adds a log record at the NOTICE level. * * @param string $message The log message * @param array $context The log context - * @return Boolean Whether the record has been processed - * @static + * @return bool Whether the record has been processed + * @static */ - public static function notice($message, $context = array()){ + public static function notice($message, $context = []) + { return \Monolog\Logger::notice($message, $context); } - + /** * Adds a log record at the WARNING level. * * @param string $message The log message * @param array $context The log context - * @return Boolean Whether the record has been processed - * @static + * @return bool Whether the record has been processed + * @static */ - public static function warning($message, $context = array()){ + public static function warning($message, $context = []) + { return \Monolog\Logger::warning($message, $context); } - + /** * Adds a log record at the ERROR level. * * @param string $message The log message * @param array $context The log context - * @return Boolean Whether the record has been processed - * @static + * @return bool Whether the record has been processed + * @static */ - public static function error($message, $context = array()){ + public static function error($message, $context = []) + { return \Monolog\Logger::error($message, $context); } - + /** * Adds a log record at the CRITICAL level. * * @param string $message The log message * @param array $context The log context - * @return Boolean Whether the record has been processed - * @static + * @return bool Whether the record has been processed + * @static */ - public static function critical($message, $context = array()){ + public static function critical($message, $context = []) + { return \Monolog\Logger::critical($message, $context); } - + /** * Adds a log record at the ALERT level. * * @param string $message The log message * @param array $context The log context - * @return Boolean Whether the record has been processed - * @static + * @return bool Whether the record has been processed + * @static */ - public static function alert($message, $context = array()){ + public static function alert($message, $context = []) + { return \Monolog\Logger::alert($message, $context); } - + /** * Adds a log record at the EMERGENCY level. * * @param string $message The log message * @param array $context The log context - * @return Boolean Whether the record has been processed - * @static + * @return bool Whether the record has been processed + * @static */ - public static function emergency($message, $context = array()){ + public static function emergency($message, $context = []) + { return \Monolog\Logger::emergency($message, $context); } - + /** * Log a message to the logs. * * @param string $level * @param string $message * @param array $context - * @return void - * @static + * @return void + * @static */ - public static function log($level, $message, $context = array()){ + public static function log($level, $message, $context = []) + { \Illuminate\Log\Writer::log($level, $message, $context); } - + /** * Dynamically pass log calls into the writer. * * @param string $level * @param string $message * @param array $context - * @return void - * @static + * @return void + * @static */ - public static function write($level, $message, $context = array()){ + public static function write($level, $message, $context = []) + { \Illuminate\Log\Writer::write($level, $message, $context); } - + /** * Register a file log handler. * * @param string $path * @param string $level - * @return void - * @static + * @return void + * @static */ - public static function useFiles($path, $level = 'debug'){ + public static function useFiles($path, $level = 'debug') + { \Illuminate\Log\Writer::useFiles($path, $level); } - + /** * Register a daily file log handler. * * @param string $path * @param int $days * @param string $level - * @return void - * @static + * @return void + * @static */ - public static function useDailyFiles($path, $days = 0, $level = 'debug'){ + public static function useDailyFiles($path, $days = 0, $level = 'debug') + { \Illuminate\Log\Writer::useDailyFiles($path, $days, $level); } - + /** * Register a Syslog handler. * * @param string $name * @param string $level - * @return \Psr\Log\LoggerInterface - * @static + * @return \Psr\Log\LoggerInterface + * @static */ - public static function useSyslog($name = 'laravel', $level = 'debug'){ + public static function useSyslog($name = 'laravel', $level = 'debug') + { return \Illuminate\Log\Writer::useSyslog($name, $level); } - + /** * Register an error_log handler. * * @param string $level * @param int $messageType - * @return void - * @static + * @return void + * @static */ - public static function useErrorLog($level = 'debug', $messageType = 0){ + public static function useErrorLog($level = 'debug', $messageType = 0) + { \Illuminate\Log\Writer::useErrorLog($level, $messageType); } - + /** * Register a new callback handler for when a log event is triggered. * * @param \Closure $callback - * @return void + * @return void * @throws \RuntimeException - * @static + * @static */ - public static function listen($callback){ + public static function listen($callback) + { \Illuminate\Log\Writer::listen($callback); } - + /** * Get the underlying Monolog instance. * - * @return \Monolog\Logger - * @static + * @return \Monolog\Logger + * @static */ - public static function getMonolog(){ + public static function getMonolog() + { return \Illuminate\Log\Writer::getMonolog(); } - + /** * Get the event dispatcher instance. * - * @return \Illuminate\Contracts\Events\Dispatcher - * @static + * @return \Illuminate\Contracts\Events\Dispatcher + * @static */ - public static function getEventDispatcher(){ + public static function getEventDispatcher() + { return \Illuminate\Log\Writer::getEventDispatcher(); } - + /** * Set the event dispatcher instance. * * @param \Illuminate\Contracts\Events\Dispatcher $dispatcher - * @return void - * @static + * @return void + * @static */ - public static function setEventDispatcher($dispatcher){ + public static function setEventDispatcher($dispatcher) + { \Illuminate\Log\Writer::setEventDispatcher($dispatcher); } - } - - class Mail extends \Illuminate\Support\Facades\Mail{ - + class Mail extends \Illuminate\Support\Facades\Mail + { /** * Set the global from address and name. * * @param string $address * @param string|null $name - * @return void - * @static + * @return void + * @static */ - public static function alwaysFrom($address, $name = null){ + public static function alwaysFrom($address, $name = null) + { \Illuminate\Mail\Mailer::alwaysFrom($address, $name); } - + /** * Set the global to address and name. * * @param string $address * @param string|null $name - * @return void - * @static + * @return void + * @static */ - public static function alwaysTo($address, $name = null){ + public static function alwaysTo($address, $name = null) + { \Illuminate\Mail\Mailer::alwaysTo($address, $name); } - + /** * Send a new message when only a raw text part. * * @param string $text * @param mixed $callback - * @return void - * @static + * @return void + * @static */ - public static function raw($text, $callback){ + public static function raw($text, $callback) + { \Illuminate\Mail\Mailer::raw($text, $callback); } - + /** * Send a new message when only a plain part. * * @param string $view * @param array $data * @param mixed $callback - * @return void - * @static + * @return void + * @static */ - public static function plain($view, $data, $callback){ + public static function plain($view, $data, $callback) + { \Illuminate\Mail\Mailer::plain($view, $data, $callback); } - + /** * Send a new message using a view. * * @param string|array $view * @param array $data * @param \Closure|string $callback - * @return void - * @static + * @return void + * @static */ - public static function send($view, $data, $callback){ + public static function send($view, $data, $callback) + { \Illuminate\Mail\Mailer::send($view, $data, $callback); } - + /** * Queue a new e-mail message for sending. * @@ -6362,13 +6870,14 @@ public static function send($view, $data, $callback){ * @param array $data * @param \Closure|string $callback * @param string|null $queue - * @return mixed - * @static + * @return mixed + * @static */ - public static function queue($view, $data, $callback, $queue = null){ + public static function queue($view, $data, $callback, $queue = null) + { return \Illuminate\Mail\Mailer::queue($view, $data, $callback, $queue); } - + /** * Queue a new e-mail message for sending on the given queue. * @@ -6376,29 +6885,31 @@ public static function queue($view, $data, $callback, $queue = null){ * @param string|array $view * @param array $data * @param \Closure|string $callback - * @return mixed - * @static + * @return mixed + * @static */ - public static function onQueue($queue, $view, $data, $callback){ + public static function onQueue($queue, $view, $data, $callback) + { return \Illuminate\Mail\Mailer::onQueue($queue, $view, $data, $callback); } - + /** * Queue a new e-mail message for sending on the given queue. - * + * * This method didn't match rest of framework's "onQueue" phrasing. Added "onQueue". * * @param string $queue * @param string|array $view * @param array $data * @param \Closure|string $callback - * @return mixed - * @static + * @return mixed + * @static */ - public static function queueOn($queue, $view, $data, $callback){ + public static function queueOn($queue, $view, $data, $callback) + { return \Illuminate\Mail\Mailer::queueOn($queue, $view, $data, $callback); } - + /** * Queue a new e-mail message for sending after (n) seconds. * @@ -6407,13 +6918,14 @@ public static function queueOn($queue, $view, $data, $callback){ * @param array $data * @param \Closure|string $callback * @param string|null $queue - * @return mixed - * @static + * @return mixed + * @static */ - public static function later($delay, $view, $data, $callback, $queue = null){ + public static function later($delay, $view, $data, $callback, $queue = null) + { return \Illuminate\Mail\Mailer::later($delay, $view, $data, $callback, $queue); } - + /** * Queue a new e-mail message for sending after (n) seconds on the given queue. * @@ -6422,310 +6934,333 @@ public static function later($delay, $view, $data, $callback, $queue = null){ * @param string|array $view * @param array $data * @param \Closure|string $callback - * @return mixed - * @static + * @return mixed + * @static */ - public static function laterOn($queue, $delay, $view, $data, $callback){ + public static function laterOn($queue, $delay, $view, $data, $callback) + { return \Illuminate\Mail\Mailer::laterOn($queue, $delay, $view, $data, $callback); } - + /** * Handle a queued e-mail message job. * * @param \Illuminate\Contracts\Queue\Job $job * @param array $data - * @return void - * @static + * @return void + * @static */ - public static function handleQueuedMessage($job, $data){ + public static function handleQueuedMessage($job, $data) + { \Illuminate\Mail\Mailer::handleQueuedMessage($job, $data); } - + /** * Get the view factory instance. * - * @return \Illuminate\Contracts\View\Factory - * @static + * @return \Illuminate\Contracts\View\Factory + * @static */ - public static function getViewFactory(){ + public static function getViewFactory() + { return \Illuminate\Mail\Mailer::getViewFactory(); } - + /** * Get the Swift Mailer instance. * - * @return \Swift_Mailer - * @static + * @return \Swift_Mailer + * @static */ - public static function getSwiftMailer(){ + public static function getSwiftMailer() + { return \Illuminate\Mail\Mailer::getSwiftMailer(); } - + /** * Get the array of failed recipients. * - * @return array - * @static + * @return array + * @static */ - public static function failures(){ + public static function failures() + { return \Illuminate\Mail\Mailer::failures(); } - + /** * Set the Swift Mailer instance. * * @param \Swift_Mailer $swift - * @return void - * @static + * @return void + * @static */ - public static function setSwiftMailer($swift){ + public static function setSwiftMailer($swift) + { \Illuminate\Mail\Mailer::setSwiftMailer($swift); } - + /** * Set the queue manager instance. * * @param \Illuminate\Contracts\Queue\Queue $queue - * @return $this - * @static + * @return $this + * @static */ - public static function setQueue($queue){ + public static function setQueue($queue) + { return \Illuminate\Mail\Mailer::setQueue($queue); } - + /** * Set the IoC container instance. * * @param \Illuminate\Contracts\Container\Container $container - * @return void - * @static + * @return void + * @static */ - public static function setContainer($container){ + public static function setContainer($container) + { \Illuminate\Mail\Mailer::setContainer($container); } - } - - class Password extends \Illuminate\Support\Facades\Password{ - + class Password extends \Illuminate\Support\Facades\Password + { /** * Attempt to get the broker from the local cache. * * @param string $name - * @return \Illuminate\Contracts\Auth\PasswordBroker - * @static + * @return \Illuminate\Contracts\Auth\PasswordBroker + * @static */ - public static function broker($name = null){ + public static function broker($name = null) + { return \Illuminate\Auth\Passwords\PasswordBrokerManager::broker($name); } - + /** * Get the default password broker name. * - * @return string - * @static + * @return string + * @static */ - public static function getDefaultDriver(){ + public static function getDefaultDriver() + { return \Illuminate\Auth\Passwords\PasswordBrokerManager::getDefaultDriver(); } - + /** * Set the default password broker name. * * @param string $name - * @return void - * @static + * @return void + * @static */ - public static function setDefaultDriver($name){ + public static function setDefaultDriver($name) + { \Illuminate\Auth\Passwords\PasswordBrokerManager::setDefaultDriver($name); } - } - - class Queue extends \Illuminate\Support\Facades\Queue{ - + class Queue extends \Illuminate\Support\Facades\Queue + { /** * Register an event listener for the before job event. * * @param mixed $callback - * @return void - * @static + * @return void + * @static */ - public static function before($callback){ + public static function before($callback) + { \Illuminate\Queue\QueueManager::before($callback); } - + /** * Register an event listener for the after job event. * * @param mixed $callback - * @return void - * @static + * @return void + * @static */ - public static function after($callback){ + public static function after($callback) + { \Illuminate\Queue\QueueManager::after($callback); } - + /** * Register an event listener for the exception occurred job event. * * @param mixed $callback - * @return void - * @static + * @return void + * @static */ - public static function exceptionOccurred($callback){ + public static function exceptionOccurred($callback) + { \Illuminate\Queue\QueueManager::exceptionOccurred($callback); } - + /** * Register an event listener for the daemon queue loop. * * @param mixed $callback - * @return void - * @static + * @return void + * @static */ - public static function looping($callback){ + public static function looping($callback) + { \Illuminate\Queue\QueueManager::looping($callback); } - + /** * Register an event listener for the failed job event. * * @param mixed $callback - * @return void - * @static + * @return void + * @static */ - public static function failing($callback){ + public static function failing($callback) + { \Illuminate\Queue\QueueManager::failing($callback); } - + /** * Register an event listener for the daemon queue stopping. * * @param mixed $callback - * @return void - * @static + * @return void + * @static */ - public static function stopping($callback){ + public static function stopping($callback) + { \Illuminate\Queue\QueueManager::stopping($callback); } - + /** * Determine if the driver is connected. * * @param string $name - * @return bool - * @static + * @return bool + * @static */ - public static function connected($name = null){ + public static function connected($name = null) + { return \Illuminate\Queue\QueueManager::connected($name); } - + /** * Resolve a queue connection instance. * * @param string $name - * @return \Illuminate\Contracts\Queue\Queue - * @static + * @return \Illuminate\Contracts\Queue\Queue + * @static */ - public static function connection($name = null){ + public static function connection($name = null) + { return \Illuminate\Queue\QueueManager::connection($name); } - + /** * Add a queue connection resolver. * * @param string $driver * @param \Closure $resolver - * @return void - * @static + * @return void + * @static */ - public static function extend($driver, $resolver){ + public static function extend($driver, $resolver) + { \Illuminate\Queue\QueueManager::extend($driver, $resolver); } - + /** * Add a queue connection resolver. * * @param string $driver * @param \Closure $resolver - * @return void - * @static + * @return void + * @static */ - public static function addConnector($driver, $resolver){ + public static function addConnector($driver, $resolver) + { \Illuminate\Queue\QueueManager::addConnector($driver, $resolver); } - + /** * Get the name of the default queue connection. * - * @return string - * @static + * @return string + * @static */ - public static function getDefaultDriver(){ + public static function getDefaultDriver() + { return \Illuminate\Queue\QueueManager::getDefaultDriver(); } - + /** * Set the name of the default queue connection. * * @param string $name - * @return void - * @static + * @return void + * @static */ - public static function setDefaultDriver($name){ + public static function setDefaultDriver($name) + { \Illuminate\Queue\QueueManager::setDefaultDriver($name); } - + /** * Get the full name for the given connection. * * @param string $connection - * @return string - * @static + * @return string + * @static */ - public static function getName($connection = null){ + public static function getName($connection = null) + { return \Illuminate\Queue\QueueManager::getName($connection); } - + /** * Determine if the application is in maintenance mode. * - * @return bool - * @static + * @return bool + * @static */ - public static function isDownForMaintenance(){ + public static function isDownForMaintenance() + { return \Illuminate\Queue\QueueManager::isDownForMaintenance(); } - + /** * Push a new job onto the queue. * * @param string $job * @param mixed $data * @param string $queue - * @return mixed - * @static + * @return mixed + * @static */ - public static function push($job, $data = '', $queue = null){ + public static function push($job, $data = '', $queue = null) + { return \Illuminate\Queue\DatabaseQueue::push($job, $data, $queue); } - + /** * Push a raw payload onto the queue. * * @param string $payload * @param string $queue * @param array $options - * @return mixed - * @static + * @return mixed + * @static */ - public static function pushRaw($payload, $queue = null, $options = array()){ + public static function pushRaw($payload, $queue = null, $options = []) + { return \Illuminate\Queue\DatabaseQueue::pushRaw($payload, $queue, $options); } - + /** * Push a new job onto the queue after a delay. * @@ -6733,107 +7268,116 @@ public static function pushRaw($payload, $queue = null, $options = array()){ * @param string $job * @param mixed $data * @param string $queue - * @return void - * @static + * @return void + * @static */ - public static function later($delay, $job, $data = '', $queue = null){ + public static function later($delay, $job, $data = '', $queue = null) + { \Illuminate\Queue\DatabaseQueue::later($delay, $job, $data, $queue); } - + /** * Push an array of jobs onto the queue. * * @param array $jobs * @param mixed $data * @param string $queue - * @return mixed - * @static + * @return mixed + * @static */ - public static function bulk($jobs, $data = '', $queue = null){ + public static function bulk($jobs, $data = '', $queue = null) + { return \Illuminate\Queue\DatabaseQueue::bulk($jobs, $data, $queue); } - + /** * Release a reserved job back onto the queue. * * @param string $queue * @param \StdClass $job * @param int $delay - * @return mixed - * @static + * @return mixed + * @static */ - public static function release($queue, $job, $delay){ + public static function release($queue, $job, $delay) + { return \Illuminate\Queue\DatabaseQueue::release($queue, $job, $delay); } - + /** * Pop the next job off of the queue. * * @param string $queue - * @return \Illuminate\Contracts\Queue\Job|null - * @static + * @return \Illuminate\Contracts\Queue\Job|null + * @static */ - public static function pop($queue = null){ + public static function pop($queue = null) + { return \Illuminate\Queue\DatabaseQueue::pop($queue); } - + /** * Delete a reserved job from the queue. * * @param string $queue * @param string $id - * @return void - * @static + * @return void + * @static */ - public static function deleteReserved($queue, $id){ + public static function deleteReserved($queue, $id) + { \Illuminate\Queue\DatabaseQueue::deleteReserved($queue, $id); } - + /** * Get the underlying database instance. * - * @return \Illuminate\Database\Connection - * @static + * @return \Illuminate\Database\Connection + * @static */ - public static function getDatabase(){ + public static function getDatabase() + { return \Illuminate\Queue\DatabaseQueue::getDatabase(); } - + /** * Get the expiration time in seconds. * - * @return int|null - * @static + * @return int|null + * @static */ - public static function getExpire(){ + public static function getExpire() + { return \Illuminate\Queue\DatabaseQueue::getExpire(); } - + /** * Set the expiration time in seconds. * * @param int|null $seconds - * @return void - * @static + * @return void + * @static */ - public static function setExpire($seconds){ + public static function setExpire($seconds) + { \Illuminate\Queue\DatabaseQueue::setExpire($seconds); } - + /** * Push a new job onto the queue. * * @param string $queue * @param string $job * @param mixed $data - * @return mixed - * @static + * @return mixed + * @static */ - public static function pushOn($queue, $job, $data = ''){ - //Method inherited from \Illuminate\Queue\Queue + public static function pushOn($queue, $job, $data = '') + { + //Method inherited from \Illuminate\Queue\Queue return \Illuminate\Queue\DatabaseQueue::pushOn($queue, $job, $data); } - + /** * Push a new job onto the queue after a delay. * @@ -6841,78 +7385,82 @@ public static function pushOn($queue, $job, $data = ''){ * @param \DateTime|int $delay * @param string $job * @param mixed $data - * @return mixed - * @static + * @return mixed + * @static */ - public static function laterOn($queue, $delay, $job, $data = ''){ - //Method inherited from \Illuminate\Queue\Queue + public static function laterOn($queue, $delay, $job, $data = '') + { + //Method inherited from \Illuminate\Queue\Queue return \Illuminate\Queue\DatabaseQueue::laterOn($queue, $delay, $job, $data); } - + /** * Set the IoC container instance. * * @param \Illuminate\Container\Container $container - * @return void - * @static + * @return void + * @static */ - public static function setContainer($container){ - //Method inherited from \Illuminate\Queue\Queue + public static function setContainer($container) + { + //Method inherited from \Illuminate\Queue\Queue \Illuminate\Queue\DatabaseQueue::setContainer($container); } - + /** * Set the encrypter implementation. * * @param \Illuminate\Contracts\Encryption\Encrypter $encrypter - * @return void - * @static + * @return void + * @static */ - public static function setEncrypter($encrypter){ - //Method inherited from \Illuminate\Queue\Queue + public static function setEncrypter($encrypter) + { + //Method inherited from \Illuminate\Queue\Queue \Illuminate\Queue\DatabaseQueue::setEncrypter($encrypter); } - } - - class Redirect extends \Illuminate\Support\Facades\Redirect{ - + class Redirect extends \Illuminate\Support\Facades\Redirect + { /** * Create a new redirect response to the "home" route. * * @param int $status - * @return \Illuminate\Http\RedirectResponse - * @static + * @return \Illuminate\Http\RedirectResponse + * @static */ - public static function home($status = 302){ + public static function home($status = 302) + { return \Illuminate\Routing\Redirector::home($status); } - + /** * Create a new redirect response to the previous location. * * @param int $status * @param array $headers - * @return \Illuminate\Http\RedirectResponse - * @static + * @return \Illuminate\Http\RedirectResponse + * @static */ - public static function back($status = 302, $headers = array()){ + public static function back($status = 302, $headers = []) + { return \Illuminate\Routing\Redirector::back($status, $headers); } - + /** * Create a new redirect response to the current URI. * * @param int $status * @param array $headers - * @return \Illuminate\Http\RedirectResponse - * @static + * @return \Illuminate\Http\RedirectResponse + * @static */ - public static function refresh($status = 302, $headers = array()){ + public static function refresh($status = 302, $headers = []) + { return \Illuminate\Routing\Redirector::refresh($status, $headers); } - + /** * Create a new redirect response, while putting the current URL in the session. * @@ -6920,13 +7468,14 @@ public static function refresh($status = 302, $headers = array()){ * @param int $status * @param array $headers * @param bool $secure - * @return \Illuminate\Http\RedirectResponse - * @static + * @return \Illuminate\Http\RedirectResponse + * @static */ - public static function guest($path, $status = 302, $headers = array(), $secure = null){ + public static function guest($path, $status = 302, $headers = [], $secure = null) + { return \Illuminate\Routing\Redirector::guest($path, $status, $headers, $secure); } - + /** * Create a new redirect response to the previously intended location. * @@ -6934,13 +7483,14 @@ public static function guest($path, $status = 302, $headers = array(), $secure = * @param int $status * @param array $headers * @param bool $secure - * @return \Illuminate\Http\RedirectResponse - * @static + * @return \Illuminate\Http\RedirectResponse + * @static */ - public static function intended($default = '/', $status = 302, $headers = array(), $secure = null){ + public static function intended($default = '/', $status = 302, $headers = [], $secure = null) + { return \Illuminate\Routing\Redirector::intended($default, $status, $headers, $secure); } - + /** * Create a new redirect response to the given path. * @@ -6948,39 +7498,42 @@ public static function intended($default = '/', $status = 302, $headers = array( * @param int $status * @param array $headers * @param bool $secure - * @return \Illuminate\Http\RedirectResponse - * @static + * @return \Illuminate\Http\RedirectResponse + * @static */ - public static function to($path, $status = 302, $headers = array(), $secure = null){ + public static function to($path, $status = 302, $headers = [], $secure = null) + { return \Illuminate\Routing\Redirector::to($path, $status, $headers, $secure); } - + /** * Create a new redirect response to an external URL (no validation). * * @param string $path * @param int $status * @param array $headers - * @return \Illuminate\Http\RedirectResponse - * @static + * @return \Illuminate\Http\RedirectResponse + * @static */ - public static function away($path, $status = 302, $headers = array()){ + public static function away($path, $status = 302, $headers = []) + { return \Illuminate\Routing\Redirector::away($path, $status, $headers); } - + /** * Create a new redirect response to the given HTTPS path. * * @param string $path * @param int $status * @param array $headers - * @return \Illuminate\Http\RedirectResponse - * @static + * @return \Illuminate\Http\RedirectResponse + * @static */ - public static function secure($path, $status = 302, $headers = array()){ + public static function secure($path, $status = 302, $headers = []) + { return \Illuminate\Routing\Redirector::secure($path, $status, $headers); } - + /** * Create a new redirect response to a named route. * @@ -6988,13 +7541,14 @@ public static function secure($path, $status = 302, $headers = array()){ * @param array $parameters * @param int $status * @param array $headers - * @return \Illuminate\Http\RedirectResponse - * @static + * @return \Illuminate\Http\RedirectResponse + * @static */ - public static function route($route, $parameters = array(), $status = 302, $headers = array()){ + public static function route($route, $parameters = [], $status = 302, $headers = []) + { return \Illuminate\Routing\Redirector::route($route, $parameters, $status, $headers); } - + /** * Create a new redirect response to a controller action. * @@ -7002,600 +7556,653 @@ public static function route($route, $parameters = array(), $status = 302, $head * @param array $parameters * @param int $status * @param array $headers - * @return \Illuminate\Http\RedirectResponse - * @static + * @return \Illuminate\Http\RedirectResponse + * @static */ - public static function action($action, $parameters = array(), $status = 302, $headers = array()){ + public static function action($action, $parameters = [], $status = 302, $headers = []) + { return \Illuminate\Routing\Redirector::action($action, $parameters, $status, $headers); } - + /** * Get the URL generator instance. * - * @return \Illuminate\Routing\UrlGenerator - * @static + * @return \Illuminate\Routing\UrlGenerator + * @static */ - public static function getUrlGenerator(){ + public static function getUrlGenerator() + { return \Illuminate\Routing\Redirector::getUrlGenerator(); } - + /** * Set the active session store. * * @param \Illuminate\Session\Store $session - * @return void - * @static + * @return void + * @static */ - public static function setSession($session){ + public static function setSession($session) + { \Illuminate\Routing\Redirector::setSession($session); } - } - - class Request extends \Illuminate\Support\Facades\Request{ - + class Request extends \Illuminate\Support\Facades\Request + { /** * Create a new Illuminate HTTP request from server variables. * - * @return static - * @static + * @return static + * @static */ - public static function capture(){ + public static function capture() + { return \Illuminate\Http\Request::capture(); } - + /** * Return the Request instance. * - * @return $this - * @static + * @return $this + * @static */ - public static function instance(){ + public static function instance() + { return \Illuminate\Http\Request::instance(); } - + /** * Get the request method. * - * @return string - * @static + * @return string + * @static */ - public static function method(){ + public static function method() + { return \Illuminate\Http\Request::method(); } - + /** * Get the root URL for the application. * - * @return string - * @static + * @return string + * @static */ - public static function root(){ + public static function root() + { return \Illuminate\Http\Request::root(); } - + /** * Get the URL (no query string) for the request. * - * @return string - * @static + * @return string + * @static */ - public static function url(){ + public static function url() + { return \Illuminate\Http\Request::url(); } - + /** * Get the full URL for the request. * - * @return string - * @static + * @return string + * @static */ - public static function fullUrl(){ + public static function fullUrl() + { return \Illuminate\Http\Request::fullUrl(); } - + /** * Get the full URL for the request with the added query string parameters. * * @param array $query - * @return string - * @static + * @return string + * @static */ - public static function fullUrlWithQuery($query){ + public static function fullUrlWithQuery($query) + { return \Illuminate\Http\Request::fullUrlWithQuery($query); } - + /** * Get the current path info for the request. * - * @return string - * @static + * @return string + * @static */ - public static function path(){ + public static function path() + { return \Illuminate\Http\Request::path(); } - + /** * Get the current encoded path info for the request. * - * @return string - * @static + * @return string + * @static */ - public static function decodedPath(){ + public static function decodedPath() + { return \Illuminate\Http\Request::decodedPath(); } - + /** * Get a segment from the URI (1 based index). * * @param int $index * @param string|null $default - * @return string|null - * @static + * @return string|null + * @static */ - public static function segment($index, $default = null){ + public static function segment($index, $default = null) + { return \Illuminate\Http\Request::segment($index, $default); } - + /** * Get all of the segments for the request path. * - * @return array - * @static + * @return array + * @static */ - public static function segments(){ + public static function segments() + { return \Illuminate\Http\Request::segments(); } - + /** * Determine if the current request URI matches a pattern. * * @param mixed string - * @return bool - * @static + * @return bool + * @static */ - public static function is(){ + public static function is() + { return \Illuminate\Http\Request::is(); } - + /** * Determine if the current request URL and query string matches a pattern. * * @param mixed string - * @return bool - * @static + * @return bool + * @static */ - public static function fullUrlIs(){ + public static function fullUrlIs() + { return \Illuminate\Http\Request::fullUrlIs(); } - + /** * Determine if the request is the result of an AJAX call. * - * @return bool - * @static + * @return bool + * @static */ - public static function ajax(){ + public static function ajax() + { return \Illuminate\Http\Request::ajax(); } - + /** * Determine if the request is the result of an PJAX call. * - * @return bool - * @static + * @return bool + * @static */ - public static function pjax(){ + public static function pjax() + { return \Illuminate\Http\Request::pjax(); } - + /** * Determine if the request is over HTTPS. * - * @return bool - * @static + * @return bool + * @static */ - public static function secure(){ + public static function secure() + { return \Illuminate\Http\Request::secure(); } - + /** * Returns the client IP address. * - * @return string - * @static + * @return string + * @static */ - public static function ip(){ + public static function ip() + { return \Illuminate\Http\Request::ip(); } - + /** * Returns the client IP addresses. * - * @return array - * @static + * @return array + * @static */ - public static function ips(){ + public static function ips() + { return \Illuminate\Http\Request::ips(); } - + /** * Determine if the request contains a given input item key. * * @param string|array $key - * @return bool - * @static + * @return bool + * @static */ - public static function exists($key){ + public static function exists($key) + { return \Illuminate\Http\Request::exists($key); } - + /** * Determine if the request contains a non-empty value for an input item. * * @param string|array $key - * @return bool - * @static + * @return bool + * @static */ - public static function has($key){ + public static function has($key) + { return \Illuminate\Http\Request::has($key); } - + /** * Get all of the input and files for the request. * - * @return array - * @static + * @return array + * @static */ - public static function all(){ + public static function all() + { return \Illuminate\Http\Request::all(); } - + /** * Retrieve an input item from the request. * * @param string $key * @param string|array|null $default - * @return string|array - * @static + * @return string|array + * @static */ - public static function input($key = null, $default = null){ + public static function input($key = null, $default = null) + { return \Illuminate\Http\Request::input($key, $default); } - + /** * Get a subset containing the provided keys with values from the input data. * * @param array|mixed $keys - * @return array - * @static + * @return array + * @static */ - public static function only($keys){ + public static function only($keys) + { return \Illuminate\Http\Request::only($keys); } - + /** * Get all of the input except for a specified array of items. * * @param array|mixed $keys - * @return array - * @static + * @return array + * @static */ - public static function except($keys){ + public static function except($keys) + { return \Illuminate\Http\Request::except($keys); } - + /** * Intersect an array of items with the input data. * * @param array|mixed $keys - * @return array - * @static + * @return array + * @static */ - public static function intersect($keys){ + public static function intersect($keys) + { return \Illuminate\Http\Request::intersect($keys); } - + /** * Retrieve a query string item from the request. * * @param string $key * @param string|array|null $default - * @return string|array - * @static + * @return string|array + * @static */ - public static function query($key = null, $default = null){ + public static function query($key = null, $default = null) + { return \Illuminate\Http\Request::query($key, $default); } - + /** * Determine if a cookie is set on the request. * * @param string $key - * @return bool - * @static + * @return bool + * @static */ - public static function hasCookie($key){ + public static function hasCookie($key) + { return \Illuminate\Http\Request::hasCookie($key); } - + /** * Retrieve a cookie from the request. * * @param string $key * @param string|array|null $default - * @return string|array - * @static + * @return string|array + * @static */ - public static function cookie($key = null, $default = null){ + public static function cookie($key = null, $default = null) + { return \Illuminate\Http\Request::cookie($key, $default); } - + /** * Get an array of all of the files on the request. * - * @return array - * @static + * @return array + * @static */ - public static function allFiles(){ + public static function allFiles() + { return \Illuminate\Http\Request::allFiles(); } - + /** * Retrieve a file from the request. * * @param string $key * @param mixed $default - * @return \Illuminate\Http\UploadedFile|array|null - * @static + * @return \Illuminate\Http\UploadedFile|array|null + * @static */ - public static function file($key = null, $default = null){ + public static function file($key = null, $default = null) + { return \Illuminate\Http\Request::file($key, $default); } - + /** * Determine if the uploaded data contains a file. * * @param string $key - * @return bool - * @static + * @return bool + * @static */ - public static function hasFile($key){ + public static function hasFile($key) + { return \Illuminate\Http\Request::hasFile($key); } - + /** * Determine if a header is set on the request. * * @param string $key - * @return bool - * @static + * @return bool + * @static */ - public static function hasHeader($key){ + public static function hasHeader($key) + { return \Illuminate\Http\Request::hasHeader($key); } - + /** * Retrieve a header from the request. * * @param string $key * @param string|array|null $default - * @return string|array - * @static + * @return string|array + * @static */ - public static function header($key = null, $default = null){ + public static function header($key = null, $default = null) + { return \Illuminate\Http\Request::header($key, $default); } - + /** * Retrieve a server variable from the request. * * @param string $key * @param string|array|null $default - * @return string|array - * @static + * @return string|array + * @static */ - public static function server($key = null, $default = null){ + public static function server($key = null, $default = null) + { return \Illuminate\Http\Request::server($key, $default); } - + /** * Retrieve an old input item. * * @param string $key * @param string|array|null $default - * @return string|array - * @static + * @return string|array + * @static */ - public static function old($key = null, $default = null){ + public static function old($key = null, $default = null) + { return \Illuminate\Http\Request::old($key, $default); } - + /** * Flash the input for the current request to the session. * * @param string $filter * @param array $keys - * @return void - * @static + * @return void + * @static */ - public static function flash($filter = null, $keys = array()){ + public static function flash($filter = null, $keys = []) + { \Illuminate\Http\Request::flash($filter, $keys); } - + /** * Flash only some of the input to the session. * * @param array|mixed $keys - * @return void - * @static + * @return void + * @static */ - public static function flashOnly($keys){ + public static function flashOnly($keys) + { \Illuminate\Http\Request::flashOnly($keys); } - + /** * Flash only some of the input to the session. * * @param array|mixed $keys - * @return void - * @static + * @return void + * @static */ - public static function flashExcept($keys){ + public static function flashExcept($keys) + { \Illuminate\Http\Request::flashExcept($keys); } - + /** * Flush all of the old input from the session. * - * @return void - * @static + * @return void + * @static */ - public static function flush(){ + public static function flush() + { \Illuminate\Http\Request::flush(); } - + /** * Merge new input into the current request's input array. * * @param array $input - * @return void - * @static + * @return void + * @static */ - public static function merge($input){ + public static function merge($input) + { \Illuminate\Http\Request::merge($input); } - + /** * Replace the input for the current request. * * @param array $input - * @return void - * @static + * @return void + * @static */ - public static function replace($input){ + public static function replace($input) + { \Illuminate\Http\Request::replace($input); } - + /** * Get the JSON payload for the request. * * @param string $key * @param mixed $default - * @return mixed - * @static + * @return mixed + * @static */ - public static function json($key = null, $default = null){ + public static function json($key = null, $default = null) + { return \Illuminate\Http\Request::json($key, $default); } - + /** * Determine if the given content types match. * * @param string $actual * @param string $type - * @return bool - * @static + * @return bool + * @static */ - public static function matchesType($actual, $type){ + public static function matchesType($actual, $type) + { return \Illuminate\Http\Request::matchesType($actual, $type); } - + /** * Determine if the request is sending JSON. * - * @return bool - * @static + * @return bool + * @static */ - public static function isJson(){ + public static function isJson() + { return \Illuminate\Http\Request::isJson(); } - + /** * Determine if the current request is asking for JSON in return. * - * @return bool - * @static + * @return bool + * @static */ - public static function wantsJson(){ + public static function wantsJson() + { return \Illuminate\Http\Request::wantsJson(); } - + /** * Determines whether the current requests accepts a given content type. * * @param string|array $contentTypes - * @return bool - * @static + * @return bool + * @static */ - public static function accepts($contentTypes){ + public static function accepts($contentTypes) + { return \Illuminate\Http\Request::accepts($contentTypes); } - + /** * Return the most suitable content type from the given array based on content negotiation. * * @param string|array $contentTypes - * @return string|null - * @static + * @return string|null + * @static */ - public static function prefers($contentTypes){ + public static function prefers($contentTypes) + { return \Illuminate\Http\Request::prefers($contentTypes); } - + /** * Determines whether a request accepts JSON. * - * @return bool - * @static + * @return bool + * @static */ - public static function acceptsJson(){ + public static function acceptsJson() + { return \Illuminate\Http\Request::acceptsJson(); } - + /** * Determines whether a request accepts HTML. * - * @return bool - * @static + * @return bool + * @static */ - public static function acceptsHtml(){ + public static function acceptsHtml() + { return \Illuminate\Http\Request::acceptsHtml(); } - + /** * Get the data format expected in the response. * * @param string $default - * @return string - * @static + * @return string + * @static */ - public static function format($default = 'html'){ + public static function format($default = 'html') + { return \Illuminate\Http\Request::format($default); } - + /** * Get the bearer token from the request headers. * - * @return string|null - * @static + * @return string|null + * @static */ - public static function bearerToken(){ + public static function bearerToken() + { return \Illuminate\Http\Request::bearerToken(); } - + /** * Create an Illuminate request from a Symfony instance. * * @param \Symfony\Component\HttpFoundation\Request $request - * @return \Illuminate\Http\Request - * @static + * @return \Illuminate\Http\Request + * @static */ - public static function createFromBase($request){ + public static function createFromBase($request) + { return \Illuminate\Http\Request::createFromBase($request); } - + /** * Clones a request and overrides some of its parameters. * @@ -7606,156 +8213,170 @@ public static function createFromBase($request){ * @param array $files The FILES parameters * @param array $server The SERVER parameters * @return \Request The duplicated request - * @static + * @static */ - public static function duplicate($query = null, $request = null, $attributes = null, $cookies = null, $files = null, $server = null){ + public static function duplicate($query = null, $request = null, $attributes = null, $cookies = null, $files = null, $server = null) + { return \Illuminate\Http\Request::duplicate($query, $request, $attributes, $cookies, $files, $server); } - + /** * Get the session associated with the request. * - * @return \Illuminate\Session\Store + * @return \Illuminate\Session\Store * @throws \RuntimeException - * @static + * @static */ - public static function session(){ + public static function session() + { return \Illuminate\Http\Request::session(); } - + /** * Get the user making the request. * * @param string|null $guard - * @return mixed - * @static + * @return mixed + * @static */ - public static function user($guard = null){ + public static function user($guard = null) + { return \Illuminate\Http\Request::user($guard); } - + /** * Get the route handling the request. * * @param string|null $param - * @return \Illuminate\Routing\Route|object|string - * @static + * @return \Illuminate\Routing\Route|object|string + * @static */ - public static function route($param = null){ + public static function route($param = null) + { return \Illuminate\Http\Request::route($param); } - + /** * Get a unique fingerprint for the request / route / IP address. * - * @return string + * @return string * @throws \RuntimeException - * @static + * @static */ - public static function fingerprint(){ + public static function fingerprint() + { return \Illuminate\Http\Request::fingerprint(); } - + /** * Get the user resolver callback. * - * @return \Closure - * @static + * @return \Closure + * @static */ - public static function getUserResolver(){ + public static function getUserResolver() + { return \Illuminate\Http\Request::getUserResolver(); } - + /** * Set the user resolver callback. * * @param \Closure $callback - * @return $this - * @static + * @return $this + * @static */ - public static function setUserResolver($callback){ + public static function setUserResolver($callback) + { return \Illuminate\Http\Request::setUserResolver($callback); } - + /** * Get the route resolver callback. * - * @return \Closure - * @static + * @return \Closure + * @static */ - public static function getRouteResolver(){ + public static function getRouteResolver() + { return \Illuminate\Http\Request::getRouteResolver(); } - + /** * Set the route resolver callback. * * @param \Closure $callback - * @return $this - * @static + * @return $this + * @static */ - public static function setRouteResolver($callback){ + public static function setRouteResolver($callback) + { return \Illuminate\Http\Request::setRouteResolver($callback); } - + /** * Get all of the input and files for the request. * - * @return array - * @static + * @return array + * @static */ - public static function toArray(){ + public static function toArray() + { return \Illuminate\Http\Request::toArray(); } - + /** * Determine if the given offset exists. * * @param string $offset - * @return bool - * @static + * @return bool + * @static */ - public static function offsetExists($offset){ + public static function offsetExists($offset) + { return \Illuminate\Http\Request::offsetExists($offset); } - + /** * Get the value at the given offset. * * @param string $offset - * @return mixed - * @static + * @return mixed + * @static */ - public static function offsetGet($offset){ + public static function offsetGet($offset) + { return \Illuminate\Http\Request::offsetGet($offset); } - + /** * Set the value at the given offset. * * @param string $offset * @param mixed $value - * @return void - * @static + * @return void + * @static */ - public static function offsetSet($offset, $value){ + public static function offsetSet($offset, $value) + { \Illuminate\Http\Request::offsetSet($offset, $value); } - + /** * Remove the value at the given offset. * * @param string $offset - * @return void - * @static + * @return void + * @static */ - public static function offsetUnset($offset){ + public static function offsetUnset($offset) + { \Illuminate\Http\Request::offsetUnset($offset); } - + /** * Sets the parameters for this request. - * + * * This method also re-initializes all properties. * * @param array $query The GET parameters @@ -7765,27 +8386,29 @@ public static function offsetUnset($offset){ * @param array $files The FILES parameters * @param array $server The SERVER parameters * @param string|resource $content The raw body data - * @static + * @static */ - public static function initialize($query = array(), $request = array(), $attributes = array(), $cookies = array(), $files = array(), $server = array(), $content = null){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function initialize($query = [], $request = [], $attributes = [], $cookies = [], $files = [], $server = [], $content = null) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::initialize($query, $request, $attributes, $cookies, $files, $server, $content); } - + /** * Creates a new request with values from PHP's super globals. * * @return \Request A new request - * @static + * @static */ - public static function createFromGlobals(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function createFromGlobals() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::createFromGlobals(); } - + /** * Creates a Request based on a given URI and configuration. - * + * * The information contained in the URI always take precedence * over the other information (server and parameters). * @@ -7797,263 +8420,281 @@ public static function createFromGlobals(){ * @param array $server The server parameters ($_SERVER) * @param string $content The raw body data * @return \Request A Request instance - * @static + * @static */ - public static function create($uri, $method = 'GET', $parameters = array(), $cookies = array(), $files = array(), $server = array(), $content = null){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function create($uri, $method = 'GET', $parameters = [], $cookies = [], $files = [], $server = [], $content = null) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::create($uri, $method, $parameters, $cookies, $files, $server, $content); } - + /** * Sets a callable able to create a Request instance. - * + * * This is mainly useful when you need to override the Request class * to keep BC with an existing system. It should not be used for any * other purpose. * * @param callable|null $callable A PHP callable - * @static + * @static */ - public static function setFactory($callable){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function setFactory($callable) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::setFactory($callable); } - + /** * Overrides the PHP global variables according to this request instance. - * + * * It overrides $_GET, $_POST, $_REQUEST, $_SERVER, $_COOKIE. * $_FILES is never overridden, see rfc1867 * - * @static + * @static */ - public static function overrideGlobals(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function overrideGlobals() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::overrideGlobals(); } - + /** * Sets a list of trusted proxies. - * + * * You should only list the reverse proxies that you manage directly. * * @param array $proxies A list of trusted proxies - * @static + * @static */ - public static function setTrustedProxies($proxies){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function setTrustedProxies($proxies) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::setTrustedProxies($proxies); } - + /** * Gets the list of trusted proxies. * * @return array An array of trusted proxies - * @static + * @static */ - public static function getTrustedProxies(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getTrustedProxies() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getTrustedProxies(); } - + /** * Sets a list of trusted host patterns. - * + * * You should only list the hosts you manage using regexs. * * @param array $hostPatterns A list of trusted host patterns - * @static + * @static */ - public static function setTrustedHosts($hostPatterns){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function setTrustedHosts($hostPatterns) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::setTrustedHosts($hostPatterns); } - + /** * Gets the list of trusted host patterns. * * @return array An array of trusted host patterns - * @static + * @static */ - public static function getTrustedHosts(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getTrustedHosts() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getTrustedHosts(); } - + /** * Sets the name for trusted headers. - * + * * The following header keys are supported: - * + * * * Request::HEADER_CLIENT_IP: defaults to X-Forwarded-For (see getClientIp()) * * Request::HEADER_CLIENT_HOST: defaults to X-Forwarded-Host (see getHost()) * * Request::HEADER_CLIENT_PORT: defaults to X-Forwarded-Port (see getPort()) * * Request::HEADER_CLIENT_PROTO: defaults to X-Forwarded-Proto (see getScheme() and isSecure()) - * + * * Setting an empty value allows to disable the trusted header for the given key. * * @param string $key The header key * @param string $value The header name * @throws \InvalidArgumentException - * @static + * @static */ - public static function setTrustedHeaderName($key, $value){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function setTrustedHeaderName($key, $value) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::setTrustedHeaderName($key, $value); } - + /** * Gets the trusted proxy header name. * * @param string $key The header key * @return string The header name * @throws \InvalidArgumentException - * @static + * @static */ - public static function getTrustedHeaderName($key){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getTrustedHeaderName($key) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getTrustedHeaderName($key); } - + /** * Normalizes a query string. - * + * * It builds a normalized query string, where keys/value pairs are alphabetized, * have consistent escaping and unneeded delimiters are removed. * * @param string $qs Query string * @return string A normalized query string for the Request - * @static + * @static */ - public static function normalizeQueryString($qs){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function normalizeQueryString($qs) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::normalizeQueryString($qs); } - + /** * Enables support for the _method request parameter to determine the intended HTTP method. - * + * * Be warned that enabling this feature might lead to CSRF issues in your code. * Check that you are using CSRF tokens when required. * If the HTTP method parameter override is enabled, an html-form with method "POST" can be altered * and used to send a "PUT" or "DELETE" request via the _method request parameter. * If these methods are not protected against CSRF, this presents a possible vulnerability. - * + * * The HTTP method can only be overridden when the real HTTP method is POST. * - * @static + * @static */ - public static function enableHttpMethodParameterOverride(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function enableHttpMethodParameterOverride() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::enableHttpMethodParameterOverride(); } - + /** * Checks whether support for the _method request parameter is enabled. * * @return bool True when the _method request parameter is enabled, false otherwise - * @static + * @static */ - public static function getHttpMethodParameterOverride(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getHttpMethodParameterOverride() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getHttpMethodParameterOverride(); } - + /** * Gets a "parameter" value from any bag. - * + * * This method is mainly useful for libraries that want to provide some flexibility. If you don't need the * flexibility in controllers, it is better to explicitly get request parameters from the appropriate * public property instead (attributes, query, request). - * + * * Order of precedence: PATH (routing placeholders or custom attributes), GET, BODY * * @param string $key the key * @param mixed $default the default value if the parameter key does not exist - * @return mixed - * @static + * @return mixed + * @static */ - public static function get($key, $default = null){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function get($key, $default = null) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::get($key, $default); } - + /** * Gets the Session. * * @return \Symfony\Component\HttpFoundation\SessionInterface|null The session - * @static + * @static */ - public static function getSession(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getSession() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getSession(); } - + /** * Whether the request contains a Session which was started in one of the * previous requests. * - * @return bool - * @static + * @return bool + * @static */ - public static function hasPreviousSession(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function hasPreviousSession() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::hasPreviousSession(); } - + /** * Whether the request contains a Session object. - * + * * This method does not give any information about the state of the session object, * like whether the session is started or not. It is just a way to check if this Request * is associated with a Session instance. * * @return bool true when the Request contains a Session object, false otherwise - * @static + * @static */ - public static function hasSession(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function hasSession() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::hasSession(); } - + /** * Sets the Session. * * @param \Symfony\Component\HttpFoundation\SessionInterface $session The Session - * @static + * @static */ - public static function setSession($session){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function setSession($session) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::setSession($session); } - + /** * Returns the client IP addresses. - * + * * In the returned array the most trusted IP address is first, and the * least trusted one last. The "real" client IP address is the last one, * but this is also the least trusted one. Trusted proxies are stripped. - * + * * Use this method carefully; you should use getClientIp() instead. * * @return array The client IP addresses * @see getClientIp() - * @static + * @static */ - public static function getClientIps(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getClientIps() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getClientIps(); } - + /** * Returns the client IP address. - * + * * This method can read the client IP address from the "X-Forwarded-For" header * when trusted proxies were set via "setTrustedProxies()". The "X-Forwarded-For" * header value is a comma+space separated list of IP addresses, the left-most * being the original client, and each successive proxy that passed the request * adding the IP address where it received the request from. - * + * * If your reverse proxy uses a different header name than "X-Forwarded-For", * ("Client-Ip" for instance), configure it via "setTrustedHeaderName()" with * the "client-ip" key. @@ -8061,211 +8702,226 @@ public static function getClientIps(){ * @return string The client IP address * @see getClientIps() * @see http://en.wikipedia.org/wiki/X-Forwarded-For - * @static + * @static */ - public static function getClientIp(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getClientIp() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getClientIp(); } - + /** * Returns current script name. * - * @return string - * @static + * @return string + * @static */ - public static function getScriptName(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getScriptName() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getScriptName(); } - + /** * Returns the path being requested relative to the executed script. - * + * * The path info always starts with a /. - * + * * Suppose this request is instantiated from /mysite on localhost: - * + * * * http://localhost/mysite returns an empty string * * http://localhost/mysite/about returns '/about' * * http://localhost/mysite/enco%20ded returns '/enco%20ded' * * http://localhost/mysite/about?var=1 returns '/about' * * @return string The raw path (i.e. not urldecoded) - * @static + * @static */ - public static function getPathInfo(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getPathInfo() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getPathInfo(); } - + /** * Returns the root path from which this request is executed. - * + * * Suppose that an index.php file instantiates this request object: - * + * * * http://localhost/index.php returns an empty string * * http://localhost/index.php/page returns an empty string * * http://localhost/web/index.php returns '/web' * * http://localhost/we%20b/index.php returns '/we%20b' * * @return string The raw path (i.e. not urldecoded) - * @static + * @static */ - public static function getBasePath(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getBasePath() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getBasePath(); } - + /** * Returns the root URL from which this request is executed. - * + * * The base URL never ends with a /. - * + * * This is similar to getBasePath(), except that it also includes the * script filename (e.g. index.php) if one exists. * * @return string The raw URL (i.e. not urldecoded) - * @static + * @static */ - public static function getBaseUrl(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getBaseUrl() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getBaseUrl(); } - + /** * Gets the request's scheme. * - * @return string - * @static + * @return string + * @static */ - public static function getScheme(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getScheme() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getScheme(); } - + /** * Returns the port on which the request is made. - * + * * This method can read the client port from the "X-Forwarded-Port" header * when trusted proxies were set via "setTrustedProxies()". - * + * * The "X-Forwarded-Port" header must contain the client port. - * + * * If your reverse proxy uses a different header name than "X-Forwarded-Port", * configure it via "setTrustedHeaderName()" with the "client-port" key. * - * @return string - * @static + * @return string + * @static */ - public static function getPort(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getPort() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getPort(); } - + /** * Returns the user. * - * @return string|null - * @static + * @return string|null + * @static */ - public static function getUser(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getUser() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getUser(); } - + /** * Returns the password. * - * @return string|null - * @static + * @return string|null + * @static */ - public static function getPassword(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getPassword() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getPassword(); } - + /** * Gets the user info. * * @return string A user name and, optionally, scheme-specific information about how to gain authorization to access the server - * @static + * @static */ - public static function getUserInfo(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getUserInfo() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getUserInfo(); } - + /** * Returns the HTTP host being requested. - * + * * The port name will be appended to the host if it's non-standard. * - * @return string - * @static + * @return string + * @static */ - public static function getHttpHost(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getHttpHost() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getHttpHost(); } - + /** * Returns the requested URI (path and query string). * * @return string The raw URI (i.e. not URI decoded) - * @static + * @static */ - public static function getRequestUri(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getRequestUri() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getRequestUri(); } - + /** * Gets the scheme and HTTP host. - * + * * If the URL was called with basic authentication, the user * and the password are not added to the generated string. * * @return string The scheme and HTTP host - * @static + * @static */ - public static function getSchemeAndHttpHost(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getSchemeAndHttpHost() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getSchemeAndHttpHost(); } - + /** * Generates a normalized URI (URL) for the Request. * * @return string A normalized URI (URL) for the Request * @see getQueryString() - * @static + * @static */ - public static function getUri(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getUri() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getUri(); } - + /** * Generates a normalized URI for the given path. * * @param string $path A path to use instead of the current one * @return string The normalized URI for the path - * @static + * @static */ - public static function getUriForPath($path){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getUriForPath($path) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getUriForPath($path); } - + /** * Returns the path as relative reference from the current Request path. - * + * * Only the URIs path component (no schema, host etc.) is relevant and must be given. * Both paths must be absolute and not contain relative parts. * Relative URLs from one resource to another are useful when generating self-contained downloadable document archives. * Furthermore, they can be used to reduce the link size in documents. - * + * * Example target paths, given a base path of "/a/b/c/d": * - "/a/b/c/d" -> "" * - "/a/b/c/" -> "./" @@ -8275,400 +8931,427 @@ public static function getUriForPath($path){ * * @param string $path The target path * @return string The relative target path - * @static + * @static */ - public static function getRelativeUriForPath($path){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getRelativeUriForPath($path) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getRelativeUriForPath($path); } - + /** * Generates the normalized query string for the Request. - * + * * It builds a normalized query string, where keys/value pairs are alphabetized * and have consistent escaping. * * @return string|null A normalized query string for the Request - * @static + * @static */ - public static function getQueryString(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getQueryString() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getQueryString(); } - + /** * Checks whether the request is secure or not. - * + * * This method can read the client protocol from the "X-Forwarded-Proto" header * when trusted proxies were set via "setTrustedProxies()". - * + * * The "X-Forwarded-Proto" header must contain the protocol: "https" or "http". - * + * * If your reverse proxy uses a different header name than "X-Forwarded-Proto" * ("SSL_HTTPS" for instance), configure it via "setTrustedHeaderName()" with * the "client-proto" key. * - * @return bool - * @static + * @return bool + * @static */ - public static function isSecure(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function isSecure() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::isSecure(); } - + /** * Returns the host name. - * + * * This method can read the client host name from the "X-Forwarded-Host" header * when trusted proxies were set via "setTrustedProxies()". - * + * * The "X-Forwarded-Host" header must contain the client host name. - * + * * If your reverse proxy uses a different header name than "X-Forwarded-Host", * configure it via "setTrustedHeaderName()" with the "client-host" key. * - * @return string + * @return string * @throws \UnexpectedValueException when the host name is invalid - * @static + * @static */ - public static function getHost(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getHost() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getHost(); } - + /** * Sets the request method. * * @param string $method - * @static + * @static */ - public static function setMethod($method){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function setMethod($method) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::setMethod($method); } - + /** * Gets the request "intended" method. - * + * * If the X-HTTP-Method-Override header is set, and if the method is a POST, * then it is used to determine the "real" intended HTTP method. - * + * * The _method request parameter can also be used to determine the HTTP method, * but only if enableHttpMethodParameterOverride() has been called. - * + * * The method is always an uppercased string. * * @return string The request method * @see getRealMethod() - * @static + * @static */ - public static function getMethod(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getMethod() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getMethod(); } - + /** * Gets the "real" request method. * * @return string The request method * @see getMethod() - * @static + * @static */ - public static function getRealMethod(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getRealMethod() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getRealMethod(); } - + /** * Gets the mime type associated with the format. * * @param string $format The format * @return string The associated mime type (null if not found) - * @static + * @static */ - public static function getMimeType($format){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getMimeType($format) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getMimeType($format); } - + /** * Gets the format associated with the mime type. * * @param string $mimeType The associated mime type * @return string|null The format (null if not found) - * @static + * @static */ - public static function getFormat($mimeType){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getFormat($mimeType) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getFormat($mimeType); } - + /** * Associates a format with mime types. * * @param string $format The format * @param string|array $mimeTypes The associated mime types (the preferred one must be the first as it will be used as the content type) - * @static + * @static */ - public static function setFormat($format, $mimeTypes){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function setFormat($format, $mimeTypes) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::setFormat($format, $mimeTypes); } - + /** * Gets the request format. - * + * * Here is the process to determine the format: - * + * * * format defined by the user (with setRequestFormat()) * * _format request attribute * * $default * * @param string $default The default format * @return string The request format - * @static + * @static */ - public static function getRequestFormat($default = 'html'){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getRequestFormat($default = 'html') + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getRequestFormat($default); } - + /** * Sets the request format. * * @param string $format The request format - * @static + * @static */ - public static function setRequestFormat($format){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function setRequestFormat($format) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::setRequestFormat($format); } - + /** * Gets the format associated with the request. * * @return string|null The format (null if no content type is present) - * @static + * @static */ - public static function getContentType(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getContentType() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getContentType(); } - + /** * Sets the default locale. * * @param string $locale - * @static + * @static */ - public static function setDefaultLocale($locale){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function setDefaultLocale($locale) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::setDefaultLocale($locale); } - + /** * Get the default locale. * - * @return string - * @static + * @return string + * @static */ - public static function getDefaultLocale(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getDefaultLocale() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getDefaultLocale(); } - + /** * Sets the locale. * * @param string $locale - * @static + * @static */ - public static function setLocale($locale){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function setLocale($locale) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::setLocale($locale); } - + /** * Get the locale. * - * @return string - * @static + * @return string + * @static */ - public static function getLocale(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getLocale() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getLocale(); } - + /** * Checks if the request method is of specified type. * * @param string $method Uppercase request method (GET, POST etc) - * @return bool - * @static + * @return bool + * @static */ - public static function isMethod($method){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function isMethod($method) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::isMethod($method); } - + /** * Checks whether the method is safe or not. * - * @return bool - * @static + * @return bool + * @static */ - public static function isMethodSafe(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function isMethodSafe() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::isMethodSafe(); } - + /** * Returns the request body content. * * @param bool $asResource If true, a resource will be returned * @return string|resource The request body content or a resource to read the body stream * @throws \LogicException - * @static + * @static */ - public static function getContent($asResource = false){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getContent($asResource = false) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getContent($asResource); } - + /** * Gets the Etags. * * @return array The entity tags - * @static + * @static */ - public static function getETags(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getETags() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getETags(); } - + /** - * - * - * @return bool - * @static + * @return bool + * @static */ - public static function isNoCache(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function isNoCache() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::isNoCache(); } - + /** * Returns the preferred language. * * @param array $locales An array of ordered available locales * @return string|null The preferred locale - * @static + * @static */ - public static function getPreferredLanguage($locales = null){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getPreferredLanguage($locales = null) + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getPreferredLanguage($locales); } - + /** * Gets a list of languages acceptable by the client browser. * * @return array Languages ordered in the user browser preferences - * @static + * @static */ - public static function getLanguages(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getLanguages() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getLanguages(); } - + /** * Gets a list of charsets acceptable by the client browser. * * @return array List of charsets in preferable order - * @static + * @static */ - public static function getCharsets(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getCharsets() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getCharsets(); } - + /** * Gets a list of encodings acceptable by the client browser. * * @return array List of encodings in preferable order - * @static + * @static */ - public static function getEncodings(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getEncodings() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getEncodings(); } - + /** * Gets a list of content types acceptable by the client browser. * * @return array List of content types in preferable order - * @static + * @static */ - public static function getAcceptableContentTypes(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function getAcceptableContentTypes() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::getAcceptableContentTypes(); } - + /** * Returns true if the request is a XMLHttpRequest. - * + * * It works if your JavaScript library sets an X-Requested-With HTTP header. * It is known to work with common JavaScript frameworks: * * @link http://en.wikipedia.org/wiki/List_of_Ajax_frameworks#JavaScript * @return bool true if the request is an XMLHttpRequest, false otherwise - * @static + * @static */ - public static function isXmlHttpRequest(){ - //Method inherited from \Symfony\Component\HttpFoundation\Request + public static function isXmlHttpRequest() + { + //Method inherited from \Symfony\Component\HttpFoundation\Request return \Illuminate\Http\Request::isXmlHttpRequest(); } - + /** * Register a custom macro. * * @param string $name * @param callable $macro - * @return void - * @static + * @return void + * @static */ - public static function macro($name, $macro){ + public static function macro($name, $macro) + { \Illuminate\Http\Request::macro($name, $macro); } - + /** * Checks if macro is registered. * * @param string $name - * @return bool - * @static + * @return bool + * @static */ - public static function hasMacro($name){ + public static function hasMacro($name) + { return \Illuminate\Http\Request::hasMacro($name); } - } - - class Response extends \Illuminate\Support\Facades\Response{ - + class Response extends \Illuminate\Support\Facades\Response + { /** * Return a new response from the application. * * @param string $content * @param int $status * @param array $headers - * @return \Illuminate\Http\Response - * @static + * @return \Illuminate\Http\Response + * @static */ - public static function make($content = '', $status = 200, $headers = array()){ + public static function make($content = '', $status = 200, $headers = []) + { return \Illuminate\Routing\ResponseFactory::make($content, $status, $headers); } - + /** * Return a new view response from the application. * @@ -8676,13 +9359,14 @@ public static function make($content = '', $status = 200, $headers = array()){ * @param array $data * @param int $status * @param array $headers - * @return \Illuminate\Http\Response - * @static + * @return \Illuminate\Http\Response + * @static */ - public static function view($view, $data = array(), $status = 200, $headers = array()){ + public static function view($view, $data = [], $status = 200, $headers = []) + { return \Illuminate\Routing\ResponseFactory::view($view, $data, $status, $headers); } - + /** * Return a new JSON response from the application. * @@ -8690,13 +9374,14 @@ public static function view($view, $data = array(), $status = 200, $headers = ar * @param int $status * @param array $headers * @param int $options - * @return \Illuminate\Http\JsonResponse - * @static + * @return \Illuminate\Http\JsonResponse + * @static */ - public static function json($data = array(), $status = 200, $headers = array(), $options = 0){ + public static function json($data = [], $status = 200, $headers = [], $options = 0) + { return \Illuminate\Routing\ResponseFactory::json($data, $status, $headers, $options); } - + /** * Return a new JSONP response from the application. * @@ -8705,26 +9390,28 @@ public static function json($data = array(), $status = 200, $headers = array(), * @param int $status * @param array $headers * @param int $options - * @return \Illuminate\Http\JsonResponse - * @static + * @return \Illuminate\Http\JsonResponse + * @static */ - public static function jsonp($callback, $data = array(), $status = 200, $headers = array(), $options = 0){ + public static function jsonp($callback, $data = [], $status = 200, $headers = [], $options = 0) + { return \Illuminate\Routing\ResponseFactory::jsonp($callback, $data, $status, $headers, $options); } - + /** * Return a new streamed response from the application. * * @param \Closure $callback * @param int $status * @param array $headers - * @return \Symfony\Component\HttpFoundation\StreamedResponse - * @static + * @return \Symfony\Component\HttpFoundation\StreamedResponse + * @static */ - public static function stream($callback, $status = 200, $headers = array()){ + public static function stream($callback, $status = 200, $headers = []) + { return \Illuminate\Routing\ResponseFactory::stream($callback, $status, $headers); } - + /** * Create a new file download response. * @@ -8732,25 +9419,27 @@ public static function stream($callback, $status = 200, $headers = array()){ * @param string $name * @param array $headers * @param string|null $disposition - * @return \Symfony\Component\HttpFoundation\BinaryFileResponse - * @static + * @return \Symfony\Component\HttpFoundation\BinaryFileResponse + * @static */ - public static function download($file, $name = null, $headers = array(), $disposition = 'attachment'){ + public static function download($file, $name = null, $headers = [], $disposition = 'attachment') + { return \Illuminate\Routing\ResponseFactory::download($file, $name, $headers, $disposition); } - + /** * Return the raw contents of a binary file. * * @param \SplFileInfo|string $file * @param array $headers - * @return \Symfony\Component\HttpFoundation\BinaryFileResponse - * @static + * @return \Symfony\Component\HttpFoundation\BinaryFileResponse + * @static */ - public static function file($file, $headers = array()){ + public static function file($file, $headers = []) + { return \Illuminate\Routing\ResponseFactory::file($file, $headers); } - + /** * Create a new redirect response to the given path. * @@ -8758,13 +9447,14 @@ public static function file($file, $headers = array()){ * @param int $status * @param array $headers * @param bool|null $secure - * @return \Illuminate\Http\RedirectResponse - * @static + * @return \Illuminate\Http\RedirectResponse + * @static */ - public static function redirectTo($path, $status = 302, $headers = array(), $secure = null){ + public static function redirectTo($path, $status = 302, $headers = [], $secure = null) + { return \Illuminate\Routing\ResponseFactory::redirectTo($path, $status, $headers, $secure); } - + /** * Create a new redirect response to a named route. * @@ -8772,13 +9462,14 @@ public static function redirectTo($path, $status = 302, $headers = array(), $sec * @param array $parameters * @param int $status * @param array $headers - * @return \Illuminate\Http\RedirectResponse - * @static + * @return \Illuminate\Http\RedirectResponse + * @static */ - public static function redirectToRoute($route, $parameters = array(), $status = 302, $headers = array()){ + public static function redirectToRoute($route, $parameters = [], $status = 302, $headers = []) + { return \Illuminate\Routing\ResponseFactory::redirectToRoute($route, $parameters, $status, $headers); } - + /** * Create a new redirect response to a controller action. * @@ -8786,13 +9477,14 @@ public static function redirectToRoute($route, $parameters = array(), $status = * @param array $parameters * @param int $status * @param array $headers - * @return \Illuminate\Http\RedirectResponse - * @static + * @return \Illuminate\Http\RedirectResponse + * @static */ - public static function redirectToAction($action, $parameters = array(), $status = 302, $headers = array()){ + public static function redirectToAction($action, $parameters = [], $status = 302, $headers = []) + { return \Illuminate\Routing\ResponseFactory::redirectToAction($action, $parameters, $status, $headers); } - + /** * Create a new redirect response, while putting the current URL in the session. * @@ -8800,13 +9492,14 @@ public static function redirectToAction($action, $parameters = array(), $status * @param int $status * @param array $headers * @param bool|null $secure - * @return \Illuminate\Http\RedirectResponse - * @static + * @return \Illuminate\Http\RedirectResponse + * @static */ - public static function redirectGuest($path, $status = 302, $headers = array(), $secure = null){ + public static function redirectGuest($path, $status = 302, $headers = [], $secure = null) + { return \Illuminate\Routing\ResponseFactory::redirectGuest($path, $status, $headers, $secure); } - + /** * Create a new redirect response to the previously intended location. * @@ -8814,970 +9507,1047 @@ public static function redirectGuest($path, $status = 302, $headers = array(), $ * @param int $status * @param array $headers * @param bool|null $secure - * @return \Illuminate\Http\RedirectResponse - * @static + * @return \Illuminate\Http\RedirectResponse + * @static */ - public static function redirectToIntended($default = '/', $status = 302, $headers = array(), $secure = null){ + public static function redirectToIntended($default = '/', $status = 302, $headers = [], $secure = null) + { return \Illuminate\Routing\ResponseFactory::redirectToIntended($default, $status, $headers, $secure); } - + /** * Register a custom macro. * * @param string $name * @param callable $macro - * @return void - * @static + * @return void + * @static */ - public static function macro($name, $macro){ + public static function macro($name, $macro) + { \Illuminate\Routing\ResponseFactory::macro($name, $macro); } - + /** * Checks if macro is registered. * * @param string $name - * @return bool - * @static + * @return bool + * @static */ - public static function hasMacro($name){ + public static function hasMacro($name) + { return \Illuminate\Routing\ResponseFactory::hasMacro($name); } - } - - class Route extends \Illuminate\Support\Facades\Route{ - + class Route extends \Illuminate\Support\Facades\Route + { /** * Register a new GET route with the router. * * @param string $uri * @param \Closure|array|string|null $action - * @return \Illuminate\Routing\Route - * @static + * @return \Illuminate\Routing\Route + * @static */ - public static function get($uri, $action = null){ + public static function get($uri, $action = null) + { return \Illuminate\Routing\Router::get($uri, $action); } - + /** * Register a new POST route with the router. * * @param string $uri * @param \Closure|array|string|null $action - * @return \Illuminate\Routing\Route - * @static + * @return \Illuminate\Routing\Route + * @static */ - public static function post($uri, $action = null){ + public static function post($uri, $action = null) + { return \Illuminate\Routing\Router::post($uri, $action); } - + /** * Register a new PUT route with the router. * * @param string $uri * @param \Closure|array|string|null $action - * @return \Illuminate\Routing\Route - * @static + * @return \Illuminate\Routing\Route + * @static */ - public static function put($uri, $action = null){ + public static function put($uri, $action = null) + { return \Illuminate\Routing\Router::put($uri, $action); } - + /** * Register a new PATCH route with the router. * * @param string $uri * @param \Closure|array|string|null $action - * @return \Illuminate\Routing\Route - * @static + * @return \Illuminate\Routing\Route + * @static */ - public static function patch($uri, $action = null){ + public static function patch($uri, $action = null) + { return \Illuminate\Routing\Router::patch($uri, $action); } - + /** * Register a new DELETE route with the router. * * @param string $uri * @param \Closure|array|string|null $action - * @return \Illuminate\Routing\Route - * @static + * @return \Illuminate\Routing\Route + * @static */ - public static function delete($uri, $action = null){ + public static function delete($uri, $action = null) + { return \Illuminate\Routing\Router::delete($uri, $action); } - + /** * Register a new OPTIONS route with the router. * * @param string $uri * @param \Closure|array|string|null $action - * @return \Illuminate\Routing\Route - * @static + * @return \Illuminate\Routing\Route + * @static */ - public static function options($uri, $action = null){ + public static function options($uri, $action = null) + { return \Illuminate\Routing\Router::options($uri, $action); } - + /** * Register a new route responding to all verbs. * * @param string $uri * @param \Closure|array|string|null $action - * @return \Illuminate\Routing\Route - * @static + * @return \Illuminate\Routing\Route + * @static */ - public static function any($uri, $action = null){ + public static function any($uri, $action = null) + { return \Illuminate\Routing\Router::any($uri, $action); } - + /** * Register a new route with the given verbs. * * @param array|string $methods * @param string $uri * @param \Closure|array|string|null $action - * @return \Illuminate\Routing\Route - * @static + * @return \Illuminate\Routing\Route + * @static */ - public static function match($methods, $uri, $action = null){ + public static function match($methods, $uri, $action = null) + { return \Illuminate\Routing\Router::match($methods, $uri, $action); } - + /** * Register an array of controllers with wildcard routing. * * @param array $controllers - * @return void + * @return void * @deprecated since version 5.2. - * @static + * @static */ - public static function controllers($controllers){ + public static function controllers($controllers) + { \Illuminate\Routing\Router::controllers($controllers); } - + /** * Route a controller to a URI with wildcard routing. * * @param string $uri * @param string $controller * @param array $names - * @return void + * @return void * @deprecated since version 5.2. - * @static + * @static */ - public static function controller($uri, $controller, $names = array()){ + public static function controller($uri, $controller, $names = []) + { \Illuminate\Routing\Router::controller($uri, $controller, $names); } - + /** * Set the unmapped global resource parameters to singular. * - * @return void - * @static + * @return void + * @static */ - public static function singularResourceParameters(){ + public static function singularResourceParameters() + { \Illuminate\Routing\Router::singularResourceParameters(); } - + /** * Set the global resource parameter mapping. * * @param array $parameters - * @return void - * @static + * @return void + * @static */ - public static function resourceParameters($parameters = array()){ + public static function resourceParameters($parameters = []) + { \Illuminate\Routing\Router::resourceParameters($parameters); } - + /** * Register an array of resource controllers. * * @param array $resources - * @return void - * @static + * @return void + * @static */ - public static function resources($resources){ + public static function resources($resources) + { \Illuminate\Routing\Router::resources($resources); } - + /** * Route a resource to a controller. * * @param string $name * @param string $controller * @param array $options - * @return void - * @static + * @return void + * @static */ - public static function resource($name, $controller, $options = array()){ + public static function resource($name, $controller, $options = []) + { \Illuminate\Routing\Router::resource($name, $controller, $options); } - + /** * Register the typical authentication routes for an application. * - * @return void - * @static + * @return void + * @static */ - public static function auth(){ + public static function auth() + { \Illuminate\Routing\Router::auth(); } - + /** * Create a route group with shared attributes. * * @param array $attributes * @param \Closure $callback - * @return void - * @static + * @return void + * @static */ - public static function group($attributes, $callback){ + public static function group($attributes, $callback) + { \Illuminate\Routing\Router::group($attributes, $callback); } - + /** * Merge the given array with the last group stack. * * @param array $new - * @return array - * @static + * @return array + * @static */ - public static function mergeWithLastGroup($new){ + public static function mergeWithLastGroup($new) + { return \Illuminate\Routing\Router::mergeWithLastGroup($new); } - + /** * Merge the given group attributes. * * @param array $new * @param array $old - * @return array - * @static + * @return array + * @static */ - public static function mergeGroup($new, $old){ + public static function mergeGroup($new, $old) + { return \Illuminate\Routing\Router::mergeGroup($new, $old); } - + /** * Get the prefix from the last group on the stack. * - * @return string - * @static + * @return string + * @static */ - public static function getLastGroupPrefix(){ + public static function getLastGroupPrefix() + { return \Illuminate\Routing\Router::getLastGroupPrefix(); } - + /** * Dispatch the request to the application. * * @param \Illuminate\Http\Request $request - * @return \Illuminate\Http\Response - * @static + * @return \Illuminate\Http\Response + * @static */ - public static function dispatch($request){ + public static function dispatch($request) + { return \Illuminate\Routing\Router::dispatch($request); } - + /** * Dispatch the request to a route and return the response. * * @param \Illuminate\Http\Request $request - * @return mixed - * @static + * @return mixed + * @static */ - public static function dispatchToRoute($request){ + public static function dispatchToRoute($request) + { return \Illuminate\Routing\Router::dispatchToRoute($request); } - + /** * Gather the middleware for the given route. * * @param \Illuminate\Routing\Route $route - * @return array - * @static + * @return array + * @static */ - public static function gatherRouteMiddlewares($route){ + public static function gatherRouteMiddlewares($route) + { return \Illuminate\Routing\Router::gatherRouteMiddlewares($route); } - + /** * Resolve the middleware name to a class name(s) preserving passed parameters. * * @param string $name - * @return string|array - * @static + * @return string|array + * @static */ - public static function resolveMiddlewareClassName($name){ + public static function resolveMiddlewareClassName($name) + { return \Illuminate\Routing\Router::resolveMiddlewareClassName($name); } - + /** * Register a route matched event listener. * * @param string|callable $callback - * @return void - * @static + * @return void + * @static */ - public static function matched($callback){ + public static function matched($callback) + { \Illuminate\Routing\Router::matched($callback); } - + /** * Get all of the defined middleware short-hand names. * - * @return array - * @static + * @return array + * @static */ - public static function getMiddleware(){ + public static function getMiddleware() + { return \Illuminate\Routing\Router::getMiddleware(); } - + /** * Register a short-hand name for a middleware. * * @param string $name * @param string $class - * @return $this - * @static + * @return $this + * @static */ - public static function middleware($name, $class){ + public static function middleware($name, $class) + { return \Illuminate\Routing\Router::middleware($name, $class); } - + /** * Register a group of middleware. * * @param string $name * @param array $middleware - * @return $this - * @static + * @return $this + * @static */ - public static function middlewareGroup($name, $middleware){ + public static function middlewareGroup($name, $middleware) + { return \Illuminate\Routing\Router::middlewareGroup($name, $middleware); } - + /** * Add a middleware to the beginning of a middleware group. - * + * * If the middleware is already in the group, it will not be added again. * * @param string $group * @param string $middleware - * @return $this - * @static + * @return $this + * @static */ - public static function prependMiddlewareToGroup($group, $middleware){ + public static function prependMiddlewareToGroup($group, $middleware) + { return \Illuminate\Routing\Router::prependMiddlewareToGroup($group, $middleware); } - + /** * Add a middleware to the end of a middleware group. - * + * * If the middleware is already in the group, it will not be added again. * * @param string $group * @param string $middleware - * @return $this - * @static + * @return $this + * @static */ - public static function pushMiddlewareToGroup($group, $middleware){ + public static function pushMiddlewareToGroup($group, $middleware) + { return \Illuminate\Routing\Router::pushMiddlewareToGroup($group, $middleware); } - + /** * Register a model binder for a wildcard. * * @param string $key * @param string $class * @param \Closure|null $callback - * @return void + * @return void * @throws \Symfony\Component\HttpKernel\Exception\NotFoundHttpException - * @static + * @static */ - public static function model($key, $class, $callback = null){ + public static function model($key, $class, $callback = null) + { \Illuminate\Routing\Router::model($key, $class, $callback); } - + /** * Add a new route parameter binder. * * @param string $key * @param string|callable $binder - * @return void - * @static + * @return void + * @static */ - public static function bind($key, $binder){ + public static function bind($key, $binder) + { \Illuminate\Routing\Router::bind($key, $binder); } - + /** * Create a class based binding using the IoC container. * * @param string $binding - * @return \Closure - * @static + * @return \Closure + * @static */ - public static function createClassBinding($binding){ + public static function createClassBinding($binding) + { return \Illuminate\Routing\Router::createClassBinding($binding); } - + /** * Set a global where pattern on all routes. * * @param string $key * @param string $pattern - * @return void - * @static + * @return void + * @static */ - public static function pattern($key, $pattern){ + public static function pattern($key, $pattern) + { \Illuminate\Routing\Router::pattern($key, $pattern); } - + /** * Set a group of global where patterns on all routes. * * @param array $patterns - * @return void - * @static + * @return void + * @static */ - public static function patterns($patterns){ + public static function patterns($patterns) + { \Illuminate\Routing\Router::patterns($patterns); } - + /** * Create a response instance from the given value. * * @param \Symfony\Component\HttpFoundation\Request $request * @param mixed $response - * @return \Illuminate\Http\Response - * @static + * @return \Illuminate\Http\Response + * @static */ - public static function prepareResponse($request, $response){ + public static function prepareResponse($request, $response) + { return \Illuminate\Routing\Router::prepareResponse($request, $response); } - + /** * Determine if the router currently has a group stack. * - * @return bool - * @static + * @return bool + * @static */ - public static function hasGroupStack(){ + public static function hasGroupStack() + { return \Illuminate\Routing\Router::hasGroupStack(); } - + /** * Get the current group stack for the router. * - * @return array - * @static + * @return array + * @static */ - public static function getGroupStack(){ + public static function getGroupStack() + { return \Illuminate\Routing\Router::getGroupStack(); } - + /** * Get a route parameter for the current route. * * @param string $key * @param string $default - * @return mixed - * @static + * @return mixed + * @static */ - public static function input($key, $default = null){ + public static function input($key, $default = null) + { return \Illuminate\Routing\Router::input($key, $default); } - + /** * Get the currently dispatched route instance. * - * @return \Illuminate\Routing\Route - * @static + * @return \Illuminate\Routing\Route + * @static */ - public static function getCurrentRoute(){ + public static function getCurrentRoute() + { return \Illuminate\Routing\Router::getCurrentRoute(); } - + /** * Get the currently dispatched route instance. * - * @return \Illuminate\Routing\Route - * @static + * @return \Illuminate\Routing\Route + * @static */ - public static function current(){ + public static function current() + { return \Illuminate\Routing\Router::current(); } - + /** * Check if a route with the given name exists. * * @param string $name - * @return bool - * @static + * @return bool + * @static */ - public static function has($name){ + public static function has($name) + { return \Illuminate\Routing\Router::has($name); } - + /** * Get the current route name. * - * @return string|null - * @static + * @return string|null + * @static */ - public static function currentRouteName(){ + public static function currentRouteName() + { return \Illuminate\Routing\Router::currentRouteName(); } - + /** * Alias for the "currentRouteName" method. * * @param mixed string - * @return bool - * @static + * @return bool + * @static */ - public static function is(){ + public static function is() + { return \Illuminate\Routing\Router::is(); } - + /** * Determine if the current route matches a given name. * * @param string $name - * @return bool - * @static + * @return bool + * @static */ - public static function currentRouteNamed($name){ + public static function currentRouteNamed($name) + { return \Illuminate\Routing\Router::currentRouteNamed($name); } - + /** * Get the current route action. * - * @return string|null - * @static + * @return string|null + * @static */ - public static function currentRouteAction(){ + public static function currentRouteAction() + { return \Illuminate\Routing\Router::currentRouteAction(); } - + /** * Alias for the "currentRouteUses" method. * * @param mixed string - * @return bool - * @static + * @return bool + * @static */ - public static function uses(){ + public static function uses() + { return \Illuminate\Routing\Router::uses(); } - + /** * Determine if the current route action matches a given action. * * @param string $action - * @return bool - * @static + * @return bool + * @static */ - public static function currentRouteUses($action){ + public static function currentRouteUses($action) + { return \Illuminate\Routing\Router::currentRouteUses($action); } - + /** * Get the request currently being dispatched. * - * @return \Illuminate\Http\Request - * @static + * @return \Illuminate\Http\Request + * @static */ - public static function getCurrentRequest(){ + public static function getCurrentRequest() + { return \Illuminate\Routing\Router::getCurrentRequest(); } - + /** * Get the underlying route collection. * - * @return \Illuminate\Routing\RouteCollection - * @static + * @return \Illuminate\Routing\RouteCollection + * @static */ - public static function getRoutes(){ + public static function getRoutes() + { return \Illuminate\Routing\Router::getRoutes(); } - + /** * Set the route collection instance. * * @param \Illuminate\Routing\RouteCollection $routes - * @return void - * @static + * @return void + * @static */ - public static function setRoutes($routes){ + public static function setRoutes($routes) + { \Illuminate\Routing\Router::setRoutes($routes); } - + /** * Get the global "where" patterns. * - * @return array - * @static + * @return array + * @static */ - public static function getPatterns(){ + public static function getPatterns() + { return \Illuminate\Routing\Router::getPatterns(); } - + /** * Register a custom macro. * * @param string $name * @param callable $macro - * @return void - * @static + * @return void + * @static */ - public static function macro($name, $macro){ + public static function macro($name, $macro) + { \Illuminate\Routing\Router::macro($name, $macro); } - + /** * Checks if macro is registered. * * @param string $name - * @return bool - * @static + * @return bool + * @static */ - public static function hasMacro($name){ + public static function hasMacro($name) + { return \Illuminate\Routing\Router::hasMacro($name); } - } - - class Schema extends \Illuminate\Support\Facades\Schema{ - + class Schema extends \Illuminate\Support\Facades\Schema + { /** * Determine if the given table exists. * * @param string $table - * @return bool - * @static + * @return bool + * @static */ - public static function hasTable($table){ + public static function hasTable($table) + { return \Illuminate\Database\Schema\MySqlBuilder::hasTable($table); } - + /** * Get the column listing for a given table. * * @param string $table - * @return array - * @static + * @return array + * @static */ - public static function getColumnListing($table){ + public static function getColumnListing($table) + { return \Illuminate\Database\Schema\MySqlBuilder::getColumnListing($table); } - + /** * Determine if the given table has a given column. * * @param string $table * @param string $column - * @return bool - * @static + * @return bool + * @static */ - public static function hasColumn($table, $column){ - //Method inherited from \Illuminate\Database\Schema\Builder + public static function hasColumn($table, $column) + { + //Method inherited from \Illuminate\Database\Schema\Builder return \Illuminate\Database\Schema\MySqlBuilder::hasColumn($table, $column); } - + /** * Determine if the given table has given columns. * * @param string $table * @param array $columns - * @return bool - * @static + * @return bool + * @static */ - public static function hasColumns($table, $columns){ - //Method inherited from \Illuminate\Database\Schema\Builder + public static function hasColumns($table, $columns) + { + //Method inherited from \Illuminate\Database\Schema\Builder return \Illuminate\Database\Schema\MySqlBuilder::hasColumns($table, $columns); } - + /** * Get the data type for the given column name. * * @param string $table * @param string $column - * @return string - * @static + * @return string + * @static */ - public static function getColumnType($table, $column){ - //Method inherited from \Illuminate\Database\Schema\Builder + public static function getColumnType($table, $column) + { + //Method inherited from \Illuminate\Database\Schema\Builder return \Illuminate\Database\Schema\MySqlBuilder::getColumnType($table, $column); } - + /** * Modify a table on the schema. * * @param string $table * @param \Closure $callback - * @return \Illuminate\Database\Schema\Blueprint - * @static + * @return \Illuminate\Database\Schema\Blueprint + * @static */ - public static function table($table, $callback){ - //Method inherited from \Illuminate\Database\Schema\Builder + public static function table($table, $callback) + { + //Method inherited from \Illuminate\Database\Schema\Builder return \Illuminate\Database\Schema\MySqlBuilder::table($table, $callback); } - + /** * Create a new table on the schema. * * @param string $table * @param \Closure $callback - * @return \Illuminate\Database\Schema\Blueprint - * @static + * @return \Illuminate\Database\Schema\Blueprint + * @static */ - public static function create($table, $callback){ - //Method inherited from \Illuminate\Database\Schema\Builder + public static function create($table, $callback) + { + //Method inherited from \Illuminate\Database\Schema\Builder return \Illuminate\Database\Schema\MySqlBuilder::create($table, $callback); } - + /** * Drop a table from the schema. * * @param string $table - * @return \Illuminate\Database\Schema\Blueprint - * @static + * @return \Illuminate\Database\Schema\Blueprint + * @static */ - public static function drop($table){ - //Method inherited from \Illuminate\Database\Schema\Builder + public static function drop($table) + { + //Method inherited from \Illuminate\Database\Schema\Builder return \Illuminate\Database\Schema\MySqlBuilder::drop($table); } - + /** * Drop a table from the schema if it exists. * * @param string $table - * @return \Illuminate\Database\Schema\Blueprint - * @static + * @return \Illuminate\Database\Schema\Blueprint + * @static */ - public static function dropIfExists($table){ - //Method inherited from \Illuminate\Database\Schema\Builder + public static function dropIfExists($table) + { + //Method inherited from \Illuminate\Database\Schema\Builder return \Illuminate\Database\Schema\MySqlBuilder::dropIfExists($table); } - + /** * Rename a table on the schema. * * @param string $from * @param string $to - * @return \Illuminate\Database\Schema\Blueprint - * @static + * @return \Illuminate\Database\Schema\Blueprint + * @static */ - public static function rename($from, $to){ - //Method inherited from \Illuminate\Database\Schema\Builder + public static function rename($from, $to) + { + //Method inherited from \Illuminate\Database\Schema\Builder return \Illuminate\Database\Schema\MySqlBuilder::rename($from, $to); } - + /** * Enable foreign key constraints. * - * @return bool - * @static + * @return bool + * @static */ - public static function enableForeignKeyConstraints(){ - //Method inherited from \Illuminate\Database\Schema\Builder + public static function enableForeignKeyConstraints() + { + //Method inherited from \Illuminate\Database\Schema\Builder return \Illuminate\Database\Schema\MySqlBuilder::enableForeignKeyConstraints(); } - + /** * Disable foreign key constraints. * - * @return bool - * @static + * @return bool + * @static */ - public static function disableForeignKeyConstraints(){ - //Method inherited from \Illuminate\Database\Schema\Builder + public static function disableForeignKeyConstraints() + { + //Method inherited from \Illuminate\Database\Schema\Builder return \Illuminate\Database\Schema\MySqlBuilder::disableForeignKeyConstraints(); } - + /** * Get the database connection instance. * - * @return \Illuminate\Database\Connection - * @static + * @return \Illuminate\Database\Connection + * @static */ - public static function getConnection(){ - //Method inherited from \Illuminate\Database\Schema\Builder + public static function getConnection() + { + //Method inherited from \Illuminate\Database\Schema\Builder return \Illuminate\Database\Schema\MySqlBuilder::getConnection(); } - + /** * Set the database connection instance. * * @param \Illuminate\Database\Connection $connection - * @return $this - * @static + * @return $this + * @static */ - public static function setConnection($connection){ - //Method inherited from \Illuminate\Database\Schema\Builder + public static function setConnection($connection) + { + //Method inherited from \Illuminate\Database\Schema\Builder return \Illuminate\Database\Schema\MySqlBuilder::setConnection($connection); } - + /** * Set the Schema Blueprint resolver callback. * * @param \Closure $resolver - * @return void - * @static + * @return void + * @static */ - public static function blueprintResolver($resolver){ - //Method inherited from \Illuminate\Database\Schema\Builder + public static function blueprintResolver($resolver) + { + //Method inherited from \Illuminate\Database\Schema\Builder \Illuminate\Database\Schema\MySqlBuilder::blueprintResolver($resolver); } - } - - class Session extends \Illuminate\Support\Facades\Session{ - + class Session extends \Illuminate\Support\Facades\Session + { /** * Get the session configuration. * - * @return array - * @static + * @return array + * @static */ - public static function getSessionConfig(){ - //Method inherited from \Illuminate\Session\SessionManager + public static function getSessionConfig() + { + //Method inherited from \Illuminate\Session\SessionManager return \Rairlie\LockingSession\SessionManager::getSessionConfig(); } - + /** * Get the default session driver name. * - * @return string - * @static + * @return string + * @static */ - public static function getDefaultDriver(){ - //Method inherited from \Illuminate\Session\SessionManager + public static function getDefaultDriver() + { + //Method inherited from \Illuminate\Session\SessionManager return \Rairlie\LockingSession\SessionManager::getDefaultDriver(); } - + /** * Set the default session driver name. * * @param string $name - * @return void - * @static + * @return void + * @static */ - public static function setDefaultDriver($name){ - //Method inherited from \Illuminate\Session\SessionManager + public static function setDefaultDriver($name) + { + //Method inherited from \Illuminate\Session\SessionManager \Rairlie\LockingSession\SessionManager::setDefaultDriver($name); } - + /** * Get a driver instance. * * @param string $driver - * @return mixed - * @static + * @return mixed + * @static */ - public static function driver($driver = null){ - //Method inherited from \Illuminate\Support\Manager + public static function driver($driver = null) + { + //Method inherited from \Illuminate\Support\Manager return \Rairlie\LockingSession\SessionManager::driver($driver); } - + /** * Register a custom driver creator Closure. * * @param string $driver * @param \Closure $callback - * @return $this - * @static + * @return $this + * @static */ - public static function extend($driver, $callback){ - //Method inherited from \Illuminate\Support\Manager + public static function extend($driver, $callback) + { + //Method inherited from \Illuminate\Support\Manager return \Rairlie\LockingSession\SessionManager::extend($driver, $callback); } - + /** * Get all of the created "drivers". * - * @return array - * @static + * @return array + * @static */ - public static function getDrivers(){ - //Method inherited from \Illuminate\Support\Manager + public static function getDrivers() + { + //Method inherited from \Illuminate\Support\Manager return \Rairlie\LockingSession\SessionManager::getDrivers(); } - + /** * Starts the session storage. * * @return bool True if session started * @throws \RuntimeException If session fails to start. - * @static + * @static */ - public static function start(){ + public static function start() + { return \Illuminate\Session\Store::start(); } - + /** * Returns the session ID. * * @return string The session ID - * @static + * @static */ - public static function getId(){ + public static function getId() + { return \Illuminate\Session\Store::getId(); } - + /** * Sets the session ID. * * @param string $id - * @static + * @static */ - public static function setId($id){ + public static function setId($id) + { return \Illuminate\Session\Store::setId($id); } - + /** * Determine if this is a valid session ID. * * @param string $id - * @return bool - * @static + * @return bool + * @static */ - public static function isValidId($id){ + public static function isValidId($id) + { return \Illuminate\Session\Store::isValidId($id); } - + /** * Returns the session name. * * @return mixed The session name - * @static + * @static */ - public static function getName(){ + public static function getName() + { return \Illuminate\Session\Store::getName(); } - + /** * Sets the session name. * * @param string $name - * @static + * @static */ - public static function setName($name){ + public static function setName($name) + { return \Illuminate\Session\Store::setName($name); } - + /** * Invalidates the current session. - * + * * Clears all session attributes and flashes and regenerates the * session and deletes the old session from persistence. * @@ -9786,12 +10556,13 @@ public static function setName($name){ * to expire with browser session. Time is in seconds, and is * not a Unix timestamp. * @return bool True if session invalidated, false if error - * @static + * @static */ - public static function invalidate($lifetime = null){ + public static function invalidate($lifetime = null) + { return \Illuminate\Session\Store::invalidate($lifetime); } - + /** * Migrates the current session to a new session id while maintaining all * session attributes. @@ -9802,1019 +10573,1103 @@ public static function invalidate($lifetime = null){ * to expire with browser session. Time is in seconds, and is * not a Unix timestamp. * @return bool True if session migrated, false if error - * @static + * @static */ - public static function migrate($destroy = false, $lifetime = null){ + public static function migrate($destroy = false, $lifetime = null) + { return \Illuminate\Session\Store::migrate($destroy, $lifetime); } - + /** * Generate a new session identifier. * * @param bool $destroy - * @return bool - * @static + * @return bool + * @static */ - public static function regenerate($destroy = false){ + public static function regenerate($destroy = false) + { return \Illuminate\Session\Store::regenerate($destroy); } - + /** * Force the session to be saved and closed. - * + * * This method is generally not required for real sessions as * the session will be automatically saved at the end of * code execution. * - * @static + * @static */ - public static function save(){ + public static function save() + { return \Illuminate\Session\Store::save(); } - + /** * Age the flash data for the session. * - * @return void - * @static + * @return void + * @static */ - public static function ageFlashData(){ + public static function ageFlashData() + { \Illuminate\Session\Store::ageFlashData(); } - + /** * Checks if an attribute is defined. * * @param string $name The attribute name * @return bool true if the attribute is defined, false otherwise - * @static + * @static */ - public static function has($name){ + public static function has($name) + { return \Illuminate\Session\Store::has($name); } - + /** * Returns an attribute. * * @param string $name The attribute name * @param mixed $default The default value if not found - * @return mixed - * @static + * @return mixed + * @static */ - public static function get($name, $default = null){ + public static function get($name, $default = null) + { return \Illuminate\Session\Store::get($name, $default); } - + /** * Get the value of a given key and then forget it. * * @param string $key * @param string $default - * @return mixed - * @static + * @return mixed + * @static */ - public static function pull($key, $default = null){ + public static function pull($key, $default = null) + { return \Illuminate\Session\Store::pull($key, $default); } - + /** * Determine if the session contains old input. * * @param string $key - * @return bool - * @static + * @return bool + * @static */ - public static function hasOldInput($key = null){ + public static function hasOldInput($key = null) + { return \Illuminate\Session\Store::hasOldInput($key); } - + /** * Get the requested item from the flashed input array. * * @param string $key * @param mixed $default - * @return mixed - * @static + * @return mixed + * @static */ - public static function getOldInput($key = null, $default = null){ + public static function getOldInput($key = null, $default = null) + { return \Illuminate\Session\Store::getOldInput($key, $default); } - + /** * Sets an attribute. * * @param string $name * @param mixed $value - * @static + * @static */ - public static function set($name, $value){ + public static function set($name, $value) + { return \Illuminate\Session\Store::set($name, $value); } - + /** * Put a key / value pair or array of key / value pairs in the session. * * @param string|array $key * @param mixed $value - * @return void - * @static + * @return void + * @static */ - public static function put($key, $value = null){ + public static function put($key, $value = null) + { \Illuminate\Session\Store::put($key, $value); } - + /** * Push a value onto a session array. * * @param string $key * @param mixed $value - * @return void - * @static + * @return void + * @static */ - public static function push($key, $value){ + public static function push($key, $value) + { \Illuminate\Session\Store::push($key, $value); } - + /** * Increment the value of an item in the session. * * @param string $key * @param int $amount - * @return mixed - * @static + * @return mixed + * @static */ - public static function increment($key, $amount = 1){ + public static function increment($key, $amount = 1) + { return \Illuminate\Session\Store::increment($key, $amount); } - + /** * Decrement the value of an item in the session. * * @param string $key * @param int $amount - * @return int - * @static + * @return int + * @static */ - public static function decrement($key, $amount = 1){ + public static function decrement($key, $amount = 1) + { return \Illuminate\Session\Store::decrement($key, $amount); } - + /** * Flash a key / value pair to the session. * * @param string $key * @param mixed $value - * @return void - * @static + * @return void + * @static */ - public static function flash($key, $value){ + public static function flash($key, $value) + { \Illuminate\Session\Store::flash($key, $value); } - + /** * Flash a key / value pair to the session * for immediate use. * * @param string $key * @param mixed $value - * @return void - * @static + * @return void + * @static */ - public static function now($key, $value){ + public static function now($key, $value) + { \Illuminate\Session\Store::now($key, $value); } - + /** * Flash an input array to the session. * * @param array $value - * @return void - * @static + * @return void + * @static */ - public static function flashInput($value){ + public static function flashInput($value) + { \Illuminate\Session\Store::flashInput($value); } - + /** * Reflash all of the session flash data. * - * @return void - * @static + * @return void + * @static */ - public static function reflash(){ + public static function reflash() + { \Illuminate\Session\Store::reflash(); } - + /** * Reflash a subset of the current flash data. * * @param array|mixed $keys - * @return void - * @static + * @return void + * @static */ - public static function keep($keys = null){ + public static function keep($keys = null) + { \Illuminate\Session\Store::keep($keys); } - + /** * Returns attributes. * * @return array Attributes - * @static + * @static */ - public static function all(){ + public static function all() + { return \Illuminate\Session\Store::all(); } - + /** * Sets attributes. * * @param array $attributes Attributes - * @static + * @static */ - public static function replace($attributes){ + public static function replace($attributes) + { return \Illuminate\Session\Store::replace($attributes); } - + /** * Removes an attribute. * * @param string $name * @return mixed The removed value or null when it does not exist - * @static + * @static */ - public static function remove($name){ + public static function remove($name) + { return \Illuminate\Session\Store::remove($name); } - + /** * Remove one or many items from the session. * * @param string|array $keys - * @return void - * @static + * @return void + * @static */ - public static function forget($keys){ + public static function forget($keys) + { \Illuminate\Session\Store::forget($keys); } - + /** * Clears all attributes. * - * @static + * @static */ - public static function clear(){ + public static function clear() + { return \Illuminate\Session\Store::clear(); } - + /** * Remove all of the items from the session. * - * @return void - * @static + * @return void + * @static */ - public static function flush(){ + public static function flush() + { \Illuminate\Session\Store::flush(); } - + /** * Checks if the session was started. * - * @return bool - * @static + * @return bool + * @static */ - public static function isStarted(){ + public static function isStarted() + { return \Illuminate\Session\Store::isStarted(); } - + /** * Registers a SessionBagInterface with the session. * * @param \Symfony\Component\HttpFoundation\Session\SessionBagInterface $bag - * @static + * @static */ - public static function registerBag($bag){ + public static function registerBag($bag) + { return \Illuminate\Session\Store::registerBag($bag); } - + /** * Gets a bag instance by name. * * @param string $name - * @return \Symfony\Component\HttpFoundation\Session\SessionBagInterface - * @static + * @return \Symfony\Component\HttpFoundation\Session\SessionBagInterface + * @static */ - public static function getBag($name){ + public static function getBag($name) + { return \Illuminate\Session\Store::getBag($name); } - + /** * Gets session meta. * - * @return \Symfony\Component\HttpFoundation\Session\MetadataBag - * @static + * @return \Symfony\Component\HttpFoundation\Session\MetadataBag + * @static */ - public static function getMetadataBag(){ + public static function getMetadataBag() + { return \Illuminate\Session\Store::getMetadataBag(); } - + /** * Get the raw bag data array for a given bag. * * @param string $name - * @return array - * @static + * @return array + * @static */ - public static function getBagData($name){ + public static function getBagData($name) + { return \Illuminate\Session\Store::getBagData($name); } - + /** * Get the CSRF token value. * - * @return string - * @static + * @return string + * @static */ - public static function token(){ + public static function token() + { return \Illuminate\Session\Store::token(); } - + /** * Get the CSRF token value. * - * @return string - * @static + * @return string + * @static */ - public static function getToken(){ + public static function getToken() + { return \Illuminate\Session\Store::getToken(); } - + /** * Regenerate the CSRF token value. * - * @return void - * @static + * @return void + * @static */ - public static function regenerateToken(){ + public static function regenerateToken() + { \Illuminate\Session\Store::regenerateToken(); } - + /** * Get the previous URL from the session. * - * @return string|null - * @static + * @return string|null + * @static */ - public static function previousUrl(){ + public static function previousUrl() + { return \Illuminate\Session\Store::previousUrl(); } - + /** * Set the "previous" URL in the session. * * @param string $url - * @return void - * @static + * @return void + * @static */ - public static function setPreviousUrl($url){ + public static function setPreviousUrl($url) + { \Illuminate\Session\Store::setPreviousUrl($url); } - + /** * Set the existence of the session on the handler if applicable. * * @param bool $value - * @return void - * @static + * @return void + * @static */ - public static function setExists($value){ + public static function setExists($value) + { \Illuminate\Session\Store::setExists($value); } - + /** * Get the underlying session handler implementation. * - * @return \SessionHandlerInterface - * @static + * @return \SessionHandlerInterface + * @static */ - public static function getHandler(){ + public static function getHandler() + { return \Illuminate\Session\Store::getHandler(); } - + /** * Determine if the session handler needs a request. * - * @return bool - * @static + * @return bool + * @static */ - public static function handlerNeedsRequest(){ + public static function handlerNeedsRequest() + { return \Illuminate\Session\Store::handlerNeedsRequest(); } - + /** * Set the request on the handler instance. * * @param \Symfony\Component\HttpFoundation\Request $request - * @return void - * @static + * @return void + * @static */ - public static function setRequestOnHandler($request){ + public static function setRequestOnHandler($request) + { \Illuminate\Session\Store::setRequestOnHandler($request); } - } - - class Storage extends \Illuminate\Support\Facades\Storage{ - + class Storage extends \Illuminate\Support\Facades\Storage + { /** * Get a filesystem instance. * * @param string $name - * @return \Illuminate\Filesystem\FilesystemAdapter - * @static + * @return \Illuminate\Filesystem\FilesystemAdapter + * @static */ - public static function drive($name = null){ + public static function drive($name = null) + { return \Illuminate\Filesystem\FilesystemManager::drive($name); } - + /** * Get a filesystem instance. * * @param string $name - * @return \Illuminate\Filesystem\FilesystemAdapter - * @static + * @return \Illuminate\Filesystem\FilesystemAdapter + * @static */ - public static function disk($name = null){ + public static function disk($name = null) + { return \Illuminate\Filesystem\FilesystemManager::disk($name); } - + /** * Get a default cloud filesystem instance. * - * @return \Illuminate\Filesystem\FilesystemAdapter - * @static + * @return \Illuminate\Filesystem\FilesystemAdapter + * @static */ - public static function cloud(){ + public static function cloud() + { return \Illuminate\Filesystem\FilesystemManager::cloud(); } - + /** * Create an instance of the local driver. * * @param array $config - * @return \Illuminate\Filesystem\FilesystemAdapter - * @static + * @return \Illuminate\Filesystem\FilesystemAdapter + * @static */ - public static function createLocalDriver($config){ + public static function createLocalDriver($config) + { return \Illuminate\Filesystem\FilesystemManager::createLocalDriver($config); } - + /** * Create an instance of the ftp driver. * * @param array $config - * @return \Illuminate\Filesystem\FilesystemAdapter - * @static + * @return \Illuminate\Filesystem\FilesystemAdapter + * @static */ - public static function createFtpDriver($config){ + public static function createFtpDriver($config) + { return \Illuminate\Filesystem\FilesystemManager::createFtpDriver($config); } - + /** * Create an instance of the Amazon S3 driver. * * @param array $config - * @return \Illuminate\Contracts\Filesystem\Cloud - * @static + * @return \Illuminate\Contracts\Filesystem\Cloud + * @static */ - public static function createS3Driver($config){ + public static function createS3Driver($config) + { return \Illuminate\Filesystem\FilesystemManager::createS3Driver($config); } - + /** * Create an instance of the Rackspace driver. * * @param array $config - * @return \Illuminate\Contracts\Filesystem\Cloud - * @static + * @return \Illuminate\Contracts\Filesystem\Cloud + * @static */ - public static function createRackspaceDriver($config){ + public static function createRackspaceDriver($config) + { return \Illuminate\Filesystem\FilesystemManager::createRackspaceDriver($config); } - + /** * Get the default driver name. * - * @return string - * @static + * @return string + * @static */ - public static function getDefaultDriver(){ + public static function getDefaultDriver() + { return \Illuminate\Filesystem\FilesystemManager::getDefaultDriver(); } - + /** * Get the default cloud driver name. * - * @return string - * @static + * @return string + * @static */ - public static function getDefaultCloudDriver(){ + public static function getDefaultCloudDriver() + { return \Illuminate\Filesystem\FilesystemManager::getDefaultCloudDriver(); } - + /** * Register a custom driver creator Closure. * * @param string $driver * @param \Closure $callback - * @return $this - * @static + * @return $this + * @static */ - public static function extend($driver, $callback){ + public static function extend($driver, $callback) + { return \Illuminate\Filesystem\FilesystemManager::extend($driver, $callback); } - + /** * Determine if a file exists. * * @param string $path - * @return bool - * @static + * @return bool + * @static */ - public static function exists($path){ + public static function exists($path) + { return \Illuminate\Filesystem\FilesystemAdapter::exists($path); } - + /** * Get the contents of a file. * * @param string $path - * @return string + * @return string * @throws \Illuminate\Contracts\Filesystem\FileNotFoundException - * @static + * @static */ - public static function get($path){ + public static function get($path) + { return \Illuminate\Filesystem\FilesystemAdapter::get($path); } - + /** * Write the contents of a file. * * @param string $path * @param string|resource $contents * @param string $visibility - * @return bool - * @static + * @return bool + * @static */ - public static function put($path, $contents, $visibility = null){ + public static function put($path, $contents, $visibility = null) + { return \Illuminate\Filesystem\FilesystemAdapter::put($path, $contents, $visibility); } - + /** * Get the visibility for the given path. * * @param string $path - * @return string - * @static + * @return string + * @static */ - public static function getVisibility($path){ + public static function getVisibility($path) + { return \Illuminate\Filesystem\FilesystemAdapter::getVisibility($path); } - + /** * Set the visibility for the given path. * * @param string $path * @param string $visibility - * @return void - * @static + * @return void + * @static */ - public static function setVisibility($path, $visibility){ + public static function setVisibility($path, $visibility) + { \Illuminate\Filesystem\FilesystemAdapter::setVisibility($path, $visibility); } - + /** * Prepend to a file. * * @param string $path * @param string $data - * @return int - * @static + * @return int + * @static */ - public static function prepend($path, $data, $separator = ''){ + public static function prepend($path, $data, $separator = '') + { return \Illuminate\Filesystem\FilesystemAdapter::prepend($path, $data, $separator); } - + /** * Append to a file. * * @param string $path * @param string $data - * @return int - * @static + * @return int + * @static */ - public static function append($path, $data, $separator = ''){ + public static function append($path, $data, $separator = '') + { return \Illuminate\Filesystem\FilesystemAdapter::append($path, $data, $separator); } - + /** * Delete the file at a given path. * * @param string|array $paths - * @return bool - * @static + * @return bool + * @static */ - public static function delete($paths){ + public static function delete($paths) + { return \Illuminate\Filesystem\FilesystemAdapter::delete($paths); } - + /** * Copy a file to a new location. * * @param string $from * @param string $to - * @return bool - * @static + * @return bool + * @static */ - public static function copy($from, $to){ + public static function copy($from, $to) + { return \Illuminate\Filesystem\FilesystemAdapter::copy($from, $to); } - + /** * Move a file to a new location. * * @param string $from * @param string $to - * @return bool - * @static + * @return bool + * @static */ - public static function move($from, $to){ + public static function move($from, $to) + { return \Illuminate\Filesystem\FilesystemAdapter::move($from, $to); } - + /** * Get the file size of a given file. * * @param string $path - * @return int - * @static + * @return int + * @static */ - public static function size($path){ + public static function size($path) + { return \Illuminate\Filesystem\FilesystemAdapter::size($path); } - + /** * Get the mime-type of a given file. * * @param string $path - * @return string|false - * @static + * @return string|false + * @static */ - public static function mimeType($path){ + public static function mimeType($path) + { return \Illuminate\Filesystem\FilesystemAdapter::mimeType($path); } - + /** * Get the file's last modification time. * * @param string $path - * @return int - * @static + * @return int + * @static */ - public static function lastModified($path){ + public static function lastModified($path) + { return \Illuminate\Filesystem\FilesystemAdapter::lastModified($path); } - + /** * Get the URL for the file at the given path. * * @param string $path - * @return string - * @static + * @return string + * @static */ - public static function url($path){ + public static function url($path) + { return \Illuminate\Filesystem\FilesystemAdapter::url($path); } - + /** * Get an array of all files in a directory. * * @param string|null $directory * @param bool $recursive - * @return array - * @static + * @return array + * @static */ - public static function files($directory = null, $recursive = false){ + public static function files($directory = null, $recursive = false) + { return \Illuminate\Filesystem\FilesystemAdapter::files($directory, $recursive); } - + /** * Get all of the files from the given directory (recursive). * * @param string|null $directory - * @return array - * @static + * @return array + * @static */ - public static function allFiles($directory = null){ + public static function allFiles($directory = null) + { return \Illuminate\Filesystem\FilesystemAdapter::allFiles($directory); } - + /** * Get all of the directories within a given directory. * * @param string|null $directory * @param bool $recursive - * @return array - * @static + * @return array + * @static */ - public static function directories($directory = null, $recursive = false){ + public static function directories($directory = null, $recursive = false) + { return \Illuminate\Filesystem\FilesystemAdapter::directories($directory, $recursive); } - + /** * Get all (recursive) of the directories within a given directory. * * @param string|null $directory - * @return array - * @static + * @return array + * @static */ - public static function allDirectories($directory = null){ + public static function allDirectories($directory = null) + { return \Illuminate\Filesystem\FilesystemAdapter::allDirectories($directory); } - + /** * Create a directory. * * @param string $path - * @return bool - * @static + * @return bool + * @static */ - public static function makeDirectory($path){ + public static function makeDirectory($path) + { return \Illuminate\Filesystem\FilesystemAdapter::makeDirectory($path); } - + /** * Recursively delete a directory. * * @param string $directory - * @return bool - * @static + * @return bool + * @static */ - public static function deleteDirectory($directory){ + public static function deleteDirectory($directory) + { return \Illuminate\Filesystem\FilesystemAdapter::deleteDirectory($directory); } - + /** * Get the Flysystem driver. * - * @return \League\Flysystem\FilesystemInterface - * @static + * @return \League\Flysystem\FilesystemInterface + * @static */ - public static function getDriver(){ + public static function getDriver() + { return \Illuminate\Filesystem\FilesystemAdapter::getDriver(); } - } - - class URL extends \Illuminate\Support\Facades\URL{ - + class URL extends \Illuminate\Support\Facades\URL + { /** * Get the full URL for the current request. * - * @return string - * @static + * @return string + * @static */ - public static function full(){ + public static function full() + { return \Illuminate\Routing\UrlGenerator::full(); } - + /** * Get the current URL for the request. * - * @return string - * @static + * @return string + * @static */ - public static function current(){ + public static function current() + { return \Illuminate\Routing\UrlGenerator::current(); } - + /** * Get the URL for the previous request. * * @param mixed $fallback - * @return string - * @static + * @return string + * @static */ - public static function previous($fallback = false){ + public static function previous($fallback = false) + { return \Illuminate\Routing\UrlGenerator::previous($fallback); } - + /** * Generate an absolute URL to the given path. * * @param string $path * @param mixed $extra * @param bool|null $secure - * @return string - * @static + * @return string + * @static */ - public static function to($path, $extra = array(), $secure = null){ + public static function to($path, $extra = [], $secure = null) + { return \Illuminate\Routing\UrlGenerator::to($path, $extra, $secure); } - + /** * Generate a secure, absolute URL to the given path. * * @param string $path * @param array $parameters - * @return string - * @static + * @return string + * @static */ - public static function secure($path, $parameters = array()){ + public static function secure($path, $parameters = []) + { return \Illuminate\Routing\UrlGenerator::secure($path, $parameters); } - + /** * Generate a URL to an application asset. * * @param string $path * @param bool|null $secure - * @return string - * @static + * @return string + * @static */ - public static function asset($path, $secure = null){ + public static function asset($path, $secure = null) + { return \Illuminate\Routing\UrlGenerator::asset($path, $secure); } - + /** * Generate a URL to an asset from a custom root domain such as CDN, etc. * * @param string $root * @param string $path * @param bool|null $secure - * @return string - * @static + * @return string + * @static */ - public static function assetFrom($root, $path, $secure = null){ + public static function assetFrom($root, $path, $secure = null) + { return \Illuminate\Routing\UrlGenerator::assetFrom($root, $path, $secure); } - + /** * Generate a URL to a secure asset. * * @param string $path - * @return string - * @static + * @return string + * @static */ - public static function secureAsset($path){ + public static function secureAsset($path) + { return \Illuminate\Routing\UrlGenerator::secureAsset($path); } - + /** * Force the schema for URLs. * * @param string $schema - * @return void - * @static + * @return void + * @static */ - public static function forceSchema($schema){ + public static function forceSchema($schema) + { \Illuminate\Routing\UrlGenerator::forceSchema($schema); } - + /** * Get the URL to a named route. * * @param string $name * @param mixed $parameters * @param bool $absolute - * @return string + * @return string * @throws \InvalidArgumentException - * @static + * @static */ - public static function route($name, $parameters = array(), $absolute = true){ + public static function route($name, $parameters = [], $absolute = true) + { return \Illuminate\Routing\UrlGenerator::route($name, $parameters, $absolute); } - + /** * Get the URL to a controller action. * * @param string $action * @param mixed $parameters * @param bool $absolute - * @return string + * @return string * @throws \InvalidArgumentException - * @static + * @static */ - public static function action($action, $parameters = array(), $absolute = true){ + public static function action($action, $parameters = [], $absolute = true) + { return \Illuminate\Routing\UrlGenerator::action($action, $parameters, $absolute); } - + /** * Set the forced root URL. * * @param string $root - * @return void - * @static + * @return void + * @static */ - public static function forceRootUrl($root){ + public static function forceRootUrl($root) + { \Illuminate\Routing\UrlGenerator::forceRootUrl($root); } - + /** * Determine if the given path is a valid URL. * * @param string $path - * @return bool - * @static + * @return bool + * @static */ - public static function isValidUrl($path){ + public static function isValidUrl($path) + { return \Illuminate\Routing\UrlGenerator::isValidUrl($path); } - + /** * Get the request instance. * - * @return \Illuminate\Http\Request - * @static + * @return \Illuminate\Http\Request + * @static */ - public static function getRequest(){ + public static function getRequest() + { return \Illuminate\Routing\UrlGenerator::getRequest(); } - + /** * Set the current request instance. * * @param \Illuminate\Http\Request $request - * @return void - * @static + * @return void + * @static */ - public static function setRequest($request){ + public static function setRequest($request) + { \Illuminate\Routing\UrlGenerator::setRequest($request); } - + /** * Set the route collection. * * @param \Illuminate\Routing\RouteCollection $routes - * @return $this - * @static + * @return $this + * @static */ - public static function setRoutes($routes){ + public static function setRoutes($routes) + { return \Illuminate\Routing\UrlGenerator::setRoutes($routes); } - + /** * Set the session resolver for the generator. * * @param callable $sessionResolver - * @return $this - * @static + * @return $this + * @static */ - public static function setSessionResolver($sessionResolver){ + public static function setSessionResolver($sessionResolver) + { return \Illuminate\Routing\UrlGenerator::setSessionResolver($sessionResolver); } - + /** * Set the root controller namespace. * * @param string $rootNamespace - * @return $this - * @static + * @return $this + * @static */ - public static function setRootControllerNamespace($rootNamespace){ + public static function setRootControllerNamespace($rootNamespace) + { return \Illuminate\Routing\UrlGenerator::setRootControllerNamespace($rootNamespace); } - + /** * Register a custom macro. * * @param string $name * @param callable $macro - * @return void - * @static + * @return void + * @static */ - public static function macro($name, $macro){ + public static function macro($name, $macro) + { \Illuminate\Routing\UrlGenerator::macro($name, $macro); } - + /** * Checks if macro is registered. * * @param string $name - * @return bool - * @static + * @return bool + * @static */ - public static function hasMacro($name){ + public static function hasMacro($name) + { return \Illuminate\Routing\UrlGenerator::hasMacro($name); } - } - - class Validator extends \Illuminate\Support\Facades\Validator{ - + class Validator extends \Illuminate\Support\Facades\Validator + { /** * Create a new Validator instance. * @@ -10822,171 +11677,183 @@ class Validator extends \Illuminate\Support\Facades\Validator{ * @param array $rules * @param array $messages * @param array $customAttributes - * @return \Illuminate\Validation\Validator - * @static + * @return \Illuminate\Validation\Validator + * @static */ - public static function make($data, $rules, $messages = array(), $customAttributes = array()){ + public static function make($data, $rules, $messages = [], $customAttributes = []) + { return \Illuminate\Validation\Factory::make($data, $rules, $messages, $customAttributes); } - + /** * Register a custom validator extension. * * @param string $rule * @param \Closure|string $extension * @param string $message - * @return void - * @static + * @return void + * @static */ - public static function extend($rule, $extension, $message = null){ + public static function extend($rule, $extension, $message = null) + { \Illuminate\Validation\Factory::extend($rule, $extension, $message); } - + /** * Register a custom implicit validator extension. * * @param string $rule * @param \Closure|string $extension * @param string $message - * @return void - * @static + * @return void + * @static */ - public static function extendImplicit($rule, $extension, $message = null){ + public static function extendImplicit($rule, $extension, $message = null) + { \Illuminate\Validation\Factory::extendImplicit($rule, $extension, $message); } - + /** * Register a custom implicit validator message replacer. * * @param string $rule * @param \Closure|string $replacer - * @return void - * @static + * @return void + * @static */ - public static function replacer($rule, $replacer){ + public static function replacer($rule, $replacer) + { \Illuminate\Validation\Factory::replacer($rule, $replacer); } - + /** * Set the Validator instance resolver. * * @param \Closure $resolver - * @return void - * @static + * @return void + * @static */ - public static function resolver($resolver){ + public static function resolver($resolver) + { \Illuminate\Validation\Factory::resolver($resolver); } - + /** * Get the Translator implementation. * - * @return \Symfony\Component\Translation\TranslatorInterface - * @static + * @return \Symfony\Component\Translation\TranslatorInterface + * @static */ - public static function getTranslator(){ + public static function getTranslator() + { return \Illuminate\Validation\Factory::getTranslator(); } - + /** * Get the Presence Verifier implementation. * - * @return \Illuminate\Validation\PresenceVerifierInterface - * @static + * @return \Illuminate\Validation\PresenceVerifierInterface + * @static */ - public static function getPresenceVerifier(){ + public static function getPresenceVerifier() + { return \Illuminate\Validation\Factory::getPresenceVerifier(); } - + /** * Set the Presence Verifier implementation. * * @param \Illuminate\Validation\PresenceVerifierInterface $presenceVerifier - * @return void - * @static + * @return void + * @static */ - public static function setPresenceVerifier($presenceVerifier){ + public static function setPresenceVerifier($presenceVerifier) + { \Illuminate\Validation\Factory::setPresenceVerifier($presenceVerifier); } - } - - class View extends \Illuminate\Support\Facades\View{ - + class View extends \Illuminate\Support\Facades\View + { /** * Get the evaluated view contents for the given view. * * @param string $path * @param array $data * @param array $mergeData - * @return \Illuminate\Contracts\View\View - * @static + * @return \Illuminate\Contracts\View\View + * @static */ - public static function file($path, $data = array(), $mergeData = array()){ + public static function file($path, $data = [], $mergeData = []) + { return \Illuminate\View\Factory::file($path, $data, $mergeData); } - + /** * Get the evaluated view contents for the given view. * * @param string $view * @param array $data * @param array $mergeData - * @return \Illuminate\Contracts\View\View - * @static + * @return \Illuminate\Contracts\View\View + * @static */ - public static function make($view, $data = array(), $mergeData = array()){ + public static function make($view, $data = [], $mergeData = []) + { return \Illuminate\View\Factory::make($view, $data, $mergeData); } - + /** * Get the evaluated view contents for a named view. * * @param string $view * @param mixed $data - * @return \Illuminate\Contracts\View\View - * @static + * @return \Illuminate\Contracts\View\View + * @static */ - public static function of($view, $data = array()){ + public static function of($view, $data = []) + { return \Illuminate\View\Factory::of($view, $data); } - + /** * Register a named view. * * @param string $view * @param string $name - * @return void - * @static + * @return void + * @static */ - public static function name($view, $name){ + public static function name($view, $name) + { \Illuminate\View\Factory::name($view, $name); } - + /** * Add an alias for a view. * * @param string $view * @param string $alias - * @return void - * @static + * @return void + * @static */ - public static function alias($view, $alias){ + public static function alias($view, $alias) + { \Illuminate\View\Factory::alias($view, $alias); } - + /** * Determine if a given view exists. * * @param string $view - * @return bool - * @static + * @return bool + * @static */ - public static function exists($view){ + public static function exists($view) + { return \Illuminate\View\Factory::exists($view); } - + /** * Get the rendered contents of a partial from a loop. * @@ -10994,505 +11861,548 @@ public static function exists($view){ * @param array $data * @param string $iterator * @param string $empty - * @return string - * @static + * @return string + * @static */ - public static function renderEach($view, $data, $iterator, $empty = 'raw|'){ + public static function renderEach($view, $data, $iterator, $empty = 'raw|') + { return \Illuminate\View\Factory::renderEach($view, $data, $iterator, $empty); } - + /** * Get the appropriate view engine for the given path. * * @param string $path - * @return \Illuminate\View\Engines\EngineInterface + * @return \Illuminate\View\Engines\EngineInterface * @throws \InvalidArgumentException - * @static + * @static */ - public static function getEngineFromPath($path){ + public static function getEngineFromPath($path) + { return \Illuminate\View\Factory::getEngineFromPath($path); } - + /** * Add a piece of shared data to the environment. * * @param array|string $key * @param mixed $value - * @return mixed - * @static + * @return mixed + * @static */ - public static function share($key, $value = null){ + public static function share($key, $value = null) + { return \Illuminate\View\Factory::share($key, $value); } - + /** * Register a view creator event. * * @param array|string $views * @param \Closure|string $callback - * @return array - * @static + * @return array + * @static */ - public static function creator($views, $callback){ + public static function creator($views, $callback) + { return \Illuminate\View\Factory::creator($views, $callback); } - + /** * Register multiple view composers via an array. * * @param array $composers - * @return array - * @static + * @return array + * @static */ - public static function composers($composers){ + public static function composers($composers) + { return \Illuminate\View\Factory::composers($composers); } - + /** * Register a view composer event. * * @param array|string $views * @param \Closure|string $callback * @param int|null $priority - * @return array - * @static + * @return array + * @static */ - public static function composer($views, $callback, $priority = null){ + public static function composer($views, $callback, $priority = null) + { return \Illuminate\View\Factory::composer($views, $callback, $priority); } - + /** * Call the composer for a given view. * * @param \Illuminate\Contracts\View\View $view - * @return void - * @static + * @return void + * @static */ - public static function callComposer($view){ + public static function callComposer($view) + { \Illuminate\View\Factory::callComposer($view); } - + /** * Call the creator for a given view. * * @param \Illuminate\Contracts\View\View $view - * @return void - * @static + * @return void + * @static */ - public static function callCreator($view){ + public static function callCreator($view) + { \Illuminate\View\Factory::callCreator($view); } - + /** * Start injecting content into a section. * * @param string $section * @param string $content - * @return void - * @static + * @return void + * @static */ - public static function startSection($section, $content = ''){ + public static function startSection($section, $content = '') + { \Illuminate\View\Factory::startSection($section, $content); } - + /** * Inject inline content into a section. * * @param string $section * @param string $content - * @return void - * @static + * @return void + * @static */ - public static function inject($section, $content){ + public static function inject($section, $content) + { \Illuminate\View\Factory::inject($section, $content); } - + /** * Stop injecting content into a section and return its contents. * - * @return string - * @static + * @return string + * @static */ - public static function yieldSection(){ + public static function yieldSection() + { return \Illuminate\View\Factory::yieldSection(); } - + /** * Stop injecting content into a section. * * @param bool $overwrite - * @return string + * @return string * @throws \InvalidArgumentException - * @static + * @static */ - public static function stopSection($overwrite = false){ + public static function stopSection($overwrite = false) + { return \Illuminate\View\Factory::stopSection($overwrite); } - + /** * Stop injecting content into a section and append it. * - * @return string + * @return string * @throws \InvalidArgumentException - * @static + * @static */ - public static function appendSection(){ + public static function appendSection() + { return \Illuminate\View\Factory::appendSection(); } - + /** * Get the string contents of a section. * * @param string $section * @param string $default - * @return string - * @static + * @return string + * @static */ - public static function yieldContent($section, $default = ''){ + public static function yieldContent($section, $default = '') + { return \Illuminate\View\Factory::yieldContent($section, $default); } - + /** * Start injecting content into a push section. * * @param string $section * @param string $content - * @return void - * @static + * @return void + * @static */ - public static function startPush($section, $content = ''){ + public static function startPush($section, $content = '') + { \Illuminate\View\Factory::startPush($section, $content); } - + /** * Stop injecting content into a push section. * - * @return string + * @return string * @throws \InvalidArgumentException - * @static + * @static */ - public static function stopPush(){ + public static function stopPush() + { return \Illuminate\View\Factory::stopPush(); } - + /** * Get the string contents of a push section. * * @param string $section * @param string $default - * @return string - * @static + * @return string + * @static */ - public static function yieldPushContent($section, $default = ''){ + public static function yieldPushContent($section, $default = '') + { return \Illuminate\View\Factory::yieldPushContent($section, $default); } - + /** * Flush all of the section contents. * - * @return void - * @static + * @return void + * @static */ - public static function flushSections(){ + public static function flushSections() + { \Illuminate\View\Factory::flushSections(); } - + /** * Flush all of the section contents if done rendering. * - * @return void - * @static + * @return void + * @static */ - public static function flushSectionsIfDoneRendering(){ + public static function flushSectionsIfDoneRendering() + { \Illuminate\View\Factory::flushSectionsIfDoneRendering(); } - + /** * Increment the rendering counter. * - * @return void - * @static + * @return void + * @static */ - public static function incrementRender(){ + public static function incrementRender() + { \Illuminate\View\Factory::incrementRender(); } - + /** * Decrement the rendering counter. * - * @return void - * @static + * @return void + * @static */ - public static function decrementRender(){ + public static function decrementRender() + { \Illuminate\View\Factory::decrementRender(); } - + /** * Check if there are no active render operations. * - * @return bool - * @static + * @return bool + * @static */ - public static function doneRendering(){ + public static function doneRendering() + { return \Illuminate\View\Factory::doneRendering(); } - + /** * Add a location to the array of view locations. * * @param string $location - * @return void - * @static + * @return void + * @static */ - public static function addLocation($location){ + public static function addLocation($location) + { \Illuminate\View\Factory::addLocation($location); } - + /** * Add a new namespace to the loader. * * @param string $namespace * @param string|array $hints - * @return void - * @static + * @return void + * @static */ - public static function addNamespace($namespace, $hints){ + public static function addNamespace($namespace, $hints) + { \Illuminate\View\Factory::addNamespace($namespace, $hints); } - + /** * Prepend a new namespace to the loader. * * @param string $namespace * @param string|array $hints - * @return void - * @static + * @return void + * @static */ - public static function prependNamespace($namespace, $hints){ + public static function prependNamespace($namespace, $hints) + { \Illuminate\View\Factory::prependNamespace($namespace, $hints); } - + /** * Register a valid view extension and its engine. * * @param string $extension * @param string $engine * @param \Closure $resolver - * @return void - * @static + * @return void + * @static */ - public static function addExtension($extension, $engine, $resolver = null){ + public static function addExtension($extension, $engine, $resolver = null) + { \Illuminate\View\Factory::addExtension($extension, $engine, $resolver); } - + /** * Get the extension to engine bindings. * - * @return array - * @static + * @return array + * @static */ - public static function getExtensions(){ + public static function getExtensions() + { return \Illuminate\View\Factory::getExtensions(); } - + /** * Get the engine resolver instance. * - * @return \Illuminate\View\Engines\EngineResolver - * @static + * @return \Illuminate\View\Engines\EngineResolver + * @static */ - public static function getEngineResolver(){ + public static function getEngineResolver() + { return \Illuminate\View\Factory::getEngineResolver(); } - + /** * Get the view finder instance. * - * @return \Illuminate\View\ViewFinderInterface - * @static + * @return \Illuminate\View\ViewFinderInterface + * @static */ - public static function getFinder(){ + public static function getFinder() + { return \Illuminate\View\Factory::getFinder(); } - + /** * Set the view finder instance. * * @param \Illuminate\View\ViewFinderInterface $finder - * @return void - * @static + * @return void + * @static */ - public static function setFinder($finder){ + public static function setFinder($finder) + { \Illuminate\View\Factory::setFinder($finder); } - + /** * Get the event dispatcher instance. * - * @return \Illuminate\Contracts\Events\Dispatcher - * @static + * @return \Illuminate\Contracts\Events\Dispatcher + * @static */ - public static function getDispatcher(){ + public static function getDispatcher() + { return \Illuminate\View\Factory::getDispatcher(); } - + /** * Set the event dispatcher instance. * * @param \Illuminate\Contracts\Events\Dispatcher $events - * @return void - * @static + * @return void + * @static */ - public static function setDispatcher($events){ + public static function setDispatcher($events) + { \Illuminate\View\Factory::setDispatcher($events); } - + /** * Get the IoC container instance. * - * @return \Illuminate\Contracts\Container\Container - * @static + * @return \Illuminate\Contracts\Container\Container + * @static */ - public static function getContainer(){ + public static function getContainer() + { return \Illuminate\View\Factory::getContainer(); } - + /** * Set the IoC container instance. * * @param \Illuminate\Contracts\Container\Container $container - * @return void - * @static + * @return void + * @static */ - public static function setContainer($container){ + public static function setContainer($container) + { \Illuminate\View\Factory::setContainer($container); } - + /** * Get an item from the shared data. * * @param string $key * @param mixed $default - * @return mixed - * @static + * @return mixed + * @static */ - public static function shared($key, $default = null){ + public static function shared($key, $default = null) + { return \Illuminate\View\Factory::shared($key, $default); } - + /** * Get all of the shared data for the environment. * - * @return array - * @static + * @return array + * @static */ - public static function getShared(){ + public static function getShared() + { return \Illuminate\View\Factory::getShared(); } - + /** * Check if section exists. * * @param string $name - * @return bool - * @static + * @return bool + * @static */ - public static function hasSection($name){ + public static function hasSection($name) + { return \Illuminate\View\Factory::hasSection($name); } - + /** * Get the entire array of sections. * - * @return array - * @static + * @return array + * @static */ - public static function getSections(){ + public static function getSections() + { return \Illuminate\View\Factory::getSections(); } - + /** * Get all of the registered named views in environment. * - * @return array - * @static + * @return array + * @static */ - public static function getNames(){ + public static function getNames() + { return \Illuminate\View\Factory::getNames(); } - } - - class Form extends \Collective\Html\FormFacade{ - + class Form extends \Collective\Html\FormFacade + { /** * Open up a new HTML form. * * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function open($options = array()){ + public static function open($options = []) + { return \Collective\Html\FormBuilder::open($options); } - + /** * Create a new model based form builder. * * @param mixed $model * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function model($model, $options = array()){ + public static function model($model, $options = []) + { return \Collective\Html\FormBuilder::model($model, $options); } - + /** * Set the model instance on the form builder. * * @param mixed $model - * @return void - * @static + * @return void + * @static */ - public static function setModel($model){ + public static function setModel($model) + { \Collective\Html\FormBuilder::setModel($model); } - + /** * Close the current form. * - * @return string - * @static + * @return string + * @static */ - public static function close(){ + public static function close() + { return \Collective\Html\FormBuilder::close(); } - + /** * Generate a hidden field with the current CSRF token. * - * @return string - * @static + * @return string + * @static */ - public static function token(){ + public static function token() + { return \Collective\Html\FormBuilder::token(); } - + /** * Create a form label element. * * @param string $name * @param string $value * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function label($name, $value = null, $options = array()){ + public static function label($name, $value = null, $options = []) + { return \Collective\Html\FormBuilder::label($name, $value, $options); } - + /** * Create a form input field. * @@ -11500,180 +12410,194 @@ public static function label($name, $value = null, $options = array()){ * @param string $name * @param string $value * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function input($type, $name, $value = null, $options = array()){ + public static function input($type, $name, $value = null, $options = []) + { return \Collective\Html\FormBuilder::input($type, $name, $value, $options); } - + /** * Create a text input field. * * @param string $name * @param string $value * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function text($name, $value = null, $options = array()){ + public static function text($name, $value = null, $options = []) + { return \Collective\Html\FormBuilder::text($name, $value, $options); } - + /** * Create a password input field. * * @param string $name * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function password($name, $options = array()){ + public static function password($name, $options = []) + { return \Collective\Html\FormBuilder::password($name, $options); } - + /** * Create a hidden input field. * * @param string $name * @param string $value * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function hidden($name, $value = null, $options = array()){ + public static function hidden($name, $value = null, $options = []) + { return \Collective\Html\FormBuilder::hidden($name, $value, $options); } - + /** * Create an e-mail input field. * * @param string $name * @param string $value * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function email($name, $value = null, $options = array()){ + public static function email($name, $value = null, $options = []) + { return \Collective\Html\FormBuilder::email($name, $value, $options); } - + /** * Create a tel input field. * * @param string $name * @param string $value * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function tel($name, $value = null, $options = array()){ + public static function tel($name, $value = null, $options = []) + { return \Collective\Html\FormBuilder::tel($name, $value, $options); } - + /** * Create a number input field. * * @param string $name * @param string $value * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function number($name, $value = null, $options = array()){ + public static function number($name, $value = null, $options = []) + { return \Collective\Html\FormBuilder::number($name, $value, $options); } - + /** * Create a date input field. * * @param string $name * @param string $value * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function date($name, $value = null, $options = array()){ + public static function date($name, $value = null, $options = []) + { return \Collective\Html\FormBuilder::date($name, $value, $options); } - + /** * Create a datetime input field. * * @param string $name * @param string $value * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function datetime($name, $value = null, $options = array()){ + public static function datetime($name, $value = null, $options = []) + { return \Collective\Html\FormBuilder::datetime($name, $value, $options); } - + /** * Create a datetime-local input field. * * @param string $name * @param string $value * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function datetimeLocal($name, $value = null, $options = array()){ + public static function datetimeLocal($name, $value = null, $options = []) + { return \Collective\Html\FormBuilder::datetimeLocal($name, $value, $options); } - + /** * Create a time input field. * * @param string $name * @param string $value * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function time($name, $value = null, $options = array()){ + public static function time($name, $value = null, $options = []) + { return \Collective\Html\FormBuilder::time($name, $value, $options); } - + /** * Create a url input field. * * @param string $name * @param string $value * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function url($name, $value = null, $options = array()){ + public static function url($name, $value = null, $options = []) + { return \Collective\Html\FormBuilder::url($name, $value, $options); } - + /** * Create a file input field. * * @param string $name * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function file($name, $options = array()){ + public static function file($name, $options = []) + { return \Collective\Html\FormBuilder::file($name, $options); } - + /** * Create a textarea input field. * * @param string $name * @param string $value * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function textarea($name, $value = null, $options = array()){ + public static function textarea($name, $value = null, $options = []) + { return \Collective\Html\FormBuilder::textarea($name, $value, $options); } - + /** * Create a select box field. * @@ -11681,13 +12605,14 @@ public static function textarea($name, $value = null, $options = array()){ * @param array $list * @param string $selected * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function select($name, $list = array(), $selected = null, $options = array()){ + public static function select($name, $list = [], $selected = null, $options = []) + { return \Collective\Html\FormBuilder::select($name, $list, $selected, $options); } - + /** * Create a select range field. * @@ -11696,13 +12621,14 @@ public static function select($name, $list = array(), $selected = null, $options * @param string $end * @param string $selected * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function selectRange($name, $begin, $end, $selected = null, $options = array()){ + public static function selectRange($name, $begin, $end, $selected = null, $options = []) + { return \Collective\Html\FormBuilder::selectRange($name, $begin, $end, $selected, $options); } - + /** * Create a select year field. * @@ -11711,13 +12637,14 @@ public static function selectRange($name, $begin, $end, $selected = null, $optio * @param string $end * @param string $selected * @param array $options - * @return mixed - * @static + * @return mixed + * @static */ - public static function selectYear(){ + public static function selectYear() + { return \Collective\Html\FormBuilder::selectYear(); } - + /** * Create a select month field. * @@ -11725,26 +12652,28 @@ public static function selectYear(){ * @param string $selected * @param array $options * @param string $format - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function selectMonth($name, $selected = null, $options = array(), $format = '%B'){ + public static function selectMonth($name, $selected = null, $options = [], $format = '%B') + { return \Collective\Html\FormBuilder::selectMonth($name, $selected, $options, $format); } - + /** * Get the select option for the given value. * * @param string $display * @param string $value * @param string $selected - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function getSelectOption($display, $value, $selected){ + public static function getSelectOption($display, $value, $selected) + { return \Collective\Html\FormBuilder::getSelectOption($display, $value, $selected); } - + /** * Create a checkbox input field. * @@ -11752,13 +12681,14 @@ public static function getSelectOption($display, $value, $selected){ * @param mixed $value * @param bool $checked * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function checkbox($name, $value = 1, $checked = null, $options = array()){ + public static function checkbox($name, $value = 1, $checked = null, $options = []) + { return \Collective\Html\FormBuilder::checkbox($name, $value, $checked, $options); } - + /** * Create a radio button input field. * @@ -11766,267 +12696,287 @@ public static function checkbox($name, $value = 1, $checked = null, $options = a * @param mixed $value * @param bool $checked * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function radio($name, $value = null, $checked = null, $options = array()){ + public static function radio($name, $value = null, $checked = null, $options = []) + { return \Collective\Html\FormBuilder::radio($name, $value, $checked, $options); } - + /** * Create a HTML reset input element. * * @param string $value * @param array $attributes - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function reset($value, $attributes = array()){ + public static function reset($value, $attributes = []) + { return \Collective\Html\FormBuilder::reset($value, $attributes); } - + /** * Create a HTML image input element. * * @param string $url * @param string $name * @param array $attributes - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function image($url, $name = null, $attributes = array()){ + public static function image($url, $name = null, $attributes = []) + { return \Collective\Html\FormBuilder::image($url, $name, $attributes); } - + /** * Create a color input field. * * @param string $name * @param string $value * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function color($name, $value = null, $options = array()){ + public static function color($name, $value = null, $options = []) + { return \Collective\Html\FormBuilder::color($name, $value, $options); } - + /** * Create a submit button element. * * @param string $value * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function submit($value = null, $options = array()){ + public static function submit($value = null, $options = []) + { return \Collective\Html\FormBuilder::submit($value, $options); } - + /** * Create a button element. * * @param string $value * @param array $options - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function button($value = null, $options = array()){ + public static function button($value = null, $options = []) + { return \Collective\Html\FormBuilder::button($value, $options); } - + /** * Get the ID attribute for a field name. * * @param string $name * @param array $attributes - * @return string - * @static + * @return string + * @static */ - public static function getIdAttribute($name, $attributes){ + public static function getIdAttribute($name, $attributes) + { return \Collective\Html\FormBuilder::getIdAttribute($name, $attributes); } - + /** * Get the value that should be assigned to the field. * * @param string $name * @param string $value - * @return mixed - * @static + * @return mixed + * @static */ - public static function getValueAttribute($name, $value = null){ + public static function getValueAttribute($name, $value = null) + { return \Collective\Html\FormBuilder::getValueAttribute($name, $value); } - + /** * Get a value from the session's old input. * * @param string $name - * @return mixed - * @static + * @return mixed + * @static */ - public static function old($name){ + public static function old($name) + { return \Collective\Html\FormBuilder::old($name); } - + /** * Determine if the old input is empty. * - * @return bool - * @static + * @return bool + * @static */ - public static function oldInputIsEmpty(){ + public static function oldInputIsEmpty() + { return \Collective\Html\FormBuilder::oldInputIsEmpty(); } - + /** * Get the session store implementation. * * @return \Illuminate\Session\SessionInterface $session - * @static + * @static */ - public static function getSessionStore(){ + public static function getSessionStore() + { return \Collective\Html\FormBuilder::getSessionStore(); } - + /** * Set the session store implementation. * * @param \Illuminate\Session\SessionInterface $session - * @return $this - * @static + * @return $this + * @static */ - public static function setSessionStore($session){ + public static function setSessionStore($session) + { return \Collective\Html\FormBuilder::setSessionStore($session); } - + /** * Register a custom macro. * * @param string $name * @param callable $macro - * @return void - * @static + * @return void + * @static */ - public static function macro($name, $macro){ + public static function macro($name, $macro) + { \Collective\Html\FormBuilder::macro($name, $macro); } - + /** * Checks if macro is registered. * * @param string $name - * @return bool - * @static + * @return bool + * @static */ - public static function hasMacro($name){ + public static function hasMacro($name) + { return \Collective\Html\FormBuilder::hasMacro($name); } - + /** * Dynamically handle calls to the class. * * @param string $method * @param array $parameters - * @return mixed + * @return mixed * @throws \BadMethodCallException - * @static + * @static */ - public static function macroCall($method, $parameters){ + public static function macroCall($method, $parameters) + { return \Collective\Html\FormBuilder::macroCall($method, $parameters); } - + /** * Register a custom component. * * @param $name * @param $view * @param array $signature - * @return void - * @static + * @return void + * @static */ - public static function component($name, $view, $signature){ + public static function component($name, $view, $signature) + { \Collective\Html\FormBuilder::component($name, $view, $signature); } - + /** * Check if a component is registered. * * @param $name - * @return bool - * @static + * @return bool + * @static */ - public static function hasComponent($name){ + public static function hasComponent($name) + { return \Collective\Html\FormBuilder::hasComponent($name); } - + /** * Dynamically handle calls to the class. * * @param string $method * @param array $parameters - * @return \Illuminate\Contracts\View\View|mixed + * @return \Illuminate\Contracts\View\View|mixed * @throws \BadMethodCallException - * @static + * @static */ - public static function componentCall($method, $parameters){ + public static function componentCall($method, $parameters) + { return \Collective\Html\FormBuilder::componentCall($method, $parameters); } - } - - class Html extends \Collective\Html\HtmlFacade{ - + class Html extends \Collective\Html\HtmlFacade + { /** * Convert an HTML string to entities. * * @param string $value - * @return string - * @static + * @return string + * @static */ - public static function entities($value){ + public static function entities($value) + { return \Collective\Html\HtmlBuilder::entities($value); } - + /** * Convert entities to HTML characters. * * @param string $value - * @return string - * @static + * @return string + * @static */ - public static function decode($value){ + public static function decode($value) + { return \Collective\Html\HtmlBuilder::decode($value); } - + /** * Generate a link to a JavaScript file. * * @param string $url * @param array $attributes * @param bool $secure - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function script($url, $attributes = array(), $secure = null){ + public static function script($url, $attributes = [], $secure = null) + { return \Collective\Html\HtmlBuilder::script($url, $attributes, $secure); } - + /** * Generate a link to a CSS file. * * @param string $url * @param array $attributes * @param bool $secure - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function style($url, $attributes = array(), $secure = null){ + public static function style($url, $attributes = [], $secure = null) + { return \Collective\Html\HtmlBuilder::style($url, $attributes, $secure); } - + /** * Generate an HTML image element. * @@ -12034,26 +12984,28 @@ public static function style($url, $attributes = array(), $secure = null){ * @param string $alt * @param array $attributes * @param bool $secure - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function image($url, $alt = null, $attributes = array(), $secure = null){ + public static function image($url, $alt = null, $attributes = [], $secure = null) + { return \Collective\Html\HtmlBuilder::image($url, $alt, $attributes, $secure); } - + /** * Generate a link to a Favicon file. * * @param string $url * @param array $attributes * @param bool $secure - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function favicon($url, $attributes = array(), $secure = null){ + public static function favicon($url, $attributes = [], $secure = null) + { return \Collective\Html\HtmlBuilder::favicon($url, $attributes, $secure); } - + /** * Generate a HTML link. * @@ -12061,26 +13013,28 @@ public static function favicon($url, $attributes = array(), $secure = null){ * @param string $title * @param array $attributes * @param bool $secure - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function link($url, $title = null, $attributes = array(), $secure = null){ + public static function link($url, $title = null, $attributes = [], $secure = null) + { return \Collective\Html\HtmlBuilder::link($url, $title, $attributes, $secure); } - + /** * Generate a HTTPS HTML link. * * @param string $url * @param string $title * @param array $attributes - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function secureLink($url, $title = null, $attributes = array()){ + public static function secureLink($url, $title = null, $attributes = []) + { return \Collective\Html\HtmlBuilder::secureLink($url, $title, $attributes); } - + /** * Generate a HTML link to an asset. * @@ -12088,26 +13042,28 @@ public static function secureLink($url, $title = null, $attributes = array()){ * @param string $title * @param array $attributes * @param bool $secure - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function linkAsset($url, $title = null, $attributes = array(), $secure = null){ + public static function linkAsset($url, $title = null, $attributes = [], $secure = null) + { return \Collective\Html\HtmlBuilder::linkAsset($url, $title, $attributes, $secure); } - + /** * Generate a HTTPS HTML link to an asset. * * @param string $url * @param string $title * @param array $attributes - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function linkSecureAsset($url, $title = null, $attributes = array()){ + public static function linkSecureAsset($url, $title = null, $attributes = []) + { return \Collective\Html\HtmlBuilder::linkSecureAsset($url, $title, $attributes); } - + /** * Generate a HTML link to a named route. * @@ -12115,13 +13071,14 @@ public static function linkSecureAsset($url, $title = null, $attributes = array( * @param string $title * @param array $parameters * @param array $attributes - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function linkRoute($name, $title = null, $parameters = array(), $attributes = array()){ + public static function linkRoute($name, $title = null, $parameters = [], $attributes = []) + { return \Collective\Html\HtmlBuilder::linkRoute($name, $title, $parameters, $attributes); } - + /** * Generate a HTML link to a controller action. * @@ -12129,418 +13086,442 @@ public static function linkRoute($name, $title = null, $parameters = array(), $a * @param string $title * @param array $parameters * @param array $attributes - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function linkAction($action, $title = null, $parameters = array(), $attributes = array()){ + public static function linkAction($action, $title = null, $parameters = [], $attributes = []) + { return \Collective\Html\HtmlBuilder::linkAction($action, $title, $parameters, $attributes); } - + /** * Generate a HTML link to an email address. * * @param string $email * @param string $title * @param array $attributes - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function mailto($email, $title = null, $attributes = array()){ + public static function mailto($email, $title = null, $attributes = []) + { return \Collective\Html\HtmlBuilder::mailto($email, $title, $attributes); } - + /** * Obfuscate an e-mail address to prevent spam-bots from sniffing it. * * @param string $email - * @return string - * @static + * @return string + * @static */ - public static function email($email){ + public static function email($email) + { return \Collective\Html\HtmlBuilder::email($email); } - + /** * Generate an ordered list of items. * * @param array $list * @param array $attributes - * @return \Illuminate\Support\HtmlString|string - * @static + * @return \Illuminate\Support\HtmlString|string + * @static */ - public static function ol($list, $attributes = array()){ + public static function ol($list, $attributes = []) + { return \Collective\Html\HtmlBuilder::ol($list, $attributes); } - + /** * Generate an un-ordered list of items. * * @param array $list * @param array $attributes - * @return \Illuminate\Support\HtmlString|string - * @static + * @return \Illuminate\Support\HtmlString|string + * @static */ - public static function ul($list, $attributes = array()){ + public static function ul($list, $attributes = []) + { return \Collective\Html\HtmlBuilder::ul($list, $attributes); } - + /** * Generate a description list of items. * * @param array $list * @param array $attributes - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function dl($list, $attributes = array()){ + public static function dl($list, $attributes = []) + { return \Collective\Html\HtmlBuilder::dl($list, $attributes); } - + /** * Build an HTML attribute string from an array. * * @param array $attributes - * @return string - * @static + * @return string + * @static */ - public static function attributes($attributes){ + public static function attributes($attributes) + { return \Collective\Html\HtmlBuilder::attributes($attributes); } - + /** * Obfuscate a string to prevent spam-bots from sniffing it. * * @param string $value - * @return string - * @static + * @return string + * @static */ - public static function obfuscate($value){ + public static function obfuscate($value) + { return \Collective\Html\HtmlBuilder::obfuscate($value); } - + /** * Generate a meta tag. * * @param string $name * @param string $content * @param array $attributes - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function meta($name, $content, $attributes = array()){ + public static function meta($name, $content, $attributes = []) + { return \Collective\Html\HtmlBuilder::meta($name, $content, $attributes); } - + /** * Generate an html tag. * * @param string $tag * @param mixed $content * @param array $attributes - * @return \Illuminate\Support\HtmlString - * @static + * @return \Illuminate\Support\HtmlString + * @static */ - public static function tag($tag, $content, $attributes = array()){ + public static function tag($tag, $content, $attributes = []) + { return \Collective\Html\HtmlBuilder::tag($tag, $content, $attributes); } - + /** * Register a custom macro. * * @param string $name * @param callable $macro - * @return void - * @static + * @return void + * @static */ - public static function macro($name, $macro){ + public static function macro($name, $macro) + { \Collective\Html\HtmlBuilder::macro($name, $macro); } - + /** * Checks if macro is registered. * * @param string $name - * @return bool - * @static + * @return bool + * @static */ - public static function hasMacro($name){ + public static function hasMacro($name) + { return \Collective\Html\HtmlBuilder::hasMacro($name); } - + /** * Dynamically handle calls to the class. * * @param string $method * @param array $parameters - * @return mixed + * @return mixed * @throws \BadMethodCallException - * @static + * @static */ - public static function macroCall($method, $parameters){ + public static function macroCall($method, $parameters) + { return \Collective\Html\HtmlBuilder::macroCall($method, $parameters); } - + /** * Register a custom component. * * @param $name * @param $view * @param array $signature - * @return void - * @static + * @return void + * @static */ - public static function component($name, $view, $signature){ + public static function component($name, $view, $signature) + { \Collective\Html\HtmlBuilder::component($name, $view, $signature); } - + /** * Check if a component is registered. * * @param $name - * @return bool - * @static + * @return bool + * @static */ - public static function hasComponent($name){ + public static function hasComponent($name) + { return \Collective\Html\HtmlBuilder::hasComponent($name); } - + /** * Dynamically handle calls to the class. * * @param string $method * @param array $parameters - * @return \Illuminate\Contracts\View\View|mixed + * @return \Illuminate\Contracts\View\View|mixed * @throws \BadMethodCallException - * @static + * @static */ - public static function componentCall($method, $parameters){ + public static function componentCall($method, $parameters) + { return \Collective\Html\HtmlBuilder::componentCall($method, $parameters); } - } - - class AdminLTE extends \Acacha\AdminLTETemplateLaravel\Facades\AdminLTE{ - + class AdminLTE extends \Acacha\AdminLTETemplateLaravel\Facades\AdminLTE + { /** * Home controller copy path. * - * @return array - * @static + * @return array + * @static */ - public static function homeController(){ + public static function homeController() + { return \Acacha\AdminLTETemplateLaravel\AdminLTE::homeController(); } - + /** * Auth controller copy path. * - * @return array - * @static + * @return array + * @static */ - public static function authController(){ + public static function authController() + { return \Acacha\AdminLTETemplateLaravel\AdminLTE::authController(); } - + /** * Public assets copy path. * - * @return array - * @static + * @return array + * @static */ - public static function publicAssets(){ + public static function publicAssets() + { return \Acacha\AdminLTETemplateLaravel\AdminLTE::publicAssets(); } - + /** * Views copy path. * - * @return array - * @static + * @return array + * @static */ - public static function views(){ + public static function views() + { return \Acacha\AdminLTETemplateLaravel\AdminLTE::views(); } - + /** * Tests copy path. * - * @return array - * @static + * @return array + * @static */ - public static function tests(){ + public static function tests() + { return \Acacha\AdminLTETemplateLaravel\AdminLTE::tests(); } - + /** * Resource assets copy path. * - * @return array - * @static + * @return array + * @static */ - public static function resourceAssets(){ + public static function resourceAssets() + { return \Acacha\AdminLTETemplateLaravel\AdminLTE::resourceAssets(); } - } - - class Socialite extends \Laravel\Socialite\Facades\Socialite{ - + class Socialite extends \Laravel\Socialite\Facades\Socialite + { /** * Get a driver instance. * * @param string $driver - * @return mixed - * @static + * @return mixed + * @static */ - public static function with($driver){ + public static function with($driver) + { return \Laravel\Socialite\SocialiteManager::with($driver); } - + /** * Build an OAuth 2 provider instance. * * @param string $provider * @param array $config - * @return \Laravel\Socialite\Two\AbstractProvider - * @static + * @return \Laravel\Socialite\Two\AbstractProvider + * @static */ - public static function buildProvider($provider, $config){ + public static function buildProvider($provider, $config) + { return \Laravel\Socialite\SocialiteManager::buildProvider($provider, $config); } - + /** * Format the server configuration. * * @param array $config - * @return array - * @static + * @return array + * @static */ - public static function formatConfig($config){ + public static function formatConfig($config) + { return \Laravel\Socialite\SocialiteManager::formatConfig($config); } - + /** * Get the default driver name. * * @throws \InvalidArgumentException - * @return string - * @static + * @return string + * @static */ - public static function getDefaultDriver(){ + public static function getDefaultDriver() + { return \Laravel\Socialite\SocialiteManager::getDefaultDriver(); } - + /** * Get a driver instance. * * @param string $driver - * @return mixed - * @static + * @return mixed + * @static */ - public static function driver($driver = null){ - //Method inherited from \Illuminate\Support\Manager + public static function driver($driver = null) + { + //Method inherited from \Illuminate\Support\Manager return \Laravel\Socialite\SocialiteManager::driver($driver); } - + /** * Register a custom driver creator Closure. * * @param string $driver * @param \Closure $callback - * @return $this - * @static + * @return $this + * @static */ - public static function extend($driver, $callback){ - //Method inherited from \Illuminate\Support\Manager + public static function extend($driver, $callback) + { + //Method inherited from \Illuminate\Support\Manager return \Laravel\Socialite\SocialiteManager::extend($driver, $callback); } - + /** * Get all of the created "drivers". * - * @return array - * @static + * @return array + * @static */ - public static function getDrivers(){ - //Method inherited from \Illuminate\Support\Manager + public static function getDrivers() + { + //Method inherited from \Illuminate\Support\Manager return \Laravel\Socialite\SocialiteManager::getDrivers(); } - } - - class Datatables extends \Yajra\Datatables\Facades\Datatables{ - + class Datatables extends \Yajra\Datatables\Facades\Datatables + { /** * Gets query and returns instance of class. * * @param mixed $builder - * @return mixed - * @static + * @return mixed + * @static */ - public static function of($builder){ + public static function of($builder) + { return \Yajra\Datatables\Datatables::of($builder); } - + /** * Datatables using Query Builder. * * @param \Illuminate\Database\Query\Builder $builder - * @return \Yajra\Datatables\Engines\QueryBuilderEngine - * @static + * @return \Yajra\Datatables\Engines\QueryBuilderEngine + * @static */ - public static function usingQueryBuilder($builder){ + public static function usingQueryBuilder($builder) + { return \Yajra\Datatables\Datatables::usingQueryBuilder($builder); } - + /** * Datatables using Collection. * * @param \Illuminate\Support\Collection $builder - * @return \Yajra\Datatables\Engines\CollectionEngine - * @static + * @return \Yajra\Datatables\Engines\CollectionEngine + * @static */ - public static function usingCollection($builder){ + public static function usingCollection($builder) + { return \Yajra\Datatables\Datatables::usingCollection($builder); } - + /** * Datatables using Eloquent. * * @param mixed $builder - * @return \Yajra\Datatables\Engines\EloquentEngine - * @static + * @return \Yajra\Datatables\Engines\EloquentEngine + * @static */ - public static function usingEloquent($builder){ + public static function usingEloquent($builder) + { return \Yajra\Datatables\Datatables::usingEloquent($builder); } - + /** * Get html builder class. * - * @return \Yajra\Datatables\Html\Builder - * @static + * @return \Yajra\Datatables\Html\Builder + * @static */ - public static function getHtmlBuilder(){ + public static function getHtmlBuilder() + { return \Yajra\Datatables\Datatables::getHtmlBuilder(); } - + /** * Get request object. * - * @return \Yajra\Datatables\Request|static - * @static + * @return \Yajra\Datatables\Request|static + * @static */ - public static function getRequest(){ + public static function getRequest() + { return \Yajra\Datatables\Datatables::getRequest(); } - } - } - - - diff --git a/app/Comment.php b/app/Comment.php index 6e9de09..4225692 100644 --- a/app/Comment.php +++ b/app/Comment.php @@ -6,17 +6,15 @@ class Comment extends Model { - protected $fillable = [ 'user_id' , 'link_id', 'body']; - - - public function user(){ + protected $fillable = ['user_id', 'link_id', 'body']; + + public function user() + { return $this->belongsTo("App\User"); } - public function link(){ + + public function link() + { return $this->hasOne("App\Link", 'id', 'link_id'); } - - } - - diff --git a/app/Console/Commands/CreateSuperAdmin.php b/app/Console/Commands/CreateSuperAdmin.php index 540726a..7b326c6 100644 --- a/app/Console/Commands/CreateSuperAdmin.php +++ b/app/Console/Commands/CreateSuperAdmin.php @@ -37,36 +37,33 @@ public function __construct() */ public function handle() { - echo "Create a Super Admin User\n"; - $name = $this->ask("Enter a name for the Super Admin User", "admin"); - $email = $this->ask("Enter an email for the Super Admin User", "admin@admin.com"); + $name = $this->ask('Enter a name for the Super Admin User', 'admin'); + $email = $this->ask('Enter an email for the Super Admin User', 'admin@admin.com'); $count = 0; $limit = 3; - do{ - if($count !== 0 ){ + do { + if ($count !== 0) { $this->error("\n\nError:"); - $this->error("Your passwords do not match. You have " . ($limit-$count) . " more tries...\n\n\n" ); + $this->error('Your passwords do not match. You have '.($limit - $count)." more tries...\n\n\n"); } - $password = $this->secret("Enter a password"); - $passwordRetype = $this->secret("Retype your password"); + $password = $this->secret('Enter a password'); + $passwordRetype = $this->secret('Retype your password'); $count++; - }while($password !== $passwordRetype && $count < 3 ); - if($count >= $limit){ + } while ($password !== $passwordRetype && $count < 3); + if ($count >= $limit) { $this->error("\n\nError:"); $this->error("Could not create user. Password tries exceeded limit.\n\n\n"); + return; - } - else{ + } else { $user = new \App\User(); $user->name = $name; $user->password = bcrypt($password); $user->email = $email; - $user->avatar = asset("/img/avatar04.png"); + $user->avatar = asset('/img/avatar04.png'); $user->save(); - $this->info("User successfully created. Got to " . env("APP_URL") . "/admin" . " to access the admin panel"); + $this->info('User successfully created. Got to '.env('APP_URL').'/admin'.' to access the admin panel'); } - } - } diff --git a/app/DataTables/LinksDataTable.php b/app/DataTables/LinksDataTable.php index 327d2b4..fbc3641 100644 --- a/app/DataTables/LinksDataTable.php +++ b/app/DataTables/LinksDataTable.php @@ -2,9 +2,8 @@ namespace App\DataTables; -use App\User; -use Yajra\Datatables\Services\DataTable; use App\Link; +use Yajra\Datatables\Services\DataTable; class LinksDataTable extends DataTable { @@ -29,6 +28,7 @@ public function query() { $query = Link::all(); dd($query); + return $this->applyScopes($query); } @@ -68,6 +68,6 @@ protected function getColumns() */ protected function filename() { - return 'linksdatatables_' . time(); + return 'linksdatatables_'.time(); } } diff --git a/app/Events/CreateLinkEvent.php b/app/Events/CreateLinkEvent.php index 8f6f127..5efdbaf 100644 --- a/app/Events/CreateLinkEvent.php +++ b/app/Events/CreateLinkEvent.php @@ -2,16 +2,15 @@ namespace App\Events; -use App\Events\Event; use App\Link; use Illuminate\Queue\SerializesModels; -use Illuminate\Contracts\Broadcasting\ShouldBroadcast; class CreateLinkEvent extends Event { use SerializesModels; public $link; + /** * Create a new event instance. * @@ -20,7 +19,7 @@ class CreateLinkEvent extends Event public function __construct(Link $link) { // - $this-> link = $link; + $this->link = $link; } /** diff --git a/app/Events/SomeEvent.php b/app/Events/SomeEvent.php index c0e9b81..e025e04 100644 --- a/app/Events/SomeEvent.php +++ b/app/Events/SomeEvent.php @@ -2,9 +2,7 @@ namespace App\Events; -use App\Events\Event; use Illuminate\Queue\SerializesModels; -use Illuminate\Contracts\Broadcasting\ShouldBroadcast; class SomeEvent extends Event { diff --git a/app/Exceptions/Handler.php b/app/Exceptions/Handler.php index 53617ef..daaf37a 100644 --- a/app/Exceptions/Handler.php +++ b/app/Exceptions/Handler.php @@ -3,11 +3,11 @@ namespace App\Exceptions; use Exception; -use Illuminate\Validation\ValidationException; use Illuminate\Auth\Access\AuthorizationException; use Illuminate\Database\Eloquent\ModelNotFoundException; -use Symfony\Component\HttpKernel\Exception\HttpException; use Illuminate\Foundation\Exceptions\Handler as ExceptionHandler; +use Illuminate\Validation\ValidationException; +use Symfony\Component\HttpKernel\Exception\HttpException; class Handler extends ExceptionHandler { diff --git a/app/File.php b/app/File.php index 0bfccd5..a3d1a5e 100644 --- a/app/File.php +++ b/app/File.php @@ -2,69 +2,87 @@ namespace App; -use Illuminate\Database\Eloquent\Model; -use Codesleeve\Stapler\ORM\StaplerableInterface; -use Codesleeve\Stapler\ORM\EloquentTrait; use Cache; +use Codesleeve\Stapler\ORM\EloquentTrait; +use Codesleeve\Stapler\ORM\StaplerableInterface; +use Illuminate\Database\Eloquent\Model; -class File extends Model implements StaplerableInterface { - +class File extends Model implements StaplerableInterface +{ use EloquentTrait; - protected $appends = ["tooltip"]; + protected $appends = ['tooltip']; protected $fillable = ['resource', 'filetype', 'public', 'user_id']; - public function __construct(array $attributes = array()) { + public function __construct(array $attributes = []) + { $this->hasAttachedFile('resource', [ ]); parent::__construct($attributes); } - public function user() { + public function user() + { return $this->belongsTo("App\User"); } - public function projects() { + public function projects() + { return $this->belongsToMany('App\Project', 'file_project', 'file_id', 'project_id'); } - public function getTooltipAttribute() { - $ids = $this->projects->pluck("id")->toArray(); + public function getTooltipAttribute() + { + $ids = $this->projects->pluck('id')->toArray(); if ($this->user_id != auth()->user()->id) { - return "You are not autorized to delete this file. Only the owner of the file can delete it."; + return 'You are not autorized to delete this file. Only the owner of the file can delete it.'; } - return count($ids) > 0 ? "File in use in project(s) " . implode(", ", $ids) . ". Please, remove project(s) first!" : ""; + + return count($ids) > 0 ? 'File in use in project(s) '.implode(', ', $ids).'. Please, remove project(s) first!' : ''; } - public function download($format) { + public function download($format) + { $graph = $this->cacheGraph(); $export = $graph->serialise($format); + return response()->downloadFromCache($export, $format, $this->resource_file_name); } - + //this function get the graph from the cache if it exists or parses the file and stores it in cache //in any case it returns an EasyRdf Graph object - public function cacheGraph() { - if (Cache::has($this->id . "_graph")) { - $graph = Cache::get($this->id . "_graph"); + public function cacheGraph() + { + if (Cache::has($this->id.'_graph')) { + $graph = Cache::get($this->id.'_graph'); } else { $graph = new \EasyRdf_Graph; - $suffix = ($this->filetype != 'ntriples' ) ? '.nt' : ''; - $graph->parseFile($this->resource->path() . $suffix, 'ntriples'); + $graph->parseFile($this->filenameSkosify(), 'ntriples'); $this->parsed = true; $this->save(); - Cache::forever($this->id . "_graph", $graph); + Cache::forever($this->id.'_graph', $graph); } + return $graph; } - public function getDirty() { + public function getDirty() + { $dirty = parent::getDirty(); return array_filter($dirty, function ($var) { - return !($var instanceof \Codesleeve\Stapler\Attachment); + return ! ($var instanceof \Codesleeve\Stapler\Attachment); }); } + public function filenameRapper() + { + return $this->resource->path().'_rappered.ttl'; + } + + public function filenameSkosify() + { + return $this->resource->path().'_skosified.nt'; + } } diff --git a/app/Http/Controllers/Auth/FacebookSocialAuthController.php b/app/Http/Controllers/Auth/FacebookSocialAuthController.php index 08c822c..243161a 100644 --- a/app/Http/Controllers/Auth/FacebookSocialAuthController.php +++ b/app/Http/Controllers/Auth/FacebookSocialAuthController.php @@ -1,9 +1,7 @@ redirect(); } - + /** * Obtain the user information from GitHub. * @@ -29,8 +27,7 @@ public function handleProviderCallback(SocialAccountService $service) { $user = $service->createOrGetUser(Socialite::driver('facebook')->user()); auth()->login($user); + return redirect()->to('/dashboard'); } - } - diff --git a/app/Http/Controllers/Auth/GithubSocialAuthController.php b/app/Http/Controllers/Auth/GithubSocialAuthController.php index 66cdd77..ab27e4f 100644 --- a/app/Http/Controllers/Auth/GithubSocialAuthController.php +++ b/app/Http/Controllers/Auth/GithubSocialAuthController.php @@ -1,9 +1,7 @@ redirect(); } - + /** * Obtain the user information from GitHub. * @@ -29,8 +27,7 @@ public function handleProviderCallback(SocialAccountService $service) { $user = $service->createOrGetUser(Socialite::driver('github')->user()); auth()->login($user); + return redirect()->to('/dashboard'); } - } - diff --git a/app/Http/Controllers/Auth/GoogleSocialAuthController.php b/app/Http/Controllers/Auth/GoogleSocialAuthController.php index 10c807e..1968344 100644 --- a/app/Http/Controllers/Auth/GoogleSocialAuthController.php +++ b/app/Http/Controllers/Auth/GoogleSocialAuthController.php @@ -1,9 +1,7 @@ redirect(); } - + /** * Obtain the user information from GitHub. * @@ -29,8 +27,7 @@ public function handleProviderCallback(SocialAccountService $service) { $user = $service->createOrGetUser(Socialite::driver('google')->user()); auth()->login($user); + return redirect()->to('/dashboard'); } - } - diff --git a/app/Http/Controllers/Auth/RegisterController.php b/app/Http/Controllers/Auth/RegisterController.php index 1af6d1c..42160f5 100644 --- a/app/Http/Controllers/Auth/RegisterController.php +++ b/app/Http/Controllers/Auth/RegisterController.php @@ -2,15 +2,15 @@ namespace App\Http\Controllers\Auth; -use App\User; use App\Http\Controllers\Controller; -use Illuminate\Support\Facades\Validator; +use App\User; +use Illuminate\Auth\Events\Registered; use Illuminate\Foundation\Auth\RegistersUsers; - use Illuminate\Http\Request; -use Illuminate\Auth\Events\Registered; +use Illuminate\Support\Facades\Validator; -class RegisterController extends Controller { +class RegisterController extends Controller +{ /* |-------------------------------------------------------------------------- | Register Controller @@ -22,7 +22,7 @@ class RegisterController extends Controller { | */ -use RegistersUsers; + use RegistersUsers; /** * Where to redirect users after registration. @@ -36,7 +36,8 @@ class RegisterController extends Controller { * * @return void */ - public function __construct() { + public function __construct() + { $this->middleware('guest'); } @@ -46,7 +47,8 @@ public function __construct() { * @param array $data * @return \Illuminate\Contracts\Validation\Validator */ - protected function validator(array $data) { + protected function validator(array $data) + { return Validator::make($data, [ 'name' => 'required|string|max:255', 'email' => 'required|string|email|max:255|unique:users', @@ -60,7 +62,8 @@ protected function validator(array $data) { * @param array $data * @return \App\User */ - protected function create(array $data) { + protected function create(array $data) + { return User::create([ 'name' => $data['name'], 'email' => $data['email'], @@ -68,7 +71,8 @@ protected function create(array $data) { ]); } - public function register(Request $request) { + public function register(Request $request) + { $this->validator($request->all())->validate(); $user = $this->create($request->all()); @@ -77,9 +81,7 @@ public function register(Request $request) { $this->guard()->login($user); - return $this->registered($request, $user) - ? : redirect($this->redirectPath()); + ?: redirect($this->redirectPath()); } - } diff --git a/app/Http/Controllers/CommentController.php b/app/Http/Controllers/CommentController.php index f719644..c768e4e 100644 --- a/app/Http/Controllers/CommentController.php +++ b/app/Http/Controllers/CommentController.php @@ -10,34 +10,34 @@ public function __construct() { $this->middleware('auth'); } - + public function show(Request $request) { $link = \App\Link::find($request->link_id); - + $comments = $link->comments; - - $response = array(); - foreach($comments as $comment){ + + $response = []; + foreach ($comments as $comment) { $user = $comment->user->name; - $avatar = $comment->user->avatar?:asset('/img/avatar04.png'); + $avatar = $comment->user->avatar ?: asset('/img/avatar04.png'); $text = $comment->body; $date = $comment->created_at; - array_push($response, ["user" => $user, - "avatar" => $avatar, - "text" => $text, - "date" => $date]); + array_push($response, ['user' => $user, + 'avatar' => $avatar, + 'text' => $text, + 'date' => $date, ]); } - - return response()->json($response); + + return response()->json($response); } - + public function create() { $input = request()->all(); - - $comment = \App\Comment::create( $input ); - + + $comment = \App\Comment::create($input); + $comment->save(); $link = $comment->link; @@ -46,8 +46,8 @@ public function create() return response()->json( [ - "message" => 'Comment posted succesfully!', - "count" => $count + 'message' => 'Comment posted succesfully!', + 'count' => $count, ]); } } diff --git a/app/Http/Controllers/Controller.php b/app/Http/Controllers/Controller.php index 03e02a2..a0a2a8a 100644 --- a/app/Http/Controllers/Controller.php +++ b/app/Http/Controllers/Controller.php @@ -2,10 +2,10 @@ namespace App\Http\Controllers; +use Illuminate\Foundation\Auth\Access\AuthorizesRequests; use Illuminate\Foundation\Bus\DispatchesJobs; -use Illuminate\Routing\Controller as BaseController; use Illuminate\Foundation\Validation\ValidatesRequests; -use Illuminate\Foundation\Auth\Access\AuthorizesRequests; +use Illuminate\Routing\Controller as BaseController; class Controller extends BaseController { diff --git a/app/Http/Controllers/CreatelinksController.php b/app/Http/Controllers/CreatelinksController.php index 22e4e26..b9055fb 100644 --- a/app/Http/Controllers/CreatelinksController.php +++ b/app/Http/Controllers/CreatelinksController.php @@ -2,18 +2,19 @@ namespace App\Http\Controllers; -use DB; -use Cache; -use Storage; use App\Project; +use Cache; +use DB; use Illuminate\Http\Request; use Illuminate\Http\Response; +use Storage; -class CreatelinksController extends Controller { - +class CreatelinksController extends Controller +{ use \App\RDFTrait; - - public function __construct() { + + public function __construct() + { $this->middleware('auth'); } @@ -22,26 +23,28 @@ public function __construct() { * * @return Response */ - public function index(Project $project) { + public function index(Project $project) + { $this->cacheOntologies(); - $nameSource = implode("_", ["project", $project->id, "source", $project->source->id, '']); - $nameTarget = implode("_", ["project", $project->id, "target", $project->target->id, '']); - $filenameS = 'json_serializer/' . $nameSource . ".json"; - $filenameT = 'json_serializer/' . $nameTarget . ".json"; - $_SESSION["source_json"] = $filenameS; - $_SESSION["target_json"] = $filenameT; + $nameSource = implode('_', ['project', $project->id, 'source', $project->source->id, '']); + $nameTarget = implode('_', ['project', $project->id, 'target', $project->target->id, '']); + $filenameS = 'json_serializer/'.$nameSource.'.json'; + $filenameT = 'json_serializer/'.$nameTarget.'.json'; + $_SESSION['source_json'] = $filenameS; + $_SESSION['target_json'] = $filenameT; $groups = $this->getGroups(); + return view('createlinks', ['project' => $project, 'groups'=>$groups, ]); - } + } - private function cacheOntologies(){ - if(Cache::has('ontologies_graph')){ - return "Ontologies already on Cache"; - } - else{ + private function cacheOntologies() + { + if (Cache::has('ontologies_graph')) { + return 'Ontologies already on Cache'; + } else { $graph1 = new \EasyRdf_Graph; $graph1->parseFile(storage_path('app/ontologies/owl.rdf')); @@ -54,75 +57,82 @@ private function cacheOntologies(){ $graph1_2 = $this->mergeGraphs($graph1, $graph2); $merged_graph = $this->mergeGraphs($graph1_2, $graph3); - Cache::forever( 'ontologies_graph', $merged_graph); - return "Ontologies Cached"; + Cache::forever('ontologies_graph', $merged_graph); + + return 'Ontologies Cached'; } } - public function json_serializer($file) { - try{ - $jsonfile = Storage::disk('public')->get('json_serializer/' . $file); - } - catch (\Exception $ex){ + public function json_serializer($file) + { + try { + $jsonfile = Storage::disk('public')->get('json_serializer/'.$file); + } catch (\Exception $ex) { dd($ex); } + return (new Response($jsonfile, 200)) ->header('Content-Type', 'application/json'); } - public function infobox(Request $request) { + public function infobox(Request $request) + { $project = Project::find($request->project_id); $dump = $request->dump; - $file = $project->$dump; + $file = $project->$dump; $graph = $file->cacheGraph(); - $uri = urldecode($request["uri"]); - $result = $graph->dumpResource($uri, "html"); + $uri = urldecode($request['uri']); + $result = $graph->dumpResource($uri, 'html'); + return $result; } - public function short_infobox(Request $request) { + public function short_infobox(Request $request) + { $project = Project::find($request->project_id); $dump = $request->dump; $file = $project->$dump; - $graph_name = $file->id . "_graph"; + $graph_name = $file->id.'_graph'; $graph = Cache::get($graph_name); - $uri = urldecode($request["uri"]); + $uri = urldecode($request['uri']); $prefLabel = $this->label($graph, $uri); - $collapsed = isset($request->collapsed) ? ($request->collapsed === "true" ? "plus" : "minus") : "plus"; - $details = CreatelinksController::infobox($request); - return view('createlinks.partials.info',['header'=> $prefLabel, 'dump'=>$request["dump"], "details"=>$details, "collapsed"=>$collapsed]); + $collapsed = isset($request->collapsed) ? ($request->collapsed === 'true' ? 'plus' : 'minus') : 'plus'; + $details = self::infobox($request); + + return view('createlinks.partials.info', ['header'=> $prefLabel, 'dump'=>$request['dump'], 'details'=>$details, 'collapsed'=>$collapsed]); } - public function comparison(Request $request, Project $project) { + public function comparison(Request $request, Project $project) + { $iri = urldecode($request['url']); - $graph_name = $project->target->id . "_graph"; + $graph_name = $project->target->id.'_graph'; $graph = Cache::get($graph_name); - $scores = Cache::get("scores_graph_project" . $project->id); - $candidates = []; + $scores = Cache::get('scores_graph_project'.$project->id); + $candidates = []; try { - if($scores){ - $results = $scores->resourcesMatching("http://knowledgeweb.semanticweb.org/heterogeneity/alignment#entity1", new \EasyRdf_Resource($iri)); - } - else{ - return view('createlinks.partials.comparison', ["candidates"=>$candidates]); + if ($scores) { + $results = $scores->resourcesMatching('http://knowledgeweb.semanticweb.org/heterogeneity/alignment#entity1', new \EasyRdf_Resource($iri)); + } else { + return view('createlinks.partials.comparison', ['candidates'=>$candidates]); } foreach ($results as $result) { - $target = $scores->get($result, new \EasyRdf_Resource("http://knowledgeweb.semanticweb.org/heterogeneity/alignment#entity2")); - $score = $scores->get($result, new \EasyRdf_Resource("http://knowledgeweb.semanticweb.org/heterogeneity/alignment#measure"))->getValue(); + $target = $scores->get($result, new \EasyRdf_Resource('http://knowledgeweb.semanticweb.org/heterogeneity/alignment#entity2')); + $score = $scores->get($result, new \EasyRdf_Resource('http://knowledgeweb.semanticweb.org/heterogeneity/alignment#measure'))->getValue(); $label = $this->label($graph, $target); - $class = ( $score < 0.3 ) ? "low" : (( $score >= 0.3 && $score < 0.8 ) ? "medium" : "high"); + $class = ($score < 0.3) ? 'low' : (($score >= 0.3 && $score < 0.8) ? 'medium' : 'high'); $candidate = [ - "target" => $target, - "score" => $score, - "label" => $label, - "class" => $class, + 'target' => $target, + 'score' => $score, + 'label' => $label, + 'class' => $class, ]; array_push($candidates, $candidate); } } catch (\Exception $ex) { - logger("empty candidates: " . $ex); - } - return view('createlinks.partials.comparison', ["candidates"=>$candidates]); + logger('empty candidates: '.$ex); + } + + return view('createlinks.partials.comparison', ['candidates'=>$candidates]); } public function getGroups() @@ -133,6 +143,7 @@ public function getGroups() ->orWhere('user_id', '=', $user) ->distinct() ->get(); + return $select; } -} \ No newline at end of file +} diff --git a/app/Http/Controllers/DashboardController.php b/app/Http/Controllers/DashboardController.php index cb202b3..35150d5 100644 --- a/app/Http/Controllers/DashboardController.php +++ b/app/Http/Controllers/DashboardController.php @@ -7,12 +7,8 @@ namespace App\Http\Controllers; -use App\Http\Requests; -use Illuminate\Http\Request; - /** - * Class DashboardController - * @package App\Http\Controllers + * Class DashboardController. */ class DashboardController extends Controller { @@ -35,4 +31,4 @@ public function index() { return view('dashboard'); } -} \ No newline at end of file +} diff --git a/app/Http/Controllers/FileController.php b/app/Http/Controllers/FileController.php index 739cbcd..cd6ca49 100644 --- a/app/Http/Controllers/FileController.php +++ b/app/Http/Controllers/FileController.php @@ -2,9 +2,8 @@ namespace App\Http\Controllers; -use Illuminate\Http\Request; - use App\File; +use Illuminate\Http\Request; class FileController extends Controller { @@ -19,11 +18,12 @@ public function __construct() * @return Response */ public function mygraphs() - { + { $user = auth()->user(); - return view('files.index',["user"=>$user, "files"=>$user->userGraphs()]); - } - + + return view('files.index', ['user'=>$user, 'files'=>$user->userGraphs()]); + } + public function store() { $input = request()->all(); @@ -31,50 +31,54 @@ public function store() 'resource' => 'file', 'resource_url' => 'url', ])->validate(); - if($input["resource_url"] !== null){ - $input["resource"] = $input["resource_url"]; + if ($input['resource_url'] !== null) { + $input['resource'] = $input['resource_url']; } - $file = File::create( $input ); + $file = File::create($input); + return redirect()->route('mygraphs')->with('notification', 'File Uploaded!!!'); } - + public function show() { $id = request('file'); $file = File::find($id); - return view('files.edit', ["file" => $file]); + + return view('files.edit', ['file' => $file]); } - - + public function update() { $input = request()->all(); - + $file = File::find($input['id']); - - $file->public = $input['public']; - + + $file->public = $input['public']; + $file->filetype = $input['filetype']; - + $file->save(); - + return redirect()->route('mygraphs')->with('notification', 'File updated!!!'); } - + public function destroy(File $file) { $this->authorize('destroy', $file); $file->delete(); + return redirect()->route('mygraphs')->with('notification', 'File Deleted!!!'); } - - public function download(Request $request, File $file){ + + public function download(Request $request, File $file) + { return $file->download($request->format); } - + public function parse(File $file) { dispatch(new \App\Jobs\Parse($file, auth()->user())); + return redirect()->back()->with('notification', 'Parsing Job Dispatched, check your logs.'); - } + } } diff --git a/app/Http/Controllers/HomeController.php b/app/Http/Controllers/HomeController.php index 4d765e7..05ae6dd 100644 --- a/app/Http/Controllers/HomeController.php +++ b/app/Http/Controllers/HomeController.php @@ -2,20 +2,15 @@ namespace App\Http\Controllers; -use Illuminate\Http\Request; - -use App\Http\Requests; - -use App\Link; - class HomeController extends Controller { - public function welcome(){ + public function welcome() + { return view('welcome'); } - - public function about(){ - + + public function about() + { return view('about'); } } diff --git a/app/Http/Controllers/LabelExtractorController.php b/app/Http/Controllers/LabelExtractorController.php index 7c6576a..a58db62 100644 --- a/app/Http/Controllers/LabelExtractorController.php +++ b/app/Http/Controllers/LabelExtractorController.php @@ -2,12 +2,8 @@ namespace App\Http\Controllers; -use App\Http\Requests; -use App\Http\Controllers\Controller; - use App\LabelExtractor; use Illuminate\Http\Request; -use Carbon\Carbon; use Session; class LabelExtractorController extends Controller @@ -41,9 +37,8 @@ public function create() */ public function store(Request $request) { - LabelExtractor::create($request->all()); - + Session::flash('flash_message', 'LabelExtractor added!'); return redirect('label-extractor'); @@ -86,7 +81,6 @@ public function edit($id) */ public function update($id, Request $request) { - $labelextractor = LabelExtractor::findOrFail($id); $labelextractor->update($request->all()); @@ -109,6 +103,5 @@ public function destroy($id) Session::flash('flash_message', 'LabelExtractor deleted!'); return redirect('label-extractor'); - } - + } } diff --git a/app/Http/Controllers/LinkController.php b/app/Http/Controllers/LinkController.php index b30241b..75e47ce 100644 --- a/app/Http/Controllers/LinkController.php +++ b/app/Http/Controllers/LinkController.php @@ -2,18 +2,17 @@ namespace App\Http\Controllers; -use Illuminate\Http\Request; -use App\User; use App\Link; use App\Project; use Auth; -use Yajra\Datatables\Datatables; use Cache; -use Carbon\Carbon; - -class LinkController extends Controller { +use Illuminate\Http\Request; +use Yajra\Datatables\Datatables; - public function __construct() { +class LinkController extends Controller +{ + public function __construct() + { $this->middleware('auth'); } @@ -22,158 +21,102 @@ public function __construct() { * * @return Response */ - public function index() { + public function index() + { $user = Auth::user(); - - - $projects = \App\Project::where("user_id", "=", $user->id) - ->orWhere("public", "=", TRUE) - ->get(); - $select = []; - foreach ($projects as $project) { - - $key = $project->id; - $value = $project->name; - $select = array_add($select, $key, $value); - - } - + return view('mylinks', [ - "user" => $user, - "projects" => $projects, - "select" => $select, + 'user' => $user, + 'projects' => $user->userAccessibleProjects(), + ]); } - public function project_links(Request $request) { - session_start(); + public function export(Request $request) + { + $user = Auth::user(); + $project_id = $request->project_id; + $graph = Link::linkGraph($user, $project_id); + $format = $request->format; + Link::exportFile($graph, $format, $project_id); + } + + public function exportVoted(Request $request) + { + $project_id = $request->project_id; + $graph = Link::createGraph(Link::votedLinks($request)); + $format = $request->filetype; + Link::exportFile($graph, $format, $project_id); + } + + public function projectLinks(Request $request) + { $project = Project::find($request->project_id); - return view('links.link_table', ["project" => $project]); + + return view('links.link_table', ['project' => $project]); } - public function connected(Request $request) { - session_start(); + public function connected(Request $request) + { $project = Project::find($request->project_id); $type = $request->type; $links = $project->links; - $connected = array(); - $entity = $type . '_entity'; + $connected = []; + $entity = $type.'_entity'; foreach ($links as $link) { array_push($connected, $link->$entity); } array_unique($connected, SORT_REGULAR); + return json_encode($connected); } - public function create(Request $request) { - $input = request()->all(); - $project = Project::find($request->project_id); - $previous = Link::where('project_id', '=', $request->project_id) - ->where('source_entity', '=', $request->source) - ->where('target_entity', '=', $request->target) - ->where('link_type', '=', $request->link_type) - ->first(); - if ($previous == null) { - $link = Link::create($input); - $link->project_id = $request->project_id; - $link->user_id = auth()->user()->id; - $link->source_id = $project->source_id; - $link->target_id = $project->target_id; - $link->source_entity = $request->source; - $link->target_entity = $request->target; - $link->link_type = $request->link_type; - $link->save(); + public function create(Request $request) + { + if (Link::existing($request) == null) { + Link::create($request, request()->all()); + return 1; } else { - return 0; } } - - public function import(){ - $import = \App\Import::create(request()->all()); - $result = $this->import_links($import); - if($import->imported){ - return \Illuminate\Support\Facades\Redirect::back()->with('notification', 'Links Imported!!!'); - } - else{ - return \Illuminate\Support\Facades\Redirect::back()->with('error', 'An error Occured. Could not import Links!!!' . $result); - } - - } - - public function convert(\App\Import $import){ - $command = 'rapper -i ' . $import->filetype . ' -o rdfxml-abbrev ' . $import->resource->path() . ' > ' . $import->resource->path(). '.rdf'; - $out = []; - logger($command); - exec( $command, $out); - logger(var_dump($out)); - return; - } - public function import_links(\App\Import $import) { - $graph = new \EasyRdf_Graph(); - try{ - if($import->filetype != 'rdfxml'){ - $this->convert($import); - $graph->parseFile($import->resource->path() . '.rdf', 'rdfxml'); - } - else{ - $graph->parseFile($import->resource->path(), 'rdfxml'); - } - $import->parsed = true; - $import->save(); - } catch (\Exception $ex) { - $import->parsed = false; - $import->save(); - return "Fail to parse file. Check filetype or valid syntax. Error:" . $ex; - } - $resources = $graph->resources(); - foreach ($resources as $resource) { - $properties = $resource->propertyUris(); - foreach ($properties as $property) { - $links = $resource->allResources(new \EasyRdf_Resource($property)); - foreach ($links as $link) { - $data = [ - "source" => $resource->getUri(), - "target" => $link->getUri(), - "link_type" => $property, - "project_id" => $import->project_id, - ]; - $request = \Illuminate\Support\Facades\Request::create("/", "GET", $data); - echo $this->create($request); - } - } + public function import() + { + $import = \App\Import::create(request()->all()); + $import->import_links($import); + if ($import->imported) { + return redirect()->back()->with('notification', 'Links Imported!!!'); + } else { + return redirect()->back()->with('error', 'An error Occured. Could not import Links!!!'.$result); } - $import->imported = true; - $import->save(); } - public function destroy(Request $request) { + public function destroy(Request $request) + { $link = \App\Link::find($request->id); - try{ + try { $this->authorize('destroy', $link); $link->delete(); $data = [ - "priority" => "success", - "title" => "Success", - "message" => "Link Deleted!!!" + 'priority' => 'success', + 'title' => 'Success', + 'message' => 'Link Deleted!!!', ]; - return response()->json($data); } catch (\Exception $ex) { $data = [ - "priority" => "error", - "title" => "Error", - "message" => "You are not authorized to delete this link!" + 'priority' => 'error', + 'title' => 'Error', + 'message' => 'You are not authorized to delete this link!', ]; - return response()->json($data); } - - - } - public function delete_all(Request $request) { + return response()->json($data); + } + public function deleteAll(Request $request) + { $project = Project::find($request->project_id); //dd($project); $links = $project->links; @@ -181,163 +124,60 @@ public function delete_all(Request $request) { // $this->authorize('destroy', $link); $link->delete(); } - return \Illuminate\Support\Facades\Redirect::back()->with('notification', 'All Links Deleted!!!'); - } - - public function CreateRDFGraph(User $user, $project_id) { - $myGraph = new \EasyRdf_Graph; - $project = Project::find($project_id); - //dd($project); - if ($project == null) { - foreach ($user->projects as $project) { - $links = $project->links; - foreach ($links as $link) { - $myGraph->addResource($link->source_entity, $link->link_type, $link->target_entity); - } - } - } else { - $links = $project->links; - foreach ($links as $link) { - $myGraph->addResource($link->source_entity, $link->link_type, $link->target_entity); - } - } - return $myGraph; - } - public function CreateRDFGraph2($links) { - $myGraph = new \EasyRdf_Graph; - foreach ($links as $link) { - $myGraph->addResource($link->source_entity, $link->link_type, $link->target_entity); - } - return $myGraph; + return redirect()->back()->with('notification', 'All Links Deleted!!!'); } - public function export(Request $request) { - $user = \Illuminate\Support\Facades\Auth::user(); - $project_id = $request->project_id; - if (!is_numeric($project_id) && !empty($project_id)) { - $project = Project::where('name', '=', $project_id)->first(); - $project_id = $project->id; - } - $myGraph = LinkController::CreateRDFGraph($user, $project_id); - $format = $request->format; - LinkController::CreateRDFFile($myGraph, $format, $project_id); - } - - public function export_voted(Request $request) { - $project_id = $request->project_id; - $links = \App\Link::where("project_id", "=", $request->project_id) - ->when(isset($request->score), function($query) use ($request) { - return $query->where('score', '>', $request->score); - }) - ->get(); - $links = $links->filter(function($link) { - return $this->confidence($link) >= request("threshold") / 100; - }); - $myGraph = $this->CreateRDFGraph2($links); - $format = $request->filetype; - $this->CreateRDFFile($myGraph, $format, $project_id); - } - - public function confidence(Link $link) { - $upVotes = $link->up_votes; - $downVotes = $link->down_votes; - $totalVotes = $upVotes + $downVotes; - if ($totalVotes > 0) { - return (double) $upVotes / $totalVotes; - } else { - return 0; - } - } - - function DownloadFile($file, $name, $format) { // $file = include path - if (file_exists($file)) { - header('Content-Description: File Transfer'); - header('Content-Disposition: attachment; filename=' . $name); - header('Content-Transfer-Encoding: binary'); - header('Expires: 0'); - header('Cache-Control: must-revalidate, post-check=0, pre-check=0'); - header('Pragma: public'); - header('Content-Length: ' . filesize($file)); - header('Content-Type: ' . $format); - ob_clean(); - flush(); - readfile($file); - unlink($file); - exit; - } - } - - function CreateRDFFile($myGraph, $format, $project_id) { - $export = $myGraph->serialise($format); - $project = Project::find($project_id); - - $File_Ext = \EasyRdf_Format::getFormat($format)->getDefaultExtension(); //get file extention - $dt = Carbon::now(); - $time = str_slug($dt->format("Y m d His")); - if ($project_id == null) { - $File_Name = "Export" . $time . "." . $File_Ext; - $NewFileName = storage_path() . "/app/projects/" . $File_Name; - file_put_contents($NewFileName, $export); - } else { - $File_Name = "Alignment_Export_" . str_slug($project->name) ."_" . $time . "." . $File_Ext; - $NewFileName = storage_path() . "/app/projects/project" . $project_id . "/" . $File_Name; - file_put_contents($NewFileName, $export); - } - LinkController::DownLoadFile($NewFileName, $File_Name, $format); - } - - public function ajax() { + public function ajax() + { $prefixes = \App\Prefix::all(); foreach ($prefixes as $prefix) { \EasyRdf_Namespace::set($prefix->prefix, $prefix->namespace); } $project = \App\Project::find(request()->project); - if(request()->route == "mylinks"){ - $links = Link::where("project_id", "=", $project->id) - ->where("user_id", "=", auth()->user()->id) - ->orderBy("created_at", "desc")->get(); + if (request()->route == 'mylinks') { + $links = Link::where('project_id', '=', $project->id) + ->where('user_id', '=', auth()->user()->id) + ->orderBy('created_at', 'desc')->get(); + } else { + $links = Link::where('project_id', '=', $project->id)->orderBy('created_at', 'desc')->get(); } - else{ - $links = Link::where("project_id", "=", $project->id)->orderBy("created_at", "desc")->get(); - } $source_graph = $project->source->cacheGraph(); $target_graph = $project->target->cacheGraph(); $ontologies_graph = Cache::get('ontologies_graph'); + return Datatables::of($links) - ->addColumn('source', function($link) use($source_graph) { - return view("links.resource", [ - "resource" => $link->source_entity, - "graph" => $source_graph, + ->addColumn('source', function ($link) use ($source_graph) { + return view('links.resource', [ + 'resource' => $link->source_entity, + 'graph' => $source_graph, ]); }) - ->addColumn('target', function($link) use ($target_graph) { - return view("links.resource", [ - "resource" => $link->target_entity, - "graph" => $target_graph, + ->addColumn('target', function ($link) use ($target_graph) { + return view('links.resource', [ + 'resource' => $link->target_entity, + 'graph' => $target_graph, ]); }) - ->addColumn('link', function($link) use ($ontologies_graph) { - return view("links.resource", [ - "resource" => $link->link_type, - "graph" => $ontologies_graph, + ->addColumn('link', function ($link) use ($ontologies_graph) { + return view('links.resource', [ + 'resource' => $link->link_type, + 'graph' => $ontologies_graph, ]); }) - ->addColumn('action', function($link) { - if($link->user_id == auth()->user()->id || $link->project->user->id == auth()->user()->id){ - $class = "btn"; - } - else{ - $class = "btn disabled"; + ->addColumn('action', function ($link) { + if ($link->user_id == auth()->user()->id || $link->project->user->id == auth()->user()->id) { + $class = 'btn'; + } else { + $class = 'btn disabled'; } - return ''; - + + return ''; }) - ->addColumn('project', function($link) { + ->addColumn('project', function ($link) { return $link->project->name; }) ->rawColumns(['source', 'target', 'link', 'action']) ->make(true); } - } diff --git a/app/Http/Controllers/LinkTypeController.php b/app/Http/Controllers/LinkTypeController.php index b9d89ca..138eac7 100644 --- a/app/Http/Controllers/LinkTypeController.php +++ b/app/Http/Controllers/LinkTypeController.php @@ -2,13 +2,8 @@ namespace App\Http\Controllers; -use Illuminate\Http\Request; - use Auth; - -Use DB; -use Illuminate\Support\Facades\Storage; - +use Illuminate\Http\Request; class LinkTypeController extends Controller { @@ -24,38 +19,34 @@ public function __construct() */ public function index() { - } - - - + public function getInstances($group) { $inputs = \App\LinkType::where('group', '=', $group) - ->where( function($query){ + ->where(function ($query) { $user = auth()->user(); $query->where('public', '=', 'true') ->orWhere('user_id', '=', $user); } ) ->get(); + return $inputs; } - - public function updateForm(Request $request){ + + public function updateForm(Request $request) + { $group = $request->group; - if(!\Illuminate\Support\Facades\Cache::has($group. '.ontology')){ + if (! \Illuminate\Support\Facades\Cache::has($group.'.ontology')) { $graph = new \EasyRdf_Graph(); - $graph->parseFile(storage_path() . "/app/ontologies/" . mb_strtolower($group) . '.rdf', 'rdfxml'); - \Illuminate\Support\Facades\Cache::put($group. '.ontology', $graph); - } - else{ - $graph = \Illuminate\Support\Facades\Cache::get($group. '.ontology'); + $graph->parseFile(storage_path().'/app/ontologies/'.mb_strtolower($group).'.rdf', 'rdfxml'); + \Illuminate\Support\Facades\Cache::put($group.'.ontology', $graph); + } else { + $graph = \Illuminate\Support\Facades\Cache::get($group.'.ontology'); } $instances = $this->getInstances($group); - return view('createlinks.partials.linkinput',["instances" => $instances, "graph" => $graph]); - } - + return view('createlinks.partials.linkinput', ['instances' => $instances, 'graph' => $graph]); + } } - diff --git a/app/Http/Controllers/PollController.php b/app/Http/Controllers/PollController.php index 779b356..9371669 100644 --- a/app/Http/Controllers/PollController.php +++ b/app/Http/Controllers/PollController.php @@ -4,79 +4,81 @@ use Illuminate\Http\Request; -use App\Http\Requests; - -use DB; - class PollController extends Controller { public function __construct() { $this->middleware('auth'); } - - public function index(){ + + public function index() + { $projects = \App\Project::where('public', '=', '1')->get(); - return view('voteApp.index', ["projects" => $projects]); + + return view('voteApp.index', ['projects' => $projects]); } - - public function projects(){ + + public function projects() + { return \App\Project::all(); } - - public function project($id){ + + public function project($id) + { return \App\Project::find($id); } - - public function getAvailableLinks(){ - + + public function getAvailableLinks() + { + //get all users votes - $userVotes = \App\Vote::where("user_id", "=", request()->user)->get(); - + $userVotes = \App\Vote::where('user_id', '=', request()->user)->get(); + //filter invalid votes - $validVotes = $userVotes->reject(function( $value, $key){ - return \App\Link::find($value->link_id) == null ; + $validVotes = $userVotes->reject(function ($value, $key) { + return \App\Link::find($value->link_id) == null; }); - + //filter votes on the particular project - $projectVotes = $validVotes->reject(function($value, $key){ - return \App\Link::find($value->link_id)->project->id != request()->project; + $projectVotes = $validVotes->reject(function ($value, $key) { + return \App\Link::find($value->link_id)->project->id != request()->project; }); - - $votedLinks = $projectVotes->map(function($value, $key){ - return $value->link_id; + + $votedLinks = $projectVotes->map(function ($value, $key) { + return $value->link_id; }); - - $links = \App\Link::where("project_id", "=", request()->project) - ->whereNotIn("id", $votedLinks)->get(); - + + $links = \App\Link::where('project_id', '=', request()->project) + ->whereNotIn('id', $votedLinks)->get(); + return $links; } - - public function createPoll(){ + + public function createPoll() + { $available = $this->getAvailableLinks(); - if ($available->count() != 0){ + if ($available->count() != 0) { $pool = $available->shuffle(); + return $pool->chunk(50)[0]; + } else { + return; } - else{ - return null; - } - } - - public function getPoll(){ + + public function getPoll() + { $project = \App\Project::find(request()->project); $candidates = $this->createPoll(); - if($candidates != null){ + if ($candidates != null) { $project->source->cacheGraph(); $project->target->cacheGraph(); } - return view('voteApp.partials.poll', + + return view('voteApp.partials.poll', [ - "candidates" => $candidates, - "project" => $project - ]); + 'candidates' => $candidates, + 'project' => $project, + ]); } - } diff --git a/app/Http/Controllers/ProfileController.php b/app/Http/Controllers/ProfileController.php index 59555a1..f6154ca 100644 --- a/app/Http/Controllers/ProfileController.php +++ b/app/Http/Controllers/ProfileController.php @@ -7,12 +7,8 @@ namespace App\Http\Controllers; -use App\Http\Requests; -use Illuminate\Http\Request; - /** - * Class DashboardController - * @package App\Http\Controllers + * Class DashboardController. */ class ProfileController extends Controller { @@ -34,30 +30,35 @@ public function __construct() public function index($id) { $user = \App\User::find($id); - if($user == null){ + if ($user == null) { abort(404); } $upvotes = $this->user_upvotes($user); $downvotes = $this->user_downvotes($user); - return view('profile', + + return view('profile', [ 'user_profile'=>$user, 'upvotes' => $upvotes, 'downvotes' => $downvotes, ]); } - - public function user_upvotes(\App\User $user){ + + public function user_upvotes(\App\User $user) + { $votes = \App\Vote::where('user_id', '=', $user->id) ->where('vote', '=', '1') ->get(); - return sizeof($votes); + + return count($votes); } - - public function user_downvotes(\App\User $user){ + + public function user_downvotes(\App\User $user) + { $votes = \App\Vote::where('user_id', '=', $user->id) ->where('vote', '=', '-1') ->get(); - return sizeof($votes); + + return count($votes); } -} \ No newline at end of file +} diff --git a/app/Http/Controllers/ProjectController.php b/app/Http/Controllers/ProjectController.php index 077128a..943b135 100644 --- a/app/Http/Controllers/ProjectController.php +++ b/app/Http/Controllers/ProjectController.php @@ -2,17 +2,17 @@ namespace App\Http\Controllers; -use Illuminate\Http\Request; -use App\Http\Requests; -use App\User; -use App\Project; use App\File; -use App\Link; +use App\Jobs\InitiateCalculations; +use App\Project; +use App\User; use Auth; +use Illuminate\Http\Request; -class ProjectController extends Controller { - - public function __construct() { +class ProjectController extends Controller +{ + public function __construct() + { $this->middleware('auth'); } @@ -21,39 +21,36 @@ public function __construct() { * * @return Response */ - public function index() { + public function index() + { $user = Auth::user(); - return view('myprojects', ["user" => $user]); + + return view('myprojects', ['user' => $user]); } - public function create(Request $request) { + public function create(Request $request) + { $input = request()->all(); - $this->validate($request, [ - 'name' => 'required|unique:projects|max:255' + 'name' => 'required|unique:projects|max:255', ]); - $project = Project::create($input); - $source = $project->source; - $target = $project->target; - $source->projects()->attach($project->id); $target->projects()->attach($project->id); return redirect()->route('myprojects')->with('notification', 'Project created!!!'); } - public function show() { + public function show() + { $id = request('project'); $project = Project::find($id); - //find valid files to create a project - $user = \App\User::find($project->user_id); - $files = $user->files; - $select = array(); - foreach ($files as $file) { + $user = User::find($project->user_id); + $select = []; + foreach ($user->files as $file) { if ($file->parsed) { $key = $file->id; $value = $file->resource_file_name; @@ -61,8 +58,7 @@ public function show() { } } //public files addition - $files = \App\File::where('public', '=', '1')->get(); - foreach ($files as $file) { + foreach (File::where('public', '=', '1')->get() as $file) { if ($file->parsed) { $key = $file->id; $value = $file->resource_file_name; @@ -70,37 +66,51 @@ public function show() { } } - return view('projects.edit', ["project" => $project, - "select" => $select, + return view('projects.edit', ['project' => $project, + 'select' => $select, ]); } - public function update(Request $request) { + public function update(Request $request) + { $input = request()->all(); $project = Project::find($input['id']); - + $this->validate($request, [ - 'name' => 'required|unique:projects,name,'.$project->id .'|max:255' + 'name' => 'required|unique:projects,name,'.$project->id.'|max:255', ]); - + $project->fill($input)->save(); return redirect()->route('myprojects')->with('notification', 'Project updated!!!'); } - public function destroy(Request $request, Project $project) { + public function destroy(Request $request, Project $project) + { $this->authorize('destroy', $project); - $project_links = $project->links; - foreach ($project_links as $link) { $link->delete(); } - $project->delete(); return redirect()->route('myprojects')->with('notification', 'Project Deleted!!!'); } + public function prepareProject($id) + { + $project = Project::find($id); + $provider = $project->settings->provider; + $user = auth()->user(); + InitiateCalculations::withChain([ + new $provider->job($project, $user), + new \App\Jobs\ParseScores($project, $user), + new \App\Jobs\Convert($project, $user, 'source'), + new \App\Jobs\Convert($project, $user, 'target'), + new \App\Jobs\ProjectReady($project, $user), + ])->dispatch($project, $provider, $user); + + return redirect()->route('myprojects')->with('notification', 'Project calculations initiated!!!'); + } } diff --git a/app/Http/Controllers/SSEController.php b/app/Http/Controllers/SSEController.php index a1d98fb..302e8f6 100644 --- a/app/Http/Controllers/SSEController.php +++ b/app/Http/Controllers/SSEController.php @@ -4,56 +4,60 @@ use Illuminate\Http\Request; -use App\Http\Requests; - class SSEController extends Controller { - public function __construct() { + public function __construct() + { $this->middleware('auth'); } - public function sse() { + public function sse() + { //support for firefox - - $response = new \Symfony\Component\HttpFoundation\StreamedResponse(function() { - - $data = $this->getData(); - if ($data != null) { - echo 'data: ' . json_encode($data) . "\n\n"; - ob_flush(); - flush(); - } - + + $response = new \Symfony\Component\HttpFoundation\StreamedResponse(function () { + $data = $this->getData(); + if ($data != null) { + echo 'data: '.json_encode($data)."\n\n"; + ob_flush(); + flush(); + } }); $response->headers->set('Content-Type', 'text/event-stream'); + return $response; } - public function getData(){ + public function getData() + { $user = auth()->user()->id; $notification = \App\Notification::where('user_id', '=', $user) ->where('read', '=', 0) ->first(); + return $notification; } - - public function get(){ + + public function get() + { $user = auth()->user()->id; $notifications = \App\Notification::where('user_id', '=', $user) ->where('read', '=', 0) ->get(); - return view('layouts.partials.notifications', ["notifications" => $notifications]); + + return view('layouts.partials.notifications', ['notifications' => $notifications]); } - - public function read(Request $request){ + + public function read(Request $request) + { $user = auth()->user()->id; - + $notification = \App\Notification::where('user_id', '=', $user) ->where('read', '=', '0') ->first(); $notification->read = true; $notification->save(); + return $user; } - } diff --git a/app/Http/Controllers/SettingsController.php b/app/Http/Controllers/SettingsController.php index 481f502..5bd2957 100644 --- a/app/Http/Controllers/SettingsController.php +++ b/app/Http/Controllers/SettingsController.php @@ -2,17 +2,16 @@ namespace App\Http\Controllers; -use App\Settings; -use App\Project; use App\Models\SuggestionConfigurations\SilkConfiguration; +use App\Settings; use Auth; use Illuminate\Database\Eloquent\ModelNotFoundException; -use Storage; use Yajra\Datatables\Datatables; -class SettingsController extends Controller { - - public function __construct() { +class SettingsController extends Controller +{ + public function __construct() + { $this->middleware('web'); } @@ -21,720 +20,89 @@ public function __construct() { * * @return Response */ - public function index() { - + public function index() + { $user = Auth::user(); $providers = \App\Models\SuggestionProvider::all(); - return view('settings', ["user" => $user, "providers" => $providers]); + return view('settings', ['user' => $user, 'providers' => $providers]); } - public function create() { - $input = request()->all(); - $input = array_filter($input); + public function create() + { + $input = array_filter(request()->all()); $settings = Settings::create($input); $settings->provider->validate($settings); + return redirect()->route('settings')->with('notification', 'Settings Created!!!'); } - public function destroy() { + public function destroy() + { $id = request()->id; Settings::destroy($id); - return "Settings with id " . $id . " was deleted"; + return 'Settings with id '.$id.' was deleted'; } - public function render() { - $file = "/app/projects/default_config.xml"; - $filename = storage_path() . $file; + public function render() + { + $file = '/app/projects/default_config.xml'; + $filename = storage_path().$file; $xml = file_get_contents($filename); $silk = new SilkConfiguration(); if ($silk->validateSchema($file)) { $result = $silk->parseXML($xml); } else { - return "Validation error. Your settings file is not a valid Silk LSL settings file"; + return 'Validation error. Your settings file is not a valid Silk LSL settings file'; } foreach ($silk->nodes as $node) { dd($silk->getNode($result, $node)); } } - public function export(){ + public function export() + { $setting = Settings::find(request()->id); return response()->download($setting->resource->path()); - } - public function copy(){ + public function copy() + { $setting = Settings::find(request()->id); return response()->download($setting->resource->path()); - } - public function errors() { - try{ - $validation = \App\ValidationError::where("setting_id", "=", request()->id)->latest()->firstOrFail(); - } - catch (ModelNotFoundException $e){ - return "There is no errors Found"; + public function errors() + { + try { + $validation = \App\ValidationError::where('setting_id', '=', request()->id)->latest()->firstOrFail(); + } catch (ModelNotFoundException $e) { + return 'There is no errors Found'; } $bag = json_decode($validation->bag); $valid = $bag->valid; $errors = $bag->errors; - return view('settings.partials.validation', [ - "validation" => $validation, - "valid" => $valid, - "errors" => $errors - ]); - - } - public function create_config($project_id) { - $project = Project::find($project_id); - $project->processed = 0; - $project->save(); - $provider = $project->settings->provider; - $provider->prepare($project); - \App\Notification::create([ - "message" => $provider->name . ' Config File Created succesfully.', - "user_id" => auth()->user()->id, - "project_id" => $project->id, - "status" => 1, + return view('settings.partials.validation', [ + 'validation' => $validation, + 'valid' => $valid, + 'errors' => $errors, ]); - dispatch(new $provider->job($project, auth()->user())); - return redirect()->route('myprojects')->with('notification', 'SiLK Config File Created succesfully!!!'); } - public function ajax() { + public function ajax() + { $settings = Settings::select(['id', 'name', 'public', 'valid']); return Datatables::of($settings) - ->addColumn('action', function($setting) { - return view("settings.partials.actions", [ - "setting" => $setting + ->addColumn('action', function ($setting) { + return view('settings.partials.actions', [ + 'setting' => $setting, ]); }) ->make(true); } - - public function updateDefault(Project $project) { - Storage::disk("projects")->makeDirectory("project" . $project->id); - $filename = storage_path() . "/app/projects/default_config.xml"; - $suffix1 = ($project->source->filetype != 'ntriples' ) ? '.nt' : ''; - $source = file_get_contents($project->source->resource->path() . $suffix1); - Storage::disk("projects")->put("/project" . $project->id . "/source.nt", $source); - $suffix2 = ($project->target->filetype != 'ntriples' ) ? '.nt' : ''; - $target = file_get_contents($project->target->resource->path() . $suffix2); - Storage::disk("projects")->put("/project" . $project->id . "/target.nt", $target); - $config = file_get_contents($filename); - Storage::disk("projects")->put("/project" . $project->id . "/project" . $project->id . "_config.xml", $config); - } - - public function silkConfiguration2(Project $project) { - Storage::disk("projects")->makeDirectory("project" . $project->id); - $settingsID = $project->settings->id; - if ($settingsID == 1 || $settingsID == 2) { - - SettingsController::updateDefault($project); - return 0; - } - -// ---------------------------------------------------------------- -// --- VARIABLES -// ---> label και code βάσει του κλικ του χρήστη! (εδώ έτοιμα) - - $prefix1 = "rdfs"; - $namespace1 = "http://www.w3.org/2000/01/rdf-schema#"; - $prefix2 = "xsd"; - $namespace2 = "http://www.w3.org/2001/XMLSchema#"; - $prefix3 = "owl"; - $namespace3 = "http://www.w3.org/2002/07/owl#"; - $prefix4 = "rdf"; - $namespace4 = "http://www.w3.org/1999/02/22-rdf-syntax-ns#"; - $prefix5 = "sesame"; - $namespace5 = "http://www.openrdf.org/schema/sesame#"; - $prefix6 = "fn"; - $namespace6 = "http://www.w3.org/2005/xpath-functions#"; - $prefix7 = "skos"; - $namespace7 = "http://www.w3.org/2004/02/skos/core#"; - - $datasourceid1 = "codelist1"; - $datasourcetype1 = "file"; - $paramuri1 = "file"; -// ---> path του source file - //$source_list = "source"; - //$paramuriv1 = $source_list . ".rdf"; - $paramuriv1 = $project->source->resource->path(); - $paramgraph1 = "format"; -// format του source - $paramgraphv1 = "RDF/XML"; - - $datasourceid2 = "codelist2"; - $datasourcetype2 = "file"; - $paramuri2 = "file"; -// ---> path του target file - //$target_list= - - $paramuriv2 = $project->target->resource->path(); - $paramgraph2 = "format"; -// format του target - $paramgraphv2 = "RDF/XML"; - - - $interlinkId = "labels"; -// τύπος σύνδεσης (χρησιμοποιείται το 1ο. δυνατότητα επιλογής; ίσως μετά τα αποτελέσματα) - $linktypeV = "skos:closeMatch"; - $linktypeV2 = "skos:exactMatch"; - -// source datasource id (όπως έχει δηλωθεί παραπάνω; ) - $sdDs = "codelist1"; -// var όπως θα περιέχεται στο ερώτημα - $sdVar = "a"; -// target datasource id (όπως έχει δηλωθεί παραπάνω; ) - $tdDs = "codelist2"; -// var όπως θα περιέχεται στο ερώτημα - $tdVar = "b"; - -// queries (sparql restriction) - //$queryS="?a skos:prefLabel " . $word ; - //$queryT="?b rdf:type skos:Concept"; - $queryS = ""; - $queryT = ""; - -// ενσωμάτωση συγκρίσεων (max, min, quadraticMean, geometricMean) - $aggType = $project->settings->aggregate; -// παράμετροι σύγκρισης -// https://www.assembla.com/wiki/show/silk/Comparison - $compMetric1 = "levenshtein"; - $compThre1 = $project->settings->thre1; - $compMetric2 = "jaro"; - $compThre2 = $project->settings->thre2; - $compMetric3 = "jaroWinkler"; - $compThre3 = $project->settings->thre3; - $compMetric4 = "jaccard"; - $compThre4 = $project->settings->thre4; - $compMetric5 = "dice"; - $compThre5 = $project->settings->thre5; - $compMetric6 = "softjaccard"; - $compThre6 = $project->settings->thre6; -// ερώτήματα σύγκρισης 1 - $input1aPath = $project->settings->path1a; - $input1bPath = $project->settings->path1b; - $input2aPath = $project->settings->path2a; - $input2bPath = $project->settings->path2b; - $input3aPath = $project->settings->path3a; - $input3bPath = $project->settings->path3b; - $input4aPath = $project->settings->path4a; - $input4bPath = $project->settings->path4b; - $input5aPath = $project->settings->path5a; - $input5bPath = $project->settings->path5b; - $input6aPath = $project->settings->path6a; - $input6bPath = $project->settings->path6b; - - -// limit - $filterLimit = $project->settings->filter_limit; - - $outputType1 = "file"; - $outputType2 = "file"; - $outputType3 = "alignment"; - $outputId1 = "suggestions"; - $outputId2 = "exactMatch"; - $outputId3 = "score"; -// min ή και max confidence - $outputMin1 = "0.5"; - $outputMin2 = "1"; - $outputMin3 = ($project->settings->minC1) / 100; - $outputMax3 = ($project->settings->maxC1) / 100; - $output_param1aName = "file"; - $output_param2aName = "file"; - $output_param3aName = "file"; -// όνομα αρχείου παραμετροποιήσιμο βάσει source_list (όνομα λίστας) και code (όρου προς σύγκριση) - //$source_list = "cpa"; - //$target_list = "cpc"; -// $output_param1aValue="top10_" . $source_list . "_" . $code . "_" . $target_list . ".nt"; -// $output_param2aValue="exact_" . $source_list . "_" . $code . "_" . $target_list . ".nt"; -// $output_param3aValue="score_" . $source_list . "_" . $code . "_" . $target_list . ".rdf"; - $output_param1aValue = "top10_project" . $project->id . ".nt"; - $output_param2aValue = "exact_project" . $project->id . ".nt"; - $output_param3aValue = "score_project" . $project->id . ".rdf"; - $output_param1bName = "format"; - $output_param2bName = "format"; - $output_param3bName = "format"; -// format αρχείου - $output_param1bValue = "N-TRIPLE"; - $output_param2bValue = "N-TRIPLE"; - $output_param3bValue = "RDF/XML"; - - $dom = new \DomDocument; - - $dom->formatOutput = true; - - $root = $dom->createElement('Silk'); - $root = $dom->appendChild($root); - -// --- PREFIXES - - $prefixes = $dom->createElement('Prefixes'); - $prefixes = $root->appendChild($prefixes); - - $prefix = $dom->createElement('Prefix'); - $prefix = $prefixes->appendChild($prefix); - $id = $dom->createAttribute('id'); - $id->appendChild($dom->createTextNode($prefix1)); - $prefix->appendChild($id); - $namespace = $dom->createAttribute('namespace'); - $namespace->appendChild($dom->createTextNode($namespace1)); - $prefix->appendChild($namespace); - - $prefix_s = $dom->createElement('Prefix'); - $prefix_s = $prefixes->appendChild($prefix_s); - $id_s = $dom->createAttribute('id'); - $id_s->appendChild($dom->createTextNode($prefix2)); - $prefix_s->appendChild($id_s); - $namespace_s = $dom->createAttribute('namespace'); - $namespace_s->appendChild($dom->createTextNode($namespace2)); - $prefix_s->appendChild($namespace_s); - - $prefix_t = $dom->createElement('Prefix'); - $prefix_t = $prefixes->appendChild($prefix_t); - $id_t = $dom->createAttribute('id'); - $id_t->appendChild($dom->createTextNode($prefix3)); - $prefix_t->appendChild($id_t); - $namespace_t = $dom->createAttribute('namespace'); - $namespace_t->appendChild($dom->createTextNode($namespace3)); - $prefix_t->appendChild($namespace_t); - - $prefix_c4 = $dom->createElement('Prefix'); - $prefix_c4 = $prefixes->appendChild($prefix_c4); - $id_c4 = $dom->createAttribute('id'); - $id_c4->appendChild($dom->createTextNode($prefix4)); - $prefix_c4->appendChild($id_c4); - $namespace_c4 = $dom->createAttribute('namespace'); - $namespace_c4->appendChild($dom->createTextNode($namespace4)); - $prefix_c4->appendChild($namespace_c4); - - $prefix_c5 = $dom->createElement('Prefix'); - $prefix_c5 = $prefixes->appendChild($prefix_c5); - $id_c5 = $dom->createAttribute('id'); - $id_c5->appendChild($dom->createTextNode($prefix5)); - $prefix_c5->appendChild($id_c5); - $namespace_c5 = $dom->createAttribute('namespace'); - $namespace_c5->appendChild($dom->createTextNode($namespace5)); - $prefix_c5->appendChild($namespace_c5); - - $prefix_c6 = $dom->createElement('Prefix'); - $prefix_c6 = $prefixes->appendChild($prefix_c6); - $id_c6 = $dom->createAttribute('id'); - $id_c6->appendChild($dom->createTextNode($prefix6)); - $prefix_c6->appendChild($id_c6); - $namespace_c6 = $dom->createAttribute('namespace'); - $namespace_c6->appendChild($dom->createTextNode($namespace6)); - $prefix_c6->appendChild($namespace_c6); - - $prefix_c7 = $dom->createElement('Prefix'); - $prefix_c7 = $prefixes->appendChild($prefix_c7); - $id_c7 = $dom->createAttribute('id'); - $id_c7->appendChild($dom->createTextNode($prefix7)); - $prefix_c7->appendChild($id_c7); - $namespace_c7 = $dom->createAttribute('namespace'); - $namespace_c7->appendChild($dom->createTextNode($namespace7)); - $prefix_c7->appendChild($namespace_c7); - - -// --- DATASOURCES - - $datasources = $dom->createElement('DataSources'); - $datasources = $root->appendChild($datasources); - -// --- SOURCE DATASOURCE - - $datasource_s = $dom->createElement('DataSource'); - $datasource_s = $datasources->appendChild($datasource_s); - - $datasource_id = $dom->createAttribute('id'); - $datasource_id->appendChild($dom->createTextNode($datasourceid1)); - $datasource_s->appendChild($datasource_id); - - $datasource_type = $dom->createAttribute('type'); - $datasource_type->appendChild($dom->createTextNode($datasourcetype1)); - $datasource_s->appendChild($datasource_type); - - $dpm = $dom->createElement('Param'); - $dpm = $datasource_s->appendChild($dpm); - $dpm_uri = $dom->createAttribute('name'); - $dpm_uri->appendChild($dom->createTextNode($paramuri1)); - $dpm->appendChild($dpm_uri); - $dpm_uriv = $dom->createAttribute('value'); - $dpm_uriv->appendChild($dom->createTextNode($paramuriv1)); - $dpm->appendChild($dpm_uriv); - - $dpm2 = $dom->createElement('Param'); - $dpm2 = $datasource_s->appendChild($dpm2); - $dpm_graph = $dom->createAttribute('name'); - $dpm_graph->appendChild($dom->createTextNode($paramgraph1)); - $dpm2->appendChild($dpm_graph); - $dpm_graphv = $dom->createAttribute('value'); - $dpm_graphv->appendChild($dom->createTextNode($paramgraphv1)); - $dpm2->appendChild($dpm_graphv); - -// --- TARGET DATASOURCE - - $datasource_t = $dom->createElement('DataSource'); - $datasource_t = $datasources->appendChild($datasource_t); - - $datasource_id2 = $dom->createAttribute('id'); - $datasource_id2->appendChild($dom->createTextNode($datasourceid2)); - $datasource_t->appendChild($datasource_id2); - - $datasource_type2 = $dom->createAttribute('type'); - $datasource_type2->appendChild($dom->createTextNode($datasourcetype2)); - $datasource_t->appendChild($datasource_type2); - - $dpm_t = $dom->createElement('Param'); - $dpm_t = $datasource_t->appendChild($dpm_t); - $dpm_uri2 = $dom->createAttribute('name'); - $dpm_uri2->appendChild($dom->createTextNode($paramuri2)); - $dpm_t->appendChild($dpm_uri2); - $dpm_uriv2 = $dom->createAttribute('value'); - $dpm_uriv2->appendChild($dom->createTextNode($paramuriv2)); - $dpm_t->appendChild($dpm_uriv2); - - $dpm2_t = $dom->createElement('Param'); - $dpm2_t = $datasource_t->appendChild($dpm2_t); - $dpm_graph2 = $dom->createAttribute('name'); - $dpm_graph2->appendChild($dom->createTextNode($paramgraph2)); - $dpm2_t->appendChild($dpm_graph2); - $dpm_graphv2 = $dom->createAttribute('value'); - $dpm_graphv2->appendChild($dom->createTextNode($paramgraphv2)); - $dpm2_t->appendChild($dpm_graphv2); - - -// --- INTERLINKS - - $interlinks = $dom->createElement('Interlinks'); - $interlinks = $root->appendChild($interlinks); - - $interlink = $dom->createElement('Interlink'); - $interlink = $interlinks->appendChild($interlink); - $interlink_id = $dom->createAttribute('id'); - $interlink_id->appendChild($dom->createTextNode($interlinkId)); - $interlink->appendChild($interlink_id); - -// --- SOURCE DATASET - - $sourcedataset = $dom->createElement('SourceDataset'); - $sourcedataset = $interlink->appendChild($sourcedataset); - $sd_ds = $dom->createAttribute('dataSource'); - $sd_ds->appendChild($dom->createTextNode($sdDs)); - $sourcedataset->appendChild($sd_ds); - $sd_var = $dom->createAttribute('var'); - $sd_var->appendChild($dom->createTextNode($sdVar)); - $sourcedataset->appendChild($sd_var); - - $restrictto_s = $dom->createElement('RestrictTo'); - $restrictto_s = $sourcedataset->appendChild($restrictto_s); - - $query_s = $dom->createTextNode($queryS); - $restrictto_s->appendChild($query_s); - -// --- TARGET DATASET - - $targetdataset = $dom->createElement('TargetDataset'); - $targetdataset = $interlink->appendChild($targetdataset); - $td_ds = $dom->createAttribute('dataSource'); - $td_ds->appendChild($dom->createTextNode($tdDs)); - $targetdataset->appendChild($td_ds); - $td_var = $dom->createAttribute('var'); - $td_var->appendChild($dom->createTextNode($tdVar)); - $targetdataset->appendChild($td_var); - - $restrictto_t = $dom->createElement('RestrictTo'); - $restrictto_t = $targetdataset->appendChild($restrictto_t); - - $query_t = $dom->createTextNode($queryT); - $restrictto_t->appendChild($query_t); - - -// --- LINKAGE RULE - - - $linkagerule = $dom->createElement('LinkageRule'); - $linkagerule = $interlink->appendChild($linkagerule); - $linktype = $dom->createAttribute('linkType'); - $linktype->appendChild($dom->createTextNode($linktypeV)); - $linkagerule->appendChild($linktype); - - - $aggregate = $dom->createElement('Aggregate'); - $aggregate = $linkagerule->appendChild($aggregate); - $agg_type = $dom->createAttribute('type'); - $agg_type->appendChild($dom->createTextNode($aggType)); - $aggregate->appendChild($agg_type); - - -// --- COMPARISON 1 - - $compare1 = $dom->createElement('Compare'); - $compare1 = $aggregate->appendChild($compare1); - $comp_metric1 = $dom->createAttribute('metric'); - $comp_metric1->appendChild($dom->createTextNode($compMetric1)); - $compare1->appendChild($comp_metric1); - $comp_thre1 = $dom->createAttribute('threshold'); - $comp_thre1->appendChild($dom->createTextNode($compThre1)); - $compare1->appendChild($comp_thre1); - - $input1a = $dom->createElement('Input'); - $input1a = $compare1->appendChild($input1a); - $input1a_path = $dom->createAttribute('path'); - $input1a_path->appendChild($dom->createTextNode($input1aPath)); - $input1a->appendChild($input1a_path); - - $input1b = $dom->createElement('Input'); - $input1b = $compare1->appendChild($input1b); - $input1b_path = $dom->createAttribute('path'); - $input1b_path->appendChild($dom->createTextNode($input1bPath)); - $input1b->appendChild($input1b_path); - -// --- COMPARISON 2 - - $compare2 = $dom->createElement('Compare'); - $compare2 = $aggregate->appendChild($compare2); - $comp_metric2 = $dom->createAttribute('metric'); - $comp_metric2->appendChild($dom->createTextNode($compMetric2)); - $compare2->appendChild($comp_metric2); - $comp_thre2 = $dom->createAttribute('threshold'); - $comp_thre2->appendChild($dom->createTextNode($compThre2)); - $compare2->appendChild($comp_thre2); - - $input2a = $dom->createElement('Input'); - $input2a = $compare2->appendChild($input2a); - $input2a_path = $dom->createAttribute('path'); - $input2a_path->appendChild($dom->createTextNode($input1aPath)); - $input2a->appendChild($input2a_path); - - $input2b = $dom->createElement('Input'); - $input2b = $compare2->appendChild($input2b); - $input2b_path = $dom->createAttribute('path'); - $input2b_path->appendChild($dom->createTextNode($input1bPath)); - $input2b->appendChild($input2b_path); - -// --- COMPARISON 3 - - $compare3 = $dom->createElement('Compare'); - $compare3 = $aggregate->appendChild($compare3); - $comp_metric3 = $dom->createAttribute('metric'); - $comp_metric3->appendChild($dom->createTextNode($compMetric3)); - $compare3->appendChild($comp_metric3); - $comp_thre3 = $dom->createAttribute('threshold'); - $comp_thre3->appendChild($dom->createTextNode($compThre3)); - $compare3->appendChild($comp_thre3); - - $input3a = $dom->createElement('Input'); - $input3a = $compare3->appendChild($input3a); - $input3a_path = $dom->createAttribute('path'); - $input3a_path->appendChild($dom->createTextNode($input1aPath)); - $input3a->appendChild($input3a_path); - - $input3b = $dom->createElement('Input'); - $input3b = $compare3->appendChild($input3b); - $input3b_path = $dom->createAttribute('path'); - $input3b_path->appendChild($dom->createTextNode($input1bPath)); - $input3b->appendChild($input3b_path); - -// --- COMPARISON 4 - - $compare4 = $dom->createElement('Compare'); - $compare4 = $aggregate->appendChild($compare4); - $comp_metric4 = $dom->createAttribute('metric'); - $comp_metric4->appendChild($dom->createTextNode($compMetric4)); - $compare4->appendChild($comp_metric4); - $comp_thre4 = $dom->createAttribute('threshold'); - $comp_thre4->appendChild($dom->createTextNode($compThre4)); - $compare4->appendChild($comp_thre4); - - $input4a = $dom->createElement('Input'); - $input4a = $compare4->appendChild($input4a); - $input4a_path = $dom->createAttribute('path'); - $input4a_path->appendChild($dom->createTextNode($input1aPath)); - $input4a->appendChild($input4a_path); - - $input4b = $dom->createElement('Input'); - $input4b = $compare4->appendChild($input4b); - $input4b_path = $dom->createAttribute('path'); - $input4b_path->appendChild($dom->createTextNode($input1bPath)); - $input4b->appendChild($input4b_path); - -// --- COMPARISON 5 - - $compare5 = $dom->createElement('Compare'); - $compare5 = $aggregate->appendChild($compare5); - $comp_metric5 = $dom->createAttribute('metric'); - $comp_metric5->appendChild($dom->createTextNode($compMetric5)); - $compare5->appendChild($comp_metric5); - $comp_thre5 = $dom->createAttribute('threshold'); - $comp_thre5->appendChild($dom->createTextNode($compThre5)); - $compare5->appendChild($comp_thre5); - - $input5a = $dom->createElement('Input'); - $input5a = $compare5->appendChild($input5a); - $input5a_path = $dom->createAttribute('path'); - $input5a_path->appendChild($dom->createTextNode($input1aPath)); - $input5a->appendChild($input5a_path); - - $input5b = $dom->createElement('Input'); - $input5b = $compare5->appendChild($input5b); - $input5b_path = $dom->createAttribute('path'); - $input5b_path->appendChild($dom->createTextNode($input1bPath)); - $input5b->appendChild($input5b_path); - -// --- COMPARISON 6 - - $compare6 = $dom->createElement('Compare'); - $compare6 = $aggregate->appendChild($compare6); - $comp_metric6 = $dom->createAttribute('metric'); - $comp_metric6->appendChild($dom->createTextNode($compMetric6)); - $compare6->appendChild($comp_metric6); - $comp_thre6 = $dom->createAttribute('threshold'); - $comp_thre6->appendChild($dom->createTextNode($compThre6)); - $compare6->appendChild($comp_thre6); - - $input6a = $dom->createElement('Input'); - $input6a = $compare6->appendChild($input6a); - $input6a_path = $dom->createAttribute('path'); - $input6a_path->appendChild($dom->createTextNode($input1aPath)); - $input6a->appendChild($input6a_path); - - $input6b = $dom->createElement('Input'); - $input6b = $compare6->appendChild($input6b); - $input6b_path = $dom->createAttribute('path'); - $input6b_path->appendChild($dom->createTextNode($input1bPath)); - $input6b->appendChild($input6b_path); - - -// --- Filter - - $filter = $dom->createElement('Filter'); - $filter = $linkagerule->appendChild($filter); - $limit = $dom->createAttribute('limit'); - $limit->appendChild($dom->createTextNode($filterLimit)); - $filter->appendChild($limit); - - $outputs = $dom->createElement('Outputs'); - $outputs = $root->appendChild($outputs); - - -// --- 1st OUTPUT - - - $output = $dom->createElement('Output'); - $output = $outputs->appendChild($output); - $output_id1 = $dom->createAttribute('id'); - $output_id1->appendChild($dom->createTextNode($outputId1)); - $output->appendChild($output_id1); - $output_type1 = $dom->createAttribute('type'); - $output_type1->appendChild($dom->createTextNode($outputType1)); - $output->appendChild($output_type1); - $output_min1 = $dom->createAttribute('minConfidence'); - $output_min1->appendChild($dom->createTextNode($outputMin1)); - $output->appendChild($output_min1); - - $output_param1a = $dom->createElement('Param'); - $output_param1a = $output->appendChild($output_param1a); - $output_param1a_name = $dom->createAttribute('name'); - $output_param1a_name->appendChild($dom->createTextNode($output_param1aName)); - $output_param1a->appendChild($output_param1a_name); - $output_param1a_value = $dom->createAttribute('value'); - $output_param1a_value->appendChild($dom->createTextNode($output_param1aValue)); - $output_param1a->appendChild($output_param1a_value); - - $output_param1b = $dom->createElement('Param'); - $output_param1b = $output->appendChild($output_param1b); - $output_param1b_name = $dom->createAttribute('name'); - $output_param1b_name->appendChild($dom->createTextNode($output_param1bName)); - $output_param1b->appendChild($output_param1b_name); - $output_param1b_value = $dom->createAttribute('value'); - $output_param1b_value->appendChild($dom->createTextNode($output_param1bValue)); - $output_param1b->appendChild($output_param1b_value); - - -// --- 2nd OUTPUT - - - $output2 = $dom->createElement('Output'); - $output2 = $outputs->appendChild($output2); - $output_id2 = $dom->createAttribute('id'); - $output_id2->appendChild($dom->createTextNode($outputId2)); - $output2->appendChild($output_id2); - $output_type2 = $dom->createAttribute('type'); - $output_type2->appendChild($dom->createTextNode($outputType2)); - $output2->appendChild($output_type2); - $output_min2 = $dom->createAttribute('minConfidence'); - $output_min2->appendChild($dom->createTextNode($outputMin2)); - $output2->appendChild($output_min2); - - $output_param2a = $dom->createElement('Param'); - $output_param2a = $output2->appendChild($output_param2a); - $output_param2a_name = $dom->createAttribute('name'); - $output_param2a_name->appendChild($dom->createTextNode($output_param2aName)); - $output_param2a->appendChild($output_param2a_name); - $output_param2a_value = $dom->createAttribute('value'); - $output_param2a_value->appendChild($dom->createTextNode($output_param2aValue)); - $output_param2a->appendChild($output_param2a_value); - - $output_param2b = $dom->createElement('Param'); - $output_param2b = $output2->appendChild($output_param2b); - $output_param2b_name = $dom->createAttribute('name'); - $output_param2b_name->appendChild($dom->createTextNode($output_param2bName)); - $output_param2b->appendChild($output_param2b_name); - $output_param2b_value = $dom->createAttribute('value'); - $output_param2b_value->appendChild($dom->createTextNode($output_param2bValue)); - $output_param2b->appendChild($output_param2b_value); - - - // --- 3rd OUTPUT - - - $output3 = $dom->createElement('Output'); - $output3 = $outputs->appendChild($output3); - $output_id3 = $dom->createAttribute('id'); - $output_id3->appendChild($dom->createTextNode($outputId3)); - $output3->appendChild($output_id3); - $output_type3 = $dom->createAttribute('type'); - $output_type3->appendChild($dom->createTextNode($outputType3)); - $output3->appendChild($output_type3); - $output_min3 = $dom->createAttribute('minConfidence'); - $output_min3->appendChild($dom->createTextNode($outputMin3)); - $output3->appendChild($output_min3); - $output_max3 = $dom->createAttribute('maxConfidence'); - $output_max3->appendChild($dom->createTextNode($outputMax3)); - $output3->appendChild($output_max3); - - $output_param3a = $dom->createElement('Param'); - $output_param3a = $output3->appendChild($output_param3a); - $output_param3a_name = $dom->createAttribute('name'); - $output_param3a_name->appendChild($dom->createTextNode($output_param3aName)); - $output_param3a->appendChild($output_param3a_name); - $output_param3a_value = $dom->createAttribute('value'); - $output_param3a_value->appendChild($dom->createTextNode($output_param3aValue)); - $output_param3a->appendChild($output_param3a_value); - - $output_param3b = $dom->createElement('Param'); - $output_param3b = $output3->appendChild($output_param3b); - $output_param3b_name = $dom->createAttribute('name'); - $output_param3b_name->appendChild($dom->createTextNode($output_param3bName)); - $output_param3b->appendChild($output_param3b_name); - $output_param3b_value = $dom->createAttribute('value'); - $output_param3b_value->appendChild($dom->createTextNode($output_param3bValue)); - $output_param3b->appendChild($output_param3b_value); - - -// --- OUTPUTS - //Storage::disk("projects")->makeDirectory("project" . $project->id); - $filename = storage_path() . "/app/projects/project" . $project->id . "/project" . $project->id . "_config.xml"; - $dom->save($filename); - } - } diff --git a/app/Http/Controllers/VoteController.php b/app/Http/Controllers/VoteController.php index 81174ec..952054f 100644 --- a/app/Http/Controllers/VoteController.php +++ b/app/Http/Controllers/VoteController.php @@ -6,9 +6,10 @@ //use Illuminate\Http\Request; -class VoteController extends Controller { - - public function __construct() { +class VoteController extends Controller +{ + public function __construct() + { $this->middleware('auth'); } @@ -17,15 +18,18 @@ public function __construct() { * * @return Response */ - public function index() { + public function index() + { return view('myvotes'); } - public function mylinks() { + public function mylinks() + { return view('votes.wrapper'); } - public function project_vote() { + public function project_vote() + { $id = request()->project_id; $project = \App\Project::find($id); $links = $project->links()->paginate(10); @@ -40,9 +44,10 @@ public function project_vote() { } //a function to vote - public function vote() { + public function vote() + { $input = request()->all(); - if (VoteController::novote($input["user_id"], $input["link_id"])) { + if (self::novote($input['user_id'], $input['link_id'])) { $vote = \App\Vote::create($input); $link = $vote->link; if ($vote->vote == 1) { @@ -54,47 +59,51 @@ public function vote() { $link->save(); $up_votes = $link->up_votes; $down_votes = $link->down_votes; - $message = "Vote counted!!!"; - return response()->json(["message" => trans('alignment/votes.vote-valid'), - "valid" => true, - "up_votes" => $up_votes, - "down_votes" => $down_votes, + $message = 'Vote counted!!!'; + + return response()->json(['message' => trans('alignment/votes.vote-valid'), + 'valid' => true, + 'up_votes' => $up_votes, + 'down_votes' => $down_votes, ]); } else { - return $this->changevote($input["user_id"], $input["link_id"], $input["vote"]); + return $this->changevote($input['user_id'], $input['link_id'], $input['vote']); } } //a function to preview an entity - public function preview() { + public function preview() + { $input = request()->all(); - $uri = $input["uri"]; + $uri = $input['uri']; //TODO: temporal fix till json-ld lib get's support to PHP7.2 $accept_options = [ 'application/rdf+xml' => 'application/rdf+xml', 'text/turtle' => 'text/turtle', ]; $client = new \EasyRdf_Http_Client($uri); - $client->setHeaders("Accept", $accept_options); + $client->setHeaders('Accept', $accept_options); try { $response = $client->request(); $graph = new \EasyRdf_Graph(); - $graph->parse($response->getBody()); + $graph->parse($response->getBody()); $message = $graph->dump('html'); } catch (\EasyRdf_Http_Exception $ex) { $info = new CreatelinksController(); $message = $info->infobox(request()); } + return response()->json( [ - "message" => $message, - "valid" => true, + 'message' => $message, + 'valid' => true, ]); } - //a function to check if user has already voted - public function novote($user, $link) { + //a function to check if user has already voted + public function novote($user, $link) + { $votes = DB::table('votes')->where([ ['user_id', '=', $user], ['link_id', '=', $link], @@ -107,17 +116,15 @@ public function novote($user, $link) { } } - //a function to check if user has already voted - public function changevote($user, $link, $current) { - + //a function to check if user has already voted + public function changevote($user, $link, $current) + { $vote = \App\Vote::where([ ['user_id', '=', $user], ['link_id', '=', $link], ])->first(); //dd($vote); if ($vote->vote != $current) { - - $link = $vote->link; if ($current == 1) { @@ -133,18 +140,19 @@ public function changevote($user, $link, $current) { $vote->save(); $up_votes = $link->up_votes; $down_votes = $link->down_votes; - $message = "You had already Voted. Vote changed"; - return response()->json(["message" => trans('alignment/votes.vote-changed'), - "valid" => true, - "up_votes" => $up_votes, - "down_votes" => $down_votes, + $message = 'You had already Voted. Vote changed'; + + return response()->json(['message' => trans('alignment/votes.vote-changed'), + 'valid' => true, + 'up_votes' => $up_votes, + 'down_votes' => $down_votes, ]); } else { - $message = "You have already Voted"; - return response()->json(["message" => trans('alignment/votes.vote-invalid'), - "valid" => false, + $message = 'You have already Voted'; + + return response()->json(['message' => trans('alignment/votes.vote-invalid'), + 'valid' => false, ]); } } - } diff --git a/app/Http/Controllers/rdfnamespaceController.php b/app/Http/Controllers/rdfnamespaceController.php index 69130e8..b41d5f6 100644 --- a/app/Http/Controllers/rdfnamespaceController.php +++ b/app/Http/Controllers/rdfnamespaceController.php @@ -2,12 +2,8 @@ namespace App\Http\Controllers; -use App\Http\Requests; -use App\Http\Controllers\Controller; - use App\rdfnamespace; use Illuminate\Http\Request; -use Carbon\Carbon; use Session; class rdfnamespaceController extends Controller @@ -41,7 +37,6 @@ public function create() */ public function store(Request $request) { - rdfnamespace::create($request->all()); Session::flash('flash_message', 'rdfnamespace added!'); @@ -86,7 +81,6 @@ public function edit($id) */ public function update($id, Request $request) { - $rdfnamespace = rdfnamespace::findOrFail($id); $rdfnamespace->update($request->all()); diff --git a/app/Http/Kernel.php b/app/Http/Kernel.php index 736f8ce..76126af 100644 --- a/app/Http/Kernel.php +++ b/app/Http/Kernel.php @@ -36,7 +36,7 @@ class Kernel extends HttpKernel 'api' => [ 'throttle:60,1', - 'bindings' + 'bindings', ], ]; diff --git a/app/Http/Middleware/VerifyCsrfToken.php b/app/Http/Middleware/VerifyCsrfToken.php index 659d2cb..7d2b0d7 100644 --- a/app/Http/Middleware/VerifyCsrfToken.php +++ b/app/Http/Middleware/VerifyCsrfToken.php @@ -20,6 +20,6 @@ class VerifyCsrfToken extends BaseVerifier 'comments/show', 'notification/*', 'linktype/*', - 'myvotes/project' + 'myvotes/project', ]; } diff --git a/app/Import.php b/app/Import.php index 2597d75..a335143 100644 --- a/app/Import.php +++ b/app/Import.php @@ -2,38 +2,119 @@ namespace App; -use Illuminate\Database\Eloquent\Model; -use Codesleeve\Stapler\ORM\StaplerableInterface; use Codesleeve\Stapler\ORM\EloquentTrait; +use Codesleeve\Stapler\ORM\StaplerableInterface; +use Illuminate\Database\Eloquent\Model; class Import extends Model implements StaplerableInterface { use EloquentTrait; - + protected $fillable = ['resource', 'filetype', 'project_id', 'user_id']; - - public function __construct(array $attributes = array()) { + + public function __construct(array $attributes = []) + { $this->hasAttachedFile('resource', [ - ]); parent::__construct($attributes); } - - public function user(){ + + public function user() + { return $this->belongsTo("App\User"); } - + public function project() { return $this->belongsTo("App\Project"); } - - public function getDirty() { + + public function getDirty() + { $dirty = parent::getDirty(); return array_filter($dirty, function ($var) { - return !($var instanceof \Codesleeve\Stapler\Attachment); + return ! ($var instanceof \Codesleeve\Stapler\Attachment); }); } + + private function convertImported() + { + $command = 'rapper -i '.$this->filetype.' -o rdfxml-abbrev '.$this->resource->path().' > '.$this->resource->path().'.rdf'; + $out = []; + exec($command, $out); + } + + public function importGraph() + { + $graph = new \EasyRdf_Graph(); + try { + if ($this->filetype != 'rdfxml') { + $this->convertImported(); + $graph->parseFile($this->resource->path().'.rdf', 'rdfxml'); + } else { + $graph->parseFile($this->resource->path(), 'rdfxml'); + } + $this->parsed = true; + $this->save(); + + return $graph; + } catch (\Exception $ex) { + $this->parsed = false; + $this->save(); + logger('Fail to parse file. Check filetype or valid syntax. Error:'.$ex); + + return; + } + } + + private function createLink( + \EasyRdf_Resource $subject, + $property, + \EasyRdf_Resource $object) + { + $data = [ + 'source' => $subject->getUri(), + 'target' => $object->getUri(), + 'link_type' => $property, + 'project_id' => $this->project_id, + ]; + $request = \Illuminate\Support\Facades\Request::create('/', 'GET', $data); + Link::create($request); + } + + private function iterateLinks(\EasyRdf_Resource $resource, $property) + { + $links = $resource->allResources(new \EasyRdf_Resource($property)); + foreach ($links as $link) { + $this->createLink($resource, $property, $link); + } + } + + private function iterateProperties(\EasyRdf_Resource $resource) + { + $properties = $resource->propertyUris(); + foreach ($properties as $property) { + $this->iterateLinks($resource, $property); + } + } + + private function iterateResources(\EasyRdf_Graph $graph) + { + $resources = $graph->resources(); + foreach ($resources as $resource) { + $this->iterateProperties($resource); + } + } + + public function importLinks() + { + $graph = $this->importGraph(); + $this->iterateResources($graph); + $this->imported = true; + $this->save(); + + return $this; + } } diff --git a/app/Jobs/CacheGraph.php b/app/Jobs/CacheGraph.php new file mode 100644 index 0000000..37d1216 --- /dev/null +++ b/app/Jobs/CacheGraph.php @@ -0,0 +1,40 @@ +file = $file; + $this->user = $user; + } + + /** + * Execute the job. + * + * @return void + */ + public function handle() + { + $this->file->cacheGraph(); + } +} diff --git a/app/Jobs/Convert.php b/app/Jobs/Convert.php index 3f921f2..c110ce0 100644 --- a/app/Jobs/Convert.php +++ b/app/Jobs/Convert.php @@ -2,21 +2,25 @@ namespace App\Jobs; -use Cache; -use Storage; +use App\Models\OntologyTypeDriver; use App\Project; -use Illuminate\Queue\SerializesModels; -use Illuminate\Queue\InteractsWithQueue; +use Cache; +use Illuminate\Bus\Queueable; use Illuminate\Contracts\Queue\ShouldQueue; -use App\Models\OntologyTypeDriver; +use Illuminate\Foundation\Bus\Dispatchable; +use Illuminate\Queue\InteractsWithQueue; +use Illuminate\Queue\SerializesModels; +use Storage; -class Convert extends Job implements ShouldQueue +class Convert implements ShouldQueue { - use InteractsWithQueue, SerializesModels; - + use InteractsWithQueue, SerializesModels, Queueable, Dispatchable; use \App\RDFTrait; - protected $project,$user, $dump; + protected $project; + protected $user; + protected $dump; + /** * Create a new job instance. * @@ -37,48 +41,34 @@ public function __construct(Project $project, $user, $dump) public function handle() { \App\Notification::create([ - "message" => 'Converting Graphs...' . $this->dump, - "user_id" => $this->user, - "project_id" => $this->project->id, - "status" => 2, - ]); + 'message' => 'Converting Graphs...'.$this->dump, + 'user_id' => $this->user, + 'project_id' => $this->project->id, + 'status' => 2, + ]); $this->D3_convert($this->project, $this->dump); - - if($this->dump === "target"){ - \App\Notification::create([ - "message" => 'Project Ready!', - "user_id" => $this->user, - "project_id" => $this->project->id, - "status" => 3, - ]); - $this->project->processed = 1; - $this->project->save(); - } - else{ - dispatch(new Convert($this->project, $this->user, "target")); - } } - - public function D3_convert(Project $project, $dump, $orderBy = null) { - $type = "SKOS"; - $file = $project->$dump; + + public function D3_convert(Project $project, $dump, $orderBy = null) + { + $type = 'SKOS'; + $file = $project->$dump; /* * Get the parent node */ - $driver = OntologyTypeDriver::Factory($type); + $driver = OntologyTypeDriver::Factory($type); /* * Read the graph */ $graph = $file->cacheGraph(); - + $parents = $graph->allOfType($driver::root); /* * Iterate through all parents */ - if($dump === "source"){ - $score = Cache::get("scores_graph_project" . $project->id); - } - else{ + if ($dump === 'source') { + $score = Cache::get('scores_graph_project'.$project->id); + } else { $score = null; } foreach ($parents as $parent) { @@ -89,7 +79,7 @@ public function D3_convert(Project $project, $dump, $orderBy = null) { $JSON['name'] = "$name"; $JSON['url'] = urlencode($parent); $children = $this->find_children($graph, $driver::firstLevelPath, $parent, $orderBy, $score, $JSON, $type); - if (sizeOf($children) == 0){ + if (count($children) == 0) { $children = $this->find_children($graph, $driver::inverseFirstLevelPath, $parent, $orderBy, $score, $JSON, $type); } $JSON['children'] = $orderBy === null ? $children : collect($children)->sortBy($orderBy)->values()->toArray(); @@ -98,13 +88,13 @@ public function D3_convert(Project $project, $dump, $orderBy = null) { /* * create JSON file */ - $name = implode("_", ["project", $project->id, $dump, $file->id, $orderBy]); - $filename = 'json_serializer/' . $name . ".json"; + $name = implode('_', ['project', $project->id, $dump, $file->id, $orderBy]); + $filename = 'json_serializer/'.$name.'.json'; Storage::disk('public')->put($filename, json_encode($JSON)); - return $filename; } - function find_children(\EasyRdf_Graph $graph, $hierarchic_link, $parent_url, $orderBy = null, $score = null, $type) { + public function find_children(\EasyRdf_Graph $graph, $hierarchic_link, $parent_url, $orderBy, $score, $type) + { $driver = OntologyTypeDriver::Factory($type); $children = $graph->allResources($parent_url, $hierarchic_link); $counter = 0; @@ -112,24 +102,22 @@ function find_children(\EasyRdf_Graph $graph, $hierarchic_link, $parent_url, $or foreach ($children as $child) { $name = $this->label($graph, $child); - $myJSON[]["name"] = "$name"; - if($score !== null){ - $suggestions = count($score->resourcesMatching("http://knowledgeweb.semanticweb.org/heterogeneity/alignment#entity1", $child)); - } - else{ + $myJSON[]['name'] = "$name"; + if ($score !== null) { + $suggestions = count($score->resourcesMatching('http://knowledgeweb.semanticweb.org/heterogeneity/alignment#entity1', $child)); + } else { $suggestions = 0; } - $myJSON[$counter]['suggestions'] = $suggestions; $myJSON[$counter]['url'] = urlencode($child); $children = $this->find_children($graph, $driver::secondLevelPath, $child, $orderBy, $score, $myJSON, $type); - if (sizeOf($children) == 0){ + if (count($children) == 0) { $children = $this->find_children($graph, $driver::inverseSecondLevelPath, $child, $orderBy, $score, $myJSON, $type); } - $myJSON[$counter]['children'] = $orderBy === null ? $children : collect($children)->sortBy($orderBy)->values()->toArray(); $counter++; } + return $myJSON; } } diff --git a/app/Jobs/InitiateCalculations.php b/app/Jobs/InitiateCalculations.php new file mode 100644 index 0000000..fbde76d --- /dev/null +++ b/app/Jobs/InitiateCalculations.php @@ -0,0 +1,50 @@ +project = $project; + $this->provider = $provider; + $this->user = $user; + } + + /** + * Execute the job. + * + * @return void + */ + public function handle() + { + $this->project->processed = 0; + $this->project->save(); + $this->provider->prepare($this->project); + \App\Notification::create([ + 'message' => $this->provider->name.' Config File Created succesfully.', + 'user_id' => $this->user->id, + 'project_id' => $this->project->id, + 'status' => 1, + ]); + } +} diff --git a/app/Jobs/Parse.php b/app/Jobs/Parse.php index 6ce52b6..a01e112 100644 --- a/app/Jobs/Parse.php +++ b/app/Jobs/Parse.php @@ -4,19 +4,20 @@ use App\File; use App\User; +use Cache; use Illuminate\Bus\Queueable; -use Illuminate\Queue\SerializesModels; -use Symfony\Component\Process\Process; -use Illuminate\Queue\InteractsWithQueue; use Illuminate\Contracts\Queue\ShouldQueue; use Illuminate\Foundation\Bus\Dispatchable; -use Symfony\Component\Process\Exception\ProcessFailedException; +use Illuminate\Queue\InteractsWithQueue; +use Illuminate\Queue\SerializesModels; class Parse implements ShouldQueue { use Dispatchable, InteractsWithQueue, Queueable, SerializesModels; - - protected $file, $user; + + protected $file; + + protected $user; /** * Create a new job instance. @@ -36,40 +37,22 @@ public function __construct(File $file, User $user) */ public function handle() { - $this->parse($this->file); + //$this->parse($this->file); + $this->invalidate(); + Rapper::withChain([ + new Skosify($this->file, $this->user), + new CacheGraph($this->file, $this->user), + ])->dispatch($this->file, $this->user); } - - public function parse(File $file) - { - /* - * Read the graph - */ - try{ - if($file->filetype != 'ntriples'){ - $this->reserialize($file); - } - $file->cacheGraph(); - } catch (\Exception $ex) { - $file->parsed = false; - $file->save(); - error_log($ex); - } - } - - public function reserialize(File $file){ - $command = [ - 'rapper', - '-i ', - $file->filetype, - '-o', - 'ntriples', - $file->resource->path(), - '>', - $file->resource->path(). '.nt' - ]; - $process = new Process($command); - $process->run(); - return; + //this function will invalidate previous + //cached graph, in order to get a fresh parsed graph always + public function invalidate() + { + $this->file->parsed = false; + $this->file->save(); + if (Cache::has($this->file->id.'_graph')) { + Cache::forget($this->file->id.'_graph'); + } } } diff --git a/app/Jobs/ParseScores.php b/app/Jobs/ParseScores.php index 8ab9910..6ad8f34 100644 --- a/app/Jobs/ParseScores.php +++ b/app/Jobs/ParseScores.php @@ -2,19 +2,22 @@ namespace App\Jobs; -use Cache; -use App\Project; -use App\Jobs\Job; use App\Notification; -use Illuminate\Queue\SerializesModels; -use Illuminate\Queue\InteractsWithQueue; +use App\Project; +use Cache; +use Illuminate\Bus\Queueable; use Illuminate\Contracts\Queue\ShouldQueue; +use Illuminate\Foundation\Bus\Dispatchable; +use Illuminate\Queue\InteractsWithQueue; +use Illuminate\Queue\SerializesModels; -class ParseScores extends Job implements ShouldQueue +class ParseScores implements ShouldQueue { - use InteractsWithQueue, SerializesModels; + use InteractsWithQueue, SerializesModels, Dispatchable, Queueable; + + protected $project; + protected $user; - protected $project,$user; /** * Create a new job instance. * @@ -34,42 +37,41 @@ public function __construct(Project $project, $user) public function handle() { $this->parseScore($this->project, $this->user); - dispatch(new \App\Jobs\Convert($this->project, $this->user, "source")); } - - private function parseScore(Project $project, $user_id){ - $old_score = storage_path() . "/app/projects/project" . $project->id . "/" . "score.nt"; - $score_filepath = storage_path() . "/app/projects/project" . $project->id . "/" . "score_project" . $project->id . ".nt"; - try{ - $command = 'rapper -i rdfxml -o ntriples ' . $old_score . ' > ' . $score_filepath; + + private function parseScore(Project $project, $user_id) + { + $old_score = storage_path().'/app/projects/project'.$project->id.'/'.'score.nt'; + $score_filepath = storage_path().'/app/projects/project'.$project->id.'/'.'score_project'.$project->id.'.nt'; + try { + $command = 'rapper -i rdfxml -o ntriples '.$old_score.' > '.$score_filepath; $out = []; logger($command); - exec( $command, $out); + exec($command, $out); logger(var_dump($out)); Notification::create([ - "message" => 'Converted Score Graph...', - "user_id" => $user_id, - "project_id" => $project->id, - "status" => 2, + 'message' => 'Converted Score Graph...', + 'user_id' => $user_id, + 'project_id' => $project->id, + 'status' => 2, ]); - } - catch(\Exception $ex){ + } catch (\Exception $ex) { logger($ex); } - try{ + try { $scores = new \EasyRdf_Graph; - $scores->parseFile($score_filepath, "ntriples"); + $scores->parseFile($score_filepath, 'ntriples'); Notification::create([ - "message" => 'Parsed and Stored Graphs!!!', - "user_id" => $user_id, - "project_id" => $project->id, - "status" => 2, + 'message' => 'Parsed and Stored Graphs!!!', + 'user_id' => $user_id, + 'project_id' => $project->id, + 'status' => 2, ]); } catch (\Exception $ex) { logger($ex); } - logger("converting files"); - Cache::forever("scores_graph_project" . $project->id, $scores); + logger('converting files'); + Cache::forever('scores_graph_project'.$project->id, $scores); } } diff --git a/app/Jobs/ProjectReady.php b/app/Jobs/ProjectReady.php new file mode 100644 index 0000000..a4f8072 --- /dev/null +++ b/app/Jobs/ProjectReady.php @@ -0,0 +1,49 @@ +project = $project; + $this->user = $user; + } + + /** + * Execute the job. + * + * @return void + */ + public function handle() + { + $this->project->processed = 1; + $this->project->save(); + \App\Notification::create([ + 'message' => 'Project Ready!', + 'user_id' => $this->user, + 'project_id' => $this->project->id, + 'status' => 3, + ]); + } +} diff --git a/app/Jobs/Rapper.php b/app/Jobs/Rapper.php new file mode 100644 index 0000000..bd6d2b6 --- /dev/null +++ b/app/Jobs/Rapper.php @@ -0,0 +1,50 @@ +file = $file; + $this->user = $user; + } + + /** + * Execute the job. + * + * @return void + */ + public function handle() + { + $command = 'rapper -i '.$this->file->filetype.' -o turtle '.$this->file->resource->path().' > '.$this->file->filenameRapper(); + $process = new Process($command); + $process->setTimeout(3600); + $process->run(function ($type, $buffer) { + if (Process::ERR === $type) { + echo 'ERR > '.$buffer; + } else { + echo 'OUT > '.$buffer; + } + }); + } +} diff --git a/app/Jobs/RunSilk.php b/app/Jobs/RunSilk.php index 03640aa..99e2e6d 100644 --- a/app/Jobs/RunSilk.php +++ b/app/Jobs/RunSilk.php @@ -2,32 +2,34 @@ namespace App\Jobs; -use App\User; use App\Project; +use App\User; +use Illuminate\Bus\Queueable; +use Illuminate\Contracts\Queue\ShouldQueue; +use Illuminate\Foundation\Bus\Dispatchable; +use Illuminate\Queue\InteractsWithQueue; use Illuminate\Queue\SerializesModels; use Symfony\Component\Process\Process; -use Illuminate\Queue\InteractsWithQueue; -use Illuminate\Contracts\Queue\ShouldQueue; -use Symfony\Component\Process\Exception\ProcessFailedException; - -class RunSilk extends Job implements ShouldQueue +class RunSilk implements ShouldQueue { - use InteractsWithQueue, SerializesModels; + use InteractsWithQueue, SerializesModels, Dispatchable, Queueable; /** * Create a new job instance. * * @return void */ - protected $project,$user, $configFileName; - + protected $project; + protected $user; + protected $configFileName; + public function __construct(Project $project, User $user) { $this->project = $project; $this->user = $user->id; - $this->configFileName = storage_path() . "/app/projects/project" . $project->id . "/project" . $project->id . "_config.xml"; - $this->checkExistingFile($project->id); + $this->configFileName = storage_path().'/app/projects/project'.$project->id.'/project'.$project->id.'_config.xml'; + $this->checkExistingFile($project->id); } /** @@ -36,44 +38,54 @@ public function __construct(Project $project, User $user) * @return void */ public function handle() - { - $this->runSiLK($this->project); + { + $this->runSiLK($this->project); } - - private function getConfig($filename){ + + private function getConfig($filename) + { $config = array_merge( - ["java"], - config("alignment.silk.config", []), + ['java'], + config('alignment.silk.config', []), [ + '-DconfigFile='.$filename, '-jar', - config("alignment.silk.jar"), - '-DconfigFile=' . $filename - ]); + config('alignment.silk.jar'), + ]); + return $config; } - - public function runSiLK(Project $project) { + + public function runSiLK(Project $project) + { \App\Notification::create([ - "message" => 'Started Job...', - "user_id" => $this->user, - "project_id" => $project->id, - "status" => 2, - ]); + 'message' => 'Started Job...', + 'user_id' => $this->user, + 'project_id' => $project->id, + 'status' => 2, + ]); $config = $this->getConfig($this->configFileName); $process = new Process($config); - $process->run(); + $process->setTimeout(3600); + $process->run(function ($type, $buffer) { + if (Process::ERR === $type) { + echo 'ERR > '.$buffer; + } else { + echo 'OUT > '.$buffer; + } + }); \App\Notification::create([ - "message" => 'Finished SiLK similarities Calculations...', - "user_id" => $this->user, - "project_id" => $project->id, - "status" => 2, + 'message' => 'Finished SiLK similarities Calculations...', + 'user_id' => $this->user, + 'project_id' => $project->id, + 'status' => 2, ]); - dispatch(new \App\Jobs\ParseScores($project, $this->user)); } - - private function checkExistingFile($id){ - if (\Storage::disk("projects")->exists("/project" . $id . "/score_project" . $id . ".nt")) { - \Storage::disk("projects")->delete("/project" . $id . "/score_project" . $id . ".nt"); - } + + private function checkExistingFile($id) + { + if (\Storage::disk('projects')->exists('/project'.$id.'/score_project'.$id.'.nt')) { + \Storage::disk('projects')->delete('/project'.$id.'/score_project'.$id.'.nt'); + } } } diff --git a/app/Jobs/Skosify.php b/app/Jobs/Skosify.php index 577c76e..440ecf1 100644 --- a/app/Jobs/Skosify.php +++ b/app/Jobs/Skosify.php @@ -2,24 +2,48 @@ namespace App\Jobs; +use App\File; +use App\User; use Illuminate\Bus\Queueable; -use Illuminate\Queue\SerializesModels; -use Illuminate\Queue\InteractsWithQueue; use Illuminate\Contracts\Queue\ShouldQueue; use Illuminate\Foundation\Bus\Dispatchable; +use Illuminate\Queue\InteractsWithQueue; +use Illuminate\Queue\SerializesModels; +use Symfony\Component\Process\Process; class Skosify implements ShouldQueue { use Dispatchable, InteractsWithQueue, Queueable, SerializesModels; + protected $file; + + protected $user; + /** * Create a new job instance. * * @return void */ - public function __construct() + public function __construct(File $file, User $user) + { + $this->file = $file; + $this->user = $user; + } + + protected function config() { - // + return [ + 'skosify', + '-f', + 'turtle', + '-F', + 'nt', + $this->file->filenameRapper(), + '-o', + $this->file->filenameSkosify(), + '-c', + storage_path('app/projects/owl2skos.cfg'), + ]; } /** @@ -29,6 +53,14 @@ public function __construct() */ public function handle() { - // + $process = new Process($this->config()); + $process->setTimeout(3600); + $process->run(function ($type, $buffer) { + if (Process::ERR === $type) { + echo 'ERR > '.$buffer; + } else { + echo 'OUT > '.$buffer; + } + }); } } diff --git a/app/LabelExtractor.php b/app/LabelExtractor.php index 33bdc4e..0558cff 100644 --- a/app/LabelExtractor.php +++ b/app/LabelExtractor.php @@ -14,10 +14,10 @@ class LabelExtractor extends Model protected $table = 'label_extractors'; /** - * The database primary key value. - * - * @var string - */ + * The database primary key value. + * + * @var string + */ protected $primaryKey = 'id'; /** diff --git a/app/Link.php b/app/Link.php index ee21481..4955fea 100644 --- a/app/Link.php +++ b/app/Link.php @@ -2,69 +2,193 @@ namespace App; +use Carbon\Carbon; use Illuminate\Database\Eloquent\Model; use Illuminate\Database\Eloquent\ModelNotFoundException; use Illuminate\Database\Eloquent\SoftDeletes; - +use Illuminate\Http\Request; class Link extends Model { use SoftDeletes; - protected $fillable = ['source_id', 'target_id','source_entity','target_entity', 'user_id']; - + + protected $fillable = ['source_id', 'target_id', 'source_entity', 'target_entity', 'user_id']; protected $dates = ['deleted_at']; - - public function project(){ + + public function project() + { return $this->belongsTo("App\Project"); } - - public function user(){ + + public function user() + { return $this->belongsTo("App\User"); } - + public function source() { - return $this->hasOne('App\File','id','source_id'); + return $this->hasOne('App\File', 'id', 'source_id'); } - - + public function target() { - return $this->hasOne('App\File','id','target_id'); + return $this->hasOne('App\File', 'id', 'target_id'); } - + public function votes() { return $this->hasMany('App\Vote'); } - public function myVote(){ - try{ - $vote = \App\Vote::where("user_id", "=", auth()->user()->id)->where("link_id", "=", $this->id)->firstOrFail(); - } - catch (ModelNotFoundException $ex){ + + public function myVote() + { + try { + $vote = \App\Vote::where('user_id', '=', auth()->user()->id)->where('link_id', '=', $this->id)->firstOrFail(); + } catch (ModelNotFoundException $ex) { $vote = null; } + return $vote; } - + public function comments() { return $this->hasMany('App\Comment'); } - - public function humanize(){ - $project = \App\Project::find($this->attributes["project_id"]); + + public function humanize() + { + $project = \App\Project::find($this->attributes['project_id']); $source_graph = $project->source->cacheGraph(); - $target_graph = $project->target->cacheGraph(); + $target_graph = $project->target->cacheGraph(); $ontologies_graph = \Illuminate\Support\Facades\Cache::get('ontologies_graph'); - $source_label = \App\RDFTrait::label($source_graph, $this->source_entity)? : EasyRdf_Namespace::shorten($this->source_entity, true); + $source_label = \App\RDFTrait::label($source_graph, $this->source_entity) ?: EasyRdf_Namespace::shorten($this->source_entity, true); $this->source_label = $source_label; - $target_label = \App\RDFTrait::label($target_graph, $this->target_entity)? : EasyRdf_Namespace::shorten($this->target_entity, true); + $target_label = \App\RDFTrait::label($target_graph, $this->target_entity) ?: EasyRdf_Namespace::shorten($this->target_entity, true); $this->target_label = $target_label; - $link_label = \App\RDFTrait::label($ontologies_graph, $this->link_type)? : EasyRdf_Namespace::shorten($this->link_type, true); + $link_label = \App\RDFTrait::label($ontologies_graph, $this->link_type) ?: EasyRdf_Namespace::shorten($this->link_type, true); $this->link_label = $link_label; $vote = $this->myVote(); $this->myvote = $vote != null ? $vote->vote : null; + return $this; } + + public static function create(Request $request, array $attributes = []) + { + $link = static::query()->create($attributes); + $project = Project::find($request->project_id); + $link->project_id = $request->project_id; + $link->source_entity = $request->source; + $link->target_entity = $request->target; + $link->link_type = $request->link_type; + $link->source_id = $project->source_id; + $link->target_id = $project->target_id; + $link->user_id = isset(auth()->user()->id) ? auth()->user()->id : 1; + $link->save(); + + return $link; + } + + public static function existing(Request $request) + { + return $link = self::where('project_id', '=', $request->project_id) + ->where('source_entity', '=', $request->source) + ->where('target_entity', '=', $request->target) + ->where('link_type', '=', $request->link_type) + ->first(); + } + + public function getConfidence(self $link) + { + $upVotes = $link->up_votes; + $downVotes = $link->down_votes; + $totalVotes = $upVotes + $downVotes; + if ($totalVotes > 0) { + return (float) $upVotes / $totalVotes; + } else { + return 0; + } + } + + public static function createGraph($links) + { + $graph = new \EasyRdf_Graph; + foreach ($links as $link) { + $graph->addResource($link->source_entity, $link->link_type, $link->target_entity); + } + + return $graph; + } + + public static function linkGraph(User $user, $project_id = null) + { + $project = Project::find($project_id); + if ($project == null) { + $links = $user->links; + } else { + $links = $project->links; + } + + return self::createGraph($links); + } + + public static function votedLinks(Request $request) + { + $links = self::where('project_id', '=', $request->project_id) + ->when(isset($request->score), function ($query) use ($request) { + return $query->where('score', '>', $request->score); + }) + ->get(); + $filtered_links = $links->filter(function ($link) use ($request) { + return $link->confidence >= $request->threshold / 100; + }); + + return $filtered_links; + } + + public static function filename($format, $project_id = null) + { + $project = Project::find($project_id); + $File_Ext = \EasyRdf_Format::getFormat($format)->getDefaultExtension(); //get file extention + $dt = Carbon::now(); + $time = str_slug($dt->format('Y m d His')); + $filename = []; + if ($project_id == null) { + $filename['filename'] = 'Export'.$time.'.'.$File_Ext; + $filename['path'] = storage_path().'/app/projects/'.$filename['filename']; + } else { + $filename['filename'] = 'Alignment_Export_'.str_slug($project->name).'_'.$time.'.'.$File_Ext; + $filename['path'] = storage_path().'/app/projects/project'.$project_id.'/'.$filename['filename']; + } + + return $filename; + } + + public static function downloadFile($file, $name, $format) + { // $file = include path + if (file_exists($file)) { + header('Content-Description: File Transfer'); + header('Content-Disposition: attachment; filename='.$name); + header('Content-Transfer-Encoding: binary'); + header('Expires: 0'); + header('Cache-Control: must-revalidate, post-check=0, pre-check=0'); + header('Pragma: public'); + header('Content-Length: '.filesize($file)); + header('Content-Type: '.$format); + ob_clean(); + flush(); + readfile($file); + unlink($file); + exit; + } + } + + public static function exportFile(\EasyRdf_Graph $graph, $format, $project_id) + { + $export = $graph->serialise($format); + $file = self::filename($format, $project_id); + file_put_contents($file['path'], $export); + self::downLoadFile($file['path'], $file['filename'], $format); + } } diff --git a/app/LinkType.php b/app/LinkType.php index 817ca7c..0e08ddb 100644 --- a/app/LinkType.php +++ b/app/LinkType.php @@ -6,9 +6,10 @@ class LinkType extends Model { - protected $fillable = [ 'user_id', 'group', 'value', 'inner', 'public']; - - public function user(){ + protected $fillable = ['user_id', 'group', 'value', 'inner', 'public']; + + public function user() + { return $this->belongsTo("App\User"); } } diff --git a/app/Listeners/CreateLinkEventListener.php b/app/Listeners/CreateLinkEventListener.php index 39f88a1..41e09a3 100644 --- a/app/Listeners/CreateLinkEventListener.php +++ b/app/Listeners/CreateLinkEventListener.php @@ -3,8 +3,6 @@ namespace App\Listeners; use App\Events\CreateLinkEvent; -use Illuminate\Queue\InteractsWithQueue; -use Illuminate\Contracts\Queue\ShouldQueue; class CreateLinkEventListener { @@ -26,7 +24,6 @@ public function __construct() */ public function handle(CreateLinkEvent $event) { - return view('utility.info.successnotofication')->with('Link created!!!'); } } diff --git a/app/Listeners/EventListener.php b/app/Listeners/EventListener.php index e9ce565..87b7e12 100644 --- a/app/Listeners/EventListener.php +++ b/app/Listeners/EventListener.php @@ -3,8 +3,6 @@ namespace App\Listeners; use App\Events\SomeEvent; -use Illuminate\Queue\InteractsWithQueue; -use Illuminate\Contracts\Queue\ShouldQueue; class EventListener { diff --git a/app/Models/OntologyTypeDriver.php b/app/Models/OntologyTypeDriver.php index 25b8cde..7a48563 100644 --- a/app/Models/OntologyTypeDriver.php +++ b/app/Models/OntologyTypeDriver.php @@ -1,16 +1,19 @@ makeDirectory("project" . $project->id); + Storage::disk('projects')->makeDirectory('project'.$project->id); //copy source ontology - $suffix1 = ($project->source->filetype != 'ntriples' ) ? '.nt' : ''; - $source = file_get_contents($project->source->resource->path() . $suffix1); - Storage::disk("projects")->put("/project" . $project->id . "/source.nt", $source); + $suffix1 = ($project->source->filetype != 'ntriples') ? '.nt' : ''; + $source = file_get_contents($project->source->resource->path().$suffix1); + Storage::disk('projects')->put('/project'.$project->id.'/source.nt', $source); //copy target ontology - $suffix2 = ($project->target->filetype != 'ntriples' ) ? '.nt' : ''; - $target = file_get_contents($project->target->resource->path() . $suffix2); - Storage::disk("projects")->put("/project" . $project->id . "/target.nt", $target); + $suffix2 = ($project->target->filetype != 'ntriples') ? '.nt' : ''; + $target = file_get_contents($project->target->resource->path().$suffix2); + Storage::disk('projects')->put('/project'.$project->id.'/target.nt', $target); //create the config $newConfig = $this->reconstruct($project->settings->id); - Storage::disk("projects")->put("/project" . $project->id . "/project" . $project->id . "_config.xml", $newConfig); + Storage::disk('projects')->put('/project'.$project->id.'/project'.$project->id.'_config.xml', $newConfig); + return 0; } - public function reconstruct($id) { + public function reconstruct($id) + { $settings = Settings::find($id); $settings_xml = file_get_contents($settings->resource->path()); $new = $this->parseXML($settings_xml); @@ -54,152 +57,169 @@ public function reconstruct($id) { $prefixes->first(), $newDatasource, $linkage->first(), - $newOutput + $newOutput, ] ); + return $xml; } - public function getNode($collection, $name) { - $node = collect($collection->where("name", $name)); + public function getNode($collection, $name) + { + $node = collect($collection->where('name', $name)); + return $node; } - public function parseXML($xml) { - + public function parseXML($xml) + { $service = new \Sabre\Xml\Service(); $result = collect($service->parse($xml)); + return $result; } - public function createOutput($originalOutput) { - $minConcfidence = $originalOutput["value"][0]["attributes"]["minConfidence"]; + public function createOutput($originalOutput) + { + $minConcfidence = $originalOutput['value'][0]['attributes']['minConfidence']; $newOutput = [ - "name" => "Outputs", - "value" => [ + 'name' => 'Outputs', + 'value' => [ [ - "name" => "Output", - "value" => [ + 'name' => 'Output', + 'value' => [ [ - "name" => "Param", - "value" => null, - "attributes" => [ - "name" => "file", - "value" => "score.nt" - ] + 'name' => 'Param', + 'value' => null, + 'attributes' => [ + 'name' => 'file', + 'value' => 'score.nt', + ], ], [ - "name" => "Param", - "value" => null, - "attributes" => [ - "name" => "format", - "value" => "N-Triples" - ] - ] + 'name' => 'Param', + 'value' => null, + 'attributes' => [ + 'name' => 'format', + 'value' => 'N-Triples', + ], + ], + ], + 'attributes' => [ + 'id' => 'score', + 'type' => 'alignment', + 'minConfidence' => $minConcfidence, ], - "attributes" => [ - "id" => "score", - "type" => "alignment", - "minConfidence" => $minConcfidence - ] - ] + ], ], - "attributes" => [] + 'attributes' => [], ]; + return $newOutput; } - public function filenameTemplate($filename) { - return [ "name" => "{}Param", - "value" => null, - "attributes" => [ - "name" => "file", - "value" => $filename - ] + public function filenameTemplate($filename) + { + return ['name' => '{}Param', + 'value' => null, + 'attributes' => [ + 'name' => 'file', + 'value' => $filename, + ], ]; } - public function formatTemplate() { - return [ "name" => "{}Param", - "value" => null, - "attributes" => [ - "name" => "format", - "value" => "N-Triples" - ] + public function formatTemplate() + { + return ['name' => '{}Param', + 'value' => null, + 'attributes' => [ + 'name' => 'format', + 'value' => 'N-Triples', + ], ]; } - public function createDataset($dataset, $filename) { - $name = $dataset["name"]; + public function createDataset($dataset, $filename) + { + $name = $dataset['name']; $file = $this->filenameTemplate($filename); $format = $this->formatTemplate(); - $graph = isset($dataset["value"][2]) ? $dataset["value"][2] : null; - $attributes = $dataset["attributes"]; + $graph = isset($dataset['value'][2]) ? $dataset['value'][2] : null; + $attributes = $dataset['attributes']; + return [ - "name" => $name, - "value" => [ + 'name' => $name, + 'value' => [ $file, $format, - $graph + $graph, ], - "attributes" => $attributes + 'attributes' => $attributes, ]; } - public function createDatasource($originalDataSource) { - $source = $this->createDataset($originalDataSource["value"][0], "source.nt"); - $target = $this->createDataset($originalDataSource["value"][1], "target.nt"); + public function createDatasource($originalDataSource) + { + $source = $this->createDataset($originalDataSource['value'][0], 'source.nt'); + $target = $this->createDataset($originalDataSource['value'][1], 'target.nt'); + return [ - "name" => "DataSources", - "value" => [ + 'name' => 'DataSources', + 'value' => [ $source, $target, ], - "attributes" => [] + 'attributes' => [], ]; } - public function validateSettingsFile(Settings $settings) { - + public function validateSettingsFile(Settings $settings) + { libxml_use_internal_errors(true); $schema = $this->validateSchema($settings->resource->path()); $validationError = \App\ValidationError::create(); $validationError->bag = $schema; $validationError->setting_id = $settings->id; $validationError->save(); + return $validationError; } - public function validateXML($xml) { + public function validateXML($xml) + { return 1; } - public function validateAlignment(Settings $settings) { + public function validateAlignment(Settings $settings) + { $xml = file_get_contents($settings->resource->path()); $parsed = $this->parseXML($xml); $linkage = $this->getNode($parsed, $this->nodes[2]); - $source = $linkage[2]["value"][0]["value"][0]["attributes"]["dataSource"]; - if ($source != "source.nt") { + $source = $linkage[2]['value'][0]['value'][0]['attributes']['dataSource']; + if ($source != 'source.nt') { return 0; } } - public function validateSchema($file) { + public function validateSchema($file) + { libxml_use_internal_errors(true); $xml = new \DOMDocument(); $errors = []; - if (!$xml->load($file)) { + if (! $xml->load($file)) { foreach (libxml_get_errors() as $error) { array_push($errors, $error); } libxml_clear_errors(); } - $schema = storage_path() . "/app/projects/LinkSpecificationLanguage.xsd"; + $schema = storage_path().'/app/projects/LinkSpecificationLanguage.xsd'; $bag = [ - "valid" => $xml->schemaValidate($schema), - "errors" => $errors + 'valid' => $xml->schemaValidate($schema), + 'errors' => $errors, ]; + return collect($bag); - } + } } diff --git a/app/Models/SuggestionProvider.php b/app/Models/SuggestionProvider.php index 184e3c5..2cc8d05 100644 --- a/app/Models/SuggestionProvider.php +++ b/app/Models/SuggestionProvider.php @@ -6,18 +6,18 @@ class SuggestionProvider extends Model { - protected $fillable = [ "name", "description", "configuration"]; + protected $fillable = ['name', 'description', 'configuration']; - public function validate(\App\Settings $settings){ + public function validate(\App\Settings $settings) + { $configuration = new $this->configuration(); $settings->valid = json_decode($configuration->validateSettingsFile($settings)->bag)->valid; $settings->save(); } - public function prepare(\App\Project $project){ + public function prepare(\App\Project $project) + { $configuration = new $this->configuration(); $configuration->prepareProject($project); } - - } diff --git a/app/Notification.php b/app/Notification.php index aa47b22..b5f711e 100644 --- a/app/Notification.php +++ b/app/Notification.php @@ -6,11 +6,12 @@ class Notification extends Model { - protected $fillable = ['user_id', 'project_id','message','status', 'read']; - + protected $fillable = ['user_id', 'project_id', 'message', 'status', 'read']; + protected $dates = ['deleted_at']; - - public function user(){ + + public function user() + { return $this->belongsTo("App\User"); } -} \ No newline at end of file +} diff --git a/app/Policies/FilePolicy.php b/app/Policies/FilePolicy.php index 112ea63..14ac90a 100644 --- a/app/Policies/FilePolicy.php +++ b/app/Policies/FilePolicy.php @@ -2,11 +2,9 @@ namespace App\Policies; -use Illuminate\Auth\Access\HandlesAuthorization; - -use App\User; - use App\File; +use App\User; +use Illuminate\Auth\Access\HandlesAuthorization; class FilePolicy { @@ -21,14 +19,13 @@ public function __construct() { // } + public function destroy(User $user, File $file) { - if(count($file->projects)==0){ + if (count($file->projects) == 0) { return $user->id === $file->user_id; - } - else{ + } else { return false; } - } } diff --git a/app/Policies/LinkPolicy.php b/app/Policies/LinkPolicy.php index f205d62..72eaeee 100644 --- a/app/Policies/LinkPolicy.php +++ b/app/Policies/LinkPolicy.php @@ -2,11 +2,9 @@ namespace App\Policies; -use Illuminate\Auth\Access\HandlesAuthorization; - -use App\User; - use App\Link; +use App\User; +use Illuminate\Auth\Access\HandlesAuthorization; class LinkPolicy { @@ -21,9 +19,11 @@ public function __construct() { // } + public function destroy(User $user, Link $link) { $project = $link->project; + return $user->id === $project->user_id || $user->id === $link->user_id; } } diff --git a/app/Policies/ProjectPolicy.php b/app/Policies/ProjectPolicy.php index ecda9f4..ae4b840 100644 --- a/app/Policies/ProjectPolicy.php +++ b/app/Policies/ProjectPolicy.php @@ -2,11 +2,9 @@ namespace App\Policies; -use Illuminate\Auth\Access\HandlesAuthorization; - -use App\User; - use App\Project; +use App\User; +use Illuminate\Auth\Access\HandlesAuthorization; class ProjectPolicy { @@ -21,7 +19,7 @@ public function __construct() { // } - + public function destroy(User $user, Project $project) { return $user->id === $project->user_id; diff --git a/app/Poll.php b/app/Poll.php index a49d399..c415947 100644 --- a/app/Poll.php +++ b/app/Poll.php @@ -6,18 +6,20 @@ class Poll extends Model { - protected $fillable = ['source_id', 'target_id','project_id', 'user_id', 'links']; - - public function project(){ + protected $fillable = ['source_id', 'target_id', 'project_id', 'user_id', 'links']; + + public function project() + { return $this->belongsTo("App\Project"); } - - public function source(){ + + public function source() + { return $this->hasOne("App\File", 'id', 'id_source'); } - - public function target(){ + + public function target() + { return $this->hasOne("App\File", 'id', 'id_target'); } - } diff --git a/app/Prefix.php b/app/Prefix.php index caf04fc..e28c011 100644 --- a/app/Prefix.php +++ b/app/Prefix.php @@ -9,5 +9,3 @@ class Prefix extends Model //Model to include new namespaces, mostly for beautification reasons. protected $fillable = ['prefix', 'namespace']; } - - diff --git a/app/Project.php b/app/Project.php index 9ad1f36..fd6954a 100644 --- a/app/Project.php +++ b/app/Project.php @@ -6,30 +6,30 @@ class Project extends Model { - protected $fillable = ['user_id', 'source_id', 'target_id','name','settings_id', 'public']; - - public function user(){ + protected $fillable = ['user_id', 'source_id', 'target_id', 'name', 'settings_id', 'public']; + + public function user() + { return $this->belongsTo("App\User"); } - + public function source() { - return $this->hasOne('App\File','id','source_id'); + return $this->hasOne('App\File', 'id', 'source_id'); } - + public function target() { - return $this->hasOne('App\File','id','target_id'); + return $this->hasOne('App\File', 'id', 'target_id'); } - + public function links() { return $this->hasMany('App\Link'); } - + public function settings() { - return $this->hasOne('App\Settings','id','settings_id'); + return $this->hasOne('App\Settings', 'id', 'settings_id'); } - } diff --git a/app/Providers/EventServiceProvider.php b/app/Providers/EventServiceProvider.php index f0a817f..12ecd7a 100644 --- a/app/Providers/EventServiceProvider.php +++ b/app/Providers/EventServiceProvider.php @@ -2,8 +2,8 @@ namespace App\Providers; -use Illuminate\Support\Facades\Event; use Illuminate\Foundation\Support\Providers\EventServiceProvider as ServiceProvider; +use Illuminate\Support\Facades\Event; class EventServiceProvider extends ServiceProvider { @@ -13,8 +13,8 @@ class EventServiceProvider extends ServiceProvider * @var array */ protected $listen = [ - 'App\Events\SomeEvent' => ['App\Listeners\EventListener',], - 'App\Events\CreateLinkEvent' => ['App\Listeners\CreateLinkEventListener',], + 'App\Events\SomeEvent' => ['App\Listeners\EventListener'], + 'App\Events\CreateLinkEvent' => ['App\Listeners\CreateLinkEventListener'], ]; /** diff --git a/app/Providers/ResponseServiceProvider.php b/app/Providers/ResponseServiceProvider.php index 8f7fa9c..32d7764 100644 --- a/app/Providers/ResponseServiceProvider.php +++ b/app/Providers/ResponseServiceProvider.php @@ -2,8 +2,8 @@ namespace App\Providers; -use Illuminate\Support\ServiceProvider; use Illuminate\Support\Facades\Response; +use Illuminate\Support\ServiceProvider; class ResponseServiceProvider extends ServiceProvider { @@ -14,17 +14,18 @@ class ResponseServiceProvider extends ServiceProvider */ public function boot() { - Response::macro("downloadFromCache", function($content, $format, $filename){ + Response::macro('downloadFromCache', function ($content, $format, $filename) { $File_Ext = \EasyRdf_Format::getFormat($format)->getDefaultExtension(); //get file extention $headers = [ 'Content-Description' => 'File Transfer', - 'Content-Disposition' => 'attachment; filename=' . $filename. '.' .$File_Ext, + 'Content-Disposition' => 'attachment; filename='.$filename.'.'.$File_Ext, 'Content-Transfer-Encoding' => 'binary', 'Expires' => '0', 'Cache-Control' => 'must-revalidate, post-check=0, pre-check=0', - 'Pragma' => 'public', - 'Content-Type' => $format + 'Pragma' => 'public', + 'Content-Type' => $format, ]; + return Response::make($content, 200, $headers); }); } diff --git a/app/Providers/RouteServiceProvider.php b/app/Providers/RouteServiceProvider.php index 532e0b1..041ee47 100644 --- a/app/Providers/RouteServiceProvider.php +++ b/app/Providers/RouteServiceProvider.php @@ -1,8 +1,9 @@ namespace($this->namespace) ->group(base_path('routes/api.php')); } -} \ No newline at end of file +} diff --git a/app/RDFTrait.php b/app/RDFTrait.php index 7338e4a..fdd24eb 100644 --- a/app/RDFTrait.php +++ b/app/RDFTrait.php @@ -2,8 +2,8 @@ namespace App; -use Illuminate\Support\Facades\Cookie; use Illuminate\Http\Request; +use Illuminate\Support\Facades\Cookie; trait RDFTrait { @@ -14,29 +14,33 @@ trait RDFTrait * method checks for \W preg_match. When hyphens are included on the prefix, * these lines cause this method to fail when serializing graphs into files */ - public static function setNamespaces(){ - $namespaces = \App\rdfnamespace::where('added','=','1')->get(); - foreach ($namespaces as $namespace){ + public static function setNamespaces() + { + $namespaces = \App\rdfnamespace::where('added', '=', '1')->get(); + foreach ($namespaces as $namespace) { \EasyRdf_Namespace::set($namespace->prefix, $namespace->uri); } + return 0; } - - public static function uknownNamespace($uri){ + + public static function uknownNamespace($uri) + { $tempnamespace = new \EasyRdf_Resource($uri); $local = $tempnamespace->localName(); - + $namespace = mb_substr($uri, 0, -mb_strlen($local)); $existing = \App\rdfnamespace::where('uri', '=', $namespace)->get(); - if($existing->isEmpty()){ + if ($existing->isEmpty()) { \App\rdfnamespace::create(['prefix'=>'null', 'uri'=>$namespace, - 'added'=> 0 + 'added'=> 0, ]); } + return $uri; } - + /* * Function to merge two graphs. Taken from https://gist.github.com/indeyets/a1e5c9882c778dd60713. * @@ -45,28 +49,29 @@ public static function uknownNamespace($uri){ * * @return EasyRdf_Graph */ - - public static function mergeGraphs(\EasyRdf_Graph $graph1, \EasyRdf_Graph $graph2){ + + public static function mergeGraphs(\EasyRdf_Graph $graph1, \EasyRdf_Graph $graph2) + { $data1 = $graph1->toRdfPhp(); $data2 = $graph2->toRdfPhp(); $merged = array_merge_recursive($data1, $data2); unset($data1, $data2); + return new \EasyRdf_Graph('urn:easyrdf:merged', $merged, 'php'); } - - - + /* function to get the label of a resource based on 4 rules by priority: * 1)Get the browser locale setting and request this language * 2)Get the label for the default language set * 3)Get any label in any language * 4)Return the IRI as a string to use for label - * + * */ - public static function label(\EasyRdf_Graph $graph, $uri) { - $label_properties = - \App\LabelExtractor::where('enabled','=', '1') - ->orderBy('priority','asc') + public static function label(\EasyRdf_Graph $graph, $uri) + { + $label_properties = + \App\LabelExtractor::where('enabled', '=', '1') + ->orderBy('priority', 'asc') ->get(); $label = null; $locale = Cookie::get('locale'); @@ -99,11 +104,10 @@ public static function label(\EasyRdf_Graph $graph, $uri) { ); } } - if($label == null){ + if ($label == null) { $label = \EasyRdf_Namespace::shorten($uri, true); } + return $label; } - - } diff --git a/app/Settings.php b/app/Settings.php index d7725a3..577b0d4 100644 --- a/app/Settings.php +++ b/app/Settings.php @@ -2,46 +2,50 @@ namespace App; -use Illuminate\Database\Eloquent\Model; -use Codesleeve\Stapler\ORM\StaplerableInterface; use Codesleeve\Stapler\ORM\EloquentTrait; +use Codesleeve\Stapler\ORM\StaplerableInterface; +use Illuminate\Database\Eloquent\Model; class Settings extends Model implements StaplerableInterface - { use EloquentTrait; protected $fillable = [ - 'name', 'user_id', 'public', 'valid', 'resource', 'suggestion_provider_id' + 'name', 'user_id', 'public', 'valid', 'resource', 'suggestion_provider_id', ]; - - public function __construct(array $attributes = array()) { + + public function __construct(array $attributes = []) + { $this->hasAttachedFile('resource', [ - + ]); parent::__construct($attributes); } - - public function projects(){ + + public function projects() + { return $this->belongsToMany("App\Project", 'projects', 'settings_id'); } /** * @return \Illuminate\Database\Eloquent\Relations\HasOne */ - public function provider(){ - return $this->belongsTo("\App\Models\SuggestionProvider", "suggestion_provider_id" ); + public function provider() + { + return $this->belongsTo("\App\Models\SuggestionProvider", 'suggestion_provider_id'); } - public function user(){ + public function user() + { return $this->belongsTo("App\User"); } - - public function getDirty() { + + public function getDirty() + { $dirty = parent::getDirty(); return array_filter($dirty, function ($var) { - return !($var instanceof \Codesleeve\Stapler\Attachment); + return ! ($var instanceof \Codesleeve\Stapler\Attachment); }); } } diff --git a/app/SocialAccountService.php b/app/SocialAccountService.php index 068ba65..9645af9 100644 --- a/app/SocialAccountService.php +++ b/app/SocialAccountService.php @@ -9,14 +9,12 @@ class SocialAccountService public function createOrGetUser(ProviderUser $providerUser) { $routeName = request()->route()->getName(); - if ($routeName == "github.callback"){ + if ($routeName == 'github.callback') { $provider = 'github'; - } - else if ($routeName == 'google.callback'){ - $provider = "google"; - } - else if ($routeName == 'facebook.callback'){ - $provider = "facebook"; + } elseif ($routeName == 'google.callback') { + $provider = 'google'; + } elseif ($routeName == 'facebook.callback') { + $provider = 'facebook'; } $account = SocialAccount::whereProvider($provider) ->whereProviderUserId($providerUser->getId()) @@ -26,23 +24,24 @@ public function createOrGetUser(ProviderUser $providerUser) } else { $account = new SocialAccount([ 'provider_user_id' => $providerUser->getId(), - 'provider' => $provider + 'provider' => $provider, ]); $user = User::whereEmail($providerUser->getEmail())->first(); - if (!$user) { - try{ + if (! $user) { + try { $user = User::create([ - 'email' => $providerUser->offsetExists("email") ? $providerUser->getEmail() : "no email", - 'name' => $providerUser->offsetExists("name") ? $providerUser->getName() : "default name", - 'avatar' => $providerUser->offsetExists("avatar") ? $providerUser->getAvatar() : "", - ]); + 'email' => $providerUser->offsetExists('email') ? $providerUser->getEmail() : 'no email', + 'name' => $providerUser->offsetExists('name') ? $providerUser->getName() : 'default name', + 'avatar' => $providerUser->offsetExists('avatar') ? $providerUser->getAvatar() : '', + ]); } catch (Exception $ex) { return $ex; - } + } } $account->user()->associate($user); $account->save(); + return $user; } } -} \ No newline at end of file +} diff --git a/app/User.php b/app/User.php index b53c157..f5e9737 100644 --- a/app/User.php +++ b/app/User.php @@ -22,42 +22,70 @@ class User extends Authenticatable */ protected $hidden = [ 'password', 'remember_token', - ]; - - public function links(){ + ]; + + public function links() + { return $this->hasMany("App\Link"); } - public function projects(){ + public function projects() + { return $this->hasMany("App\Project"); } - - public function files(){ + + public function files() + { return $this->hasMany("App\File"); } - - public function votes(){ + + public function votes() + { return $this->hasMany("App\Vote"); } - - public function comments(){ + + public function comments() + { return $this->hasMany("App\Comment"); } - - public function social(){ + + public function social() + { return $this->hasMany("App\SocialAccount"); } - - public function userGraphs(){ - return $this->ownGraphs()->merge($this->publicGraphs()); + + public function userGraphs() + { + return $this->ownGraphs()->merge($this->publicGraphs()); } - - public function ownGraphs(){ - return File::where("user_id", $this->id)->withCount("projects")->with("projects")->get(); + + public function ownGraphs() + { + return File::where('user_id', $this->id)->withCount('projects')->with('projects')->get(); } - - public function publicGraphs(){ - return File::where("public", true)->where("user_id", "!=", $this->id)->withCount("projects")->with("projects")->get(); + + public function publicGraphs() + { + return File::where('public', true)->where('user_id', '!=', $this->id)->withCount('projects')->with('projects')->get(); + } + + public function userAccessibleProjects() + { + $projects = Project::where('user_id', '=', $this->id) + ->orWhere('public', '=', true) + ->get(); + + return $projects; + } + + public function userAccessibleProjectsArray() + { + $projects = $this->userAccessibleProjects(); + $select = []; + foreach ($projects as $project) { + $select = array_add($select, $project->id, $project->name); + } + + return $select; } - } diff --git a/app/ValidationError.php b/app/ValidationError.php index f84bed5..23cd44e 100644 --- a/app/ValidationError.php +++ b/app/ValidationError.php @@ -7,8 +7,9 @@ class ValidationError extends Model { protected $fillable = ['setting_id', 'bag']; - - public function setting(){ + + public function setting() + { return $this->belongsTo("App\Setting"); - } + } } diff --git a/app/Vote.php b/app/Vote.php index fc9706a..4eb331b 100644 --- a/app/Vote.php +++ b/app/Vote.php @@ -7,12 +7,14 @@ class Vote extends Model { protected $fillable = ['user_id', 'link_id', 'vote']; - - public function user(){ + + public function user() + { return $this->belongsTo("App\User"); } - - public function link(){ + + public function link() + { return $this->hasOne("App\Link", 'id', 'link_id'); - } + } } diff --git a/app/rdfnamespace.php b/app/rdfnamespace.php index 1cb66a2..a9c3bf2 100644 --- a/app/rdfnamespace.php +++ b/app/rdfnamespace.php @@ -14,10 +14,10 @@ class rdfnamespace extends Model protected $table = 'rdfnamespaces'; /** - * The database primary key value. - * - * @var string - */ + * The database primary key value. + * + * @var string + */ protected $primaryKey = 'id'; /** diff --git a/composer.lock b/composer.lock index 21e1430..d8bc3d6 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,6 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", "This file is @generated automatically" ], - "hash": "7b87e6cbb1f13309753fd0338f885c12", "content-hash": "c9899c3826ee8be90a069b69c26aa482", "packages": [ { @@ -78,7 +77,7 @@ "template", "theme" ], - "time": "2018-03-14 17:20:41" + "time": "2018-03-14T17:20:41+00:00" }, { "name": "acacha/filesystem", @@ -130,7 +129,7 @@ "acacha", "filesystem" ], - "time": "2017-08-31 14:32:51" + "time": "2017-08-31T14:32:51+00:00" }, { "name": "acacha/helpers", @@ -186,7 +185,7 @@ "helpers", "laravel" ], - "time": "2017-06-20 13:28:48" + "time": "2017-06-20T13:28:48+00:00" }, { "name": "acacha/user", @@ -240,7 +239,7 @@ "acacha", "user" ], - "time": "2016-12-05 13:39:37" + "time": "2016-12-05T13:39:37+00:00" }, { "name": "barryvdh/laravel-debugbar", @@ -308,7 +307,7 @@ "profiler", "webprofiler" ], - "time": "2018-03-06 08:35:31" + "time": "2018-03-06T08:35:31+00:00" }, { "name": "barryvdh/laravel-ide-helper", @@ -381,7 +380,7 @@ "phpstorm", "sublime" ], - "time": "2018-02-08 07:56:07" + "time": "2018-02-08T07:56:07+00:00" }, { "name": "barryvdh/reflection-docblock", @@ -430,7 +429,7 @@ "email": "mike.vanriel@naenius.com" } ], - "time": "2016-06-13 19:28:20" + "time": "2016-06-13T19:28:20+00:00" }, { "name": "codesleeve/laravel-stapler", @@ -480,7 +479,7 @@ "stapler", "upload" ], - "time": "2017-10-21 19:45:46" + "time": "2017-10-21T19:45:46+00:00" }, { "name": "codesleeve/stapler", @@ -580,7 +579,7 @@ "gravatar", "laravel" ], - "time": "2018-03-29 22:10:58" + "time": "2018-03-29T22:10:58+00:00" }, { "name": "dnoegel/php-xdg-base-dir", @@ -613,7 +612,7 @@ "MIT" ], "description": "implementation of xdg base directory specification for php", - "time": "2014-10-24 07:27:01" + "time": "2014-10-24T07:27:01+00:00" }, { "name": "doctrine/annotations", @@ -681,7 +680,7 @@ "docblock", "parser" ], - "time": "2017-12-06 07:11:42" + "time": "2017-12-06T07:11:42+00:00" }, { "name": "doctrine/cache", @@ -755,7 +754,7 @@ "cache", "caching" ], - "time": "2017-08-25 07:02:50" + "time": "2017-08-25T07:02:50+00:00" }, { "name": "doctrine/collections", @@ -822,7 +821,7 @@ "collections", "iterator" ], - "time": "2017-07-22 10:37:32" + "time": "2017-07-22T10:37:32+00:00" }, { "name": "doctrine/common", @@ -895,7 +894,7 @@ "persistence", "spl" ], - "time": "2016-11-30 16:50:46" + "time": "2016-11-30T16:50:46+00:00" }, { "name": "doctrine/dbal", @@ -966,7 +965,7 @@ "persistence", "queryobject" ], - "time": "2016-01-05 22:11:12" + "time": "2016-01-05T22:11:12+00:00" }, { "name": "doctrine/inflector", @@ -1033,7 +1032,7 @@ "singularize", "string" ], - "time": "2018-01-09 20:05:19" + "time": "2018-01-09T20:05:19+00:00" }, { "name": "doctrine/lexer", @@ -1087,27 +1086,27 @@ "lexer", "parser" ], - "time": "2014-09-09 13:34:57" + "time": "2014-09-09T13:34:57+00:00" }, { "name": "dragonmantank/cron-expression", - "version": "v2.0.0", + "version": "v2.1.0", "source": { "type": "git", "url": "https://github.com/dragonmantank/cron-expression.git", - "reference": "8a84aee649c3a3ba03a721c1fb080e08dfbcd68b" + "reference": "3f00985deec8df53d4cc1e5c33619bda1ee309a5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/dragonmantank/cron-expression/zipball/8a84aee649c3a3ba03a721c1fb080e08dfbcd68b", - "reference": "8a84aee649c3a3ba03a721c1fb080e08dfbcd68b", + "url": "https://api.github.com/repos/dragonmantank/cron-expression/zipball/3f00985deec8df53d4cc1e5c33619bda1ee309a5", + "reference": "3f00985deec8df53d4cc1e5c33619bda1ee309a5", "shasum": "" }, "require": { "php": ">=7.0.0" }, "require-dev": { - "phpunit/phpunit": "~5.7" + "phpunit/phpunit": "~6.4" }, "type": "library", "autoload": { @@ -1136,7 +1135,7 @@ "cron", "schedule" ], - "time": "2017-10-12 15:59:13" + "time": "2018-04-06T15:51:55+00:00" }, { "name": "easyrdf/easyrdf", @@ -1203,20 +1202,20 @@ "irc": "irc://chat.freenode.net/easyrdf", "source": "https://github.com/skarampatakis/easyrdf/tree/okgreece" }, - "time": "2017-01-17 14:01:43" + "time": "2017-01-17T14:01:43+00:00" }, { "name": "egulias/email-validator", - "version": "2.1.3", + "version": "2.1.4", "source": { "type": "git", "url": "https://github.com/egulias/EmailValidator.git", - "reference": "1bec00a10039b823cc94eef4eddd47dcd3b2ca04" + "reference": "8790f594151ca6a2010c6218e09d96df67173ad3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/egulias/EmailValidator/zipball/1bec00a10039b823cc94eef4eddd47dcd3b2ca04", - "reference": "1bec00a10039b823cc94eef4eddd47dcd3b2ca04", + "url": "https://api.github.com/repos/egulias/EmailValidator/zipball/8790f594151ca6a2010c6218e09d96df67173ad3", + "reference": "8790f594151ca6a2010c6218e09d96df67173ad3", "shasum": "" }, "require": { @@ -1225,7 +1224,7 @@ }, "require-dev": { "dominicsayers/isemail": "dev-master", - "phpunit/phpunit": "^4.8.35", + "phpunit/phpunit": "^4.8.35||^5.7||^6.0", "satooshi/php-coveralls": "^1.0.1" }, "suggest": { @@ -1260,7 +1259,7 @@ "validation", "validator" ], - "time": "2017-11-15 23:40:40" + "time": "2018-04-10T10:11:19+00:00" }, { "name": "erusev/parsedown", @@ -1306,7 +1305,7 @@ "markdown", "parser" ], - "time": "2018-03-08 01:11:30" + "time": "2018-03-08T01:11:30+00:00" }, { "name": "guzzlehttp/guzzle", @@ -1371,7 +1370,7 @@ "rest", "web service" ], - "time": "2018-03-26 16:33:04" + "time": "2018-03-26T16:33:04+00:00" }, { "name": "guzzlehttp/promises", @@ -1422,7 +1421,7 @@ "keywords": [ "promise" ], - "time": "2016-12-20 10:07:11" + "time": "2016-12-20T10:07:11+00:00" }, { "name": "guzzlehttp/psr7", @@ -1487,7 +1486,7 @@ "uri", "url" ], - "time": "2017-03-20 17:10:46" + "time": "2017-03-20T17:10:46+00:00" }, { "name": "imagine/imagine", @@ -1544,7 +1543,7 @@ "image manipulation", "image processing" ], - "time": "2015-09-19 16:54:05" + "time": "2015-09-19T16:54:05+00:00" }, { "name": "jakub-onderka/php-console-color", @@ -1587,7 +1586,7 @@ "homepage": "http://www.acci.cz" } ], - "time": "2014-04-08 15:00:19" + "time": "2014-04-08T15:00:19+00:00" }, { "name": "jakub-onderka/php-console-highlighter", @@ -1631,20 +1630,20 @@ "homepage": "http://www.acci.cz/" } ], - "time": "2015-04-20 18:58:01" + "time": "2015-04-20T18:58:01+00:00" }, { "name": "laravel/framework", - "version": "v5.6.15", + "version": "v5.6.16", "source": { "type": "git", "url": "https://github.com/laravel/framework.git", - "reference": "baa42cf6bdd942523fafece21ec16a1843c6db0f" + "reference": "fcdbc791bc3e113ada38ab0a1147141fb9ec2b16" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/framework/zipball/baa42cf6bdd942523fafece21ec16a1843c6db0f", - "reference": "baa42cf6bdd942523fafece21ec16a1843c6db0f", + "url": "https://api.github.com/repos/laravel/framework/zipball/fcdbc791bc3e113ada38ab0a1147141fb9ec2b16", + "reference": "fcdbc791bc3e113ada38ab0a1147141fb9ec2b16", "shasum": "" }, "require": { @@ -1709,6 +1708,7 @@ "aws/aws-sdk-php": "~3.0", "doctrine/dbal": "~2.6", "filp/whoops": "^2.1.4", + "league/flysystem-cached-adapter": "~1.0", "mockery/mockery": "~1.0", "moontoast/math": "^1.1", "orchestra/testbench-core": "3.6.*", @@ -1727,7 +1727,7 @@ "guzzlehttp/guzzle": "Required to use the Mailgun and Mandrill mail drivers and the ping methods on schedules (~6.0).", "laravel/tinker": "Required to use the tinker console command (~1.0).", "league/flysystem-aws-s3-v3": "Required to use the Flysystem S3 driver (~1.0).", - "league/flysystem-cached-adapter": "Required to use Flysystem caching (~1.0).", + "league/flysystem-cached-adapter": "Required to use the Flysystem cache (~1.0).", "league/flysystem-rackspace": "Required to use the Flysystem Rackspace driver (~1.0).", "league/flysystem-sftp": "Required to use the Flysystem SFTP driver (~1.0).", "nexmo/client": "Required to use the Nexmo transport (~1.0).", @@ -1769,7 +1769,7 @@ "framework", "laravel" ], - "time": "2018-03-30 13:29:58" + "time": "2018-04-09T16:07:04+00:00" }, { "name": "laravel/socialite", @@ -1831,7 +1831,7 @@ "laravel", "oauth" ], - "time": "2017-11-06 16:02:48" + "time": "2017-11-06T16:02:48+00:00" }, { "name": "laravel/tinker", @@ -1894,20 +1894,20 @@ "laravel", "psysh" ], - "time": "2018-03-06 17:34:36" + "time": "2018-03-06T17:34:36+00:00" }, { "name": "laravelcollective/html", - "version": "v5.6.5", + "version": "v5.6.6", "source": { "type": "git", "url": "https://github.com/LaravelCollective/html.git", - "reference": "623a150c91e2d3f92eeee9f9eda58a841e3cb548" + "reference": "b3a10245c791a211e5f8ec37117f4549cd22aabe" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/LaravelCollective/html/zipball/623a150c91e2d3f92eeee9f9eda58a841e3cb548", - "reference": "623a150c91e2d3f92eeee9f9eda58a841e3cb548", + "url": "https://api.github.com/repos/LaravelCollective/html/zipball/b3a10245c791a211e5f8ec37117f4549cd22aabe", + "reference": "b3a10245c791a211e5f8ec37117f4549cd22aabe", "shasum": "" }, "require": { @@ -1962,20 +1962,20 @@ ], "description": "HTML and Form Builders for the Laravel Framework", "homepage": "https://laravelcollective.com", - "time": "2018-03-16 16:57:31" + "time": "2018-04-09T14:09:32+00:00" }, { "name": "league/flysystem", - "version": "1.0.43", + "version": "1.0.44", "source": { "type": "git", "url": "https://github.com/thephpleague/flysystem.git", - "reference": "1ce7cc142d906ba58dc54c82915d355a9191c8a8" + "reference": "168dbe519737221dc87d17385cde33073881fd02" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/thephpleague/flysystem/zipball/1ce7cc142d906ba58dc54c82915d355a9191c8a8", - "reference": "1ce7cc142d906ba58dc54c82915d355a9191c8a8", + "url": "https://api.github.com/repos/thephpleague/flysystem/zipball/168dbe519737221dc87d17385cde33073881fd02", + "reference": "168dbe519737221dc87d17385cde33073881fd02", "shasum": "" }, "require": { @@ -2046,7 +2046,7 @@ "sftp", "storage" ], - "time": "2018-03-01 10:27:04" + "time": "2018-04-06T09:58:14+00:00" }, { "name": "league/oauth1-client", @@ -2109,7 +2109,7 @@ "tumblr", "twitter" ], - "time": "2016-08-17 00:36:58" + "time": "2016-08-17T00:36:58+00:00" }, { "name": "maximebf/debugbar", @@ -2170,7 +2170,7 @@ "debug", "debugbar" ], - "time": "2017-12-15 11:13:46" + "time": "2017-12-15T11:13:46+00:00" }, { "name": "mbostock/d3", @@ -2207,7 +2207,7 @@ "svg", "visualization" ], - "time": "2016-02-18 01:37:32" + "time": "2016-02-18T01:37:32+00:00" }, { "name": "ml/iri", @@ -2254,7 +2254,7 @@ "uri", "url" ], - "time": "2014-01-21 13:43:39" + "time": "2014-01-21T13:43:39+00:00" }, { "name": "ml/json-ld", @@ -2304,7 +2304,7 @@ "JSON-LD", "jsonld" ], - "time": "2018-01-28 12:53:52" + "time": "2018-01-28T12:53:52+00:00" }, { "name": "monolog/monolog", @@ -2382,7 +2382,7 @@ "logging", "psr-3" ], - "time": "2017-06-19 01:22:40" + "time": "2017-06-19T01:22:40+00:00" }, { "name": "nesbot/carbon", @@ -2435,7 +2435,7 @@ "datetime", "time" ], - "time": "2018-03-19 15:50:49" + "time": "2018-03-19T15:50:49+00:00" }, { "name": "nikic/php-parser", @@ -2486,20 +2486,20 @@ "parser", "php" ], - "time": "2018-02-28 20:30:58" + "time": "2018-02-28T20:30:58+00:00" }, { "name": "paragonie/random_compat", - "version": "v2.0.11", + "version": "v2.0.12", "source": { "type": "git", "url": "https://github.com/paragonie/random_compat.git", - "reference": "5da4d3c796c275c55f057af5a643ae297d96b4d8" + "reference": "258c89a6b97de7dfaf5b8c7607d0478e236b04fb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/paragonie/random_compat/zipball/5da4d3c796c275c55f057af5a643ae297d96b4d8", - "reference": "5da4d3c796c275c55f057af5a643ae297d96b4d8", + "url": "https://api.github.com/repos/paragonie/random_compat/zipball/258c89a6b97de7dfaf5b8c7607d0478e236b04fb", + "reference": "258c89a6b97de7dfaf5b8c7607d0478e236b04fb", "shasum": "" }, "require": { @@ -2534,7 +2534,7 @@ "pseudorandom", "random" ], - "time": "2017-09-27 21:40:39" + "time": "2018-04-04T21:24:14+00:00" }, { "name": "psr/container", @@ -2583,7 +2583,7 @@ "container-interop", "psr" ], - "time": "2017-02-14 16:28:37" + "time": "2017-02-14T16:28:37+00:00" }, { "name": "psr/http-message", @@ -2633,7 +2633,7 @@ "request", "response" ], - "time": "2016-08-06 14:39:51" + "time": "2016-08-06T14:39:51+00:00" }, { "name": "psr/log", @@ -2680,7 +2680,7 @@ "psr", "psr-3" ], - "time": "2016-10-10 12:19:37" + "time": "2016-10-10T12:19:37+00:00" }, { "name": "psr/simple-cache", @@ -2728,7 +2728,7 @@ "psr-16", "simple-cache" ], - "time": "2017-10-23 01:57:42" + "time": "2017-10-23T01:57:42+00:00" }, { "name": "psy/psysh", @@ -2800,7 +2800,7 @@ "interactive", "shell" ], - "time": "2018-04-02 05:41:44" + "time": "2018-04-02T05:41:44+00:00" }, { "name": "rairlie/laravel-locking-session", @@ -2841,7 +2841,7 @@ "laravel", "session" ], - "time": "2017-11-28 22:28:43" + "time": "2017-11-28T22:28:43+00:00" }, { "name": "ramsey/uuid", @@ -2921,7 +2921,7 @@ "identifier", "uuid" ], - "time": "2018-01-20 00:28:24" + "time": "2018-01-20T00:28:24+00:00" }, { "name": "sabre/uri", @@ -2972,7 +2972,7 @@ "uri", "url" ], - "time": "2017-02-20 20:02:35" + "time": "2017-02-20T20:02:35+00:00" }, { "name": "sabre/xml", @@ -3035,7 +3035,7 @@ "dom", "xml" ], - "time": "2018-02-08 11:00:49" + "time": "2018-02-08T11:00:49+00:00" }, { "name": "swiftmailer/swiftmailer", @@ -3090,11 +3090,11 @@ "mail", "mailer" ], - "time": "2017-09-30 22:39:41" + "time": "2017-09-30T22:39:41+00:00" }, { "name": "symfony/class-loader", - "version": "v3.4.6", + "version": "v3.4.8", "source": { "type": "git", "url": "https://github.com/symfony/class-loader.git", @@ -3146,20 +3146,20 @@ ], "description": "Symfony ClassLoader Component", "homepage": "https://symfony.com", - "time": "2018-01-03 07:37:34" + "time": "2018-01-03T07:37:34+00:00" }, { "name": "symfony/console", - "version": "v4.0.6", + "version": "v4.0.8", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "555c8dbe0ae9e561740451eabdbed2cc554b6a51" + "reference": "aad9a6fe47319f22748fd764f52d3a7ca6fa6b64" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/555c8dbe0ae9e561740451eabdbed2cc554b6a51", - "reference": "555c8dbe0ae9e561740451eabdbed2cc554b6a51", + "url": "https://api.github.com/repos/symfony/console/zipball/aad9a6fe47319f22748fd764f52d3a7ca6fa6b64", + "reference": "aad9a6fe47319f22748fd764f52d3a7ca6fa6b64", "shasum": "" }, "require": { @@ -3214,7 +3214,7 @@ ], "description": "Symfony Console Component", "homepage": "https://symfony.com", - "time": "2018-02-26 15:55:47" + "time": "2018-04-03T05:24:00+00:00" }, { "name": "symfony/css-selector", @@ -3267,20 +3267,20 @@ ], "description": "Symfony CssSelector Component", "homepage": "https://symfony.com", - "time": "2017-01-02 20:31:54" + "time": "2017-01-02T20:31:54+00:00" }, { "name": "symfony/debug", - "version": "v4.0.6", + "version": "v4.0.8", "source": { "type": "git", "url": "https://github.com/symfony/debug.git", - "reference": "1721e4e7effb23480966690cdcdc7d2a4152d489" + "reference": "5961d02d48828671f5d8a7805e06579d692f6ede" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/debug/zipball/1721e4e7effb23480966690cdcdc7d2a4152d489", - "reference": "1721e4e7effb23480966690cdcdc7d2a4152d489", + "url": "https://api.github.com/repos/symfony/debug/zipball/5961d02d48828671f5d8a7805e06579d692f6ede", + "reference": "5961d02d48828671f5d8a7805e06579d692f6ede", "shasum": "" }, "require": { @@ -3323,20 +3323,20 @@ ], "description": "Symfony Debug Component", "homepage": "https://symfony.com", - "time": "2018-02-28 21:50:02" + "time": "2018-04-03T05:24:00+00:00" }, { "name": "symfony/event-dispatcher", - "version": "v4.0.6", + "version": "v4.0.8", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "85eaf6a8ec915487abac52e133efc4a268204428" + "reference": "63353a71073faf08f62caab4e6889b06a787f07b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/85eaf6a8ec915487abac52e133efc4a268204428", - "reference": "85eaf6a8ec915487abac52e133efc4a268204428", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/63353a71073faf08f62caab4e6889b06a787f07b", + "reference": "63353a71073faf08f62caab4e6889b06a787f07b", "shasum": "" }, "require": { @@ -3386,20 +3386,20 @@ ], "description": "Symfony EventDispatcher Component", "homepage": "https://symfony.com", - "time": "2018-02-14 14:11:10" + "time": "2018-04-06T07:35:43+00:00" }, { "name": "symfony/finder", - "version": "v4.0.6", + "version": "v4.0.8", "source": { "type": "git", "url": "https://github.com/symfony/finder.git", - "reference": "44a796d2ecc2a16a5fc8f2956a34ee617934d55f" + "reference": "ca27c02b7a3fef4828c998c2ff9ba7aae1641c49" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/44a796d2ecc2a16a5fc8f2956a34ee617934d55f", - "reference": "44a796d2ecc2a16a5fc8f2956a34ee617934d55f", + "url": "https://api.github.com/repos/symfony/finder/zipball/ca27c02b7a3fef4828c998c2ff9ba7aae1641c49", + "reference": "ca27c02b7a3fef4828c998c2ff9ba7aae1641c49", "shasum": "" }, "require": { @@ -3435,20 +3435,20 @@ ], "description": "Symfony Finder Component", "homepage": "https://symfony.com", - "time": "2018-03-05 18:28:26" + "time": "2018-04-04T05:10:37+00:00" }, { "name": "symfony/http-foundation", - "version": "v4.0.6", + "version": "v4.0.8", "source": { "type": "git", "url": "https://github.com/symfony/http-foundation.git", - "reference": "6c181e81a3a9a7996c62ebd7803592536e729c5a" + "reference": "d0864a82e5891ab61d31eecbaa48bed5a09b8e6c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-foundation/zipball/6c181e81a3a9a7996c62ebd7803592536e729c5a", - "reference": "6c181e81a3a9a7996c62ebd7803592536e729c5a", + "url": "https://api.github.com/repos/symfony/http-foundation/zipball/d0864a82e5891ab61d31eecbaa48bed5a09b8e6c", + "reference": "d0864a82e5891ab61d31eecbaa48bed5a09b8e6c", "shasum": "" }, "require": { @@ -3488,20 +3488,20 @@ ], "description": "Symfony HttpFoundation Component", "homepage": "https://symfony.com", - "time": "2018-03-05 16:01:10" + "time": "2018-04-03T05:24:00+00:00" }, { "name": "symfony/http-kernel", - "version": "v4.0.6", + "version": "v4.0.8", "source": { "type": "git", "url": "https://github.com/symfony/http-kernel.git", - "reference": "2a1ebfe8c37240500befcb17bceb3893adacffa3" + "reference": "6dd620d96d64456075536ffe3c6c4658dd689021" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-kernel/zipball/2a1ebfe8c37240500befcb17bceb3893adacffa3", - "reference": "2a1ebfe8c37240500befcb17bceb3893adacffa3", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/6dd620d96d64456075536ffe3c6c4658dd689021", + "reference": "6dd620d96d64456075536ffe3c6c4658dd689021", "shasum": "" }, "require": { @@ -3574,7 +3574,7 @@ ], "description": "Symfony HttpKernel Component", "homepage": "https://symfony.com", - "time": "2018-03-05 22:27:01" + "time": "2018-04-06T16:25:03+00:00" }, { "name": "symfony/polyfill-mbstring", @@ -3633,7 +3633,7 @@ "portable", "shim" ], - "time": "2018-01-30 19:27:44" + "time": "2018-01-30T19:27:44+00:00" }, { "name": "symfony/polyfill-php72", @@ -3688,7 +3688,7 @@ "portable", "shim" ], - "time": "2018-01-31 17:43:24" + "time": "2018-01-31T17:43:24+00:00" }, { "name": "symfony/process", @@ -3737,20 +3737,20 @@ ], "description": "Symfony Process Component", "homepage": "https://symfony.com", - "time": "2018-04-03 05:24:00" + "time": "2018-04-03T05:24:00+00:00" }, { "name": "symfony/routing", - "version": "v4.0.6", + "version": "v4.0.8", "source": { "type": "git", "url": "https://github.com/symfony/routing.git", - "reference": "9c6268c1970c7e507bedc8946bece32a7db23515" + "reference": "0663036dd57dbfd4e9ff29f75bbd5dd3253ebe71" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/routing/zipball/9c6268c1970c7e507bedc8946bece32a7db23515", - "reference": "9c6268c1970c7e507bedc8946bece32a7db23515", + "url": "https://api.github.com/repos/symfony/routing/zipball/0663036dd57dbfd4e9ff29f75bbd5dd3253ebe71", + "reference": "0663036dd57dbfd4e9ff29f75bbd5dd3253ebe71", "shasum": "" }, "require": { @@ -3815,11 +3815,11 @@ "uri", "url" ], - "time": "2018-02-28 21:50:02" + "time": "2018-04-04T13:50:32+00:00" }, { "name": "symfony/translation", - "version": "v4.0.6", + "version": "v4.0.8", "source": { "type": "git", "url": "https://github.com/symfony/translation.git", @@ -3883,20 +3883,20 @@ ], "description": "Symfony Translation Component", "homepage": "https://symfony.com", - "time": "2018-02-22 10:50:29" + "time": "2018-02-22T10:50:29+00:00" }, { "name": "symfony/var-dumper", - "version": "v4.0.6", + "version": "v4.0.8", "source": { "type": "git", "url": "https://github.com/symfony/var-dumper.git", - "reference": "c7d89044ed6ed3b7d8b558d509cca0666b947e58" + "reference": "e1b4d008100f4d203cc38b0d793ad6252d8d8af0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/var-dumper/zipball/c7d89044ed6ed3b7d8b558d509cca0666b947e58", - "reference": "c7d89044ed6ed3b7d8b558d509cca0666b947e58", + "url": "https://api.github.com/repos/symfony/var-dumper/zipball/e1b4d008100f4d203cc38b0d793ad6252d8d8af0", + "reference": "e1b4d008100f4d203cc38b0d793ad6252d8d8af0", "shasum": "" }, "require": { @@ -3952,7 +3952,7 @@ "debug", "dump" ], - "time": "2018-02-26 15:55:47" + "time": "2018-04-04T05:10:37+00:00" }, { "name": "tijsverkoyen/css-to-inline-styles", @@ -3999,7 +3999,7 @@ ], "description": "CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.", "homepage": "https://github.com/tijsverkoyen/CssToInlineStyles", - "time": "2017-11-27 11:13:29" + "time": "2017-11-27T11:13:29+00:00" }, { "name": "vlucas/phpdotenv", @@ -4049,7 +4049,7 @@ "env", "environment" ], - "time": "2016-09-01 10:05:43" + "time": "2016-09-01T10:05:43+00:00" }, { "name": "vluzrmos/language-detector", @@ -4104,20 +4104,20 @@ "locale", "lumen" ], - "time": "2017-03-11 03:40:17" + "time": "2017-03-11T03:40:17+00:00" }, { "name": "yajra/laravel-datatables-oracle", - "version": "v8.4.2", + "version": "v8.4.3", "source": { "type": "git", "url": "https://github.com/yajra/laravel-datatables.git", - "reference": "eab6cc583ae778d056c5caf21b70db803d956e14" + "reference": "9a87175e5ca02627aec98ec767fce5f5cbc98177" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/yajra/laravel-datatables/zipball/eab6cc583ae778d056c5caf21b70db803d956e14", - "reference": "eab6cc583ae778d056c5caf21b70db803d956e14", + "url": "https://api.github.com/repos/yajra/laravel-datatables/zipball/9a87175e5ca02627aec98ec767fce5f5cbc98177", + "reference": "9a87175e5ca02627aec98ec767fce5f5cbc98177", "shasum": "" }, "require": { @@ -4175,7 +4175,7 @@ "jquery", "laravel" ], - "time": "2018-03-28 16:31:13" + "time": "2018-04-05T14:51:57+00:00" } ], "packages-dev": [ @@ -4231,7 +4231,7 @@ "constructor", "instantiate" ], - "time": "2017-07-22 11:58:36" + "time": "2017-07-22T11:58:36+00:00" }, { "name": "filp/whoops", @@ -4292,7 +4292,7 @@ "throwable", "whoops" ], - "time": "2017-11-23 18:22:44" + "time": "2017-11-23T18:22:44+00:00" }, { "name": "fzaninotto/faker", @@ -4342,7 +4342,7 @@ "faker", "fixtures" ], - "time": "2017-08-15 16:48:10" + "time": "2017-08-15T16:48:10+00:00" }, { "name": "hamcrest/hamcrest-php", @@ -4387,7 +4387,7 @@ "keywords": [ "test" ], - "time": "2015-05-11 14:41:42" + "time": "2015-05-11T14:41:42+00:00" }, { "name": "mockery/mockery", @@ -4428,7 +4428,7 @@ ], "authors": [ { - "name": "Pádraic Brady", + "name": "Padraic Brady", "email": "padraic.brady@gmail.com", "homepage": "http://blog.astrumfutura.com" }, @@ -4452,7 +4452,7 @@ "test double", "testing" ], - "time": "2017-02-28 12:52:32" + "time": "2017-02-28T12:52:32+00:00" }, { "name": "myclabs/deep-copy", @@ -4497,7 +4497,7 @@ "object", "object graph" ], - "time": "2017-10-19 19:58:43" + "time": "2017-10-19T19:58:43+00:00" }, { "name": "phar-io/manifest", @@ -4552,7 +4552,7 @@ } ], "description": "Component for reading phar.io manifest information from a PHP Archive (PHAR)", - "time": "2017-03-05 18:14:27" + "time": "2017-03-05T18:14:27+00:00" }, { "name": "phar-io/version", @@ -4599,7 +4599,7 @@ } ], "description": "Library for handling version information and constraints", - "time": "2017-03-05 17:38:23" + "time": "2017-03-05T17:38:23+00:00" }, { "name": "phpdocumentor/reflection-common", @@ -4653,7 +4653,7 @@ "reflection", "static analysis" ], - "time": "2017-09-11 18:02:19" + "time": "2017-09-11T18:02:19+00:00" }, { "name": "phpdocumentor/reflection-docblock", @@ -4704,7 +4704,7 @@ } ], "description": "With this component, a library can provide support for annotations via DocBlocks or otherwise retrieve information that is embedded in a DocBlock.", - "time": "2017-11-30 07:14:17" + "time": "2017-11-30T07:14:17+00:00" }, { "name": "phpdocumentor/type-resolver", @@ -4751,7 +4751,7 @@ "email": "me@mikevanriel.com" } ], - "time": "2017-07-14 14:27:02" + "time": "2017-07-14T14:27:02+00:00" }, { "name": "phpspec/prophecy", @@ -4814,20 +4814,20 @@ "spy", "stub" ], - "time": "2018-02-19 10:16:54" + "time": "2018-02-19T10:16:54+00:00" }, { "name": "phpunit/php-code-coverage", - "version": "5.3.0", + "version": "5.3.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "661f34d0bd3f1a7225ef491a70a020ad23a057a1" + "reference": "c89677919c5dd6d3b3852f230a663118762218ac" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/661f34d0bd3f1a7225ef491a70a020ad23a057a1", - "reference": "661f34d0bd3f1a7225ef491a70a020ad23a057a1", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/c89677919c5dd6d3b3852f230a663118762218ac", + "reference": "c89677919c5dd6d3b3852f230a663118762218ac", "shasum": "" }, "require": { @@ -4877,7 +4877,7 @@ "testing", "xunit" ], - "time": "2017-12-06 09:29:45" + "time": "2018-04-06T15:36:58+00:00" }, { "name": "phpunit/php-file-iterator", @@ -4924,7 +4924,7 @@ "filesystem", "iterator" ], - "time": "2017-11-27 13:52:08" + "time": "2017-11-27T13:52:08+00:00" }, { "name": "phpunit/php-text-template", @@ -4965,7 +4965,7 @@ "keywords": [ "template" ], - "time": "2015-06-21 13:50:34" + "time": "2015-06-21T13:50:34+00:00" }, { "name": "phpunit/php-timer", @@ -5014,7 +5014,7 @@ "keywords": [ "timer" ], - "time": "2017-02-26 11:10:40" + "time": "2017-02-26T11:10:40+00:00" }, { "name": "phpunit/php-token-stream", @@ -5063,20 +5063,20 @@ "keywords": [ "tokenizer" ], - "time": "2017-11-27 05:48:46" + "time": "2017-11-27T05:48:46+00:00" }, { "name": "phpunit/phpunit", - "version": "6.5.7", + "version": "6.5.8", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "6bd77b57707c236833d2b57b968e403df060c9d9" + "reference": "4f21a3c6b97c42952fd5c2837bb354ec0199b97b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/6bd77b57707c236833d2b57b968e403df060c9d9", - "reference": "6bd77b57707c236833d2b57b968e403df060c9d9", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/4f21a3c6b97c42952fd5c2837bb354ec0199b97b", + "reference": "4f21a3c6b97c42952fd5c2837bb354ec0199b97b", "shasum": "" }, "require": { @@ -5147,7 +5147,7 @@ "testing", "xunit" ], - "time": "2018-02-26 07:01:09" + "time": "2018-04-10T11:38:34+00:00" }, { "name": "phpunit/phpunit-mock-objects", @@ -5206,7 +5206,7 @@ "mock", "xunit" ], - "time": "2018-01-06 05:45:45" + "time": "2018-01-06T05:45:45+00:00" }, { "name": "sebastian/code-unit-reverse-lookup", @@ -5251,7 +5251,7 @@ ], "description": "Looks up which function or method a line of code belongs to", "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", - "time": "2017-03-04 06:30:41" + "time": "2017-03-04T06:30:41+00:00" }, { "name": "sebastian/comparator", @@ -5315,7 +5315,7 @@ "compare", "equality" ], - "time": "2018-02-01 13:46:46" + "time": "2018-02-01T13:46:46+00:00" }, { "name": "sebastian/diff", @@ -5367,7 +5367,7 @@ "keywords": [ "diff" ], - "time": "2017-08-03 08:09:46" + "time": "2017-08-03T08:09:46+00:00" }, { "name": "sebastian/environment", @@ -5417,7 +5417,7 @@ "environment", "hhvm" ], - "time": "2017-07-01 08:51:00" + "time": "2017-07-01T08:51:00+00:00" }, { "name": "sebastian/exporter", @@ -5484,7 +5484,7 @@ "export", "exporter" ], - "time": "2017-04-03 13:19:02" + "time": "2017-04-03T13:19:02+00:00" }, { "name": "sebastian/global-state", @@ -5535,7 +5535,7 @@ "keywords": [ "global state" ], - "time": "2017-04-27 15:39:26" + "time": "2017-04-27T15:39:26+00:00" }, { "name": "sebastian/object-enumerator", @@ -5582,7 +5582,7 @@ ], "description": "Traverses array structures and object graphs to enumerate all referenced objects", "homepage": "https://github.com/sebastianbergmann/object-enumerator/", - "time": "2017-08-03 12:35:26" + "time": "2017-08-03T12:35:26+00:00" }, { "name": "sebastian/object-reflector", @@ -5627,7 +5627,7 @@ ], "description": "Allows reflection of object attributes, including inherited and non-public ones", "homepage": "https://github.com/sebastianbergmann/object-reflector/", - "time": "2017-03-29 09:07:27" + "time": "2017-03-29T09:07:27+00:00" }, { "name": "sebastian/recursion-context", @@ -5680,7 +5680,7 @@ ], "description": "Provides functionality to recursively process PHP variables", "homepage": "http://www.github.com/sebastianbergmann/recursion-context", - "time": "2017-03-03 06:23:57" + "time": "2017-03-03T06:23:57+00:00" }, { "name": "sebastian/resource-operations", @@ -5722,7 +5722,7 @@ ], "description": "Provides a list of PHP built-in functions that operate on resources", "homepage": "https://www.github.com/sebastianbergmann/resource-operations", - "time": "2015-07-28 20:34:47" + "time": "2015-07-28T20:34:47+00:00" }, { "name": "sebastian/version", @@ -5765,7 +5765,7 @@ ], "description": "Library that helps with managing the version number of Git-hosted PHP projects", "homepage": "https://github.com/sebastianbergmann/version", - "time": "2016-10-03 07:35:21" + "time": "2016-10-03T07:35:21+00:00" }, { "name": "symfony/dom-crawler", @@ -5821,7 +5821,7 @@ ], "description": "Symfony DomCrawler Component", "homepage": "https://symfony.com", - "time": "2017-01-21 17:13:55" + "time": "2017-01-21T17:13:55+00:00" }, { "name": "theseer/tokenizer", @@ -5861,7 +5861,7 @@ } ], "description": "A small library for converting tokenized PHP source code into XML and potentially other formats", - "time": "2017-04-07 12:08:54" + "time": "2017-04-07T12:08:54+00:00" }, { "name": "webmozart/assert", @@ -5911,7 +5911,7 @@ "check", "validate" ], - "time": "2018-01-29 19:49:41" + "time": "2018-01-29T19:49:41+00:00" } ], "aliases": [ diff --git a/config/alignment/qSKOS.php b/config/alignment/qSKOS.php index 3d41d9e..dd4ce38 100644 --- a/config/alignment/qSKOS.php +++ b/config/alignment/qSKOS.php @@ -1,11 +1,11 @@ "", -]; \ No newline at end of file + 'qSKOS-jar' => '', +]; diff --git a/config/alignment/silk.php b/config/alignment/silk.php index f7b6b42..f86e33e 100644 --- a/config/alignment/silk.php +++ b/config/alignment/silk.php @@ -1,20 +1,20 @@ app_path() . '/functions/silk/silk.jar', - - "config" => [ + + 'jar'=> app_path().'/functions/silk/silk.jar', + + 'config' => [ '-d64', '-Xms2G', - '-Xmx4G', + '-Xmx4G', '-Dreload=true', - '-Dthreads=4' - ] - + '-Dthreads=4', + ], + ]; diff --git a/config/app.php b/config/app.php index 231e888..441caf6 100644 --- a/config/app.php +++ b/config/app.php @@ -143,14 +143,14 @@ Illuminate\Queue\QueueServiceProvider::class, Illuminate\Redis\RedisServiceProvider::class, Illuminate\Auth\Passwords\PasswordResetServiceProvider::class, - + //added locking session drivers //Illuminate\Session\SessionServiceProvider::class, Rairlie\LockingSession\LockingSessionServiceProvider::class, Illuminate\Translation\TranslationServiceProvider::class, Illuminate\Validation\ValidationServiceProvider::class, Illuminate\View\ViewServiceProvider::class, - + /* * Language detector */ @@ -171,7 +171,7 @@ //IDE helper Barryvdh\LaravelIdeHelper\IdeHelperServiceProvider::class, Barryvdh\Debugbar\ServiceProvider::class, - Codesleeve\LaravelStapler\Providers\L5ServiceProvider::class, + Codesleeve\LaravelStapler\Providers\L5ServiceProvider::class, Collective\Html\HtmlServiceProvider::class, // Socialite Laravel\Socialite\SocialiteServiceProvider::class, diff --git a/config/database.php b/config/database.php index def1e56..04ecbd1 100644 --- a/config/database.php +++ b/config/database.php @@ -77,6 +77,17 @@ 'prefix' => '', 'schema' => 'public', ], + 'testing' => [ + 'driver' => 'mysql', + 'host' => env('DB_TEST_HOST', 'localhost'), + 'database' => env('DB_TEST_DATABASE', 'homestead'), + 'username' => env('DB_TEST_USERNAME', 'homestead'), + 'password' => env('DB_TEST_PASSWORD', 'secret'), + 'charset' => 'utf8', + 'collation' => 'utf8_unicode_ci', + 'prefix' => '', + 'strict' => false, + ], ], diff --git a/config/datatables.php b/config/datatables.php index f5cc2b3..e0d23b0 100644 --- a/config/datatables.php +++ b/config/datatables.php @@ -1,59 +1,59 @@ [ - /** + /* * Smart search will enclose search keyword with wildcard string "%keyword%". * SQL: column LIKE "%keyword%" */ 'smart' => true, - /** + /* * Case insensitive will search the keyword in lower case format. * SQL: LOWER(column) LIKE LOWER(keyword) */ 'case_insensitive' => true, - /** + /* * Wild card will add "%" in between every characters of the keyword. * SQL: column LIKE "%k%e%y%w%o%r%d%" */ 'use_wildcards' => false, ], - /** + /* * DataTables fractal configurations. */ 'fractal' => [ - /** + /* * Request key name to parse includes on fractal. */ 'includes' => 'include', - /** + /* * Default fractal serializer. */ 'serializer' => 'League\Fractal\Serializer\DataArraySerializer', ], - /** + /* * DataTables script view template. */ 'script_template' => 'datatables::script', - /** + /* * DataTables internal index id response column name. */ 'index_column' => 'DT_Row_Index', - /** + /* * Namespaces used by the generator. */ 'namespace' => [ - /** + /* * Base namespace/directory to create the new file. * This is appended on default Laravel namespace. * Usage: php artisan datatables:make User @@ -63,7 +63,7 @@ */ 'base' => 'DataTables', - /** + /* * Base namespace/directory where your model's are located. * This is appended on default Laravel namespace. * Usage: php artisan datatables:make Post --model @@ -74,7 +74,7 @@ 'model' => '', ], - /** + /* * PDF generator to be used when converting the table to pdf. * Available generators: excel, snappy * Snappy package: barryvdh/laravel-snappy @@ -82,7 +82,7 @@ */ 'pdf_generator' => 'excel', - /** + /* * Snappy PDF options. */ 'snappy' => [ diff --git a/config/debugbar.php b/config/debugbar.php index e1b1777..a572905 100644 --- a/config/debugbar.php +++ b/config/debugbar.php @@ -1,6 +1,6 @@ env("DEBUGBAR_ENABLED"), + 'enabled' => env('DEBUGBAR_ENABLED'), /* |-------------------------------------------------------------------------- @@ -26,13 +26,13 @@ | can also be used. For PDO, run the package migrations first. | */ - 'storage' => array( + 'storage' => [ 'enabled' => true, 'driver' => 'file', // redis, file, pdo, custom 'path' => storage_path('debugbar'), // For file driver 'connection' => null, // Leave null for default connection (Redis/PDO) - 'provider' => '' // Instance of StorageInterface for custom driver - ), + 'provider' => '', // Instance of StorageInterface for custom driver + ], /* |-------------------------------------------------------------------------- @@ -82,7 +82,7 @@ | */ - 'collectors' => array( + 'collectors' => [ 'phpinfo' => true, // Php version 'messages' => true, // Messages 'time' => true, // Time Datalogger @@ -103,7 +103,7 @@ 'auth' => false, // Display Laravel authentication status 'gate' => false, // Display Laravel Gate checks 'session' => true, // Display session data - ), + ], /* |-------------------------------------------------------------------------- @@ -114,33 +114,33 @@ | */ - 'options' => array( - 'auth' => array( + 'options' => [ + 'auth' => [ 'show_name' => false, // Also show the users name/email in the debugbar - ), - 'db' => array( + ], + 'db' => [ 'with_params' => true, // Render SQL with the parameters substituted 'timeline' => false, // Add the queries to the timeline 'backtrace' => false, // EXPERIMENTAL: Use a backtrace to find the origin of the query in your files. - 'explain' => array( // EXPERIMENTAL: Show EXPLAIN output on queries + 'explain' => [ // EXPERIMENTAL: Show EXPLAIN output on queries 'enabled' => false, - 'types' => array('SELECT'), // array('SELECT', 'INSERT', 'UPDATE', 'DELETE'); for MySQL 5.6.3+ - ), + 'types' => ['SELECT'], // array('SELECT', 'INSERT', 'UPDATE', 'DELETE'); for MySQL 5.6.3+ + ], 'hints' => true, // Show hints for common mistakes - ), - 'mail' => array( - 'full_log' => false - ), - 'views' => array( + ], + 'mail' => [ + 'full_log' => false, + ], + 'views' => [ 'data' => false, //Note: Can slow down the application, because the data can be quite large.. - ), - 'route' => array( - 'label' => true // show complete route on bar - ), - 'logs' => array( - 'file' => null - ), - ), + ], + 'route' => [ + 'label' => true, // show complete route on bar + ], + 'logs' => [ + 'file' => null, + ], + ], /* |-------------------------------------------------------------------------- @@ -167,4 +167,4 @@ */ 'route_prefix' => '_debugbar', -); +]; diff --git a/config/filesystems.php b/config/filesystems.php index 3c124a5..e7a5ac8 100644 --- a/config/filesystems.php +++ b/config/filesystems.php @@ -53,7 +53,7 @@ 'root' => storage_path('app/public'), 'visibility' => 'public', ], - + 'projects' => [ 'driver' => 'local', 'root' => storage_path('app/projects'), diff --git a/config/ide-helper.php b/config/ide-helper.php index 5350f3a..373b8f6 100644 --- a/config/ide-helper.php +++ b/config/ide-helper.php @@ -1,6 +1,6 @@ false, - 'helper_files' => array( + 'helper_files' => [ base_path().'/vendor/laravel/framework/src/Illuminate/Support/helpers.php', - ), + ], /* |-------------------------------------------------------------------------- @@ -51,10 +51,9 @@ | */ - 'model_locations' => array( + 'model_locations' => [ 'app', - ), - + ], /* |-------------------------------------------------------------------------- @@ -65,13 +64,13 @@ | */ - 'extra' => array( - 'Eloquent' => array('Illuminate\Database\Eloquent\Builder', 'Illuminate\Database\Query\Builder'), - 'Session' => array('Illuminate\Session\Store'), - ), + 'extra' => [ + 'Eloquent' => ['Illuminate\Database\Eloquent\Builder', 'Illuminate\Database\Query\Builder'], + 'Session' => ['Illuminate\Session\Store'], + ], - 'magic' => array( - 'Log' => array( + 'magic' => [ + 'Log' => [ 'debug' => 'Monolog\Logger::addDebug', 'info' => 'Monolog\Logger::addInfo', 'notice' => 'Monolog\Logger::addNotice', @@ -80,8 +79,8 @@ 'critical' => 'Monolog\Logger::addCritical', 'alert' => 'Monolog\Logger::addAlert', 'emergency' => 'Monolog\Logger::addEmergency', - ) - ), + ], + ], /* |-------------------------------------------------------------------------- @@ -93,9 +92,9 @@ | */ - 'interfaces' => array( + 'interfaces' => [ - ), + ], /* |-------------------------------------------------------------------------- @@ -123,9 +122,9 @@ | ), | */ - 'custom_db_types' => array( + 'custom_db_types' => [ - ), + ], /* |-------------------------------------------------------------------------- @@ -161,8 +160,8 @@ | Cast the given "real type" to the given "type". | */ - 'type_overrides' => array( + 'type_overrides' => [ 'integer' => 'int', 'boolean' => 'bool', - ), -); + ], +]; diff --git a/config/lang-detector.php b/config/lang-detector.php index f2cb111..280427a 100644 --- a/config/lang-detector.php +++ b/config/lang-detector.php @@ -26,7 +26,7 @@ * or just use the array of languages with its aliases. */ 'languages' => parse_langs_to_array( - env('LANG_DETECTOR_LANGUAGES', ['en','el']) + env('LANG_DETECTOR_LANGUAGES', ['en', 'el']) ), /* diff --git a/config/laravel-stapler/bindings.php b/config/laravel-stapler/bindings.php index f6e94b7..18c72a6 100644 --- a/config/laravel-stapler/bindings.php +++ b/config/laravel-stapler/bindings.php @@ -55,4 +55,4 @@ */ 'validator' => '\Codesleeve\Stapler\Validator', -]; \ No newline at end of file +]; diff --git a/config/laravel-stapler/s3.php b/config/laravel-stapler/s3.php index a565027..246acda 100644 --- a/config/laravel-stapler/s3.php +++ b/config/laravel-stapler/s3.php @@ -8,7 +8,7 @@ |-------------------------------------------------------------------------- | | This is array holds the default configuration options used when creating - | an instance of Aws\S3\S3Client. These options will be passed directly to + | an instance of Aws\S3\S3Client. These options will be passed directly to | the s3ClientFactory when creating an S3 client instance. | */ @@ -26,7 +26,7 @@ | | An array of options used by the Aws\S3\S3Client::putObject() method when | storing a file on S3. - | AWS Documentation for Aws\S3\S3Client::putObject() at + | AWS Documentation for Aws\S3\S3Client::putObject() at | http://docs.aws.amazon.com/aws-sdk-php/latest/class-Aws.S3.S3Client.html#_putObject | */ diff --git a/config/logging.php b/config/logging.php index 739c0b6..bb82fcd 100644 --- a/config/logging.php +++ b/config/logging.php @@ -1,5 +1,7 @@ 'debug', ], ], -]; \ No newline at end of file +]; diff --git a/config/session.php b/config/session.php index edf5a26..b04fb3d 100644 --- a/config/session.php +++ b/config/session.php @@ -109,7 +109,7 @@ | */ - 'cookie' => env("APP_NAME") . '_session', + 'cookie' => env('APP_NAME').'_session', /* |-------------------------------------------------------------------------- @@ -148,6 +148,6 @@ | */ - 'secure' => env("APP_HTTPS", FALSE), + 'secure' => env('APP_HTTPS', false), ]; diff --git a/database/migrations/2014_10_12_000000_create_users_table.php b/database/migrations/2014_10_12_000000_create_users_table.php index a72d081..505a02d 100644 --- a/database/migrations/2014_10_12_000000_create_users_table.php +++ b/database/migrations/2014_10_12_000000_create_users_table.php @@ -1,7 +1,7 @@ increments('id'); $table->timestamps(); - $table->integer("session_id"); - $table->integer("source_id"); - $table->integer("target_id"); - $table->string("source_entity"); - $table->string("target_entity"); - $table->integer("link_type_id"); - $table->integer("up_votes"); - $table->integer("down_votes"); - $table->decimal("score"); - $table->integer("status_id"); + $table->integer('session_id'); + $table->integer('source_id'); + $table->integer('target_id'); + $table->string('source_entity'); + $table->string('target_entity'); + $table->integer('link_type_id'); + $table->integer('up_votes'); + $table->integer('down_votes'); + $table->decimal('score'); + $table->integer('status_id'); }); } diff --git a/database/migrations/2016_03_02_143648_create_sessions_table.php b/database/migrations/2016_03_02_143648_create_sessions_table.php index f9f4b28..50aba88 100644 --- a/database/migrations/2016_03_02_143648_create_sessions_table.php +++ b/database/migrations/2016_03_02_143648_create_sessions_table.php @@ -1,7 +1,7 @@ integer('source_id'); $table->integer('target_id'); $table->timestamp('ended_at'); - }); } diff --git a/database/migrations/2016_03_02_143705_create_files_table.php b/database/migrations/2016_03_02_143705_create_files_table.php index da05111..a198f15 100644 --- a/database/migrations/2016_03_02_143705_create_files_table.php +++ b/database/migrations/2016_03_02_143705_create_files_table.php @@ -1,7 +1,7 @@ increments('id'); $table->timestamps(); - }); } diff --git a/database/migrations/2016_03_03_150728_add_resource_fields_to_files_table.php b/database/migrations/2016_03_03_150728_add_resource_fields_to_files_table.php index 31ba1bb..8601d23 100644 --- a/database/migrations/2016_03_03_150728_add_resource_fields_to_files_table.php +++ b/database/migrations/2016_03_03_150728_add_resource_fields_to_files_table.php @@ -3,8 +3,8 @@ use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; -class AddResourceFieldsToFilesTable extends Migration { - +class AddResourceFieldsToFilesTable extends Migration +{ /** * Make changes to the table. * @@ -12,15 +12,12 @@ class AddResourceFieldsToFilesTable extends Migration { */ public function up() { - Schema::table('files', function(Blueprint $table) { - + Schema::table('files', function (Blueprint $table) { $table->string('resource_file_name')->nullable(); $table->integer('resource_file_size')->nullable()->after('resource_file_name'); $table->string('resource_content_type')->nullable()->after('resource_file_size'); $table->timestamp('resource_updated_at')->nullable()->after('resource_content_type'); - }); - } /** @@ -30,10 +27,8 @@ public function up() */ public function down() { - Schema::table('files', function(Blueprint $table) { - + Schema::table('files', function (Blueprint $table) { $table->dropColumn(['resource_file_name', 'resource_file_size', 'resource_content_type', 'resource_updated_at']); }); } - } diff --git a/database/migrations/2016_03_04_150728_add_utility_fields_to_files_table.php b/database/migrations/2016_03_04_150728_add_utility_fields_to_files_table.php index 3250573..bdfc350 100644 --- a/database/migrations/2016_03_04_150728_add_utility_fields_to_files_table.php +++ b/database/migrations/2016_03_04_150728_add_utility_fields_to_files_table.php @@ -3,8 +3,8 @@ use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; -class AddUtilityFieldsToFilesTable extends Migration { - +class AddUtilityFieldsToFilesTable extends Migration +{ /** * Make changes to the table. * @@ -12,13 +12,10 @@ class AddUtilityFieldsToFilesTable extends Migration { */ public function up() { - Schema::table('files', function(Blueprint $table) { - + Schema::table('files', function (Blueprint $table) { $table->boolean('parsed')->default(0)->after('public'); $table->integer('user_id')->nullable()->after('parsed'); - }); - } /** @@ -28,9 +25,8 @@ public function up() */ public function down() { - Schema::table('files', function(Blueprint $table) { - $table->dropColumn(['parsed','user_id']); + Schema::table('files', function (Blueprint $table) { + $table->dropColumn(['parsed', 'user_id']); }); } - -} \ No newline at end of file +} diff --git a/database/migrations/2016_03_05_171222_rename_sessions_table.php b/database/migrations/2016_03_05_171222_rename_sessions_table.php index 6ebd312..bcb4746 100644 --- a/database/migrations/2016_03_05_171222_rename_sessions_table.php +++ b/database/migrations/2016_03_05_171222_rename_sessions_table.php @@ -1,6 +1,5 @@ dropColumn('name'); + $table->dropColumn('name'); }); } } diff --git a/database/migrations/2016_03_07_170522_rename_session_id_to_project_id.php b/database/migrations/2016_03_07_170522_rename_session_id_to_project_id.php index 449e737..2c40d7c 100644 --- a/database/migrations/2016_03_07_170522_rename_session_id_to_project_id.php +++ b/database/migrations/2016_03_07_170522_rename_session_id_to_project_id.php @@ -1,7 +1,7 @@ dropColumn('link_type_id'); $table->string('link_type')->nullable(); - }); } @@ -27,13 +25,11 @@ public function up() */ public function down() { - if(Schema::hasColumn('links', 'link_type')){ + if (Schema::hasColumn('links', 'link_type')) { Schema::table('links', function (Blueprint $table) { $table->dropColumn('link_type'); $table->integer('link_type_id'); - }); } - } } diff --git a/database/migrations/2016_03_10_135355_create_settings_table.php b/database/migrations/2016_03_10_135355_create_settings_table.php index e3d3251..630c6b9 100644 --- a/database/migrations/2016_03_10_135355_create_settings_table.php +++ b/database/migrations/2016_03_10_135355_create_settings_table.php @@ -1,7 +1,7 @@ increments('id'); $table->timestamps(); @@ -78,10 +77,9 @@ public function up() * * @return void */ - public function down() { - /** + /* * Schema::drop('settings'); */ } diff --git a/database/migrations/2016_03_11_115335_add_column_settings_id_to_table_projects.php b/database/migrations/2016_03_11_115335_add_column_settings_id_to_table_projects.php index b1ef54e..b1362fe 100644 --- a/database/migrations/2016_03_11_115335_add_column_settings_id_to_table_projects.php +++ b/database/migrations/2016_03_11_115335_add_column_settings_id_to_table_projects.php @@ -1,7 +1,7 @@ string('name')->nullable(); @@ -26,10 +25,9 @@ public function up() * * @return void */ - public function down() { - /** + /* Schema::table('settings', function (Blueprint $table) { // $table->dropColumn('name'); diff --git a/database/migrations/2016_04_11_150422_create_jobs_table.php b/database/migrations/2016_04_11_150422_create_jobs_table.php index 81b2d29..1d2900a 100644 --- a/database/migrations/2016_04_11_150422_create_jobs_table.php +++ b/database/migrations/2016_04_11_150422_create_jobs_table.php @@ -1,7 +1,7 @@ boolean('processed')->default(0); - + // }); } diff --git a/database/migrations/2016_05_27_115816_create_prefixes_table.php b/database/migrations/2016_05_27_115816_create_prefixes_table.php index e2441a2..8206984 100644 --- a/database/migrations/2016_05_27_115816_create_prefixes_table.php +++ b/database/migrations/2016_05_27_115816_create_prefixes_table.php @@ -1,7 +1,7 @@ increments('id'); $table->timestamps(); - $table->string('prefix',20)->unique(); - $table->string('namespace',200)->unique(); + $table->string('prefix', 20)->unique(); + $table->string('namespace', 200)->unique(); }); } diff --git a/database/migrations/2016_05_28_101339_add_public_column_project_table.php b/database/migrations/2016_05_28_101339_add_public_column_project_table.php index 2bddf82..3e18343 100644 --- a/database/migrations/2016_05_28_101339_add_public_column_project_table.php +++ b/database/migrations/2016_05_28_101339_add_public_column_project_table.php @@ -1,7 +1,7 @@ boolean("public")->default(0)->after("user_id"); + $table->boolean('public')->default(0)->after('user_id'); // }); } @@ -27,7 +27,7 @@ public function down() { Schema::table('projects', function (Blueprint $table) { // - $table->dropColumn("public"); + $table->dropColumn('public'); }); } } diff --git a/database/migrations/2016_05_31_103958_add_softdelete_links.php b/database/migrations/2016_05_31_103958_add_softdelete_links.php index b7da418..bd97304 100644 --- a/database/migrations/2016_05_31_103958_add_softdelete_links.php +++ b/database/migrations/2016_05_31_103958_add_softdelete_links.php @@ -1,7 +1,7 @@ increments('id'); $table->string('prefix'); $table->string('uri'); diff --git a/database/migrations/2016_08_27_070841_create_label_extractors_table.php b/database/migrations/2016_08_27_070841_create_label_extractors_table.php index 7371f9a..429e282 100644 --- a/database/migrations/2016_08_27_070841_create_label_extractors_table.php +++ b/database/migrations/2016_08_27_070841_create_label_extractors_table.php @@ -12,7 +12,7 @@ class CreateLabelExtractorsTable extends Migration */ public function up() { - Schema::create('label_extractors', function(Blueprint $table) { + Schema::create('label_extractors', function (Blueprint $table) { $table->increments('id'); $table->string('property'); $table->integer('priority'); diff --git a/database/migrations/2016_11_04_193553_add_columns_to_votes_table.php b/database/migrations/2016_11_04_193553_add_columns_to_votes_table.php index 05b9d0d..9728795 100644 --- a/database/migrations/2016_11_04_193553_add_columns_to_votes_table.php +++ b/database/migrations/2016_11_04_193553_add_columns_to_votes_table.php @@ -1,7 +1,7 @@ integer("user_id")->after("id")->nullable(); - $table->integer("link_id")->after("user_id")->nullable(); - $table->integer("vote")->after("link_id")->nullable(); + $table->integer('user_id')->after('id')->nullable(); + $table->integer('link_id')->after('user_id')->nullable(); + $table->integer('vote')->after('link_id')->nullable(); }); } @@ -27,7 +27,7 @@ public function up() public function down() { Schema::table('votes', function (Blueprint $table) { - $table->dropColumn("user_id", "link_id", "vote"); + $table->dropColumn('user_id', 'link_id', 'vote'); }); } } diff --git a/database/migrations/2016_11_05_064643_create_comments_table.php b/database/migrations/2016_11_05_064643_create_comments_table.php index a0a721a..408ce78 100644 --- a/database/migrations/2016_11_05_064643_create_comments_table.php +++ b/database/migrations/2016_11_05_064643_create_comments_table.php @@ -1,7 +1,7 @@ integer("user_id")->nullable(); - $table->integer("project_id")->nullable(); - + $table->integer('user_id')->nullable(); + $table->integer('project_id')->nullable(); }); } @@ -27,8 +26,7 @@ public function up() public function down() { Schema::table('links', function (Blueprint $table) { - $table->dropColumn(["user_id", "project_id"]); - + $table->dropColumn(['user_id', 'project_id']); }); } } diff --git a/database/migrations/2016_12_23_193554_add_columns_to_link_types_table.php b/database/migrations/2016_12_23_193554_add_columns_to_link_types_table.php index a26836b..c050320 100644 --- a/database/migrations/2016_12_23_193554_add_columns_to_link_types_table.php +++ b/database/migrations/2016_12_23_193554_add_columns_to_link_types_table.php @@ -1,7 +1,7 @@ integer("user_id")->after("id")->nullable(); - $table->text("group")->after("user_id")->nullable(); - $table->text("inner")->after("group")->nullable(); - $table->text("value")->after("inner")->nullable(); - $table->boolean("public")->after("value")->default(0); - - + $table->integer('user_id')->after('id')->nullable(); + $table->text('group')->after('user_id')->nullable(); + $table->text('inner')->after('group')->nullable(); + $table->text('value')->after('inner')->nullable(); + $table->boolean('public')->after('value')->default(0); }); } @@ -31,7 +29,7 @@ public function up() public function down() { Schema::table('link_types', function (Blueprint $table) { - $table->dropColumn("user_id", "group", "inner", "value", "public"); + $table->dropColumn('user_id', 'group', 'inner', 'value', 'public'); }); } } diff --git a/database/migrations/2017_03_06_123534_create_imports_table.php b/database/migrations/2017_03_06_123534_create_imports_table.php index 94bf216..fa959e5 100644 --- a/database/migrations/2017_03_06_123534_create_imports_table.php +++ b/database/migrations/2017_03_06_123534_create_imports_table.php @@ -1,7 +1,7 @@ increments('id'); $table->integer('user_id'); - $table->integer("project_id"); - $table->string("filetype"); - $table->boolean("parsed"); - $table->boolean("imported"); + $table->integer('project_id'); + $table->string('filetype'); + $table->boolean('parsed'); + $table->boolean('imported'); $table->timestamps(); }); } diff --git a/database/migrations/2017_03_06_124008_add_resource_fields_to_imports_table.php b/database/migrations/2017_03_06_124008_add_resource_fields_to_imports_table.php index c29cb90..782f1f7 100644 --- a/database/migrations/2017_03_06_124008_add_resource_fields_to_imports_table.php +++ b/database/migrations/2017_03_06_124008_add_resource_fields_to_imports_table.php @@ -3,8 +3,8 @@ use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; -class AddResourceFieldsToImportsTable extends Migration { - +class AddResourceFieldsToImportsTable extends Migration +{ /** * Make changes to the table. * @@ -12,15 +12,12 @@ class AddResourceFieldsToImportsTable extends Migration { */ public function up() { - Schema::table('imports', function(Blueprint $table) { - + Schema::table('imports', function (Blueprint $table) { $table->string('resource_file_name')->nullable(); $table->integer('resource_file_size')->nullable()->after('resource_file_name'); $table->string('resource_content_type')->nullable()->after('resource_file_size'); $table->timestamp('resource_updated_at')->nullable()->after('resource_content_type'); - }); - } /** @@ -30,12 +27,8 @@ public function up() */ public function down() { - Schema::table('imports', function(Blueprint $table) { - - + Schema::table('imports', function (Blueprint $table) { $table->dropColumn('resource_file_name', 'resource_file_size', 'resource_content_type', 'resource_updated_at'); - }); } - -} \ No newline at end of file +} diff --git a/database/migrations/2017_03_09_140602_editSettingsTable.php b/database/migrations/2017_03_09_140602_editSettingsTable.php index ae67a62..7ac3c64 100644 --- a/database/migrations/2017_03_09_140602_editSettingsTable.php +++ b/database/migrations/2017_03_09_140602_editSettingsTable.php @@ -1,7 +1,7 @@ increments('id'); - $table->string("name"); - $table->integer("user_id"); - $table->boolean("valid")->default(false); - $table->boolean("public")->default(false); + $table->string('name'); + $table->integer('user_id'); + $table->boolean('valid')->default(false); + $table->boolean('public')->default(false); $table->timestamps(); - }); } diff --git a/database/migrations/2017_03_09_172505_add_resource_fields_to_settings_table.php b/database/migrations/2017_03_09_172505_add_resource_fields_to_settings_table.php index 3d94998..1f374ff 100644 --- a/database/migrations/2017_03_09_172505_add_resource_fields_to_settings_table.php +++ b/database/migrations/2017_03_09_172505_add_resource_fields_to_settings_table.php @@ -3,8 +3,8 @@ use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; -class AddResourceFieldsToSettingsTable extends Migration { - +class AddResourceFieldsToSettingsTable extends Migration +{ /** * Make changes to the table. * @@ -12,15 +12,12 @@ class AddResourceFieldsToSettingsTable extends Migration { */ public function up() { - Schema::table('settings', function(Blueprint $table) { - + Schema::table('settings', function (Blueprint $table) { $table->string('resource_file_name')->nullable(); $table->integer('resource_file_size')->nullable()->after('resource_file_name'); $table->string('resource_content_type')->nullable()->after('resource_file_size'); $table->timestamp('resource_updated_at')->nullable()->after('resource_content_type'); - }); - } /** @@ -30,9 +27,8 @@ public function up() */ public function down() { - Schema::table('settings', function(Blueprint $table) { - $table->dropColumn( 'resource_file_name', 'resource_file_size', 'resource_content_type', 'resource_updated_at'); + Schema::table('settings', function (Blueprint $table) { + $table->dropColumn('resource_file_name', 'resource_file_size', 'resource_content_type', 'resource_updated_at'); }); } - -} \ No newline at end of file +} diff --git a/database/migrations/2017_03_10_144612_create_validation_errors_table.php b/database/migrations/2017_03_10_144612_create_validation_errors_table.php index 944f3c8..ab8ac14 100644 --- a/database/migrations/2017_03_10_144612_create_validation_errors_table.php +++ b/database/migrations/2017_03_10_144612_create_validation_errors_table.php @@ -1,7 +1,7 @@ increments('id'); $table->integer('setting_id'); - $table->json("bag"); + $table->json('bag'); $table->timestamps(); }); } diff --git a/database/migrations/2017_08_29_162003_AddProviderColumnToSettings.php b/database/migrations/2017_08_29_162003_AddProviderColumnToSettings.php index 666ae23..961dcf7 100644 --- a/database/migrations/2017_08_29_162003_AddProviderColumnToSettings.php +++ b/database/migrations/2017_08_29_162003_AddProviderColumnToSettings.php @@ -1,7 +1,7 @@ addColumn("integer","suggestion_provider_id")->default(1); + $table->addColumn('integer', 'suggestion_provider_id')->default(1); }); } @@ -25,7 +25,7 @@ public function up() public function down() { Schema::table('settings', function (Blueprint $table) { - $table->dropColumn("suggestion_provider_id"); + $table->dropColumn('suggestion_provider_id'); }); } } diff --git a/database/migrations/2017_08_29_162936_create_suggestion_providers_table.php b/database/migrations/2017_08_29_162936_create_suggestion_providers_table.php index f92d2d4..5a962b7 100644 --- a/database/migrations/2017_08_29_162936_create_suggestion_providers_table.php +++ b/database/migrations/2017_08_29_162936_create_suggestion_providers_table.php @@ -1,7 +1,7 @@ increments('id'); - $table->string("name"); - $table->string("description"); - $table->string("configuration"); - $table->string("job"); + $table->string('name'); + $table->string('description'); + $table->string('configuration'); + $table->string('job'); $table->timestamps(); }); } diff --git a/database/migrations/2018_04_04_090710_create_failed_jobs_table.php b/database/migrations/2018_04_04_090710_create_failed_jobs_table.php index df9f443..a77357d 100644 --- a/database/migrations/2018_04_04_090710_create_failed_jobs_table.php +++ b/database/migrations/2018_04_04_090710_create_failed_jobs_table.php @@ -1,8 +1,8 @@ call(\ProjectFilePivotTableSeeder::class); - $this->call(\SettingsSeeder::class); - $this->call(\LinkTypeSeeder::class); - $this->call(\LabelExtractorSeeder::class); - $this->call(\SuggestionProvidersSeeder::class); + $this->call(\ProjectFilePivotTableSeeder::class); + $this->call(\SettingsSeeder::class); + $this->call(\LinkTypeSeeder::class); + $this->call(\LabelExtractorSeeder::class); + $this->call(\SuggestionProvidersSeeder::class); } - } diff --git a/database/seeds/LabelExtractorSeeder.php b/database/seeds/LabelExtractorSeeder.php index b4035ad..54aa30c 100644 --- a/database/seeds/LabelExtractorSeeder.php +++ b/database/seeds/LabelExtractorSeeder.php @@ -1,8 +1,7 @@ enabled = true; $label1->priority = 1; - $label1->property = "skos:prefLabel"; + $label1->property = 'skos:prefLabel'; $label1->save(); $label2 = new LabelExtractor(); $label2->enabled = true; - $label2->priority =2; - $label2->property = "rdfs:label"; + $label2->priority = 2; + $label2->property = 'rdfs:label'; $label2->save(); } } diff --git a/database/seeds/LinkTypeSeeder.php b/database/seeds/LinkTypeSeeder.php index eba73e4..b156080 100644 --- a/database/seeds/LinkTypeSeeder.php +++ b/database/seeds/LinkTypeSeeder.php @@ -1,8 +1,7 @@ 0, - 'group' => "SKOS", - 'inner' => "Exact Match", - 'value' => "http://www.w3.org/2004/02/skos/core#exactMatch", + 'group' => 'SKOS', + 'inner' => 'Exact Match', + 'value' => 'http://www.w3.org/2004/02/skos/core#exactMatch', 'public' => true, 'created_at' => Carbon::now(), 'updated_at' => Carbon::now(), ], [ 'user_id' => 0, - 'group' => "SKOS", - 'inner' => "Narrow Match", - 'value' => "http://www.w3.org/2004/02/skos/core#narrowMatch", + 'group' => 'SKOS', + 'inner' => 'Narrow Match', + 'value' => 'http://www.w3.org/2004/02/skos/core#narrowMatch', 'public' => true, 'created_at' => Carbon::now(), 'updated_at' => Carbon::now(), ], [ 'user_id' => 0, - 'group' => "SKOS", - 'inner' => "Broad Match", - 'value' => "http://www.w3.org/2004/02/skos/core#broadMatch", + 'group' => 'SKOS', + 'inner' => 'Broad Match', + 'value' => 'http://www.w3.org/2004/02/skos/core#broadMatch', 'public' => true, 'created_at' => Carbon::now(), 'updated_at' => Carbon::now(), ], [ 'user_id' => 0, - 'group' => "SKOS", - 'inner' => "Related Match", - 'value' => "http://www.w3.org/2004/02/skos/core#relatedMatch", + 'group' => 'SKOS', + 'inner' => 'Related Match', + 'value' => 'http://www.w3.org/2004/02/skos/core#relatedMatch', 'public' => true, 'created_at' => Carbon::now(), 'updated_at' => Carbon::now(), ], [ 'user_id' => 0, - 'group' => "SKOS", - 'inner' => "Close Match", - 'value' => "http://www.w3.org/2004/02/skos/core#closeMatch", + 'group' => 'SKOS', + 'inner' => 'Close Match', + 'value' => 'http://www.w3.org/2004/02/skos/core#closeMatch', 'public' => true, 'created_at' => Carbon::now(), 'updated_at' => Carbon::now(), ], - + //OWL [ 'user_id' => 0, - 'group' => "OWL", - 'inner' => "Same As", - 'value' => "http://www.w3.org/2002/07/owl#sameAs", + 'group' => 'OWL', + 'inner' => 'Same As', + 'value' => 'http://www.w3.org/2002/07/owl#sameAs', 'public' => true, 'created_at' => Carbon::now(), 'updated_at' => Carbon::now(), ], [ 'user_id' => 0, - 'group' => "OWL", - 'inner' => "Disjoint With", - 'value' => "http://www.w3.org/2002/07/owl#disjointWith", + 'group' => 'OWL', + 'inner' => 'Disjoint With', + 'value' => 'http://www.w3.org/2002/07/owl#disjointWith', 'public' => true, 'created_at' => Carbon::now(), 'updated_at' => Carbon::now(), ], [ 'user_id' => 0, - 'group' => "OWL", - 'inner' => "Equivalent Class", - 'value' => "http://www.w3.org/2002/07/owl#equivalentClass", + 'group' => 'OWL', + 'inner' => 'Equivalent Class', + 'value' => 'http://www.w3.org/2002/07/owl#equivalentClass', 'public' => true, 'created_at' => Carbon::now(), 'updated_at' => Carbon::now(), ], [ 'user_id' => 0, - 'group' => "OWL", - 'inner' => "Complement Of", - 'value' => "http://www.w3.org/2002/07/owl#complementOf", + 'group' => 'OWL', + 'inner' => 'Complement Of', + 'value' => 'http://www.w3.org/2002/07/owl#complementOf', 'public' => true, 'created_at' => Carbon::now(), 'updated_at' => Carbon::now(), - ], + ], [ 'user_id' => 0, - 'group' => "OWL", - 'inner' => "Different From", - 'value' => "http://www.w3.org/2002/07/owl#differentFrom", + 'group' => 'OWL', + 'inner' => 'Different From', + 'value' => 'http://www.w3.org/2002/07/owl#differentFrom', 'public' => true, 'created_at' => Carbon::now(), 'updated_at' => Carbon::now(), ], [ 'user_id' => 0, - 'group' => "OWL", - 'inner' => "Equivalent Property", - 'value' => "http://www.w3.org/2002/07/owl#equivalentProperty", + 'group' => 'OWL', + 'inner' => 'Equivalent Property', + 'value' => 'http://www.w3.org/2002/07/owl#equivalentProperty', 'public' => true, 'created_at' => Carbon::now(), 'updated_at' => Carbon::now(), ], [ 'user_id' => 0, - 'group' => "OWL", - 'inner' => "Inverse Of", - 'value' => "http://www.w3.org/2002/07/owl#inverseOf", + 'group' => 'OWL', + 'inner' => 'Inverse Of', + 'value' => 'http://www.w3.org/2002/07/owl#inverseOf', 'public' => true, 'created_at' => Carbon::now(), 'updated_at' => Carbon::now(), ], - + //RDFS [ 'user_id' => 0, - 'group' => "RDFS", - 'inner' => "See Also", - 'value' => "http://www.w3.org/2000/01/rdf-schema#seeAlso", + 'group' => 'RDFS', + 'inner' => 'See Also', + 'value' => 'http://www.w3.org/2000/01/rdf-schema#seeAlso', 'public' => true, 'created_at' => Carbon::now(), 'updated_at' => Carbon::now(), ], [ 'user_id' => 0, - 'group' => "RDFS", - 'inner' => "Sub-class Of", - 'value' => "http://www.w3.org/2000/01/rdf-schema#subClassOf", + 'group' => 'RDFS', + 'inner' => 'Sub-class Of', + 'value' => 'http://www.w3.org/2000/01/rdf-schema#subClassOf', 'public' => true, 'created_at' => Carbon::now(), 'updated_at' => Carbon::now(), ], [ 'user_id' => 0, - 'group' => "RDFS", - 'inner' => "Sub Property Of", - 'value' => "http://www.w3.org/2000/01/rdf-schema#subPropertyOf", + 'group' => 'RDFS', + 'inner' => 'Sub Property Of', + 'value' => 'http://www.w3.org/2000/01/rdf-schema#subPropertyOf', 'public' => true, 'created_at' => Carbon::now(), 'updated_at' => Carbon::now(), ], - + ]); - } -} \ No newline at end of file +} diff --git a/database/seeds/ProjectFilePivotTableSeeder.php b/database/seeds/ProjectFilePivotTableSeeder.php index cd2329e..de7acab 100644 --- a/database/seeds/ProjectFilePivotTableSeeder.php +++ b/database/seeds/ProjectFilePivotTableSeeder.php @@ -1,10 +1,7 @@ source; - + $target = $project->target; - + $source->projects()->attach($project->id); $target->projects()->attach($project->id); } - } } diff --git a/database/seeds/SettingsSeeder.php b/database/seeds/SettingsSeeder.php index f8d422a..a203379 100644 --- a/database/seeds/SettingsSeeder.php +++ b/database/seeds/SettingsSeeder.php @@ -1,7 +1,7 @@ count(); - $this->command->info('Found ' . $count .' settings.'); - if($count === 0){ + $this->command->info('Found '.$count.' settings.'); + if ($count === 0) { $this->command->info('Settings table empty. Running seeder...'); $settings = new Settings(); $settings->name = 'DEFAULT'; $settings->user_id = 1; $settings->public = true; $settings->valid = true; - $file = "/app/projects/default_config.xml"; - $filename = storage_path() . $file; - $settings->resource = $filename; + $file = '/app/projects/default_config.xml'; + $filename = storage_path().$file; + $tmpFilePath = sys_get_temp_dir().'/default_config.xml'; + copy($filename, $tmpFilePath); + $settings->resource = $tmpFilePath; $settings->save(); } } diff --git a/database/seeds/SuggestionProvidersSeeder.php b/database/seeds/SuggestionProvidersSeeder.php index aa9abee..dd4586c 100644 --- a/database/seeds/SuggestionProvidersSeeder.php +++ b/database/seeds/SuggestionProvidersSeeder.php @@ -1,7 +1,8 @@ truncate(); $silk = new SuggestionProvider(); - $silk->name = "Silk"; - $silk->description = "The Silk Link Discovery Framework"; + $silk->name = 'Silk'; + $silk->description = 'The Silk Link Discovery Framework'; $silk->configuration = "\App\Models\SuggestionConfigurations\SilkConfiguration"; $silk->job = "\App\Jobs\RunSilk"; $silk->save(); diff --git a/database/seeds/TestProject.php b/database/seeds/TestProject.php new file mode 100644 index 0000000..3724e4f --- /dev/null +++ b/database/seeds/TestProject.php @@ -0,0 +1,45 @@ +filetype = 'ntriples'; + $source->public = 1; + $source->user_id = 1; + $tmpFilePath = sys_get_temp_dir().'/stw.nt'; + copy($path.'stw.nt', $tmpFilePath); + $source->resource = $tmpFilePath; + $source->save(); + + $target = new File(); + $target->filetype = 'ntriples'; + $target->public = 1; + $target->user_id = 1; + $tmpFilePath = sys_get_temp_dir().'/jel.nt'; + copy($path.'jel.nt', $tmpFilePath); + $target->resource = $tmpFilePath; + $target->save(); + + $project = new Project(); + $project->user_id = 1; + $project->source_id = $source->id; + $project->target_id = $target->id; + $project->public = 1; + $project->settings_id = 1; + $project->name = 'SWT to JEL test project'; + $project->save(); + } +} diff --git a/public/index.php b/public/index.php index c582053..fc6eb49 100644 --- a/public/index.php +++ b/public/index.php @@ -1,9 +1,8 @@ */ diff --git a/public/js/silk/silkform.js b/public/js/silk/silkform.js deleted file mode 100644 index d1e37b2..0000000 --- a/public/js/silk/silkform.js +++ /dev/null @@ -1,58 +0,0 @@ - - - -function erasePath(field) { - -document.getElementById(field).value=""; - -} - -function showpaths(p) { - -var path="path"+p; -var field_a = "path"+p+"a"; -var field_b = "path"+p+"b"; -var field2_a = "trans"+p+"a"; -var field2_b = "trans"+p+"b"; -var field2_c = "trans"+p+"c"; -var field2_d = "trans"+p+"d"; - -if(document.getElementById(path).style.display=="none"){ -document.getElementById(path).style.display="block"; -document.getElementById(field_a).value="source path"; -document.getElementById(field_b).value="target path"; -document.getElementById(field2_a).value="none"; -document.getElementById(field2_b).value="none"; -document.getElementById(field2_c).value="none"; -document.getElementById(field2_d).value="none"; -} -else if(document.getElementById(path).style.display=="block") -document.getElementById(path).style.display="none"; -} - -function changeSource() { - -if(document.getElementById("sds_type").value=="sparqlEndpoint"){ -document.getElementById("source_selection").innerHTML='
endpointURI | |
graph |
file path | |
format |
endpointURI | |
graph |
file path | |
format |
Choose file type.
Select a local File to import
{{ $source_label}} | diff --git a/resources/views/mylinks.blade.php b/resources/views/mylinks.blade.php index 60e93b5..a3be058 100644 --- a/resources/views/mylinks.blade.php +++ b/resources/views/mylinks.blade.php @@ -17,7 +17,7 @@ @endif @include('links.export_modal') - @include('links.import_modal', ["select" => $select]) + @include('links.import_modal') @include('links.full_link_table') @endsection diff --git a/resources/views/play.blade.php b/resources/views/play.blade.php index b762b6e..ffbfd41 100644 --- a/resources/views/play.blade.php +++ b/resources/views/play.blade.php @@ -1,6 +1,6 @@ $value) { if ($key and $value) { - $html .= " ".htmlspecialchars($key)."=\"". - htmlspecialchars($value)."\""; + $html .= ' '.htmlspecialchars($key).'="'. + htmlspecialchars($value).'"'; } } + return $html; } -function tag($name, $options = array(), $open = false) +function tag($name, $options = [], $open = false) { - return "<$name".tag_options($options).($open ? ">" : " />"); + return "<$name".tag_options($options).($open ? '>' : ' />'); } -function content_tag($name, $content = null, $options = array()) +function content_tag($name, $content = null, $options = []) { - return "<$name".tag_options($options).">". + return "<$name".tag_options($options).'>'. htmlspecialchars($content)."$name>"; } -function link_to2($text, $uri = null, $options = array()) +function link_to2($text, $uri = null, $options = []) { - if ($uri == null) $uri = $text; - $options = array_merge(array('href' => $uri), $options); + if ($uri == null) { + $uri = $text; + } + $options = array_merge(['href' => $uri], $options); + return content_tag('a', $text, $options); } -function link_to2_self($text, $query_string, $options = array()) +function link_to2_self($text, $query_string, $options = []) { return link_to2($text, $_SERVER['PHP_SELF'].'?'.$query_string, $options); } -function image_tag($src, $options = array()) +function image_tag($src, $options = []) { - $options = array_merge(array('src' => $src), $options); + $options = array_merge(['src' => $src], $options); + return tag('img', $options); } -function input_tag($type, $name, $value = null, $options = array()) +function input_tag($type, $name, $value = null, $options = []) { $options = array_merge( - array( + [ 'type' => $type, 'name' => $name, 'id' => $name, - 'value' => $value - ), + 'value' => $value, + ], $options ); + return tag('input', $options); } -function text_field_tag($name, $default = null, $options = array()) +function text_field_tag($name, $default = null, $options = []) { $value = isset($_REQUEST[$name]) ? $_REQUEST[$name] : $default; + return input_tag('text', $name, $value, $options); } -function text_area_tag($name, $default = null, $options = array()) +function text_area_tag($name, $default = null, $options = []) { $content = isset($_REQUEST[$name]) ? $_REQUEST[$name] : $default; $options = array_merge( - array( + [ 'name' => $name, 'id' => $name, 'cols' => 60, - 'rows' => 5 - ), + 'rows' => 5, + ], $options ); + return content_tag('textarea', $content, $options); } -function hidden_field_tag($name, $default = null, $options = array()) +function hidden_field_tag($name, $default = null, $options = []) { $value = isset($_REQUEST[$name]) ? $_REQUEST[$name] : $default; + return input_tag('hidden', $name, $value, $options); } -function password_field_tag($name = 'password', $default = null, $options = array()) +function password_field_tag($name = 'password', $default = null, $options = []) { $value = isset($_REQUEST[$name]) ? $_REQUEST[$name] : $default; + return input_tag('password', $name, $value, $options); } -function radio_button_tag($name, $value, $default = false, $options = array()) +function radio_button_tag($name, $value, $default = false, $options = []) { if ((isset($_REQUEST[$name]) and $_REQUEST[$name] == $value) or - (!isset($_REQUEST[$name]) and $default)) - { - $options = array_merge(array('checked' => 'checked'), $options); + (! isset($_REQUEST[$name]) and $default)) { + $options = array_merge(['checked' => 'checked'], $options); } - $options = array_merge(array('id' => $name.'_'.$value), $options); + $options = array_merge(['id' => $name.'_'.$value], $options); + return input_tag('radio', $name, $value, $options); } -function check_box_tag($name, $value = '1', $default = false, $options = array()) +function check_box_tag($name, $value = '1', $default = false, $options = []) { if ((isset($_REQUEST[$name]) and $_REQUEST[$name] == $value) or - (!isset($_REQUEST['submit']) and $default)) - { - $options = array_merge(array('checked' => 'checked'),$options); + (! isset($_REQUEST['submit']) and $default)) { + $options = array_merge(['checked' => 'checked'], $options); } + return input_tag('checkbox', $name, $value, $options); } -function submit_tag($name = '', $value = 'Submit', $options = array()) +function submit_tag($name = '', $value = 'Submit', $options = []) { return input_tag('submit', $name, $value, $options); } -function reset_tag($name = '', $value = 'Reset', $options = array()) +function reset_tag($name = '', $value = 'Reset', $options = []) { return input_tag('reset', $name, $value, $options); } -function label_tag($name, $text = null, $options = array()) +function label_tag($name, $text = null, $options = []) { if ($text == null) { $text = ucwords(str_replace('_', ' ', $name)).': '; } $options = array_merge( - array('for' => $name, 'id' => "label_for_$name"), + ['for' => $name, 'id' => "label_for_$name"], $options ); + return content_tag('label', $text, $options); } -function labeled_text_field_tag($name, $default = null, $options = array()) +function labeled_text_field_tag($name, $default = null, $options = []) { return label_tag($name).text_field_tag($name, $default, $options); } -function select_tag($name, $options, $default = null, $html_options = array()) +function select_tag($name, $options, $default = null, $html_options = []) { $opts = ''; foreach ($options as $key => $value) { - $arr = array('value' => $value); + $arr = ['value' => $value]; if ((isset($_REQUEST[$name]) and $_REQUEST[$name] == $value) or - (!isset($_REQUEST[$name]) and $default == $value)) - { - $arr = array_merge(array('selected' => 'selected'),$arr); + (! isset($_REQUEST[$name]) and $default == $value)) { + $arr = array_merge(['selected' => 'selected'], $arr); } $opts .= content_tag('option', $key, $arr); } $html_options = array_merge( - array('name' => $name, 'id' => $name), + ['name' => $name, 'id' => $name], $html_options ); - return ""; + + return '"; } -function form_tag($uri = null, $options = array()) +function form_tag($uri = null, $options = []) { if ($uri == null) { $uri = $_SERVER['PHP_SELF']; } $options = array_merge( - array('method' => 'get', 'action' => $uri), + ['method' => 'get', 'action' => $uri], $options ); + return tag('form', $options, true); } function form_end_tag() { - return ""; + return ''; } ?> 'guess'); - $output_format_options = array(); + $input_format_options = ['Guess' => 'guess']; + $output_format_options = []; foreach (EasyRdf_Format::getFormats() as $format) { if ($format->getSerialiserClass()) { $output_format_options[$format->getLabel()] = $format->getName(); @@ -217,28 +227,28 @@ function form_end_tag() $_REQUEST['data'] = stripslashes($_REQUEST['data']); } // Default to Guess input and Turtle output - if (!isset($_REQUEST['output_format'])) { + if (! isset($_REQUEST['output_format'])) { $_REQUEST['output_format'] = 'turtle'; } - if (!isset($_REQUEST['input_format'])) { + if (! isset($_REQUEST['input_format'])) { $_REQUEST['input_format'] = 'guess'; } // Display the form, if raw option isn't set - if (!isset($_REQUEST['raw'])) { - print "\n"; - print "|||||||||
- | diff --git a/resources/views/projects/user_projects_tab.blade.php b/resources/views/projects/user_projects_tab.blade.php index 194a8aa..ba609f9 100644 --- a/resources/views/projects/user_projects_tab.blade.php +++ b/resources/views/projects/user_projects_tab.blade.php @@ -7,14 +7,16 @@|||||||||
- | diff --git a/resources/views/projects/vote_projects_tab.blade.php b/resources/views/projects/vote_projects_tab.blade.php index b3ad19d..bb57be3 100644 --- a/resources/views/projects/vote_projects_tab.blade.php +++ b/resources/views/projects/vote_projects_tab.blade.php @@ -31,16 +31,16 @@ | {{ $project->created_at }} | - |
diff --git a/resources/views/settings/partials/create_modal.blade.php b/resources/views/settings/partials/create_modal.blade.php
index c711389..33cd505 100644
--- a/resources/views/settings/partials/create_modal.blade.php
+++ b/resources/views/settings/partials/create_modal.blade.php
@@ -12,13 +12,13 @@
- = Form::file('resource',['id' => "inputFile", 'required'=>'true']) ?>
+ = Form::file('resource', ['id' => 'inputFile', 'required'=>'true']) ?>
Attach a valid provider specific configuration file
= Form::label('name', 'Enter a user friendly name') ?>
- = Form::text('name', null, ["class" => "form-control"]) ?>
+ = Form::text('name', null, ['class' => 'form-control']) ?>
Select Suggestions Provider
diff --git a/resources/views/settings/partials/error.blade.php b/resources/views/settings/partials/error.blade.php
index 7e93b81..2fbf0b1 100644
--- a/resources/views/settings/partials/error.blade.php
+++ b/resources/views/settings/partials/error.blade.php
@@ -1,18 +1,18 @@
level){
+ switch ($error->level) {
case 1:
- $bg = "bg-yellow-gradient";
- $header = "LIBXML_ERR_WARNING";
+ $bg = 'bg-yellow-gradient';
+ $header = 'LIBXML_ERR_WARNING';
break;
case 2:
- $bg = "bg-red-gradient";
- $header = " LIBXML_ERR_ERROR";
+ $bg = 'bg-red-gradient';
+ $header = ' LIBXML_ERR_ERROR';
break;
case 3:
- $bg = "bg-black-gradient";
- $header = "LIBXML_ERR_FATAL";
+ $bg = 'bg-black-gradient';
+ $header = 'LIBXML_ERR_FATAL';
break;
}
?>
diff --git a/resources/views/voteApp/partials/poll.blade.php b/resources/views/voteApp/partials/poll.blade.php
index 45efd79..ada24bb 100644
--- a/resources/views/voteApp/partials/poll.blade.php
+++ b/resources/views/voteApp/partials/poll.blade.php
@@ -1,8 +1,8 @@
count();
- $source_graph = \Illuminate\Support\Facades\Cache::get($candidates[0]->source_id . "_graph");
- $target_graph = \Illuminate\Support\Facades\Cache::get($candidates[0]->target_id . "_graph");
+ $source_graph = \Illuminate\Support\Facades\Cache::get($candidates[0]->source_id.'_graph');
+ $target_graph = \Illuminate\Support\Facades\Cache::get($candidates[0]->target_id.'_graph');
$ontologies_graph = \Illuminate\Support\Facades\Cache::get('ontologies_graph');
}
?>
@@ -30,9 +30,9 @@
source_entity)? : EasyRdf_Namespace::shorten($candidate->source_entity, true);
- $link_type_label = \App\RDFTrait::label($ontologies_graph, $candidate->link_type)? : EasyRdf_Namespace::shorten($candidate->link_type, true);
- $target_label = \App\RDFTrait::label($target_graph, $candidate->target_entity)? : EasyRdf_Namespace::shorten($candidate->target_entity, true);
+ $source_label = \App\RDFTrait::label($source_graph, $candidate->source_entity) ?: EasyRdf_Namespace::shorten($candidate->source_entity, true);
+ $link_type_label = \App\RDFTrait::label($ontologies_graph, $candidate->link_type) ?: EasyRdf_Namespace::shorten($candidate->link_type, true);
+ $target_label = \App\RDFTrait::label($target_graph, $candidate->target_entity) ?: EasyRdf_Namespace::shorten($candidate->target_entity, true);
?>
{{$source_label}} {{$link_type_label}} {{$target_label}}
diff --git a/resources/views/votes/export-voted-modal.blade.php b/resources/views/votes/export-voted-modal.blade.php
index 642419b..5707658 100644
--- a/resources/views/votes/export-voted-modal.blade.php
+++ b/resources/views/votes/export-voted-modal.blade.php
@@ -10,7 +10,7 @@
{!! Form::open(['id'=>'export-voted-form', 'url'=>'myvotes/export']) !!}
user()->projects;
- $select = array();
+ $select = [];
foreach ($projects as $project) {
$key = $project->id;
$value = $project->name;
@@ -26,7 +26,7 @@
?>
= Form::label('project', 'Select Project') ?>
- = Form::select('project_id', $select, null, ["class" => "form-control"]) ?>
+ = Form::select('project_id', $select, null, ['class' => 'form-control']) ?>
Set a threshold:
diff --git a/resources/views/votes/voter-modal.blade.php b/resources/views/votes/voter-modal.blade.php
index 1302209..14878ae 100644
--- a/resources/views/votes/voter-modal.blade.php
+++ b/resources/views/votes/voter-modal.blade.php
@@ -11,18 +11,18 @@
user()->projects;
- $select = array();
+ $select = [];
foreach ($projects as $project) {
- $key = $project->id;
- $value = $project->name;
- $select = array_add($select, $key, $value);
+ $key = $project->id;
+ $value = $project->name;
+ $select = array_add($select, $key, $value);
}
//public files addition
$projects = App\Project::where('public', '=', '1')->get();
foreach ($projects as $project) {
- $key = $project->id;
- $value = $project->name;
- $select = array_add($select, $key, $value);
+ $key = $project->id;
+ $value = $project->name;
+ $select = array_add($select, $key, $value);
}
?>
= Form::label('project', 'Select Project') ?>
diff --git a/routes/api.php b/routes/api.php
index 3ac00fa..e74c76c 100644
--- a/routes/api.php
+++ b/routes/api.php
@@ -1,8 +1,7 @@
'HomeController@welcome', "as" => "home"]);
+Route::get('/', ['uses' => 'HomeController@welcome', 'as' => 'home']);
Route::group(['middleware' => ['web']], function () {
-
Auth::routes();
if (env('APP_REGISTRATION')) {
@@ -63,7 +61,7 @@
Route::post('notification/get', ['uses' => 'SSEController@get', 'as' => 'notification.get']);
- Route::post('createlinks/utility/link_table/{project?}', ['uses' => 'LinkController@project_links', 'as' => 'createlinks.project_links']);
+ Route::post('createlinks/utility/link_table/{project?}', ['uses' => 'LinkController@projectLinks', 'as' => 'createlinks.project_links']);
Route::get('createlinks/{project?}', ['uses' => 'CreatelinksController@index', 'as' => 'createlinks']);
@@ -75,7 +73,7 @@
Route::post('createlinks/utility/create', ['uses' => 'LinkController@create', 'as' => 'mylinks.create']);
- Route::get('createlinks/utility/delete_all', ['uses' => 'LinkController@delete_all', 'as' => 'mylinks.delete_all']);
+ Route::get('createlinks/utility/delete_all', ['uses' => 'LinkController@deleteAll', 'as' => 'mylinks.delete_all']);
Route::get('createlinks/utility/export_table', ['uses' => 'LinkController@export', 'as' => 'mylinks.export']);
@@ -83,7 +81,7 @@
Route::get('mylinks/utility/export_table', ['uses' => 'LinkController@export', 'as' => 'mylinks.export2']);
- Route::post('myvotes/export', ['uses' => 'LinkController@export_voted', 'as' => 'myvotes.export']);
+ Route::post('myvotes/export', ['uses' => 'LinkController@exportVoted', 'as' => 'myvotes.export']);
Route::delete('createlinks/utility/delete', ['uses' => 'LinkController@destroy', 'as' => 'mylinks.delete']);
@@ -113,6 +111,8 @@
Route::put('myprojects/', ['uses' => 'ProjectController@update', 'as' => 'myprojects.update']);
+ Route::get('myprojects/prepare/{id}', ['uses' => 'ProjectController@prepareProject', 'as' => 'myprojects.prepareproject']);
+
Route::delete('project/delete/{project}', ['uses' => 'ProjectController@destroy', 'as' => 'myprojects.delete']);
Route::get('settings/', ['uses' => 'SettingsController@index', 'as' => 'settings']);
@@ -127,8 +127,6 @@
Route::delete('settings/delete', ['uses' => 'SettingsController@destroy', 'as' => 'settings.delete']);
- Route::post('settings/create_config/{project_id}', ['uses' => 'SettingsController@create_config', 'as' => 'settings.create_config']);
-
Route::get('myvotes/', ['uses' => 'VoteController@index', 'as' => 'myvotes']);
Route::post('myvotes/project', ['uses' => 'VoteController@project_vote', 'as' => 'project_vote']);
@@ -145,42 +143,42 @@
Route::post('/comments/create', ['uses' => 'CommentController@create', 'as' => 'comment.create']);
- Route::resource('rdfnamespace', 'rdfnamespaceController', array('names' => array('create' => 'rdfnamespace.create',
+ Route::resource('rdfnamespace', 'rdfnamespaceController', ['names' => ['create' => 'rdfnamespace.create',
'show' => 'rdfnamespace.show',
'index' => 'rdfnamespace.index',
'store' => 'rdfnamespace.store',
'update' => 'rdfnamespace.update',
'edit' => 'rdfnamespace.edit',
- 'destroy' => 'rdfnamespace.destroy')));
+ 'destroy' => 'rdfnamespace.destroy', ]]);
- Route::resource('label-extractor', 'LabelExtractorController', array('names' => array('create' => 'label-extractor.create',
+ Route::resource('label-extractor', 'LabelExtractorController', ['names' => ['create' => 'label-extractor.create',
'show' => 'label-extractor.show',
'index' => 'label-extractor.index',
'store' => 'label-extractor.store',
'update' => 'label-extractor.update',
'edit' => 'label-extractor.edit',
- 'destroy' => 'label-extractor.destroy')));
+ 'destroy' => 'label-extractor.destroy', ]]);
Route::get('about/', ['as' => 'about', 'uses' => 'HomeController@about']);
- Route::get('voteApp/', ['as' => 'voteApp', 'uses' => "PollController@index"]);
+ Route::get('voteApp/', ['as' => 'voteApp', 'uses' => 'PollController@index']);
- Route::get('getPoll/', ['as' => 'getPoll', 'uses' => "PollController@getPoll"]);
+ Route::get('getPoll/', ['as' => 'getPoll', 'uses' => 'PollController@getPoll']);
- Route::get('api/projects', ['as' => 'api.projects', 'uses' => "PollController@projects"]);
+ Route::get('api/projects', ['as' => 'api.projects', 'uses' => 'PollController@projects']);
- Route::post('api/project', ['as' => 'api.project', 'uses' => "PollController@project"]);
+ Route::post('api/project', ['as' => 'api.project', 'uses' => 'PollController@project']);
- Route::post("mylinks/import", ["as" => 'links.import', 'uses' => 'LinkController@import']);
+ Route::post('mylinks/import', ['as' => 'links.import', 'uses' => 'LinkController@import']);
- Route::get("link/ajax", ["as" => 'links.ajax', 'uses' => 'LinkController@ajax']);
+ Route::get('link/ajax', ['as' => 'links.ajax', 'uses' => 'LinkController@ajax']);
- Route::get("settings/ajax", ["as" => 'settings.ajax', 'uses' => 'SettingsController@ajax']);
+ Route::get('settings/ajax', ['as' => 'settings.ajax', 'uses' => 'SettingsController@ajax']);
- Route::get("settings/validation/errors", ["as" => 'settings.validation.errors', 'uses' => 'SettingsController@errors']);
+ Route::get('settings/validation/errors', ['as' => 'settings.validation.errors', 'uses' => 'SettingsController@errors']);
- Route::get("settings/reconstruct", ["as" => 'settings.reconstruct', 'uses' => 'SettingsController@reconstruct']);
+ Route::get('settings/reconstruct', ['as' => 'settings.reconstruct', 'uses' => 'SettingsController@reconstruct']);
- Route::get("settings/validate", ["as" => 'settings.validate', 'uses' => 'SettingsController@validateSettingsFile']);
+ Route::get('settings/validate', ['as' => 'settings.validate', 'uses' => 'SettingsController@validateSettingsFile']);
});
});
diff --git a/server.php b/server.php
index f65c7c4..1b4655b 100644
--- a/server.php
+++ b/server.php
@@ -1,12 +1,10 @@
*/
-
$uri = urldecode(
parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH)
);
diff --git a/storage/app/.gitignore b/storage/app/.gitignore
index 058e73c..4541b90 100644
--- a/storage/app/.gitignore
+++ b/storage/app/.gitignore
@@ -2,4 +2,5 @@
!public/
!projects/
!ontologies/
+!test/
!.gitignore
diff --git a/storage/app/test/jel.nt b/storage/app/test/jel.nt
new file mode 100644
index 0000000..82f406f
--- /dev/null
+++ b/storage/app/test/jel.nt
@@ -0,0 +1,17863 @@
+ |