talk_api_internal/
config.rs

1use crate::agent::TalkApiAgent;
2
3#[derive(Debug, Clone, Copy)]
4pub struct Config<'a> {
5    pub language: &'a str,
6    pub version: &'a str,
7
8    pub agent: TalkApiAgent<'a>,
9}
10
11impl Config<'_> {
12    pub fn get_user_agent(self) -> String {
13        self.agent.get_user_agent(self.version, self.language)
14    }
15}