JRA, PHP cAPI interface
  • Namespace
  • Class
  • Tree

Namespaces

  • JRA
    • Abstracts
    • Commands
      • Invokers
      • Methods
        • Content
        • Token
        • User
      • Routes
    • ComposerHandler
    • Config
      • Helper
    • Exceptions
    • Facades
    • Factories
    • Interfaces
    • Objects
      • Response
        • Data
    • Responsibilities
      • Handlers
      • Responsible
        • Login
        • Logout

Classes

  • ARSAnnatech
  • Authenticate
  • Server
  • Version

Class Authenticate

Namespace: JRA\Config
Located at Config/Authenticate.php

Methods summary

public
# __construct( integer $pAuthMethod, integer $pAutoLogin )

Authenticate constructor.

Authenticate constructor.

Parameters

$pAuthMethod
$pAutoLogin
public
# setToken( string $pToken )

Sets the token for an token required authentication method.

Sets the token for an token required authentication method.

Parameters

$pToken
The token which should be set.

Throws

JRA\Exceptions\TokenConfigException
If the authentication method is not set to an token required authentication method an exception will be thrown.
public
# setCredentials( string $pUsername, string $pPassword )

Sets the user credentials for an user credentials required authentication method.

Sets the user credentials for an user credentials required authentication method.

Parameters

$pUsername
The username which should be used for authentication.
$pPassword
The password which should be used for authentication.

Throws

JRA\Exceptions\UserCredentialsConfigException
If the authentication method is not set to an user credentials required authentication method an exception will be thrown.
public integer
# getAuthenticationMethod( )

Returns the specified authentication method.

Returns the specified authentication method.

Returns

integer
The authentication method.
public boolean
# isAutoLoginOn( )

Checks if auto login is on or off.

Checks if auto login is on or off.

Returns

boolean
True if auto login is on, false otherwise.
public array|string
# getAuthenticationCredentials( )

Returns the authentication credentials, based on the specified authentication method and if they are set before.

Returns the authentication credentials, based on the specified authentication method and if they are set before.

Returns

array|string
The user credentials or the token.

Throws

JRA\Exceptions\AuthenticationConfigException
Throws an exception if the authentication method is not set.
JRA\Exceptions\TokenConfigException
Throws an exception if the token is not specified and a token required authentication method is specified.
JRA\Exceptions\UserCredentialsConfigException
Throws an exception if the user credentials are not specified and a user credentials required authentication method is specified.
public
# setSession( string $pSession )

Sets the current session of the Joomla.

Sets the current session of the Joomla.

Parameters

$pSession
public string
# getSession( )

Returns the current session of the Joomla.

Returns the current session of the Joomla.

Returns

string

Constants summary

integer AUTH_METHOD_HEADER_TOKEN

The auth method id for header token authentication.

The auth method id for header token authentication.

# 100
integer AUTH_METHOD_USER_CREDENTIALS

The auth method id for user credentials authentication.

The auth method id for user credentials authentication.

# 101
integer AUTH_METHOD_TOKEN

The auth method if for token authentication.

The auth method if for token authentication.

# 102
integer AUTH_AUTO_LOGIN_ON

The auto login id if the api should automatically login.

The auto login id if the api should automatically login.

# 200
integer AUTH_AUTO_LOGIN_OFF

The auto login id if the api should not automatically login.

The auto login id if the api should not automatically login.

# 201
JRA, PHP cAPI interface API documentation generated by ApiGen