yatbcpp  0.0.1
Yet another Telegram Bot CPP Library
Public Member Functions | Static Public Member Functions | Private Attributes | List of all members
yatbcpp::Token Class Reference

#include "Token.h"

Public Member Functions

 Token (const char ttoken[__TELEGRAM_TOKEN_LENGTH])
 
 Token (const Token &T)
 
const std::string getToken () const
 
void setToken (std::string s)
 

Static Public Member Functions

static Token FromFile (const char *fileLocation)
 

Private Attributes

std::string token
 

Detailed Description

Definition at line 16 of file Token.h.

Constructor & Destructor Documentation

◆ Token() [1/2]

Token::Token ( const char  ttoken[__TELEGRAM_TOKEN_LENGTH])

Limited to the max char length of 45 characters, from then on it is stl

Parameters
ttoken

Definition at line 46 of file Token.cc.

◆ Token() [2/2]

Token::Token ( const Token T)

Definition at line 50 of file Token.cc.

Member Function Documentation

◆ FromFile()

Token Token::FromFile ( const char *  filelocation)
static

Reads file and gets the token from the file

Parameters
filelocation,thefile location of the token
Returns

Definition at line 60 of file Token.cc.

◆ getToken()

const std::string Token::getToken ( ) const

returns the token as string

Returns
the Token

Definition at line 23 of file Token.cc.

◆ setToken()

void Token::setToken ( std::string  s)

Sets the Token, additional verification is done

Parameters
s

Definition at line 32 of file Token.cc.

Member Data Documentation

◆ token

std::string yatbcpp::Token::token
private

Definition at line 29 of file Token.h.


The documentation for this class was generated from the following files: