LaravelInvites   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 27
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 1
eloc 2
dl 0
loc 27
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A getFacadeAccessor() 0 3 1
1
<?php
2
3
namespace mathewparet\LaravelInvites\Facades;
4
5
use Illuminate\Support\Facades\Facade;
6
7
class LaravelInvites extends Facade
8
{
9
    /**
10
     * @method mixed get() Get the invites from DB
11
     * @method \mathewparet\LaravelInvites\Facades\LaravelInvites for(string $email) Set the email property for generating or getting invitation
12
     * @method \mathewparet\LaravelInvites\Facades\LaravelInvites validFrom(\Carbon\Carbon $date) Set the validity start date for the invitation
13
     * @method mixed generate(integer $number_of_invites = 1) Generate invitations
14
     * @method \mathewparet\LaravelInvites\Models\Invite generateFor(string $email) Generate invitations for a particular email
15
     * @method \mathewparet\LaravelInvites\Facades\LaravelInvites allow(integer $num_allowed = 1) Set the number of uses allowed for this invite
16
     * @method \mathewparet\LaravelInvites\Facades\LaravelInvites withoutExpiry() Set expiry to never expire (overrides config)
17
     * @method \mathewparet\LaravelInvites\Facades\LaravelInvites setExpiry(\Carbon\Carbon $date) Set an expiry date
18
     * @method \mathewparet\LaravelInvites\Models\Invite find(string $code) Find an invitation based on code
19
     * @method boolean validate(string $attribute, string $value, array $parameters, Validator $validator) Validate the form submission for a valid invitation code
20
     * @method boolean isValid(strong $code, string $email = null) Check whether an invitation is valid with the provided email
21
     * @method boolean check(string $code, string $email = null) Check the validity of the invitiation code & thrown exception
22
     * @method boolean redeem(string $code, string $email = null) Redeem the invitation code. Make sure the form field is validated before this calls to avoid exceptions
23
     * @method \mathewparet\LaravelInvites\Facades\LaravelInvites notBefore(\Carbon\Carbon $date) Set a validity start date for the invitation
24
     */
25
26
    /**
27
     * Get the registered name of the component.
28
     *
29
     * @return string
30
     */
31
    protected static function getFacadeAccessor()
32
    {
33
        return 'laravelinvites';
34
    }
35
36
}
37