-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathInlineQuery_T.m
33 lines (32 loc) · 929 Bytes
/
InlineQuery_T.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
function iquery = InlineQuery_T(id,from, query, offset, varargin)
% InlineQuery_T - This object represents an incoming inline query. When the
% user sends an empty query, your bot could return some default or trending
% results.
%
% id String Unique identifier for this query
%
% from User Sender
%
% location Location Optional. Sender location, only for bots that
% request user location
%
% query String Text of the query (up to 256 characters)
%
% offset String Offset of the results to be returned, can be controlled
% by the bot
%
iquery = struct;
iquery.id = id;
iquery.from = from;
iquery.query = query;
iquery.offset = offset;
while ~isempty(varargin)
switch lower(varargin{1})
case 'location'
iquery.location = varargin{2};
otherwise
error(['Unexpected option: ' varargin{1}])
end %switch
varargin(1:2) = [];
end % while isempty
end