Дерево страниц

Сравнение версий

Ключ

  • Эта строка добавлена.
  • Эта строка удалена.
  • Изменено форматирование.
Комментарий: Published by Scroll Versions from space TMINT and version 6.5
Sv translation
languageru

Наименование

Описание

Пример кода

EventId

Идентификатор загружаемого события.

typedef i64 EventId

StreamId

Идентификатор загружаемого потока данных события

typedef i64 StreamId

ItemId

Идентификатор элемента в событии

typedef i32 ItemId

InterfaceVersion

Версия PushAPI интерфейса

typedef i32 InterfaceVersion

struct Attribute

Отдельный атрибут любой сущности события (самого события, идентификации, потока данных)

{
1: required string name,
2: required string value,
}

struct Identity

Идентификация получателя или отправителя объекта

{
1: required ItemId identity_id
2: required IdentityItemType identity_type,
3: required list<Attribute> identity_contacts,
4: optional list<Attribute> identity_attributes
}

struct EventData

Описание потока данных события

{
1: required ItemId data_id
2: optional list<Attribute> data_attributes
}
data_id - Уникальный идентификатор потока данных внутри события, используется для ссылок на поток;
data_attributes - необязательный набор атрибутов потока данных;

struct ItemLink

Описание связи между различными сущностями события

{
1: required ItemId id,
2: required ItemId link_to_id,
3: required string link_name
}

id - идентификатор сущности события, от которой идёт связь;
link_to_id - идентификатор сущности события, к которой идёт связь;
link_name - имя(тип) связи;

struct ChatMessage

Описание одного сообщения класса "Беседа"

{
1: required ItemId sender_id,
2: required string sent_time,
3: required string utf8_text,
4: optional ItemId mes_data_id,
}

sender_id - ссылка на идентификацию, которая является отправителем сообщения;
sent_time – локальное время передачи сообщения в формате ГГГГ-ММ-ДДTЧЧ:ММ:СС+ЧЧ:ММ(ISO 8601 c форматированием yyyy-MM-ddTHH:mm:sszzz);
utf8_text - текст сообщения в кодировке UTF-8;
mes_data_id - идентификатор данных объекта, в которых будет передано содержимое сообщения, если utf8_text пустой;

struct Event

Описание события, которое нужно передать на Traffic Monitor

{
1: required EventClass evt_class,
2: required string evt_service,
3: optional list<Attribute> evt_attributes,
4: required list<Identity> evt_senders,
5: required list<Identity> evt_receivers
6: required list<EventData> evt_data,
8: optional list<ChatMessage> evt_messages,
7: optional list<ItemLink> evt_links
}

evt_class - класс события;
evt_service - сервис события;
evt_attributes - атрибуты события;
evt_senders - отправители события;
evt_receivers - получатели события
evt_data - данные события;
evt_messages - сообщения события для класса "Беседа";
evt_links - связи между сущностями в событии;

struct Credentials

Структура, описывающая параметры доступа к Traffic Monitor

{
1: required string company_name,
2: required string token
}

company_name - название клиента (или компании в нашем случае). Этот параметр связывает плагин внешнего разработчика с лицензией;
token - токен авторизации. Эта строка является «секретом», который знают плагин и Traffic Monitor. Так реализована авторизация источника данных.

Sv translation
languageen
Name
Description
Sample code
EventIdAn identifier of the loaded eventtypedef i64 EventId
StreamIdAn identifier of the loaded stream with the event datatypedef i64 StreamId
ItemIdAn identifier of the element in the eventtypedef i32 ItemId
InterfaceVersionThe version of PushAPI interfacetypedef i32 InterfaceVersion
struct AttributeA separate attribute of any entity of the event (the event itself, the identification, the data stream){ 
1: required string name, 
2: required string value, 
}
struct IdentityIdentification of the object sender or recipient{ 
1: required ItemId identity_id 
2: required IdentityItemType identity_type, 
3: required list<Attribute> identity_contacts, 
4: optional list<Attribute> identity_attributes 
}
struct EventDataA description of the event data stream{ 
1: required ItemId data_id 
2: optional list<Attribute> data_attributes 
} 
where 
data_id is a unique identifier of the data stream within an event; is used for links to the stream; 
data_attributes is an optional set of attributes for a data stream.
struct ItemLinkA description of a connection between different event entities{ 
1: required ItemId id, 
2: required ItemId link_to_id, 
3: required string link_name 
} 

where 
id is an identifier of the event entity, from which the connection goes; 
link_to_id is an identifier of the event entity, to which the connection goes; 
link_name is the connection name (type).
struct ChatMessageA description of a single message of the "Chat" class{ 
1: required ItemId sender_id, 
2: required string sent_time, 
3: required string utf8_text, 
4: optional ItemId mes_data_id, 
} 

where
sender_id is a link to the identification which is a message sender; 
sent_time is the local time of sending the message in YY-MM-DDTHH:MM:SS+HH:MM (ISO 8601 with yyyy-MM-ddTHH:mm:sszzz formatting); 
utf8_text is the message text in UTF-8 encoding; 
mes_data_id is an identifier of the object data, in which the message contents will be sent if utf8_text is empty.
struct EventThe event description which must be passed to Traffic Monitor{ 
1: required EventClass evt_class, 
2: required string evt_service, 
3: optional list<Attribute> evt_attributes, 
4: required list<Identity> evt_senders, 
5: required list<Identity> evt_receivers 
6: required list<EventData> evt_data, 
8: optional list<ChatMessage> evt_messages, 
7: optional list<ItemLink> evt_links 
} 

where
evt_class is the event class; 
evt_service is the event service; 
evt_attributes are the event attributes; 
evt_senders are the event senders; 
evt_receivers are the event recipients; 
evt_data is the event data; 
evt_messages are the event messages for the "Chat" class; 
evt_links are connections between entities in the event.
struct CredentialsA structure which describes parameters of access to Traffic Monitor{ 
1: required string company_name, 
2: required string token 
} 

where
company_name is the name of the client (or company in our case). This parameter connects the plugin of an external developer with the license; 
token is an authorization token. This string is a "secret" known to the plugin and Traffic Monitor. The authorization of the data source is implemented in this way.