<?php

namespace Encgateway;

class Apib
{
	
    // @var string The Stripe API key to be used for requests.
    public static $apiKey;

    // @var string The base URL for the Stripe API.
    public static $apiBase = 'https://demo.paycertify.net/';
 
    // @var string|null The version of the Stripe API to use for requests.
    public static $apiVersion = '1.0.1';

 	public static $outputFormat = 'array';
 
    /**
     * @return string The API key used for requests.
     */
    public static function getApiKey()
    {
        return self::$apiKey;
    }

	public static function getApiBase(){
		return self::$apiBase;
	}

    /**
     * Sets the API key to be used for requests.
     *
     * @param string $apiKey
     */
    public static function setApiKey($apiKey)
    {
        self::$apiKey = $apiKey;
    }

	
    /**
     * @return string The API version used for requests. null if we're using the
     *    latest version.
     */
    public static function getApiVersion()
    {
        return self::$apiVersion;
    }

    /**
     * @param string $apiVersion The API version to use for requests.
     */
    public static function setApiVersion($apiVersion)
    {
        self::$apiVersion = $apiVersion;
    }

	/**
     * @return output format key used for requests.
     */
    public static function getOutputFormat()
    {
        return self::$outputFormat;
    }

    /**
     * Sets the output format to be used for requests.
     *
     * @param string $apiKey
     */
    public static function SetOutputFormat($outputFormat)
    {
		$format = self::getOutputFormat();
		if($outputFormat == 'array' || $outputFormat == 'xml' || $outputFormat == 'json'){
        	$format = $outputFormat;
		}
		self::$outputFormat = $format;
    }

}