/// <reference path="./sigApi.ApiBase.d.ts" />

declare namespace SigApi {
    interface ApiAccessSequence extends ApiBase {
        /**
         * Checks if the current user has the permission to interact with the given accessNumber
         * 
         * @param {number} accNum The accessnumber which should be checked
         * @param {string|number} [userId=undefined] The Id or the username of the user which should be checked
         * 
         * default value: current user
         * @returns {boolean} true if the user is allowed to interact with the given number, and false if not
         */
        checkAccess(accNum: number, userId?: string | number): boolean
        /**
         * Checks if the current user has the permission to interact read-only with the given accessNumber
         * 
         * @param {number} accNum The accessnumber which should be checked
         * @param {string|number} [userId=undefined] The Id or the username of the user which should be checked
         * 
         * default value: current user
         * @returns {boolean} true if the user is allowed to interact read-only with the given number, and false if not
         */
        checkReadAccess(accNum: number, userId?: string | number): boolean
        /**
         * Checks if the Access API is ready (access sequence must be initialized before sending events, reading datapoints, etc...)
         * 
         * @returns {boolean} true if the access Sequence is initialized and ready
         */
        isReady(): boolean
    }
}
